From b63e4e9f97aba58867a01b85e7d128b6eb738a0a Mon Sep 17 00:00:00 2001
From: username@email.com <yzy2002yzy@163.com>
Date: 星期四, 09 十月 2025 09:48:50 +0800
Subject: [PATCH] 请示类别要增加 维修申请 维修付款申请
---
CY_ECommercePlatform/CY.WebForm/Pages/business/DeliverWork.aspx.cs | 191 +++++++++++++++++++++++++++--------------------
1 files changed, 110 insertions(+), 81 deletions(-)
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/DeliverWork.aspx.cs b/CY_ECommercePlatform/CY.WebForm/Pages/business/DeliverWork.aspx.cs
index 227855c..818a63a 100644
--- a/CY_ECommercePlatform/CY.WebForm/Pages/business/DeliverWork.aspx.cs
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/DeliverWork.aspx.cs
@@ -17,20 +17,20 @@
private EC_OrderBasicBLL _eC_OrderBasicBLL = new EC_OrderBasicBLL();
private Sys_DictionaryBLL _bll_Sys_DictionaryBLL = new Sys_DictionaryBLL();
private EC_AcceptWayByOrderBLL _AcceptWayByOrderBLL = new EC_AcceptWayByOrderBLL();
- public int orderId
- {
- get
- {
- if (Request["id"] != null)
- {
- return Request["id"].ToString().ToInt32().Value;
- }
- else
- {
- return 0;
- }
- }
- }
+ //public int orderId
+ //{
+ // get
+ // {
+ // if (Request["id"] != null)
+ // {
+ // return Request["id"].ToString().ToInt32().Value;
+ // }
+ // else
+ // {
+ // return 0;
+ // }
+ // }
+ //}
/// <summary>
/// 缁戝畾鏀惰揣鏂瑰紡
@@ -50,16 +50,21 @@
if (!IsPostBack)
{
BindAcceptType();
- if (orderId != 0)
- {
- EC_AwbInfo model = _eC_OrderBasicBLL.SelectAwbInfoById(orderId);
+
+ List<EC_OrderBasic> m_EC_OrderBasicList = _eC_OrderBasicBLL.GetEC_OrderBasicListByKeyid(Request["ids"].ToString2().Trim(','), CurrentUser.MemberId) as List<EC_OrderBasic>;
+ this.RepClientList.DataSource = m_EC_OrderBasicList;
+ this.RepClientList.DataBind();
+
+
+ EC_AwbInfo model = _eC_OrderBasicBLL.SelectAwbInfoById(m_EC_OrderBasicList[0].Keyid.Value);
if (model != null)
{
this.txtTheAwb.Text = model.TheAwb;
this.txtDeliverPerson.Text = model.DeliverPerson;
if (model.DeliverTime.HasValue)
this.txtDeliverTime.Text = model.DeliverTime.Value.ToShortDateString();
- this.txtRemark.Text = model.Remark;
+ this.txtSonghuoJine.Value = model.SonghuoJine.HasValue? model.SonghuoJine.Value.ToString("0.0000"):"0";
+ this.txtRemark.Text = model.Remark;
this.ddlAcceptType.SelectedValue = model.AcceptTypeId.ToString();
switch (model.AcceptTypeId)
{
@@ -86,7 +91,7 @@
else
{
this.txtDeliverTime.Text = DateTime.Now.ToShortDateString();
- EC_AcceptWayByOrder acceptWayByOrder = _AcceptWayByOrderBLL.GetModelByTargetId(orderId);
+ EC_AcceptWayByOrder acceptWayByOrder = _AcceptWayByOrderBLL.GetModelByTargetId(m_EC_OrderBasicList[0].Keyid.Value);
if (acceptWayByOrder != null)
{
this.ddlAcceptType.SelectedValue = acceptWayByOrder.AcceptTypeId.ToString();
@@ -118,7 +123,7 @@
}
}
}
- }
+
}
}
@@ -127,76 +132,100 @@
protected void btnSubmit_Click(object sender, EventArgs e)
{
bool isSuccess = false;
- EC_AwbInfo eC_AwbInfo = new EC_AwbInfo();
- eC_AwbInfo.Keyid = orderId;
- eC_AwbInfo.TheAwb = this.txtTheAwb.Text;
- eC_AwbInfo.DeliverPerson = this.txtDeliverPerson.Text;
- if (this.txtDeliverTime.Text != string.Empty)
- eC_AwbInfo.DeliverTime = this.txtDeliverTime.Text.ToDateTime2();
+ string[] ids = Request["ids"].ToString2().Trim(',').Split(',');
- eC_AwbInfo.AcceptTypeId = ddlAcceptType.SelectedValue.ToString().ToInt32().Value;
- switch (eC_AwbInfo.AcceptTypeId)
+ foreach (var item in ids)
{
- case 104:
- eC_AwbInfo.AppointCourierCompany = string.Empty;
- eC_AwbInfo.FetchAddress = string.Empty;
- eC_AwbInfo.FetchContacts = string.Empty;
- eC_AwbInfo.FetchPhoneNum = string.Empty;
- break;
- case 105:
- eC_AwbInfo.AppointCourierCompany = this.txtAppointCourierCompany.Text;
- eC_AwbInfo.FetchAddress = this.txtFetchAddress.Text;
- eC_AwbInfo.FetchContacts = this.txtFetchContacts.Text;
- eC_AwbInfo.FetchPhoneNum = this.txtFetchPhoneNum.Text;
- break;
- case 106:
- eC_AwbInfo.AppointCourierCompany = string.Empty;
- eC_AwbInfo.FetchAddress = string.Empty;
- eC_AwbInfo.FetchContacts = this.txtAcceptPerson.Text;
- eC_AwbInfo.FetchPhoneNum = this.txtAcceptPhoneNum.Text;
- break;
- case 107:
- eC_AwbInfo.AppointCourierCompany = this.txtAppointCourierCompany.Text;
- eC_AwbInfo.FetchAddress = this.txtFetchAddress.Text;
- eC_AwbInfo.FetchContacts = this.txtFetchContacts.Text;
- eC_AwbInfo.FetchPhoneNum = this.txtFetchPhoneNum.Text;
- break;
+ EC_AwbInfo eC_AwbInfo = new EC_AwbInfo();
+ eC_AwbInfo.Keyid = item.ToInt32();
+ eC_AwbInfo.TheAwb = this.txtTheAwb.Text;
+ eC_AwbInfo.DeliverPerson = this.txtDeliverPerson.Text;
+ if (this.txtDeliverTime.Text != string.Empty)
+ eC_AwbInfo.DeliverTime = this.txtDeliverTime.Text.ToDateTime2();
+ eC_AwbInfo.SonghuoJine = this.txtSonghuoJine.Value.ToDecimal2();
+ eC_AwbInfo.AcceptTypeId = ddlAcceptType.SelectedValue.ToString().ToInt32().Value;
+ switch (eC_AwbInfo.AcceptTypeId)
+ {
+ case 104:
+ eC_AwbInfo.AppointCourierCompany = string.Empty;
+ eC_AwbInfo.FetchAddress = string.Empty;
+ eC_AwbInfo.FetchContacts = string.Empty;
+ eC_AwbInfo.FetchPhoneNum = string.Empty;
+ break;
+ case 105:
+ eC_AwbInfo.AppointCourierCompany = this.txtAppointCourierCompany.Text;
+ eC_AwbInfo.FetchAddress = this.txtFetchAddress.Text;
+ eC_AwbInfo.FetchContacts = this.txtFetchContacts.Text;
+ eC_AwbInfo.FetchPhoneNum = this.txtFetchPhoneNum.Text;
+ break;
+ case 106:
+ eC_AwbInfo.AppointCourierCompany = string.Empty;
+ eC_AwbInfo.FetchAddress = string.Empty;
+ eC_AwbInfo.FetchContacts = this.txtAcceptPerson.Text;
+ eC_AwbInfo.FetchPhoneNum = this.txtAcceptPhoneNum.Text;
+ break;
+ case 107:
+ eC_AwbInfo.AppointCourierCompany = this.txtAppointCourierCompany.Text;
+ eC_AwbInfo.FetchAddress = this.txtFetchAddress.Text;
+ eC_AwbInfo.FetchContacts = this.txtFetchContacts.Text;
+ eC_AwbInfo.FetchPhoneNum = this.txtFetchPhoneNum.Text;
+ break;
+ }
+ eC_AwbInfo.Remark = this.txtRemark.Text;
+ eC_AwbInfo.Operate.OrderId = eC_AwbInfo.Keyid;
+ eC_AwbInfo.Operate.Remark = eC_AwbInfo.Remark;
+ eC_AwbInfo.Operate.Operator = CurrentUser.ShortName;
+ //int orderState = Request["OrderState"].ToString().ToInt32().Value;
+ var order = _eC_OrderBasicBLL.SelectModelById(item.ToInt32().Value);
+ int orderState = order.OrderState.Value;
+ if (orderState == -1)
+ {
+ eC_AwbInfo.Operate.OperateType = -1;
+ }
+ else if (this.radDeliverType.SelectedValue == "1")
+ {
+ eC_AwbInfo.Operate.OperateType = 5;
+ }
+ else
+ {
+ eC_AwbInfo.Operate.OperateType = 4;
+ }
+
+ isSuccess = _eC_OrderBasicBLL.DeliverPresswork(eC_AwbInfo);
+ if (isSuccess)
+ {
+ EC_OrderBasic m_EC_OrderBasic_Out = _eC_OrderBasicBLL.SelectFromOutOrderById(eC_AwbInfo.Keyid.ToInt32() ?? 0);
+ if (m_EC_OrderBasic_Out != null)
+ {
+ EC_AwbInfo m_EC_AwbInfoOut = new EC_AwbInfo();
+ m_EC_AwbInfoOut = eC_AwbInfo;
+ m_EC_AwbInfoOut.Keyid = m_EC_OrderBasic_Out.Keyid;
+ m_EC_AwbInfoOut.Operate.OrderId = eC_AwbInfo.Keyid;
+ isSuccess = _eC_OrderBasicBLL.DeliverPresswork(m_EC_AwbInfoOut);
+ if (!isSuccess)
+ {
+ JavaScript.MessageBox("鎿嶄綔澶辫触", this);
+ }
+ }
+
+ }
+ else
+ {
+ JavaScript.MessageBox("鎿嶄綔澶辫触", this);
+ }
}
- eC_AwbInfo.Remark = this.txtRemark.Text;
- eC_AwbInfo.Operate.OrderId = eC_AwbInfo.Keyid;
- eC_AwbInfo.Operate.Remark = eC_AwbInfo.Remark;
- eC_AwbInfo.Operate.Operator = CurrentUser.ShortName;
- int orderState = Request["OrderState"].ToString().ToInt32().Value;
- if (orderState == -1)
- {
- eC_AwbInfo.Operate.OperateType = -1;
- }
- else if (this.radDeliverType.SelectedValue == "1")
- {
- eC_AwbInfo.Operate.OperateType = 5;
- }
- else
- {
- eC_AwbInfo.Operate.OperateType = 4;
- }
+
+
- isSuccess = _eC_OrderBasicBLL.DeliverPresswork(eC_AwbInfo);
+
+
if (isSuccess)
{
- EC_OrderBasic m_EC_OrderBasic_Out = _eC_OrderBasicBLL.SelectFromOutOrderById(eC_AwbInfo.Keyid.ToInt32() ?? 0);
- if (m_EC_OrderBasic_Out != null)
- {
- EC_AwbInfo m_EC_AwbInfoOut = new EC_AwbInfo();
- m_EC_AwbInfoOut = eC_AwbInfo;
- m_EC_AwbInfoOut.Keyid = m_EC_OrderBasic_Out.Keyid;
- m_EC_AwbInfoOut.Operate.OrderId = eC_AwbInfo.Keyid;
- isSuccess = _eC_OrderBasicBLL.DeliverPresswork(m_EC_AwbInfoOut);
- }
- JavaScript.MessageBox("鎿嶄綔鎴愬姛", this,true,true);
+ JavaScript.MessageBox("鎿嶄綔鎴愬姛", this, true, true);
}
else
{
- JavaScript.MessageBox("鎿嶄綔澶辫触",this);
+ JavaScript.MessageBox("鎿嶄綔澶辫触", this);
}
}
}
--
Gitblit v1.9.1