| | |
| | | using CY.Model.Inquiry; |
| | | using CY.BLL.OA; |
| | | using CY.SQLDAL; |
| | | using CY.BLL.Inquiry; |
| | | |
| | | namespace CY.WebForm.Pages.business |
| | | { |
| | |
| | | public string shukuanhuaceneiye4 = ""; |
| | | public string shukuanhuaceneiye5 = ""; |
| | | public string PrintTypeId = ""; |
| | | |
| | | AfterParameterInfoBLL _afterParameterInfoBLL = null; |
| | | //初始化 |
| | | public AgSpecialOrderEdit() |
| | | { |
| | |
| | | bll_OA_InventoryBLL = new OA_InventoryBLL(); |
| | | bll_OA_OutOfStorageBLL = new OA_OutOfStorageBLL(); |
| | | bll_EC_CuttingPaperSpecBLL = new EC_CuttingPaperSpecBLL(); |
| | | _afterParameterInfoBLL = new AfterParameterInfoBLL(); |
| | | } |
| | | |
| | | //页面加载 |
| | |
| | | this.RepClientList.DataSource = m_EC_SpecialForumsList; |
| | | this.RepClientList.DataBind(); |
| | | |
| | | List<EC_SpecialHoudaos> m_EC_SpecialHoudaosList = bll_EC_SpecialOrdersBLL.GetEC_SpecialHoudaosListByKeyid(m_EC_SpecialOrders.Keyid) as List<EC_SpecialHoudaos>; |
| | | if (m_EC_SpecialHoudaosList == null || m_EC_SpecialHoudaosList.Count == 0) |
| | | { |
| | | m_EC_SpecialHoudaosList = new List<EC_SpecialHoudaos>(); |
| | | EC_SpecialHoudaos m_EC_SpecialHoudaos = new EC_SpecialHoudaos(); |
| | | m_EC_SpecialHoudaosList.Add(m_EC_SpecialHoudaos); |
| | | |
| | | } |
| | | |
| | | var ssssss = _inquiryCommonModel.AfterWorkList; |
| | | var inquiryInsideModels = _inquiryCommonModel.InquiryInsideList; |
| | | foreach (var c_SpecialHoudaos in m_EC_SpecialHoudaosList) |
| | | { |
| | | List<int> houdaolist = new List<int>(); |
| | | string select = "<option value=''>无</option>"; |
| | | if (ssssss != null && ssssss.Count > 0) |
| | | { |
| | | if (_eC_OrderBasic.PrintTypeId != 27) |
| | | { |
| | | foreach (var aaaaa in ssssss) |
| | | { |
| | | houdaolist.Add(aaaaa); |
| | | } |
| | | } |
| | | } |
| | | if (inquiryInsideModels != null && inquiryInsideModels.Count > 0) |
| | | { |
| | | foreach (var inquiryInsideModel in inquiryInsideModels) |
| | | { |
| | | var afterWorkList = inquiryInsideModel.AfterWorkList; |
| | | if (afterWorkList != null && afterWorkList.Count > 0) |
| | | { |
| | | foreach (var aaaaa in afterWorkList) |
| | | { |
| | | houdaolist.Add(aaaaa); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | var sysInquiry_Afters = _afterParameterInfoBLL.GetModelList().Where(x => houdaolist.Contains(x.KeyId)).ToList(); |
| | | if (sysInquiry_Afters != null && sysInquiry_Afters.Count > 0) |
| | | { |
| | | foreach (var item in sysInquiry_Afters) |
| | | { |
| | | if (item.ParameterName == c_SpecialHoudaos.PSF_Houdaogongxu) |
| | | { |
| | | select += "<option value='" + item.ParameterName + "' selected=\"selected\" >" + item.ParameterName + "</option>"; |
| | | } |
| | | else |
| | | { |
| | | select += "<option value='" + item.ParameterName + "'>" + item.ParameterName + "</option>"; |
| | | } |
| | | |
| | | } |
| | | } |
| | | if (_eC_OrderBasic.PrintTypeId == 29 || _eC_OrderBasic.PrintTypeId == 27) |
| | | { |
| | | if (_inquiryCommonModel.JTWZ == c_SpecialHoudaos.PSF_Houdaogongxu) |
| | | { |
| | | select += "<option value='" + _inquiryCommonModel.JTWZ + "' selected=\"selected\" >" + _inquiryCommonModel.JTWZ + "</option>"; |
| | | } |
| | | else |
| | | { |
| | | select += "<option value='" + _inquiryCommonModel.JTWZ + "' >" + _inquiryCommonModel.JTWZ + "</option>"; |
| | | } |
| | | |
| | | |
| | | } |
| | | c_SpecialHoudaos.PSF_Houdaogongxu = select; |
| | | } |
| | | |
| | | this.RepeaterHoudaoList.DataSource = m_EC_SpecialHoudaosList; |
| | | this.RepeaterHoudaoList.DataBind(); |
| | | |
| | | |
| | | |
| | | |
| | | //获取开料尺寸 |
| | | EC_CuttingPaperSpec model = new EC_CuttingPaperSpec(); |
| | | //model = bll_EC_CuttingPaperSpecBLL.SelectListByMemberIdAndParType(CurrentUser.MemberId, "小全开"); |
| | |
| | | string[] PSF_PrintedColorRear = Request["PSF_PrintedColorRear"].ToString2().Split(','); |
| | | string[] PSF_Typesetting = Request["PSF_Typesetting"].ToString2().Split(','); |
| | | string[] PSF_Typesettinghide = Request["PSF_Typesettinghide"].ToString2().Split(','); |
| | | string[] PSF_Fabantaoshu = Request["PSF_Fabantaoshu"].ToString2().Split(','); |
| | | string[] PSF_PrintedCount = Request["PSF_PrintedCount"].ToString2().Split(','); |
| | | string[] PSF_PrintedPositive = Request["PSF_PrintedPositive"].ToString2().Split(','); |
| | | string[] PSF_LastNum = Request["PSF_LastNum"].ToString2().Split(','); |
| | |
| | | string[] oldPSF_PaperId = Request["oldPSF_PaperId"].ToString2().Split(','); |
| | | string[] oldPSF_BigPaperCount = Request["oldPSF_BigPaperCount"].ToString2().Split(','); |
| | | |
| | | |
| | | string[] selHoudaogongxu = Request["selHoudaogongxu"].ToString2().Split(','); |
| | | string[] txtShuliang = Request["txtShuliang"].ToString2().Split(','); |
| | | string[] txtBeishu = Request["txtBeishu"].ToString2().Split(','); |
| | | string[] txtJichang = Request["txtJichang"].ToString2().Split(','); |
| | | string[] txtYaoqiu = Request["txtYaoqiu"].ToString2().Split(','); |
| | | |
| | | //if (PSF_Forumsid.Length != PSF_Component.Length || PSF_Forumsid.Length != PSF_PNum.Length || PSF_Forumsid.Length != PSF_PressesDesk.Length || PSF_Forumsid.Length != PSF_PrintedColorPositive.Length || PSF_Forumsid.Length != PSF_PrintedColorRear.Length || PSF_Forumsid.Length != PSF_Typesetting.Length || PSF_Forumsid.Length != PSF_PrintedCount.Length || PSF_Forumsid.Length != PSF_PrintedPositive.Length || PSF_Forumsid.Length != PSF_LastNum.Length || PSF_Forumsid.Length != PSF_SheetSource.Length || PSF_Forumsid.Length != PSF_SpecificationsSheet.Length || PSF_Forumsid.Length != PSF_EditionCount.Length || PSF_Forumsid.Length != PSF_PaperSource.Length || PSF_Forumsid.Length != PSF_PaperId.Length || PSF_Forumsid.Length != PSF_PaperName.Length || PSF_Forumsid.Length != PSF_MaterialSpecifications.Length || PSF_Forumsid.Length != PSF_BigPaperCount.Length || PSF_Forumsid.Length != PSF_OpenSpecifications.Length || PSF_Forumsid.Length != PSF_OpenWidth.Length || PSF_Forumsid.Length != PSF_OpenLength.Length || PSF_Forumsid.Length != PSF_Note.Length) |
| | | //{ |
| | | // JavaScript.MessageBox("提交失败", this); |
| | |
| | | List<EC_SpecialForums> m_EC_SpecialForumsList = new List<EC_SpecialForums>(); |
| | | List<OA_Inventory> m_OA_InventoryList = new List<OA_Inventory>(); |
| | | List<OA_OutOfStorage> m_OA_OutOfStorageList = new List<OA_OutOfStorage>(); |
| | | List<EC_SpecialHoudaos> m_EC_SpecialHoudaosList = new List<EC_SpecialHoudaos>(); |
| | | |
| | | for (int i = 0; i < PSF_Forumsid.Length; i++) |
| | | { |
| | |
| | | m_EC_SpecialForums.PSF_Typesetting = PSF_Typesetting[i].ToString2().Replace(",+-+,", ","); |
| | | } |
| | | |
| | | |
| | | m_EC_SpecialForums.PSF_Fabantaoshu = PSF_Fabantaoshu[i]; |
| | | if (PSF_PrintedCount[i].ToInt32() == null) |
| | | { |
| | | m_EC_SpecialForums.PSF_PrintedCount = 0; |
| | |
| | | m_EC_SpecialForums.PSF_CTPSpecType = selFilmSpec[i].ToString2().Replace(",+-+,", ","); |
| | | m_EC_SpecialForums.PSF_CTPCount = 0; |
| | | } |
| | | m_EC_SpecialForums.PSF_CTPSpecType = CTPSpecName[i].ToString2().Replace(",+-+,", ","); |
| | | |
| | | if (CTPCount[i].ToInt32() == null) |
| | | { |
| | | m_EC_SpecialForums.PSF_CTPCount = 0; |
| | | } |
| | | else |
| | | { |
| | | m_EC_SpecialForums.PSF_CTPCount = CTPCount[i].ToInt32(); |
| | | } |
| | | m_EC_SpecialForums.PSF_FilmType = ""; |
| | | m_EC_SpecialForums.PSF_PSSpec = PSF_PSBan[i].ToString2().Replace(",+-+,", ","); |
| | | if (PSCount[i].ToInt32() == null) |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | for (int i = 0; i < selHoudaogongxu.Length; i++) |
| | | { |
| | | EC_SpecialHoudaos m_EC_SpecialHoudaos = new EC_SpecialHoudaos(); |
| | | m_EC_SpecialHoudaos.PSF_Houdaogongxu = selHoudaogongxu[i].ToString2().Replace(",+-+,", ","); |
| | | m_EC_SpecialHoudaos.PSF_Shuliang = txtShuliang[i] ; |
| | | m_EC_SpecialHoudaos.PSF_Beishu = txtBeishu[i]; |
| | | m_EC_SpecialHoudaos.PSF_Jichang = txtJichang[i]; |
| | | m_EC_SpecialHoudaos.PSF_Yaoqiu = txtYaoqiu[i].Trim(); |
| | | if(!string.IsNullOrEmpty(m_EC_SpecialHoudaos.PSF_Houdaogongxu) |
| | | || !string.IsNullOrEmpty(m_EC_SpecialHoudaos.PSF_Shuliang) |
| | | || !string.IsNullOrEmpty(m_EC_SpecialHoudaos.PSF_Beishu) |
| | | || !string.IsNullOrEmpty(m_EC_SpecialHoudaos.PSF_Jichang) |
| | | || !string.IsNullOrEmpty(m_EC_SpecialHoudaos.PSF_Yaoqiu)){ |
| | | m_EC_SpecialHoudaosList.Add(m_EC_SpecialHoudaos); |
| | | } |
| | | } |
| | | |
| | | |
| | | m_EC_SpecialOrders.LastUpdateTime = DateTime.Now; |
| | | m_EC_SpecialOrders.Operator = CurrentUser.ShortName; |
| | | m_EC_SpecialOrders.PSO_Remarks = this.txtPSO_Remarks.InnerText; |
| | |
| | | if (m_EC_SpecialOrders.Keyid > 0) |
| | | { |
| | | |
| | | if (bll_EC_SpecialOrdersBLL.UpdateSpecialForums(m_EC_SpecialOrders, m_EC_SpecialForumsList, m_OA_InventoryList, m_OA_OutOfStorageList)) |
| | | if (bll_EC_SpecialOrdersBLL.UpdateSpecialForums(m_EC_SpecialOrders, m_EC_SpecialForumsList, m_OA_InventoryList, m_OA_OutOfStorageList, m_EC_SpecialHoudaosList)) |
| | | //JavaScript.MessageBox("操作成功", this); |
| | | JavaScript.RefreshDIVOpener(this); |
| | | else |
| | |
| | | m_OA_OrderWorkListRelation.RelationTypeId = 1; //专版1,合版2,后道外协3,整单外协4 |
| | | |
| | | //bll_EC_SpecialOrdersBLL.AddSpecialForums(m_EC_OrderOperate, m_EC_SpecialOrders, m_OA_OrderWorkListRelation, m_EC_SpecialForumsList, m_OA_InventoryList, m_OA_OutOfStorageList) |
| | | if (bll_EC_SpecialOrdersBLL.AddSpecialForums(m_EC_OrderOperate, m_EC_SpecialOrders, m_OA_OrderWorkListRelation, m_EC_SpecialForumsList, m_OA_InventoryList, m_OA_OutOfStorageList)) |
| | | if (bll_EC_SpecialOrdersBLL.AddSpecialForums(m_EC_OrderOperate, m_EC_SpecialOrders, m_OA_OrderWorkListRelation, m_EC_SpecialForumsList, m_OA_InventoryList, m_OA_OutOfStorageList, m_EC_SpecialHoudaosList)) |
| | | { |
| | | //JavaScript.MessageBox("操作成功", this); |
| | | JavaScript.RefreshDIVOpener(this); |