<%@ Page Title="" Language="C#" MasterPageFile="~/Master/UserMaster.master" CodeBehind="ReceiveList.aspx.cs" Inherits="WAP2P.Web.PC.User.Loan.ReceiveList" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="content" runat="server">
    <div class="m-userbox">
        <dl class="ui-tab">
            <dt><a href="javascript:void(0);" class="on">我的债权</a></dt>
            <dt><a href="TransferList<% =PageExt %>">正在转让的债权</a></dt>
            <dt><a href="TransferBidList<% =PageExt %>">债权变更记录</a></dt>
            <dd>
                <div class="m-prompt pl10 pr10 mt20">
                    <div class="prompt-left g-left mt10">
                        联系专属客服：<div class="mt10 fs14 g-fcenter"><% =CurrentUser.GetService() %></div>
                    </div>
                    <div class="prompt-small g-right">
                        <p>成功的投资后及转换为您所拥有的债权，在债权到期前30天内，您可以对债权进行转让，转让当日的收益归您所有，还款当日不可转让。</p>
                        <p>详细情况具体请查看 <a target="_blank" href="/Help/">帮助中心</a>。</p>
                    </div>
                </div>
                <table class="table-normal mt25" width="100%">
                    <tr>
                        <th style="width:25%;">借款标题</th>
                        <th style="width:14%;">债权总额</th>
                        <th style="width:14%;">待收总额</th>
                        <th style="width:14%;">待收利息</th>
                        <th style="width:18%;">到期时间</th>                        
                        <th style="width:15%;">操作</th>
                    </tr>
                    <ruson:Repater runat="server" ID="rptList">
                        <ItemTemplate>
                            <tr<%# Container.ItemIndex % 2 == 0 ? string.Empty : " class=\"alt\"" %>>
                                <td class="g-fleft"><a href="<%# WAP2P.Web.Extensions.GetBorrowUrl((long)Eval("BorrowId")) %>" target="_blank"><%# Eval("BorrowName") %></a></td>
                                <td class="fcred-3"><%# ((decimal)Eval("PrincipalSum")).ToMoneyString() %>元</td>
                                <td><%# ((decimal)Eval("WaitReceiveSum")).ToMoneyString() %>元</td>
                                <td><%# ((decimal)Eval("WaitInterestSum")).ToMoneyString() %>元</td>
                                <td><%# ((DateTime)Eval("EndAt")).ToDateTimeString() %></td>
                                <td>
                                    <%# Eval("Status") %><a href="javascript:void(0);" class="ml10" onclick="$.jPopupHtml($(this).next()[0].innerHTML, '分期明细', 1000);">分期明细</a>
                                    <script type="text/template">
                                        <table class="table-normal" width="100%" style="border-top:1px solid #fff;">
                                            <tr>
                                                <th width="5%">期数</th>
                                                <th width="8%">待收本金</th>
                                                <th width="8%">已收本金</th>
                                                <th width="8%">待收利息</th>
                                                <th width="8%">已收利息</th>
                                                <th width="8%">待收罚息</th>
                                                <th width="8%">已收罚息</th>
                                                <th width="10%">待收总额</th>
                                                <th width="10%">已收总额</th>
                                                <th width="10%">预计还款时间</th>
                                                <th width="10%">实际还款时间</th>
                                                <th width="7%">状态</th>
                                            </tr>
                                            <asp:Repeater runat="server" ID="rptDetail" ItemType="WAP2P.BorrowLoan.Receive">
                                                <ItemTemplate>
                                                    <tr>
                                                        <td><%# Item.Period %></td>
                                                        <td><%# Item.ShouldRepayPrincipal.ToMoneyString() %></td>
                                                        <td><%# Item.ActuaRepayPrincipal.ToMoneyString() %></td>
                                                        <td><%# Item.ShouldRepayInterest.ToMoneyString() %></td>
                                                        <td><%# Item.ActuaRepayInterest.ToMoneyString() %></td>
                                                        <td><%# Item.ShouldRepayOverdue.ToMoneyString() %></td>
                                                        <td><%# Item.ActuaRepayOverdue.ToMoneyString() %></td>
                                                        <td><%# (Item.ShouldRepayPrincipal + Item.ShouldRepayInterest + Item.ShouldRepayOverdue).ToMoneyString() %></td>
                                                        <td><%# (Item.ActuaRepayPrincipal + Item.ActuaRepayInterest + Item.ActuaRepayOverdue).ToMoneyString() %></td>
                                                        <td><%# Item.ShouldRepayAt.ToDateString() %></td>
                                                        <td><%# Item.ActualRepayAt.ToDateString() %></td>
                                                        <td><%# (bool)Eval("Settle") ? "已还款" : "还款中" %></td>
                                                    </tr>
                                                </ItemTemplate>                                                
                                            </asp:Repeater>                                            
                                        </table>
                                    </script>
                                </td>
                            </tr>
                        </ItemTemplate>
                        <EmptyTemplate>
                            <tr>
                                <td class="g-fleft" colspan="6">暂无数据。</td>
                            </tr>
                        </EmptyTemplate>
                    </ruson:Repater>
                </table>
            </dd>
        </dl>
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="script" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="list" runat="server">
</asp:Content>
