username@email.com
2025-05-15 6fe02a16e55f17e45a3997171e1b2284d45af25b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using CY.BLL;
using CY.Model;
using CY.Infrastructure.Query;
using CY.Infrastructure.Common;
using CY.BLL.Sys;
using CY.BLL.OA;
using CY.BLL.EC;
using CY.BLL.Inquiry;
using CY.Model.Inquiry;
 
namespace CY.WebForm.Pages.financial
{
    public partial class OrderFinancialPrint : BasePage
    {
        EC_OrderBasicBLL _eC_OrderBasicBLL = null;
        OA_StaffBLL bll_OA_StaffBLL = null;
 
        public string ssshtml = "";
 
        //初始化
        public OrderFinancialPrint()
        {
 
            _eC_OrderBasicBLL = new EC_OrderBasicBLL();
            bll_OA_StaffBLL = new OA_StaffBLL();
 
        }
        protected void Page_Load(object sender, EventArgs e)
        {
 
            if (!IsPostBack)
            {
 
 
 
 
 
                BindList();
 
            }
        }
 
        //绑定列表
        private void BindList()
        {
 
            Pagination pa = new Pagination();
            pa.PageSize = 10000;
            pa.PageIndex = 1;
 
           
 
            Dictionary<int, object> searchParam = new Dictionary<int, object>();
            Guid customeid = MyConvert.ConvertToGuid(Request["customeid"]);
            if (!Guid.Empty.Equals(customeid))
                SetParamValue(searchParam, 0, customeid);
            SetParamValue(searchParam, 1, CurrentUser.MemberId);
            SetParamValue(searchParam, 2, Request["txtOrderId"].ToString2());
            SetParamValue(searchParam, 3, Request["txtCustormerName"].ToString2());
            SetParamValue(searchParam, 4, Request["txtBeginData"].ToString2());
            SetParamValue(searchParam, 5, Request["txtEndDate"].ToString2());
            SetParamValue(searchParam, 6, Request["selPrintTypes"].ToString2());
            SetParamValue(searchParam, 7, Request["selOrderTypes"].ToString2());
            SetParamValue(searchParam, 8, Request["selOrderStates"].ToString2());
            SetParamValue(searchParam, 9, Request["selPayStates"].ToString2());
            SetParamValue(searchParam, 10, Request["txtCreaterName"].ToString2());
            SetParamValue(searchParam, 11, Request["selCustormerLevels"].ToString2());
            SetParamValue(searchParam, 12, Request["selAccountManagerId"].ToString2());
            SetParamValue(searchParam, 13, Request["selBusinessManagerId"].ToString2());
 
            
 
 
             
 
            List<EC_OrderBasic> result = _eC_OrderBasicBLL.SelectModelPage_Financial(pa, searchParam).ToList();
 
 
            int aaa = 1;
 
            //List<OA_DeliverPlan> oA_DeliverPlans1 = oA_DeliverPlans.OrderBy(x => x.DriverId).ThenBy(x => x.Sort).ToList();
            ssshtml = "";
            ssshtml += "<div class=\"printtable printtable1\"> <table   border=\"1\" cellpadding=\"0\" cellspacing=\"0\" style=\"border:0;\">";
            ssshtml += "<tr><th style=\"width:2%;\">编号</th><th style=\"text-align:center;\"width=\"7%\">订单号</th><th width=\"20%\">印件名称</th><th width=\"15%\">客户名称</th><th style=\"text-align:center;\"width=\"5%\">印刷类别</th><th width=\"5%\">订单状态</th><th width=\"5%\">支付状态</th><th width=\"5%\">订单类型</th><th width=\"5%\">印刷数量</th><th width=\"5%\">金额</th><th width=\"5%\">已收款</th><th width=\"5%\">未收款</th></tr>";
            for (int i = 0; i < result.Count; i++)
            {
 
 
 
 
                ssshtml += "<tr><td>" + (i+1) + "</td><td>" + result[i].SellerOrderId + "</td><td>" + result[i].DocumentName + "</td><td>" + result[i].BuyerName + "</td><td>" + result[i].PrintType.PrintName + "</td><td>" + result[i].OrderStateObj.Name + "</td><td>" + result[i].PayStateObj.Name + "</td><td>" + result[i].OrderType.Name + "</td><td>" + result[i].OrderExtend.PrintNum + " </td><td>" + result[i].SumPrice + "</td><td>" + result[i].TradingSingle.PayedMoney + "</td><td>" + result[i].UnPayedMoney + "</td></tr>";
 
 
 
 
            }
            ssshtml += "</table></div>";
 
            // this.RepClientList.DataSource =
            //this.RepClientList.DataBind();
            //UCPager1.AspNetPager.RecordCount = pa.RecordCount;
        }
 
        /// <summary>
        /// 设置查询参数方法
        /// </summary>
        /// <param name="target">设置目标</param>
        /// <param name="key">键</param>
        /// <param name="value">值</param>
        private static void SetParamValue(Dictionary<int, object> target, int key, object value)
        {
            if (string.IsNullOrEmpty(string.Format("{0}", value)))
                return;
            else
            {
            }
 
            if (target.ContainsKey(key))
            {
                target[key] = value;
            }
            else
            {
                target.Add(key, value);
            }
        }
    }
}