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
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;
 
namespace CY.WebForm.Pages.sysglobal
{
    //吴辉
    //授信管理
    public partial class CreditLineLevelRuleConfig : BasePage
    {
        Pay_CreditLineLevelRuleBLL bll_Pay_CreditLineLevelRuleBLL = null;
 
        //初始化
        public CreditLineLevelRuleConfig()
        {
            bll_Pay_CreditLineLevelRuleBLL = new Pay_CreditLineLevelRuleBLL();
        }
 
        //页面加载
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                BindList();
            }
            if (Request["delete"]!=null && Request["delete"].ToInt32() > 0)
            {
                Pay_CreditLineLevelRule model = bll_Pay_CreditLineLevelRuleBLL.GetModel(Request["delete"].ToInt32());
                if (model != null && model.Keyid > 0)
                {
                    if (bll_Pay_CreditLineLevelRuleBLL.DeleteModel(model))
                        JavaScript.MessageBox("删除成功", this);
                    else
                        JavaScript.MessageBox("删除失败", this);
                    BindList();
                }
            }
        }
 
        /// <summary>
        /// 绑定数据
        /// </summary>
        private void BindList()
        {
            Pagination pa = new Pagination();
            pa.PageSize = 500;
            pa.PageIndex = 1;
            this.RepCreditLineList.DataSource = bll_Pay_CreditLineLevelRuleBLL.GetModelPageList(pa);
            this.RepCreditLineList.DataBind();
        }
 
        //分页事件
        protected void AspNetPager1_PageChanged(object src, EventArgs e)
        {
            BindList();
        }
    }
}