username@email.com
2025-05-14 99ddfbcecf0fa2881eb3a91028257eef87dab6de
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
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using CY.Model;
using CY.BLL;
using CY.Infrastructure.Common;
using CY.BLL.Sys;
 
namespace CY.WebForm.Pages.front
{
    //吴辉
    //印刷顾问-印刷垫资
    public partial class PC_Loaning : FrontBasePage
    {
        SysInquiry_PrintingTypeBLL bll_SysInquiry_PrintingTypeBLL = null;
        EC_PrintingConsultancyBLL bll_EC_PrintingConsultancyBLL = null;
        Sys_DictionaryBLL bll_Sys_DictionaryBLL = null;
 
        //初始化
        public PC_Loaning()
        {
            bll_EC_PrintingConsultancyBLL = new EC_PrintingConsultancyBLL();
            bll_SysInquiry_PrintingTypeBLL = new SysInquiry_PrintingTypeBLL();
            bll_Sys_DictionaryBLL = new Sys_DictionaryBLL();
        }
 
        //页面加载
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                this.txtPeople.Value = CurrentMemberExtend.BusinessContacts;
                this.txtPhone.Value = CurrentMemberExtend.PhoneNum;
            }
            this.selHope.DataSource = bll_Sys_DictionaryBLL.GetDataByType("印刷顾问垫资周期");
            this.selHope.DataValueField = "Name";
            this.selHope.DataTextField = "Name";
            this.selHope.DataBind();
        }
 
        //提交事件
        protected void btn_submit_form(object sender, EventArgs e)
        {
            try
            {
                EC_PrintingConsultancy m_EC_PrintingConsultancy = new EC_PrintingConsultancy();
                m_EC_PrintingConsultancy.PC_Type = "印刷垫资";
                m_EC_PrintingConsultancy.Memberid = CurrentUser.MemberId;
                m_EC_PrintingConsultancy.PC_People = this.txtPeople.Value.ToString2();
                m_EC_PrintingConsultancy.PC_Phone = this.txtPhone.Value.ToString2();
                m_EC_PrintingConsultancy.PC_HopeMoney = this.selHope.Value.ToString2();
                m_EC_PrintingConsultancy.PC_Remark = this.txtPC_Remark.Value.ToString2();
                m_EC_PrintingConsultancy.PC_Price = this.txtPC_Price.Value.ToString2();
                m_EC_PrintingConsultancy.PC_Content = this.txtPayYear.Value.ToString2();
                m_EC_PrintingConsultancy.PC_Status = "已提交";
                m_EC_PrintingConsultancy.LastUpdateTime = DateTime.Now;
                m_EC_PrintingConsultancy.Operator = CurrentUser.ShortName;
                if (bll_EC_PrintingConsultancyBLL.InsertModel(m_EC_PrintingConsultancy))
                {
                    this.txtPayYear.Value = "";
                    this.selHope.Value = "";
                    this.txtPC_Price.Value = "";
                    JavaScript.MessageBox("提交成功,请等待回复", this, "window.location.href = '/adviser/loaning.html'");
                }
                else
                {
                    JavaScript.MessageBox("提交失败,请稍后再试", this);
                }
            }
            catch (Exception ex)
            {
                PAGEHandleException(ex);
                JavaScript.MessageBox("操作失败", this);
            }
        }
    }
}