<%@ Page Title="" Language="C#" MasterPageFile="~/Master/UserMaster.master" CodeBehind="TransferList.aspx.cs" Inherits="WAP2P.Web.PC.User.Loan.TransferList" %>
<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="ReceiveList<% =PageBase.PageExt %>">我的债权</a></dt>
            <dt><a href="javascript:void(0);" class="on">正在转让的债权</a></dt>
            <dt><a href="TransferBidList<% =PageBase.PageExt %>">债权变更记录</a></dt>
            <dd>
                <form action="?action=search" method="get" class="search">
                    <table class="m-filter mt20 js-filter">
                        <tr class="filter-date">
                            <th style="width: 12%;">日期范围</th>
                            <td>
                                <input type="text" class="text w130 ui-date" name="startAt" id="startAt" value="<% =Request.QueryString["startAt"].UrlEncode() %>" data-maxdate="#endAt" />
                                <span>-</span>
                                <input type="text" class="text w130 ui-date" name="endAt" id="endAt" value="<% =Request.QueryString["endAt"].UrlEncode() %>" data-mindate="#startAt" data-maxdate="<%= DateTime.Now.AddDays(1).ToDateString() %>" />
                                <a href="javascript:void(0);" data-filter-to="#startAt|#endAt" data-filter-value="<%= DateTime.Now.AddDays(-7).ToDateString() %>|<%= DateTime.Now.AddDays(1).ToDateString() %>">近一周</a>
                                <a href="javascript:void(0);" data-filter-to="#startAt|#endAt" data-filter-value="<%= DateTime.Now.AddMonths(-1).ToDateString() %>|<%= DateTime.Now.AddDays(1).ToDateString() %>">近一月</a>
                                <a href="javascript:void(0);" data-filter-to="#startAt|#endAt" data-filter-value="<%= DateTime.Now.AddMonths(-3).ToDateString() %>|<%= DateTime.Now.AddDays(1).ToDateString() %>">近三月</a>
                                <a href="javascript:void(0);" data-filter-to="#startAt|#endAt" data-filter-value="<%= DateTime.Now.AddYears(-1).ToDateString() %>|<%= DateTime.Now.AddDays(1).ToDateString() %>">近一年</a>
                            </td>
                        </tr>
                    </table>
                </form>
                <table class="table-normal mt20 js-ajaxlist" 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>
                </table>    
            </dd>
        </dl>
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="script" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="list" runat="server">
    <ruson:Repater runat="server" ID="rptList" ItemType="WAP2P.BorrowLoan.Transfer">
        <ItemTemplate>
            <tr id="tr<%# Item.Id %>" class="js-data">
                <td class="g-fleft"><a href="<%# WAP2P.Web.Extensions.GetTransferUrl(Item.Id) %>" target="_blank"><%# Item.Name %></a></td>
                <td class="fcred-3"><%# Item.Amount.ToMoneyString() %>元</td>
                <td class="<%# Item.UpDownAmount == Item.Amount ? string.Empty : Item.UpDownAmount > Item.Amount ? "fcred-3" : "fcgreen-3" %>"><%# Item.UpDownAmount.ToMoneyString() %>元</td>
                <td><%# Item.BidAmountCount.ToMoneyString() %>元</td>
                <td><%# Item.CreateAt.ToDateTimeString() %></td>
                <td><input type="button" value="撤销" class="js-action btn-small" data-action="?action=undo&id=<%# Item.Id %>" data-action-confirm="确定要撤销吗？" data-action-success="var tb = $('.js-ajaxlist'); $('#tr<%# Item.Id %>').remove(); if(tb.find('tr.js-data').length == 0) location.href = location.href;" /></td>
            </tr>
        </ItemTemplate>
        <EmptyTemplate>
            <tr>
                <td colspan="6" class="g-fleft">暂无数据。</td>
            </tr>
        </EmptyTemplate>
    </ruson:Repater>
    <tr class="pager">
        <td colspan="6">
            <div class="ui-pages g-fright">
                <ruson:Pager runat="server" ID="pages" CssClass="pages" />
                <a href="<% =Request.RawUrl.UrlEncodeParam() %>" class="g-hide"></a>
            </div>
        </td>
    </tr>
</asp:Content>
