diff --git a/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx b/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx index 553a15f..78f8d24 100644 --- a/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx +++ b/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx @@ -28,7 +28,7 @@ EnableCollapse="false" EnableCheckBoxSelect="false" EmptyText="File not uploaded" DataIDField="id" OnRowCommand="Grid1_RowCommand"> - + diff --git a/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.cs b/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.cs index 90d8042..5fb510b 100644 --- a/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.cs +++ b/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.cs @@ -61,9 +61,20 @@ namespace FineUIPro.Web.AttachFile Session[sessionName] = null; ToKeyId = Request.QueryString["toKeyId"]; + if (!string.IsNullOrEmpty(Request.QueryString["strParam"])) + { + this.ToKeyId = this.ToKeyId + "#" + Request.QueryString["strParam"]; + } AttachPath = Request.QueryString["path"]; ParamStr = sessionName + "|" + AttachPath; MenuId = Request.QueryString["menuId"]; + + string t = Request.QueryString["type"]; + if (t == "-1") + { + this.Toolbar1.Hidden = true; + this.Grid1.Columns[4].Hidden = true; + } BindGrid(); } else diff --git a/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.designer.cs b/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.designer.cs index 15412c1..9651d7b 100644 --- a/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.designer.cs +++ b/FCL/FineUIPro.Web/AttachFile/webuploader2.aspx.designer.cs @@ -7,11 +7,13 @@ // //------------------------------------------------------------------------------ -namespace FineUIPro.Web.AttachFile { - - - public partial class webuploader2 { - +namespace FineUIPro.Web.AttachFile +{ + + + public partial class webuploader2 + { + /// /// form1 控件。 /// @@ -20,7 +22,7 @@ namespace FineUIPro.Web.AttachFile { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; - + /// /// PageManager1 控件。 /// @@ -29,7 +31,7 @@ namespace FineUIPro.Web.AttachFile { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.PageManager PageManager1; - + /// /// Grid1 控件。 /// @@ -38,7 +40,16 @@ namespace FineUIPro.Web.AttachFile { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Grid Grid1; - + + /// + /// Toolbar1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Toolbar Toolbar1; + /// /// btnSelectFiles 控件。 /// @@ -47,7 +58,7 @@ namespace FineUIPro.Web.AttachFile { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Button btnSelectFiles; - + /// /// btnDelete 控件。 /// @@ -56,7 +67,7 @@ namespace FineUIPro.Web.AttachFile { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Button btnDelete; - + /// /// btnSave 控件。 /// diff --git a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigation.aspx.cs b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigation.aspx.cs index c962631..23fc000 100644 --- a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigation.aspx.cs +++ b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigation.aspx.cs @@ -53,17 +53,10 @@ namespace FineUIPro.Web.ContractorQuality where Flag='2' "; List listStr = new List(); var role = BLL.Sys_RoleService.GetRole(CurrUser.RoleId); - var departleader = BLL.DepartService.GetDepartByLeader(this.CurrUser.UserId); - if (this.CurrUser.UserId == BLL.Const.GlyId || role.RoleName.Contains("Contractor_Leader") || role.RoleName.Contains("CTE/D Manager")) { this.rblState.Hidden = true; } - else if (departleader != null) - { - this.rblState.Hidden = true; - strSql += " and d.DepartLeader='" + this.CurrUser.UserId + "'"; - } else { if (rblState.SelectedValue == "1") diff --git a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx index 8e98ca4..2733606 100644 --- a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx +++ b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx @@ -54,6 +54,7 @@ + @@ -175,7 +176,8 @@ - + + @@ -276,7 +278,8 @@ - + + diff --git a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.cs b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.cs index 5146f62..33aa7f1 100644 --- a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.cs +++ b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.cs @@ -94,7 +94,7 @@ namespace FineUIPro.Web.ContractorQuality GroupPanel4.Hidden = false; GroupPanel5.Hidden = false; - var audit = BLL.PunishmentAuditService.GetAuditBypunishmentIdAndAuditMan(this.PunishmentId,this.CurrUser.UserId); + var audit = BLL.PunishmentAuditService.GetAuditBypunishmentIdAndAuditMan(this.PunishmentId, this.CurrUser.UserId); if (pun.IsPass == false && audit != null) { frMCNoPass.Hidden = false; @@ -123,7 +123,7 @@ namespace FineUIPro.Web.ContractorQuality } } } - else if(pun.SeType=="2")//物资 + else if (pun.SeType == "2")//物资 { fr1.Hidden = true; fr2.Hidden = true; @@ -174,7 +174,8 @@ namespace FineUIPro.Web.ContractorQuality this.btnSave.Hidden = false; this.btnSbumit.Hidden = false; this.btnNoPass.Hidden = false;//拒绝按钮 - GroupPanel1.Enabled = false; + //GroupPanel1.Enabled = false; + GroupPanel1Enabled(); GroupPanel2.Hidden = false; if (pun.SeType == "1")//服务 { @@ -239,7 +240,8 @@ namespace FineUIPro.Web.ContractorQuality } else if (pun.States == "2") //框架合同:主协调员办理,非框架合同:需求人办理 { - GroupPanel1.Enabled = false; + //GroupPanel1.Enabled = false; + GroupPanel1Enabled(); GroupPanel2.Hidden = false; GroupPanel2.Enabled = false; GroupPanel3.Hidden = false; @@ -292,20 +294,24 @@ namespace FineUIPro.Web.ContractorQuality } else if (pun.States == "3" && pun.IsFrame == true)//用户部门填写 { - GroupPanel1.Enabled = false; + //GroupPanel1.Enabled = false; + GroupPanel1Enabled(); GroupPanel2.Hidden = false; GroupPanel2.Enabled = false; - GroupPanel3.Enabled = false; + //GroupPanel3.Enabled = false; + GroupPanel3Enabled(); GroupPanel3.Hidden = false; GroupPanel4.Hidden = false; this.btnSbumit.Hidden = false; } else if (pun.States == "4" && pun.IsFrame == true)//合同管理员填写 { - GroupPanel1.Enabled = false; + //GroupPanel1.Enabled = false; + GroupPanel1Enabled(); GroupPanel2.Hidden = false; GroupPanel2.Enabled = false; - GroupPanel3.Enabled = false; + //GroupPanel3.Enabled = false; + GroupPanel3Enabled(); GroupPanel3.Hidden = false; GroupPanel4.Hidden = false; GroupPanel4.Enabled = false; @@ -314,7 +320,8 @@ namespace FineUIPro.Web.ContractorQuality } else if (pun.States == "5")//采购员填写 { - GroupPanel1.Enabled = false; + //GroupPanel1.Enabled = false; + GroupPanel1Enabled(); GroupPanel2.Hidden = false; GroupPanel2.Enabled = false; fr2.Hidden = true; @@ -325,7 +332,8 @@ namespace FineUIPro.Web.ContractorQuality if (pun.SeType == "1") { GroupPanel3.Hidden = false; - GroupPanel3.Enabled = false; + //GroupPanel3.Enabled = false; + GroupPanel3Enabled(); GroupPanel6.Hidden = false; fr1.Hidden = false; frNoFrame1.Hidden = false; @@ -339,7 +347,8 @@ namespace FineUIPro.Web.ContractorQuality frNoFrame2.Hidden = true; frWz.Hidden = false; GroupPanel7.Hidden = false; - GroupPanel7.Enabled = false; + //GroupPanel7.Enabled = false; + GroupPanel7Enabled(); GroupPanel6.Hidden = false; } } @@ -392,7 +401,7 @@ namespace FineUIPro.Web.ContractorQuality } if (pun.SeType == "2") { - this.txtContractor2.Text = pun.Contractor; + this.txtContractor2.Text = pun.Contractor; //this.txtContractor3.Text = pun.Contractor; } if (!string.IsNullOrEmpty(pun.ContractAdmin)) @@ -406,7 +415,7 @@ namespace FineUIPro.Web.ContractorQuality this.drpContractRequester.SelectedValue = pun.ContractRequester; } this.txtContractRequesterDep.Text = pun.ContractRequesterDep; - + if (!string.IsNullOrEmpty(pun.ViolationClauseId)) { if (pun.SeType == "1") @@ -431,7 +440,7 @@ namespace FineUIPro.Web.ContractorQuality this.txtCompany2.Text = pun.Company.HasValue ? pun.Company.ToString() : ""; } } - + this.txtIndividualPerson.Text = pun.IndividualPerson; this.txtIndividual.Text = pun.Individual.HasValue ? pun.Individual.ToString() : ""; if (!string.IsNullOrEmpty(pun.UserDep)) @@ -448,7 +457,7 @@ namespace FineUIPro.Web.ContractorQuality { this.txtNoFrameCompletionDate.Text = pun.CompletionDate.HasValue ? string.Format("{0:yyyy-MM-dd}", pun.CompletionDate) : ""; } - rblSeType.SelectedValue = pun.SeType == "2" ? "2" : "1"; + rblSeType.SelectedValue = pun.SeType == "2" ? "2" : "1"; if (!string.IsNullOrEmpty(pun.PVTRequester)) { this.drpPVTRequester.SelectedValue = pun.PVTRequester; @@ -477,6 +486,54 @@ namespace FineUIPro.Web.ContractorQuality } } } + + /// + /// 申报人填写不可编辑 + /// + protected void GroupPanel1Enabled() + { + txtPunishDate.Enabled = false; + txtLocation.Enabled = false; + txtDescription.Enabled = false; + txtViolation_Inspector.Enabled = false; + txtViolation_InspectorDep.Enabled = false; + txtMIContractor.Enabled = false; + Label3.Enabled = false; + lblAttach.Enabled = false; + btnAttach.Enabled = false; + lblTips.Enabled = false; + } + + /// + /// 主协调员填写不可编辑 + /// + protected void GroupPanel3Enabled() + { + drpViolationClause.Enabled = false; + drpViolationDegree.Enabled = false; + txtCompany.Enabled = false; + txtIndividualPerson.Enabled = false; + txtIndividual.Enabled = false; + drpUserDep.Enabled = false; + Label2.Enabled = false; + btnAttach2.Enabled = false; + Label6.Enabled = false; + } + + /// + /// PVT组长或请购人填写 + /// + protected void GroupPanel7Enabled() + { + drpBuyer2.Enabled = false; + drpViolationClause2.Enabled = false; + drpViolationDegree2.Enabled = false; + txtCompany2.Enabled = false; + txtFo.Enabled = false; + Label7.Enabled = false; + btnAttach3.Enabled = false; + Label8.Enabled = false; + } #endregion #region 保存、提交 @@ -618,7 +675,7 @@ namespace FineUIPro.Web.ContractorQuality { userId = pun.PVTRequester;//物资:发送给PVT小组组长 } - + var userTo = from x in Funs.DB.Sys_User where x.UserId.Contains(userId) && x.Email != null && x.Email != "" @@ -722,7 +779,7 @@ namespace FineUIPro.Web.ContractorQuality where ((x.PunishmentId == this.PunishmentId && x.AuditDate != null) || x.UserId.Contains(pun.Violation_Inspector)) && x.Email != null && x.Email != "" select x; - if (userCc!=null) + if (userCc != null) { mailCC = userCc.Select(x => x.Email).Distinct().ToArray(); } @@ -770,7 +827,7 @@ namespace FineUIPro.Web.ContractorQuality var emailTemplate = Funs.DB.SendEmailTemplate.Where(x => x.EmailName.Contains("合同需求人填写完成后通知")); if (emailTemplate.Count() > 0) - { + { var userTo = from x in Funs.DB.Sys_User where x.UserId.Contains(pun.Buyer) && x.Email != null && x.Email != "" select x; @@ -939,7 +996,7 @@ namespace FineUIPro.Web.ContractorQuality } var userCc = from x in Funs.DB.View_EMail_UserTo - where (x.PunishmentId == this.PunishmentId && x.AuditDate != null) + where (x.PunishmentId == this.PunishmentId && x.AuditDate != null) || (x.UserId.Contains(pun.Violation_Inspector)) && x.Email != null && x.Email != "" select x; @@ -1006,10 +1063,10 @@ namespace FineUIPro.Web.ContractorQuality { string departLeader = string.Empty; var user = BLL.Sys_UserService.GetUsersByUserId(pun.Violation_Inspector); - if (user!=null) + if (user != null) { var depart = BLL.DepartService.GetDepartById(user.DepartId); - if (depart!=null) + if (depart != null) { departLeader = depart.DepartLeader; } @@ -1294,7 +1351,7 @@ namespace FineUIPro.Web.ContractorQuality { punishment.States = "0";//申请人未提交 } - var att = from x in Funs.DB.AttachFile where x.ToKeyId == punishment.PunishmentId select x; + var att = from x in Funs.DB.AttachFile where x.ToKeyId == punishment.PunishmentId + "#1" select x; if (att.Count() > 0) { punishment.AttachUrl = att.First().AttachUrl; @@ -1574,7 +1631,7 @@ namespace FineUIPro.Web.ContractorQuality } #endregion - #region 附件上传 + #region 附件上传、查看 /// /// 相关附件上传 /// @@ -1586,7 +1643,17 @@ namespace FineUIPro.Web.ContractorQuality { this.hdId.Text = SQLHelper.GetNewID(typeof(Model.EMC_Punishment)); } - PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../AttachFile/webuploader2.aspx?type=0&toKeyId={0}&path=FileUpload/SES/EMC_Punishment&menuId={1}", this.hdId.Text, BLL.Const.IncidentInvestigationMenuId))); + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../AttachFile/webuploader2.aspx?type=0&toKeyId={0}&path=FileUpload/SES/EMC_Punishment&menuId={1}&strParam=1", this.hdId.Text, BLL.Const.IncidentInvestigationMenuId))); + } + + /// + /// 附件查看 + /// + /// + /// + protected void lbtnViewAttach_Click(object sender, EventArgs e) + { + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../AttachFile/webuploader2.aspx?type=-1&toKeyId={0}&path=FileUpload/SES/EMC_Punishment&menuId={1}&strParam=1", this.hdId.Text, BLL.Const.IncidentInvestigationMenuId))); } /// @@ -1600,7 +1667,17 @@ namespace FineUIPro.Web.ContractorQuality { this.hdId.Text = SQLHelper.GetNewID(typeof(Model.EMC_Punishment)); } - PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../AttachFile/webuploader2.aspx?type=0&toKeyId={0}&path=FileUpload/SES/EMC_Punishment&menuId={1}", this.hdId.Text, BLL.Const.IncidentInvestigationMenuId))); + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../AttachFile/webuploader2.aspx?type=0&toKeyId={0}&path=FileUpload/SES/EMC_Punishment&menuId={1}&strParam=2", this.hdId.Text, BLL.Const.IncidentInvestigationMenuId))); + } + + /// + /// 附件查看 + /// + /// + /// + protected void lbtnViewAttach2_Click(object sender, EventArgs e) + { + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../AttachFile/webuploader2.aspx?type=-1&toKeyId={0}&path=FileUpload/SES/EMC_Punishment&menuId={1}&strParam=2", this.hdId.Text, BLL.Const.IncidentInvestigationMenuId))); } #endregion @@ -1652,5 +1729,7 @@ namespace FineUIPro.Web.ContractorQuality PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference()); } #endregion + + } } \ No newline at end of file diff --git a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.designer.cs b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.designer.cs index 7791809..40c65a0 100644 --- a/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.designer.cs +++ b/FCL/FineUIPro.Web/ContractorQuality/IncidentInvestigationEdit.aspx.designer.cs @@ -158,6 +158,15 @@ namespace FineUIPro.Web.ContractorQuality /// protected global::FineUIPro.Label lblTips; + /// + /// lbtnViewAttach 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.LinkButton lbtnViewAttach; + /// /// GroupPanel2 控件。 /// @@ -491,6 +500,15 @@ namespace FineUIPro.Web.ContractorQuality /// protected global::FineUIPro.Label Label6; + /// + /// lbtnViewAttach2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.LinkButton lbtnViewAttach2; + /// /// frMCNoPass 控件。 /// @@ -662,6 +680,15 @@ namespace FineUIPro.Web.ContractorQuality /// protected global::FineUIPro.Label Label8; + /// + /// lbtnAttach3 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.LinkButton lbtnAttach3; + /// /// frPVTNoPass 控件。 /// diff --git a/FCL/FineUIPro.Web/FineUIPro.Web.csproj.user b/FCL/FineUIPro.Web/FineUIPro.Web.csproj.user index fcf3204..accb770 100644 --- a/FCL/FineUIPro.Web/FineUIPro.Web.csproj.user +++ b/FCL/FineUIPro.Web/FineUIPro.Web.csproj.user @@ -2,7 +2,7 @@ ShowAllFiles - Debug|Any CPU + Release|Any CPU true diff --git a/FCL/FineUIPro.Web/Web.config b/FCL/FineUIPro.Web/Web.config index 4a08f09..c97a2b2 100644 --- a/FCL/FineUIPro.Web/Web.config +++ b/FCL/FineUIPro.Web/Web.config @@ -55,7 +55,7 @@ - + diff --git a/FCL/WebApi/WebApi.csproj.user b/FCL/WebApi/WebApi.csproj.user index ca0d73e..643f3e5 100644 --- a/FCL/WebApi/WebApi.csproj.user +++ b/FCL/WebApi/WebApi.csproj.user @@ -8,7 +8,7 @@ - Debug|Any CPU + Release|Any CPU