Compare commits
2 Commits
7871e1ed7e
...
cba8e9e2f7
Author | SHA1 | Date |
---|---|---|
|
cba8e9e2f7 | |
|
1ec4f71825 |
|
@ -1198,3 +1198,7 @@ FCL/WebApi/obj/Release/WebApi.pdb
|
|||
/备份/FCLPackFile_2024.06.06
|
||||
/FCL/packages
|
||||
/FCL/FineUIPro.Web/Web.config
|
||||
/DataBase/版本日志
|
||||
/FCL/FineUIPro.Web/FileUpload/SES/EMC_Punishment
|
||||
/FCLPackFile_2024.09.18
|
||||
/备份
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -30,12 +30,12 @@ namespace BLL.APIService
|
|||
}
|
||||
public static void GetSyncUserInfo()
|
||||
{
|
||||
//var token = GetUserToken(); //获取接口token
|
||||
var token = GetUserToken(); //获取接口token
|
||||
var dic = GetDepartList(); //把本地数据库中的部门全部取出作为字典
|
||||
var dicUser = GetUserInfoByAccount(); //同上把所有用户取出来
|
||||
string file = System.Web.HttpContext.Current.Server.MapPath("~/data.txt");
|
||||
string result = System.IO.File.ReadAllText(file);
|
||||
//string result = BLL.Common.HttpHelper.HttpPostRequest(GETHRINfOAPI, "", token);
|
||||
//string file = System.Web.HttpContext.Current.Server.MapPath("~/data.txt");
|
||||
//string result = System.IO.File.ReadAllText(file);
|
||||
string result = BLL.Common.HttpHelper.HttpPostRequest(GETHRINfOAPI, "", token);
|
||||
var data = JsonHelper.DeserializeJsonToObject<ResultData<List<UserInfo>>>(result);
|
||||
List<Model.SyncDataUserLogs> logList = new List<Model.SyncDataUserLogs>();
|
||||
if (data.code == "200")
|
||||
|
|
|
@ -110,6 +110,7 @@
|
|||
<Compile Include="BaseInfo\TaxRateService.cs" />
|
||||
<Compile Include="BaseInfo\TemplateTypeService.cs" />
|
||||
<Compile Include="BaseInfo\TypeService.cs" />
|
||||
<Compile Include="BaseInfo\ViolationClauseService.cs" />
|
||||
<Compile Include="Common\AccessTokenModel.cs" />
|
||||
<Compile Include="Common\AttachFileService.cs" />
|
||||
<Compile Include="Common\ChartControlService.cs" />
|
||||
|
|
|
@ -0,0 +1,96 @@
|
|||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
public class ViolationClauseService
|
||||
{
|
||||
/// <summary>
|
||||
/// 根据主键获取类型
|
||||
/// </summary>
|
||||
/// <param name="violationClauseId"></param>
|
||||
/// <returns></returns>
|
||||
public static Model.EMC_ViolationClause GetViolationClause(string violationClauseId)
|
||||
{
|
||||
return Funs.DB.EMC_ViolationClause.FirstOrDefault(e => e.ViolationClauseId == violationClauseId);
|
||||
}
|
||||
|
||||
public static List<Model.EMC_ViolationClause> GetSupViolationClause()
|
||||
{
|
||||
return Funs.DB.EMC_ViolationClause.Where(e => e.SupViolationClause == null).ToList();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 添加
|
||||
/// </summary>
|
||||
/// <param name="violationClause"></param>
|
||||
public static void AddViolationClause(Model.EMC_ViolationClause violationClause)
|
||||
{
|
||||
Model.EMC_ViolationClause newType = new Model.EMC_ViolationClause();
|
||||
newType.ViolationClauseId = violationClause.ViolationClauseId;
|
||||
newType.ClauseDef = violationClause.ClauseDef;
|
||||
newType.DeductionComPany1 = violationClause.DeductionComPany1;
|
||||
newType.DeductionComPany2 = violationClause.DeductionComPany2;
|
||||
newType.DeductionComPany3 = violationClause.DeductionComPany3;
|
||||
newType.DeductionIndividual1 = violationClause.DeductionIndividual1;
|
||||
newType.DeductionIndividual2 = violationClause.DeductionIndividual2;
|
||||
newType.DeductionIndividual3 = violationClause.DeductionIndividual3;
|
||||
newType.ApplicationDef= violationClause.ApplicationDef;
|
||||
newType.SupViolationClause = violationClause.SupViolationClause;
|
||||
newType.SortIndex = violationClause.SortIndex;
|
||||
Funs.DB.EMC_ViolationClause.InsertOnSubmit(newType);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 修改
|
||||
/// </summary>
|
||||
/// <param name="violationClause"></param>
|
||||
public static void UpdateViolationClause(Model.EMC_ViolationClause violationClause)
|
||||
{
|
||||
Model.EMC_ViolationClause newType = Funs.DB.EMC_ViolationClause.FirstOrDefault(e => e.ViolationClauseId == violationClause.ViolationClauseId);
|
||||
if (newType != null)
|
||||
{
|
||||
newType.ClauseDef = violationClause.ClauseDef;
|
||||
newType.DeductionComPany1 = violationClause.DeductionComPany1;
|
||||
newType.DeductionComPany2 = violationClause.DeductionComPany2;
|
||||
newType.DeductionComPany3 = violationClause.DeductionComPany3;
|
||||
newType.DeductionIndividual1 = violationClause.DeductionIndividual1;
|
||||
newType.DeductionIndividual2 = violationClause.DeductionIndividual2;
|
||||
newType.DeductionIndividual3 = violationClause.DeductionIndividual3;
|
||||
newType.ApplicationDef = violationClause.ApplicationDef;
|
||||
newType.SortIndex = violationClause.SortIndex;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除类型
|
||||
/// </summary>
|
||||
/// <param name="typeId"></param>
|
||||
public static void DeleteViolationClause(string violationClauseId)
|
||||
{
|
||||
Model.EMC_ViolationClause type = Funs.DB.EMC_ViolationClause.FirstOrDefault(e => e.ViolationClauseId == violationClauseId);
|
||||
if (type != null)
|
||||
{
|
||||
Funs.DB.EMC_ViolationClause.DeleteOnSubmit(type);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
||||
public static void InitViolationClause(FineUIPro.DropDownList dropName, bool isShowPlease)
|
||||
{
|
||||
dropName.DataGroupField = "SupClauseDef";
|
||||
dropName.DataValueField = "ViolationClauseId";
|
||||
dropName.DataTextField = "ClauseDef";
|
||||
dropName.DataSource = (from x in Funs.DB.EMC_ViolationClause
|
||||
join y in Funs.DB.EMC_ViolationClause on x.SupViolationClause equals y.ViolationClauseId
|
||||
select new { x.ViolationClauseId, x.ClauseDef, SupClauseDef = y.ClauseDef }).ToList();
|
||||
dropName.DataBind();
|
||||
if (isShowPlease)
|
||||
{
|
||||
Funs.FineUIPleaseSelect(dropName);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -120,6 +120,21 @@ namespace BLL
|
|||
/// </summary>
|
||||
public const string BtnOut = "Export";
|
||||
|
||||
/// <summary>
|
||||
/// FC导出
|
||||
/// </summary>
|
||||
public const string FCExport = "FCExport";
|
||||
|
||||
/// <summary>
|
||||
/// Person导出
|
||||
/// </summary>
|
||||
public const string PersonExport = "PersonExport";
|
||||
|
||||
/// <summary>
|
||||
/// Fo导出
|
||||
/// </summary>
|
||||
public const string FoExport = "FoExport";
|
||||
|
||||
/// <summary>
|
||||
/// 导出分数
|
||||
/// </summary>
|
||||
|
@ -316,6 +331,11 @@ namespace BLL
|
|||
/// </summary>
|
||||
public const string FOOffsetMenuId = "AE8C4BCB-A7E0-4EC6-B3F3-124C5B77D32F";
|
||||
|
||||
/// <summary>
|
||||
/// 违章条款
|
||||
/// </summary>
|
||||
public const string ViolationClauseMenuId = "CCAF3391-23FD-4E4D-A552-0C4AD3CFF44A";
|
||||
|
||||
#endregion
|
||||
|
||||
#region EMC Contracts
|
||||
|
|
|
@ -41,7 +41,7 @@ namespace BLL.Common
|
|||
/// <returns></returns>
|
||||
public static string HttpPostRequest(string url, string postJsonData,string token)
|
||||
{
|
||||
BLL.ErrLogInfo.WriteLog("token=" + token);
|
||||
//BLL.ErrLogInfo.WriteLog("token=" + token);
|
||||
string strPostReponse = string.Empty;
|
||||
try
|
||||
{
|
||||
|
|
|
@ -84,7 +84,7 @@ namespace BLL.Common
|
|||
|
||||
//email.To.Add(send);
|
||||
//主题
|
||||
email.Subject = mailSubject;
|
||||
email.Subject = mailSubject.Replace("\r","").Replace("\n", "");
|
||||
//附件
|
||||
if (!string.IsNullOrEmpty(mailAttch))
|
||||
{
|
||||
|
@ -273,7 +273,7 @@ namespace BLL.Common
|
|||
|
||||
//email.To.Add(send);
|
||||
//主题
|
||||
email.Subject = mailSubject;
|
||||
email.Subject = mailSubject.Replace("\r", "").Replace("\n", "");
|
||||
//附件
|
||||
|
||||
//优先级
|
||||
|
|
|
@ -23,7 +23,12 @@ namespace BLL
|
|||
return Funs.DB.View_EMC_Punishment.FirstOrDefault(e => e.PunishmentId == punishmentId);
|
||||
}
|
||||
|
||||
|
||||
public static Model.View_EMC_Que_Punishment GetQuePunishmentViewById(string punishmentId)
|
||||
{
|
||||
return Funs.DB.View_EMC_Que_Punishment.FirstOrDefault(e => e.PunishmentId == punishmentId);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 添加扣款项
|
||||
|
@ -34,6 +39,7 @@ namespace BLL
|
|||
Model.EMC_Punishment newPunishment = new Model.EMC_Punishment();
|
||||
newPunishment.PunishmentId = punishment.PunishmentId;
|
||||
newPunishment.FO_NO = punishment.FO_NO;
|
||||
newPunishment.ItemNo = punishment.ItemNo;
|
||||
newPunishment.SES_No = punishment.SES_No;
|
||||
newPunishment.PunishDate = punishment.PunishDate;
|
||||
newPunishment.Location = punishment.Location;
|
||||
|
@ -50,6 +56,15 @@ namespace BLL
|
|||
newPunishment.Def=punishment.Def;
|
||||
newPunishment.CreateDate = punishment.CreateDate;
|
||||
|
||||
newPunishment.Contractor= punishment.Contractor;
|
||||
newPunishment.Discipline=punishment.Discipline;
|
||||
newPunishment.ViolationClauseId= punishment.ViolationClauseId;
|
||||
newPunishment.IsFrame= punishment.IsFrame;
|
||||
newPunishment.ViolationPerson =punishment.ViolationPerson;
|
||||
newPunishment.BYC_Person= punishment.BYC_Person;
|
||||
newPunishment.Requisitioner=punishment.Requisitioner;
|
||||
newPunishment.AttachUrl = punishment.AttachUrl;
|
||||
|
||||
Funs.DB.EMC_Punishment.InsertOnSubmit(newPunishment);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
|
@ -64,6 +79,7 @@ namespace BLL
|
|||
if (newPunishment != null)
|
||||
{
|
||||
newPunishment.FO_NO = punishment.FO_NO;
|
||||
newPunishment.ItemNo = punishment.ItemNo;
|
||||
newPunishment.SES_No = punishment.SES_No;
|
||||
newPunishment.PunishDate = punishment.PunishDate;
|
||||
newPunishment.Location = punishment.Location;
|
||||
|
@ -77,6 +93,16 @@ namespace BLL
|
|||
newPunishment.ViolationRelatedSes = punishment.ViolationRelatedSes;
|
||||
newPunishment.SelectYesNo = punishment.SelectYesNo;
|
||||
newPunishment.Def = punishment.Def;
|
||||
|
||||
newPunishment.Contractor = punishment.Contractor;
|
||||
newPunishment.Discipline = punishment.Discipline;
|
||||
newPunishment.ViolationClauseId = punishment.ViolationClauseId;
|
||||
newPunishment.IsFrame = punishment.IsFrame;
|
||||
newPunishment.ViolationPerson = punishment.ViolationPerson;
|
||||
newPunishment.BYC_Person = punishment.BYC_Person;
|
||||
newPunishment.Requisitioner = punishment.Requisitioner;
|
||||
newPunishment.AttachUrl = punishment.AttachUrl;
|
||||
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,108 @@
|
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ViolationClause.aspx.cs" Inherits="FineUIPro.Web.BaseInfo.ViolationClause" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head runat="server">
|
||||
<title>Violation Clause</title>
|
||||
<link href="../../res/css/common.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<form id="form1" runat="server">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="Panel1" runat="server" />
|
||||
<f:Panel ID="Panel1" runat="server" Margin="5px" BodyPadding="5px" ShowBorder="false"
|
||||
ShowHeader="false" Layout="Region" BoxConfigAlign="Stretch">
|
||||
<Items>
|
||||
<f:Panel runat="server" ID="panelLeftRegion" RegionPosition="Left" RegionSplit="true"
|
||||
EnableCollapse="true" Width="220px" Title="FO" ShowBorder="true" Layout="VBox"
|
||||
ShowHeader="false" AutoScroll="true" BodyPadding="5px" IconFont="ArrowCircleLeft">
|
||||
<Items>
|
||||
<f:Tree ID="tvViolationClause" ShowHeader="false" OnNodeCommand="tvViolationClause_NodeCommand" runat="server"
|
||||
ShowBorder="false" EnableCollapse="true" EnableSingleClickExpand="true"
|
||||
AutoLeafIdentification="true" EnableSingleExpand="true" EnableTextSelection="true">
|
||||
</f:Tree>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Panel runat="server" ID="panelCenterRegion" RegionPosition="Center" ShowBorder="true"
|
||||
Layout="VBox" ShowHeader="false" BodyPadding="5px" IconFont="PlusCircle" Title="Files Management"
|
||||
TitleToolTip="Role Authorization" AutoScroll="true">
|
||||
<Items>
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="Violation Clause" EnableCollapse="true"
|
||||
runat="server" BoxFlex="1" DataKeyNames="ViolationClauseId" AllowCellEditing="true" EnableColumnLines="true"
|
||||
ClicksToEdit="2" DataIDField="ViolationClauseId" AllowSorting="true" SortField="SortIndex"
|
||||
SortDirection="ASC" OnSort="Grid1_Sort"
|
||||
EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar2" Position="Top" runat="server">
|
||||
<Items>
|
||||
<f:Button ID="btnNew" ToolTip="Add" Icon="Add" Text="Add" OnClick="btnAdd_Click" runat="server">
|
||||
</f:Button>
|
||||
<f:Button ID="btnEdit" ToolTip="Modify" Text="Modify" Icon="Pencil" runat="server" OnClick="btnEdit_Click">
|
||||
</f:Button>
|
||||
<f:Button ID="btnDelete" ToolTip="Delete" Text="Delete" Icon="Delete" ConfirmText="Make sure to delete the current data?" OnClick="btnDelete_Click"
|
||||
runat="server">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Columns>
|
||||
<f:RenderField Width="350px" ColumnID="ClauseDef" DataField="ClauseDef"
|
||||
SortField="ClauseDef" FieldType="String" HeaderText="违章条款描述" HeaderTextAlign="Center" TextAlign="Left">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="DeductionComPany1" DataField="DeductionComPany1"
|
||||
FieldType="String" HeaderText="一般违章(公司)" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="DeductionIndividual1" DataField="DeductionIndividual1"
|
||||
FieldType="String" HeaderText="一般违章(个人)" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="DeductionComPany2" DataField="DeductionComPany2"
|
||||
FieldType="String" HeaderText="严重违章(公司)" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="DeductionIndividual2" DataField="DeductionIndividual2"
|
||||
FieldType="String" HeaderText="严重违章(个人)" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="DeductionComPany3" DataField="DeductionComPany3"
|
||||
FieldType="String" HeaderText="零容忍(公司)" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="DeductionIndividual3" DataField="DeductionIndividual3"
|
||||
FieldType="String" HeaderText="零容忍(个人)" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="350px" ColumnID="ApplicationDef" DataField="ApplicationDef"
|
||||
FieldType="String" HeaderText="示例应用场景" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
</Columns>
|
||||
<Listeners>
|
||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />
|
||||
</Listeners>
|
||||
</f:Grid>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Window ID="Window1" Title="Pop-up window" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
||||
Target="Self" EnableResize="true" runat="server" OnClose="Window1_Close" IsModal="true"
|
||||
Width="900px" Height="600px">
|
||||
</f:Window>
|
||||
<f:Menu ID="Menu1" runat="server">
|
||||
<f:MenuButton ID="btnMenuEdit" OnClick="btnMenuEdit_Click" EnablePostBack="true"
|
||||
Icon="BulletEdit" runat="server" Text="Modify">
|
||||
</f:MenuButton>
|
||||
<f:MenuButton ID="btnMenuDelete" OnClick="btnMenuDelete_Click" EnablePostBack="true"
|
||||
Icon="Delete" ConfirmText="Delete selected row?" ConfirmTarget="Top" runat="server" Text="Delete">
|
||||
</f:MenuButton>
|
||||
</f:Menu>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
var menuID = '<%= Menu1.ClientID %>';
|
||||
// 返回false,来阻止浏览器右键菜单
|
||||
function onRowContextMenu(event, rowId) {
|
||||
F(menuID).show(); //showAt(event.pageX, event.pageY);
|
||||
return false;
|
||||
}
|
||||
|
||||
function reloadGrid() {
|
||||
__doPostBack(null, 'reloadGrid');
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,275 @@
|
|||
using BLL;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Data.SqlClient;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace FineUIPro.Web.BaseInfo
|
||||
{
|
||||
public partial class ViolationClause : PageBase
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
GetButtonPower();//权限设置
|
||||
btnDelete.OnClientClick = Grid1.GetNoSelectionAlertReference("Please select at least one item!");
|
||||
btnDelete.ConfirmText = String.Format("Are you sure you want to delete the selected <b><script>{0}</script></b> rows?", Grid1.GetSelectedCountReference());
|
||||
InitTreeMenu();
|
||||
// 绑定表格
|
||||
//BindGrid();
|
||||
}
|
||||
}
|
||||
|
||||
#region 加载树
|
||||
private void InitTreeMenu()
|
||||
{
|
||||
this.tvViolationClause.Nodes.Clear();
|
||||
TreeNode rootRole = new TreeNode();
|
||||
rootRole.Text = "违章条款";
|
||||
rootRole.NodeID = "0";
|
||||
rootRole.Expanded = true;
|
||||
this.tvViolationClause.Nodes.Add(rootRole);
|
||||
BoundTree(rootRole.Nodes);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 遍历节点
|
||||
/// </summary>
|
||||
/// <param name="nodes"></param>
|
||||
/// <param name="parentId"></param>
|
||||
/// <param name="type"></param>
|
||||
private void BoundTree(TreeNodeCollection nodes)
|
||||
{
|
||||
List<Model.EMC_ViolationClause> supVio = BLL.ViolationClauseService.GetSupViolationClause();
|
||||
|
||||
if (supVio.Count() > 0)
|
||||
{
|
||||
TreeNode tn = null;
|
||||
foreach (var q in supVio)
|
||||
{
|
||||
tn = new TreeNode();
|
||||
tn.Text = q.ClauseDef;
|
||||
tn.NodeID = q.ViolationClauseId;
|
||||
tn.EnableClickEvent = true;
|
||||
nodes.Add(tn);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Tree点击事件
|
||||
/// <summary>
|
||||
/// 选择角色事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void tvViolationClause_NodeCommand(object sender, TreeCommandEventArgs e)
|
||||
{
|
||||
this.BindGrid(this.tvViolationClause.SelectedNodeID);
|
||||
}
|
||||
#endregion
|
||||
|
||||
private void BindGrid(string supViolationClauseId)
|
||||
{
|
||||
string strSql = @"SELECT ViolationClauseId,ClauseDef,ApplicationDef,
|
||||
(CASE WHEN (DeductionIndividual1=0 OR DeductionIndividual1 IS NULL) THEN 'N/A' ELSE CAST(CAST(DeductionIndividual1 AS REAL) AS VARCHAR) END) AS DeductionIndividual1,
|
||||
(CASE WHEN (DeductionComPany1=0 OR DeductionComPany1 IS NULL) THEN 'N/A' ELSE CAST(CAST(DeductionComPany1 AS REAL) AS VARCHAR) END) AS DeductionComPany1,
|
||||
(CASE WHEN (DeductionIndividual2=0 OR DeductionIndividual2 IS NULL) THEN 'N/A' ELSE CAST(CAST(DeductionIndividual2 AS REAL) AS VARCHAR) END) AS DeductionIndividual2,
|
||||
(CASE WHEN (DeductionComPany2=0 OR DeductionComPany2 IS NULL) THEN 'N/A' ELSE CAST(CAST(DeductionComPany2 AS REAL) AS VARCHAR) END) AS DeductionComPany2,
|
||||
(CASE WHEN (DeductionIndividual3=0 OR DeductionIndividual3 IS NULL) THEN 'N/A' ELSE CAST(CAST(DeductionIndividual3 AS REAL) AS VARCHAR) END) AS DeductionIndividual3,
|
||||
(CASE WHEN (DeductionComPany3=0 OR DeductionComPany3 IS NULL) THEN 'N/A' ELSE CAST(CAST(DeductionComPany3 AS REAL) AS VARCHAR) END) AS DeductionComPany3
|
||||
FROM dbo.EMC_ViolationClause
|
||||
WHERE SupViolationClause=@SupViolationClause
|
||||
ORDER BY SortIndex";
|
||||
List<SqlParameter> parms = new List<SqlParameter>();
|
||||
parms.Add(new SqlParameter("@SupViolationClause", supViolationClauseId));
|
||||
SqlParameter[] parameter = parms.ToArray();
|
||||
DataTable dt = SQLHelper.GetDataTableRunText(strSql, parameter);
|
||||
// 2.获取当前分页数据
|
||||
Grid1.DataSource = dt;
|
||||
Grid1.DataBind();
|
||||
}
|
||||
|
||||
#region 编辑
|
||||
|
||||
protected void btnAdd_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (tvViolationClause.SelectedNodeID=="" || tvViolationClause.SelectedNodeID =="0")
|
||||
{
|
||||
Alert.ShowInParent("Please select Tree Node!");
|
||||
return;
|
||||
}
|
||||
string Id = tvViolationClause.SelectedNodeID;
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ViolationClauseEdit.aspx?supViolationClauseId={0}", Id, "编辑 - ")));
|
||||
}
|
||||
/// <summary>
|
||||
/// 编辑
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnEdit_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length == 0)
|
||||
{
|
||||
Alert.ShowInParent("Please select at least one record!");
|
||||
return;
|
||||
}
|
||||
string Id = Grid1.SelectedRowID;
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ViolationClauseEdit.aspx?violationClauseId={0}", Id, "编辑 - ")));
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 右键编辑事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnMenuEdit_Click(object sender, EventArgs e)
|
||||
{
|
||||
btnEdit_Click(null, null);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Grid行双击事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e)
|
||||
{
|
||||
btnEdit_Click(null, null);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 删除数据
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnDelete_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.DeleteData();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 右键删除事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnMenuDelete_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.DeleteData();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 删除方法
|
||||
/// </summary>
|
||||
private void DeleteData()
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length > 0)
|
||||
{
|
||||
foreach (int rowIndex in Grid1.SelectedRowIndexArray)
|
||||
{
|
||||
string rowID = Grid1.DataKeys[rowIndex][0].ToString();
|
||||
var role = BLL.ViolationClauseService.GetViolationClause(rowID);
|
||||
if (role != null)
|
||||
{
|
||||
if (judgementDelete(rowID, false))
|
||||
{
|
||||
BLL.ViolationClauseService.DeleteViolationClause(rowID);
|
||||
}
|
||||
}
|
||||
}
|
||||
this.BindGrid(this.tvViolationClause.SelectedNodeID);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Delete Violation Clause");
|
||||
ShowNotify("Deleted successfully!");
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 关闭弹出窗口
|
||||
/// <summary>
|
||||
/// 关闭窗口
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Window1_Close(object sender, EventArgs e)
|
||||
{
|
||||
this.BindGrid(this.tvViolationClause.SelectedNodeID);
|
||||
}
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// 排序
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Grid1_Sort(object sender, FineUIPro.GridSortEventArgs e)
|
||||
{
|
||||
Grid1.SortDirection = e.SortDirection;
|
||||
Grid1.SortField = e.SortField;
|
||||
this.BindGrid(this.tvViolationClause.SelectedNodeID);
|
||||
}
|
||||
|
||||
|
||||
#region 判断是否可删除
|
||||
/// <summary>
|
||||
/// 判断是否可以删除
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private bool judgementDelete(string id, bool isShow)
|
||||
{
|
||||
string content = string.Empty;
|
||||
if (Funs.DB.EMC_Punishment.FirstOrDefault(x => x.ViolationClauseId == id) != null)
|
||||
{
|
||||
content = "This role is already in use in [违章条款] and cannot be deleted!";
|
||||
}
|
||||
|
||||
if (string.IsNullOrEmpty(content))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (isShow)
|
||||
{
|
||||
Alert.ShowInTop(content);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 权限设置
|
||||
/// <summary>
|
||||
/// 菜单按钮权限
|
||||
/// </summary>
|
||||
private void GetButtonPower()
|
||||
{
|
||||
var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.UserId, BLL.Const.ViolationClauseMenuId);
|
||||
if (buttonList.Count() > 0)
|
||||
{
|
||||
if (buttonList.Contains(BLL.Const.BtnAdd))
|
||||
{
|
||||
this.btnNew.Hidden = false;
|
||||
}
|
||||
if (buttonList.Contains(BLL.Const.BtnModify))
|
||||
{
|
||||
this.btnEdit.Hidden = false;
|
||||
this.btnMenuEdit.Hidden = false;
|
||||
}
|
||||
if (buttonList.Contains(BLL.Const.BtnDelete))
|
||||
{
|
||||
this.btnDelete.Hidden = false;
|
||||
this.btnMenuDelete.Hidden = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -0,0 +1,152 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.BaseInfo
|
||||
{
|
||||
|
||||
|
||||
public partial class ViolationClause
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel Panel1;
|
||||
|
||||
/// <summary>
|
||||
/// panelLeftRegion 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelLeftRegion;
|
||||
|
||||
/// <summary>
|
||||
/// tvViolationClause 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Tree tvViolationClause;
|
||||
|
||||
/// <summary>
|
||||
/// panelCenterRegion 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelCenterRegion;
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar2;
|
||||
|
||||
/// <summary>
|
||||
/// btnNew 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnNew;
|
||||
|
||||
/// <summary>
|
||||
/// btnEdit 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnEdit;
|
||||
|
||||
/// <summary>
|
||||
/// btnDelete 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnDelete;
|
||||
|
||||
/// <summary>
|
||||
/// Window1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window1;
|
||||
|
||||
/// <summary>
|
||||
/// Menu1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Menu Menu1;
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuEdit 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.MenuButton btnMenuEdit;
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuDelete 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.MenuButton btnMenuDelete;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,79 @@
|
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ViolationClauseEdit.aspx.cs" Inherits="FineUIPro.Web.BaseInfo.ViolationClauseEdit" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head runat="server">
|
||||
<title>编辑违章条款</title>
|
||||
<link href="../../res/css/common.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<form id="form1" runat="server">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="SimpleForm1" runat="server" />
|
||||
<f:Form ID="SimpleForm1" ShowBorder="false" ShowHeader="false" AutoScroll="true"
|
||||
BodyPadding="10px" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtClauseDef" runat="server" Label="违章条款描述" LabelWidth="150px" Required="true" ShowRedStar="true">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numDeductionIndividual1" runat="server" Label="一般违章(公司)" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numDeductionComPany1" runat="server" Label="一般违章(个人)" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numDeductionIndividual2" runat="server" Label="严重违章(公司)" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numDeductionComPany2" runat="server" Label="严重违章(个人)" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numDeductionIndividual3" runat="server" Label="零容忍(公司)" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numDeductionComPany3" runat="server" Label="零容忍(个人)" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numSortIndex" runat="server" Label="排序号" LabelWidth="150px" NoDecimal="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtApplicationDef" runat="server" Label="示例应用场景" LabelWidth="150px"></f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar1" Position="Bottom" ToolbarAlign="Right" runat="server">
|
||||
<Items>
|
||||
<f:Button ID="btnSave" Icon="SystemSave" runat="server" Text="Save" ToolTip="Save" ValidateForms="SimpleForm1"
|
||||
OnClick="btnSave_Click">
|
||||
</f:Button>
|
||||
<f:Button ID="btnClose" EnablePostBack="false" ToolTip="Close" Text="Close" runat="server" Icon="SystemClose">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
</f:Form>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,136 @@
|
|||
using BLL;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace FineUIPro.Web.BaseInfo
|
||||
{
|
||||
public partial class ViolationClauseEdit : PageBase
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
GetButtonPower();//按钮权限
|
||||
btnClose.OnClientClick = ActiveWindow.GetHideReference();
|
||||
string violationClauseId = Request.Params["violationClauseId"];
|
||||
|
||||
if (!string.IsNullOrEmpty(violationClauseId))
|
||||
{
|
||||
var vio = BLL.ViolationClauseService.GetViolationClause(violationClauseId);
|
||||
if (vio != null)
|
||||
{
|
||||
this.txtClauseDef.Text = vio.ClauseDef;
|
||||
this.txtApplicationDef.Text = vio.ApplicationDef;
|
||||
if (vio.DeductionIndividual1 != null && vio.DeductionIndividual1 != 0)
|
||||
{
|
||||
numDeductionIndividual1.Text = vio.DeductionIndividual1.ToString();
|
||||
}
|
||||
if (vio.DeductionComPany1 != null && vio.DeductionComPany1 != 0)
|
||||
{
|
||||
numDeductionComPany1.Text = vio.DeductionComPany1.ToString();
|
||||
}
|
||||
if (vio.DeductionIndividual2 != null && vio.DeductionIndividual2 != 0)
|
||||
{
|
||||
numDeductionIndividual2.Text = vio.DeductionIndividual2.ToString();
|
||||
}
|
||||
if (vio.DeductionComPany2 != null && vio.DeductionComPany2 != 0)
|
||||
{
|
||||
numDeductionComPany2.Text = vio.DeductionComPany2.ToString();
|
||||
}
|
||||
if (vio.DeductionIndividual3 != null && vio.DeductionIndividual3 != 0)
|
||||
{
|
||||
numDeductionIndividual3.Text = vio.DeductionIndividual3.ToString();
|
||||
}
|
||||
if (vio.DeductionComPany3 != null && vio.DeductionComPany3 != 0)
|
||||
{
|
||||
numDeductionComPany3.Text = vio.DeductionComPany3.ToString();
|
||||
}
|
||||
if (vio.SortIndex != null)
|
||||
{
|
||||
numSortIndex.Text = vio.SortIndex.ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
string violationClauseId = Request.Params["violationClauseId"];
|
||||
string supViolationClauseId = Request.Params["supViolationClauseId"];
|
||||
Model.EMC_ViolationClause vio = new Model.EMC_ViolationClause();
|
||||
vio.ClauseDef = txtClauseDef.Text.Trim();
|
||||
vio.ApplicationDef = txtApplicationDef.Text.Trim();
|
||||
if (!string.IsNullOrEmpty(numDeductionIndividual1.Text))
|
||||
{
|
||||
vio.DeductionIndividual1 = Convert.ToDecimal(numDeductionIndividual1.Text);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(numDeductionComPany1.Text))
|
||||
{
|
||||
vio.DeductionComPany1 = Convert.ToDecimal(numDeductionComPany1.Text);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(numDeductionIndividual2.Text))
|
||||
{
|
||||
vio.DeductionIndividual2 = Convert.ToDecimal(numDeductionIndividual2.Text);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(numDeductionComPany2.Text))
|
||||
{
|
||||
vio.DeductionComPany2 = Convert.ToDecimal(numDeductionComPany2.Text);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(numDeductionIndividual3.Text))
|
||||
{
|
||||
vio.DeductionIndividual3 = Convert.ToDecimal(numDeductionIndividual3.Text);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(numDeductionComPany3.Text))
|
||||
{
|
||||
vio.DeductionComPany3 = Convert.ToDecimal(numDeductionComPany3.Text);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(numSortIndex.Text))
|
||||
{
|
||||
vio.SortIndex = Convert.ToInt32(numSortIndex.Text);
|
||||
}
|
||||
|
||||
if (string.IsNullOrEmpty(violationClauseId))
|
||||
{
|
||||
if (!string.IsNullOrEmpty(supViolationClauseId))
|
||||
{
|
||||
string newKeyID = SQLHelper.GetNewID(typeof(Model.EMC_ViolationClause));
|
||||
vio.ViolationClauseId = newKeyID;
|
||||
vio.SupViolationClause = supViolationClauseId;
|
||||
BLL.ViolationClauseService.AddViolationClause(vio);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Add Violation Clause!");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
vio.ViolationClauseId = violationClauseId;
|
||||
BLL.ViolationClauseService.UpdateViolationClause(vio);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Modify Violation Clause!");
|
||||
}
|
||||
ShowNotify("Save successfully!", MessageBoxIcon.Success);
|
||||
PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
|
||||
}
|
||||
|
||||
#region 权限设置
|
||||
/// <summary>
|
||||
/// 菜单按钮权限
|
||||
/// </summary>
|
||||
private void GetButtonPower()
|
||||
{
|
||||
var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.UserId, BLL.Const.ViolationClauseMenuId);
|
||||
if (buttonList.Count() > 0)
|
||||
{
|
||||
if (buttonList.Contains(BLL.Const.BtnSave))
|
||||
{
|
||||
this.btnSave.Hidden = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -0,0 +1,152 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.BaseInfo
|
||||
{
|
||||
|
||||
|
||||
public partial class ViolationClauseEdit
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
/// <summary>
|
||||
/// SimpleForm1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form SimpleForm1;
|
||||
|
||||
/// <summary>
|
||||
/// txtClauseDef 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtClauseDef;
|
||||
|
||||
/// <summary>
|
||||
/// numDeductionIndividual1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numDeductionIndividual1;
|
||||
|
||||
/// <summary>
|
||||
/// numDeductionComPany1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numDeductionComPany1;
|
||||
|
||||
/// <summary>
|
||||
/// numDeductionIndividual2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numDeductionIndividual2;
|
||||
|
||||
/// <summary>
|
||||
/// numDeductionComPany2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numDeductionComPany2;
|
||||
|
||||
/// <summary>
|
||||
/// numDeductionIndividual3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numDeductionIndividual3;
|
||||
|
||||
/// <summary>
|
||||
/// numDeductionComPany3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numDeductionComPany3;
|
||||
|
||||
/// <summary>
|
||||
/// numSortIndex 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox numSortIndex;
|
||||
|
||||
/// <summary>
|
||||
/// txtApplicationDef 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtApplicationDef;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar1;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnSave;
|
||||
|
||||
/// <summary>
|
||||
/// btnClose 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnClose;
|
||||
}
|
||||
}
|
|
@ -116,10 +116,10 @@
|
|||
FieldType="String" HeaderText="项目名称" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="100px" ColumnID="Quotation" DataField="Quotation" SortField="Quotation"
|
||||
FieldType="Float" HeaderText="承包商报价" HeaderTextAlign="Center" RendererFunction="renderSalaryFloat">
|
||||
FieldType="Double" HeaderText="承包商报价" HeaderTextAlign="Center" >
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="100px" ColumnID="Tax_Value" DataField="Tax_Value" SortField="Tax_Value"
|
||||
FieldType="Float" HeaderText="CTE/D审价" HeaderTextAlign="Center" RendererFunction="renderSalaryFloat">
|
||||
FieldType="Double" HeaderText="CTE/D审价" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="100px" ColumnID="ThirdParty_PriceReview" DataField="ThirdParty_PriceReview" SortField="ThirdParty_PriceReview" FieldType="Float"
|
||||
HeaderText="第三方审价" TextAlign="Right">
|
||||
|
|
|
@ -359,30 +359,30 @@ namespace FineUIPro.Web.Evaluation
|
|||
if (reportModel.GetRow(3) == null) reportModel.CreateRow(3);
|
||||
if (reportModel.GetRow(3).GetCell(2) == null) reportModel.GetRow(3).CreateCell(2);
|
||||
reportModel.GetRow(3).GetCell(2).SetCellValue(eva.Discipline);
|
||||
//7行
|
||||
if (reportModel.GetRow(6) == null) reportModel.CreateRow(6);
|
||||
if (reportModel.GetRow(6).GetCell(2) == null) reportModel.GetRow(6).CreateCell(2);
|
||||
reportModel.GetRow(6).GetCell(2).SetCellValue(eva.FO_NO);
|
||||
if (reportModel.GetRow(6).GetCell(6) == null) reportModel.GetRow(6).CreateCell(6);
|
||||
//6行
|
||||
if (reportModel.GetRow(5) == null) reportModel.CreateRow(5);
|
||||
if (reportModel.GetRow(5).GetCell(2) == null) reportModel.GetRow(5).CreateCell(2);
|
||||
reportModel.GetRow(5).GetCell(2).SetCellValue(eva.FO_NO);
|
||||
if (reportModel.GetRow(5).GetCell(6) == null) reportModel.GetRow(5).CreateCell(6);
|
||||
if (eva.Validate_Date.HasValue)
|
||||
{
|
||||
reportModel.GetRow(6).GetCell(6).SetCellValue(eva.Validate_Date.Value.ToString("yyyy/MM/dd"));
|
||||
reportModel.GetRow(5).GetCell(6).SetCellValue(eva.Validate_Date.Value.ToString("yyyy/MM/dd"));
|
||||
//reportModel.GetRow(6).GetCell(6).CellStyle = styleDate;
|
||||
}
|
||||
if (reportModel.GetRow(6).GetCell(8) == null) reportModel.GetRow(6).CreateCell(8);
|
||||
if (reportModel.GetRow(5).GetCell(8) == null) reportModel.GetRow(5).CreateCell(8);
|
||||
if (eva.Expire_Date.HasValue)
|
||||
{
|
||||
reportModel.GetRow(6).GetCell(8).SetCellValue(eva.Expire_Date.Value.ToString("yyyy/MM/dd"));
|
||||
reportModel.GetRow(5).GetCell(8).SetCellValue(eva.Expire_Date.Value.ToString("yyyy/MM/dd"));
|
||||
//reportModel.GetRow(6).GetCell(8).CellStyle = styleDate;
|
||||
}
|
||||
|
||||
|
||||
//8行
|
||||
if (reportModel.GetRow(7) == null) reportModel.CreateRow(7);
|
||||
if (reportModel.GetRow(7).GetCell(2) == null) reportModel.GetRow(7).CreateCell(2);
|
||||
reportModel.GetRow(7).GetCell(2).SetCellValue(eva.Contractor);
|
||||
if (reportModel.GetRow(7).GetCell(8) == null) reportModel.GetRow(7).CreateCell(8);
|
||||
reportModel.GetRow(7).GetCell(8).SetCellValue(eva.VolumeAllocation);
|
||||
//7行
|
||||
if (reportModel.GetRow(6) == null) reportModel.CreateRow(6);
|
||||
if (reportModel.GetRow(6).GetCell(2) == null) reportModel.GetRow(6).CreateCell(2);
|
||||
reportModel.GetRow(6).GetCell(2).SetCellValue(eva.Contractor);
|
||||
if (reportModel.GetRow(6).GetCell(8) == null) reportModel.GetRow(6).CreateCell(8);
|
||||
reportModel.GetRow(6).GetCell(8).SetCellValue(eva.VolumeAllocation);
|
||||
|
||||
//9行
|
||||
if (reportModel.GetRow(8) == null) reportModel.CreateRow(8);
|
||||
|
@ -433,26 +433,26 @@ namespace FineUIPro.Web.Evaluation
|
|||
if (sesDataScore.Count(p => p.dataMonth == curDate.ToString("yyyy-MM")) > 0 && Funs.GetNewDecimal(sesDataScore.FirstOrDefault(p => p.dataMonth == curDate.ToString("yyyy-MM")).SumScore) > 0)
|
||||
{
|
||||
var yearNums = float.Parse(sesDataScore.FirstOrDefault(p => p.dataMonth == curDate.ToString("yyyy-MM")).SumScore).ToString("0.##");
|
||||
reportModel.GetRow(13 + j).GetCell(1).SetCellValue(yearNums);
|
||||
reportModel.GetRow(13 + j).GetCell(2).SetCellValue(yearNums);
|
||||
}
|
||||
else
|
||||
{
|
||||
reportModel.GetRow(13 + j).GetCell(1).SetCellValue("");
|
||||
reportModel.GetRow(13 + j).GetCell(2).SetCellValue("");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (reportModel.GetRow(13 + j - 12).GetCell(2) == null) reportModel.GetRow(13 + j - 12).CreateCell(2);
|
||||
reportModel.GetRow(13 + j - 12).GetCell(2).SetCellValue(curDate.ToString("yyyy-MM"));
|
||||
if (reportModel.GetRow(13 + j - 12).GetCell(3) == null) reportModel.GetRow(13 + j - 12).CreateCell(3);
|
||||
reportModel.GetRow(13 + j - 12).GetCell(3).SetCellValue(curDate.ToString("yyyy-MM"));
|
||||
|
||||
if (sesDataScore.Count(p => p.dataMonth == curDate.ToString("yyyy-MM")) > 0 && Funs.GetNewDecimal(sesDataScore.FirstOrDefault(p => p.dataMonth == curDate.ToString("yyyy-MM")).SumScore) > 0)
|
||||
{
|
||||
var yearNums = float.Parse(sesDataScore.FirstOrDefault(p => p.dataMonth == curDate.ToString("yyyy-MM")).SumScore).ToString("0.##");
|
||||
reportModel.GetRow(13 + j - 12).GetCell(3).SetCellValue(yearNums);
|
||||
reportModel.GetRow(13 + j - 12).GetCell(4).SetCellValue(yearNums);
|
||||
}
|
||||
else
|
||||
{
|
||||
reportModel.GetRow(13 + j - 12).GetCell(3).SetCellValue("");
|
||||
reportModel.GetRow(13 + j - 12).GetCell(4).SetCellValue("");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -542,6 +542,8 @@ namespace FineUIPro.Web.Evaluation
|
|||
//reportModel.GetRow(20).GetCell(5).SetCellValue(priceLevel);
|
||||
|
||||
// 28
|
||||
if (reportModel.GetRow(26) == null) reportModel.CreateRow(26);
|
||||
if (reportModel.GetRow(27) == null) reportModel.CreateRow(27);
|
||||
if (reportModel.GetRow(28) == null) reportModel.CreateRow(28);
|
||||
if (reportModel.GetRow(29) == null) reportModel.CreateRow(29);
|
||||
if (reportModel.GetRow(31) == null) reportModel.CreateRow(31);
|
||||
|
@ -553,220 +555,189 @@ namespace FineUIPro.Web.Evaluation
|
|||
if (reportModel.GetRow(37) == null) reportModel.CreateRow(37);
|
||||
if (reportModel.GetRow(38) == null) reportModel.CreateRow(38);
|
||||
if (reportModel.GetRow(39) == null) reportModel.CreateRow(39);
|
||||
//if (reportModel.GetRow(40) == null) reportModel.CreateRow(40);
|
||||
//if (reportModel.GetRow(41) == null) reportModel.CreateRow(41);
|
||||
//if (reportModel.GetRow(42) == null) reportModel.CreateRow(42);
|
||||
if (reportModel.GetRow(42) == null) reportModel.CreateRow(42);
|
||||
|
||||
if (reportModel.GetRow(43) == null) reportModel.CreateRow(43);
|
||||
if (reportModel.GetRow(44) == null) reportModel.CreateRow(44);
|
||||
if (reportModel.GetRow(45) == null) reportModel.CreateRow(45);
|
||||
if (reportModel.GetRow(46) == null) reportModel.CreateRow(46);
|
||||
if (reportModel.GetRow(47) == null) reportModel.CreateRow(47);
|
||||
if (reportModel.GetRow(48) == null) reportModel.CreateRow(48);
|
||||
//if (reportModel.GetRow(43) == null) reportModel.CreateRow(43);
|
||||
//if (reportModel.GetRow(44) == null) reportModel.CreateRow(44);
|
||||
//if (reportModel.GetRow(45) == null) reportModel.CreateRow(45);
|
||||
//if (reportModel.GetRow(46) == null) reportModel.CreateRow(46);
|
||||
//if (reportModel.GetRow(47) == null) reportModel.CreateRow(47);
|
||||
//if (reportModel.GetRow(48) == null) reportModel.CreateRow(48);
|
||||
|
||||
if (reportModel.GetRow(49) == null) reportModel.CreateRow(49);
|
||||
if (reportModel.GetRow(50) == null) reportModel.CreateRow(50);
|
||||
if (reportModel.GetRow(51) == null) reportModel.CreateRow(51);
|
||||
if (reportModel.GetRow(52) == null) reportModel.CreateRow(52);
|
||||
if (reportModel.GetRow(53) == null) reportModel.CreateRow(53);
|
||||
//if (reportModel.GetRow(49) == null) reportModel.CreateRow(49);
|
||||
//if (reportModel.GetRow(50) == null) reportModel.CreateRow(50);
|
||||
//if (reportModel.GetRow(51) == null) reportModel.CreateRow(51);
|
||||
//if (reportModel.GetRow(52) == null) reportModel.CreateRow(52);
|
||||
//if (reportModel.GetRow(53) == null) reportModel.CreateRow(53);
|
||||
|
||||
|
||||
if (reportModel.GetRow(29).GetCell(5) == null) reportModel.GetRow(29).CreateCell(5);
|
||||
reportModel.GetRow(29).GetCell(5).SetCellValue(eva.ReviewOfFC);
|
||||
if (reportModel.GetRow(26).GetCell(5) == null) reportModel.GetRow(26).CreateCell(5);
|
||||
reportModel.GetRow(26).GetCell(5).SetCellValue(eva.ReviewOfFC);
|
||||
|
||||
if (eva.IsInquiry == true)
|
||||
{
|
||||
|
||||
reportModel.GetRow(29).GetCell(1).SetCellValue(eva.InquiryNum != null ? eva.InquiryNum.Value.ToString() : "0");
|
||||
reportModel.GetRow(28).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(28).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(27).GetCell(1).SetCellValue(eva.InquiryNum != null ? eva.InquiryNum.Value.ToString() : "0");
|
||||
reportModel.GetRow(26).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(26).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else if (eva.IsInquiry == false)
|
||||
{
|
||||
reportModel.GetRow(29).GetCell(1).SetCellValue("");
|
||||
reportModel.GetRow(28).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(28).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(27).GetCell(1).SetCellValue("");
|
||||
reportModel.GetRow(26).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(26).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else
|
||||
{
|
||||
reportModel.GetRow(28).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(28).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(28).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(28).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(26).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(26).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(26).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(26).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
|
||||
if (eva.NCRIsReview == true)
|
||||
{
|
||||
|
||||
reportModel.GetRow(33).GetCell(1).SetCellValue(eva.NCRReviewNum != null ? eva.NCRReviewNum.Value.ToString() : "0");
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(30).GetCell(1).SetCellValue(eva.NCRReviewNum != null ? eva.NCRReviewNum.Value.ToString() : "0");
|
||||
reportModel.GetRow(29).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(29).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else if (eva.NCRIsReview == false)
|
||||
{
|
||||
reportModel.GetRow(33).GetCell(1).SetCellValue("");
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(30).GetCell(1).SetCellValue("");
|
||||
reportModel.GetRow(29).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(29).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else
|
||||
{
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(29).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(29).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(29).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(29).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
|
||||
//string auditResult = string.Empty;
|
||||
if (eva.AuditResult == "1")
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
if (eva.AuditResult == "2")
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
if (eva.AuditResult == "3")
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
if (eva.AuditResult == "4")
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
if (eva.AuditResult == "5")
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
if (eva.AuditResult == "6")
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
|
||||
}
|
||||
if (string.IsNullOrEmpty(eva.AuditResult))
|
||||
{
|
||||
reportModel.GetRow(32).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(32).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(32).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(33).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(33).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(34).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(34).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
|
||||
|
||||
if (eva.IsOthers == true)
|
||||
{
|
||||
|
||||
reportModel.GetRow(37).GetCell(1).SetCellValue(eva.OtherDef);
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else if (eva.IsOthers == false)
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else
|
||||
{
|
||||
reportModel.GetRow(36).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(36).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(36).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(37).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(37).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(38).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(38).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
|
||||
// 去年CT/K
|
||||
//if (eva.BoQIsAudit == true)
|
||||
//{
|
||||
// reportModel.GetRow(41).GetCell(0).SetCellValue(txtNo);
|
||||
// reportModel.GetRow(41).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
// if (eva.BoQAuditComments.Length > 0 && eva.BoQAuditComments.Length <= 6)
|
||||
// {
|
||||
// reportModel.GetRow(41).GetCell(4).SetCellValue(eva.BoQAuditComments);
|
||||
|
||||
// }
|
||||
// if (eva.BoQAuditComments.Length > 6)
|
||||
// {
|
||||
// reportModel.GetRow(41).GetCell(4).SetCellValue(eva.BoQAuditComments.Substring(0, 6));
|
||||
// reportModel.GetRow(42).GetCell(0).SetCellValue(eva.BoQAuditComments.Substring(6, eva.BoQAuditComments.Length - 6));
|
||||
// }
|
||||
|
||||
//}
|
||||
//else if (eva.BoQIsAudit == false)
|
||||
//{
|
||||
// reportModel.GetRow(41).GetCell(2).SetCellValue(txtNo);
|
||||
// reportModel.GetRow(41).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// reportModel.GetRow(41).GetCell(0).SetCellValue(txtNo);
|
||||
// reportModel.GetRow(41).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
// reportModel.GetRow(41).GetCell(2).SetCellValue(txtNo);
|
||||
// reportModel.GetRow(41).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
//}
|
||||
|
||||
if (eva.IsOthers == true)
|
||||
{
|
||||
|
||||
reportModel.GetRow(46).GetCell(1).SetCellValue(eva.OtherDef);
|
||||
reportModel.GetRow(45).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(45).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else if (eva.IsOthers == false)
|
||||
{
|
||||
reportModel.GetRow(45).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(45).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
else
|
||||
{
|
||||
reportModel.GetRow(45).GetCell(0).SetCellValue(txtNo);
|
||||
reportModel.GetRow(45).GetCell(0).CellStyle.SetFont(content_Font);
|
||||
reportModel.GetRow(45).GetCell(2).SetCellValue(txtNo);
|
||||
reportModel.GetRow(45).GetCell(2).CellStyle.SetFont(content_Font);
|
||||
}
|
||||
|
||||
if (reportModel.GetRow(48).GetCell(3) == null) reportModel.GetRow(48).CreateCell(3);
|
||||
reportModel.GetRow(48).GetCell(3).SetCellValue(eva.TechnicalBonus);
|
||||
if (reportModel.GetRow(50).GetCell(3) == null) reportModel.GetRow(50).CreateCell(3);
|
||||
reportModel.GetRow(50).GetCell(3).SetCellValue(eva.SafetyBonus);
|
||||
reportModel.GetRow(53).GetCell(0).SetCellValue(eva.Proposed);
|
||||
if (reportModel.GetRow(38).GetCell(3) == null) reportModel.GetRow(38).CreateCell(3);
|
||||
reportModel.GetRow(38).GetCell(3).SetCellValue(eva.TechnicalBonus);
|
||||
if (reportModel.GetRow(39).GetCell(3) == null) reportModel.GetRow(39).CreateCell(3);
|
||||
reportModel.GetRow(39).GetCell(3).SetCellValue(eva.SafetyBonus);
|
||||
reportModel.GetRow(42).GetCell(0).SetCellValue(eva.Proposed);
|
||||
}
|
||||
#endregion
|
||||
reportModel.ForceFormulaRecalculation = true;
|
||||
|
|
Binary file not shown.
Binary file not shown.
|
@ -47,9 +47,13 @@
|
|||
<OutputPath>bin\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<WarningLevel>1</WarningLevel>
|
||||
<LangVersion>7.3</LangVersion>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
<DeployEncryptKey>加密密码仅在任何部署设置标记为安全时使用</DeployEncryptKey>
|
||||
<LegacyPublishPropertiesPageEnabled>true</LegacyPublishPropertiesPageEnabled>
|
||||
<IncludeIisSettings>false</IncludeIisSettings>
|
||||
<PublishDatabases>true</PublishDatabases>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="BouncyCastle.Crypto, Version=1.8.9.0, Culture=neutral, PublicKeyToken=0e99375e54769942, processorArchitecture=MSIL">
|
||||
|
@ -192,6 +196,8 @@
|
|||
<Content Include="BaseInfo\TaxRate.aspx" />
|
||||
<Content Include="BaseInfo\TemplateType.aspx" />
|
||||
<Content Include="BaseInfo\Type.aspx" />
|
||||
<Content Include="BaseInfo\ViolationClause.aspx" />
|
||||
<Content Include="BaseInfo\ViolationClauseEdit.aspx" />
|
||||
<Content Include="CCP\CcpEdit.aspx" />
|
||||
<Content Include="CCP\CcpList.aspx" />
|
||||
<Content Include="CCP\CCPUpload.aspx" />
|
||||
|
@ -354,6 +360,7 @@
|
|||
<Content Include="Images\face_ku_bottom.png" />
|
||||
<Content Include="Images\face_ku_top.png" />
|
||||
<Content Include="Images\focus.swf" />
|
||||
<Content Include="Images\Login.jpg" />
|
||||
<Content Include="Images\LoginHSSE.jpg" />
|
||||
<Content Include="Images\love_gary.png" />
|
||||
<Content Include="Images\love_red.png" />
|
||||
|
@ -2172,6 +2179,7 @@
|
|||
<Content Include="res\images\errortip.gif" />
|
||||
<Content Include="res\images\expand-all.gif" />
|
||||
<Content Include="res\images\f.png" />
|
||||
<Content Include="res\images\face_happy_top.png" />
|
||||
<Content Include="res\images\fa_png\chevron-down_ffffff_16.png" />
|
||||
<Content Include="res\images\fa_png\chevron-up_ffffff_16.png" />
|
||||
<Content Include="res\images\fa_png\close_ffffff_16.png" />
|
||||
|
@ -2215,6 +2223,7 @@
|
|||
<Content Include="res\images\loading\loading_bar.gif" />
|
||||
<Content Include="res\images\loading\readme.txt" />
|
||||
<Content Include="res\images\login.png" />
|
||||
<Content Include="res\images\loginpwd.png" />
|
||||
<Content Include="res\images\logo\favicon.gif" />
|
||||
<Content Include="res\images\logo\favicon.ico" />
|
||||
<Content Include="res\images\logo\favicon.jpg" />
|
||||
|
@ -2244,6 +2253,7 @@
|
|||
<Content Include="res\images\pagemenu-separator.gif" />
|
||||
<Content Include="res\images\pagemenu_toolbar_background.gif" />
|
||||
<Content Include="res\images\pkg.gif" />
|
||||
<Content Include="res\images\sanjiao.png" />
|
||||
<Content Include="res\images\snapshot\1.png" />
|
||||
<Content Include="res\images\snapshot\10.png" />
|
||||
<Content Include="res\images\snapshot\11.png" />
|
||||
|
@ -2382,6 +2392,7 @@
|
|||
<Content Include="res\images\up.png" />
|
||||
<Content Include="res\images\visa.png" />
|
||||
<Content Include="res\images\zsxq.jpg" />
|
||||
<Content Include="res\images\账号密码登录.png" />
|
||||
<Content Include="res\index\css\font\iconfont.svg" />
|
||||
<Content Include="res\index\css\home.css" />
|
||||
<Content Include="res\index\css\index.css" />
|
||||
|
@ -2758,6 +2769,20 @@
|
|||
<Compile Include="BaseInfo\Type.aspx.designer.cs">
|
||||
<DependentUpon>Type.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BaseInfo\ViolationClause.aspx.cs">
|
||||
<DependentUpon>ViolationClause.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="BaseInfo\ViolationClause.aspx.designer.cs">
|
||||
<DependentUpon>ViolationClause.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BaseInfo\ViolationClauseEdit.aspx.cs">
|
||||
<DependentUpon>ViolationClauseEdit.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="BaseInfo\ViolationClauseEdit.aspx.designer.cs">
|
||||
<DependentUpon>ViolationClauseEdit.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="CCP\CcpEdit.aspx.cs">
|
||||
<DependentUpon>CcpEdit.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ProjectView>ProjectFiles</ProjectView>
|
||||
<ProjectView>ShowAllFiles</ProjectView>
|
||||
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
|
||||
<UseIISExpress>true</UseIISExpress>
|
||||
<Use64BitIISExpress>
|
||||
|
@ -11,7 +11,7 @@
|
|||
<IISExpressWindowsAuthentication />
|
||||
<IISExpressUseClassicPipelineMode />
|
||||
<UseGlobalApplicationHostFile />
|
||||
<NameOfLastUsedPublishProfile>E:\MyProject\FCL\Basf_FCL\FCL\FineUIPro.Web\Properties\PublishProfiles\FolderProfile.pubxml</NameOfLastUsedPublishProfile>
|
||||
<NameOfLastUsedPublishProfile>FolderProfile</NameOfLastUsedPublishProfile>
|
||||
</PropertyGroup>
|
||||
<ProjectExtensions>
|
||||
<VisualStudio>
|
||||
|
|
|
@ -159,7 +159,18 @@
|
|||
if (DateTime.Now.Hour == 10)
|
||||
{
|
||||
System.Timers.Timer aTimer = new System.Timers.Timer();
|
||||
aTimer.Elapsed += new System.Timers.ElapsedEventHandler(RelatedSes_EmailSend);
|
||||
aTimer.Elapsed += new System.Timers.ElapsedEventHandler(Safe_RelatedSes_EmailSend);
|
||||
//60分钟执行一次
|
||||
aTimer.Interval = 1000 * 3 * 60 * 60;
|
||||
aTimer.Enabled = true;
|
||||
aTimer.Start();
|
||||
}
|
||||
|
||||
// 承包商质量违规关联SES号的填写通知
|
||||
if (DateTime.Now.Hour == 10)
|
||||
{
|
||||
System.Timers.Timer aTimer = new System.Timers.Timer();
|
||||
aTimer.Elapsed += new System.Timers.ElapsedEventHandler(CQuality_RelatedSes_EmailSend);
|
||||
//60分钟执行一次
|
||||
aTimer.Interval = 1000 * 3 * 60 * 60;
|
||||
aTimer.Enabled = true;
|
||||
|
@ -1418,14 +1429,15 @@
|
|||
BLL.SQLHelper.ExecutSql(strSql);
|
||||
}
|
||||
|
||||
#region 承包商EHSS违规关联SES号的填写通知
|
||||
private void RelatedSes_EmailSend(object sender, System.Timers.ElapsedEventArgs e)
|
||||
#region 承包商EHSS违规关联SES号的填写通知(5天后如还没录入再发邮件提醒)
|
||||
private void Safe_RelatedSes_EmailSend(object sender, System.Timers.ElapsedEventArgs e)
|
||||
{
|
||||
var vses = (from x in Funs.DB.EMC_Punishment
|
||||
where (x.RelatedSesMailIsSend == null || x.RelatedSesMailIsSend == false)
|
||||
&& x.BYC_RU != null && x.BYC_RU.ToUpper() != "NA"
|
||||
&& x.CreateDate.HasValue && x.CreateDate.Value.AddDays(1).Date <= DateTime.Now.Date
|
||||
select x).ToList();
|
||||
where (x.RelatedSesMailIsSend2 == null || x.RelatedSesMailIsSend2 == false)
|
||||
&& x.BYC_RU != null && x.BYC_RU.ToUpper() != "NA" && x.Flag == "1"
|
||||
&& (x.ViolationRelatedSes == null || x.ViolationRelatedSes == "")
|
||||
&& x.CreateDate.HasValue && x.CreateDate.Value.AddDays(5).Date <= DateTime.Now.Date
|
||||
select x).ToList();
|
||||
if (vses.Count() > 0)
|
||||
{
|
||||
Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
|
@ -1484,7 +1496,68 @@
|
|||
|
||||
if (result)
|
||||
{
|
||||
ses.RelatedSesMailIsSend = true;
|
||||
ses.RelatedSesMailIsSend2 = true;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 承包商质量违规关联SES号的填写通知(5天后如还没录入SES再发邮件提醒)
|
||||
private void CQuality_RelatedSes_EmailSend(object sender, System.Timers.ElapsedEventArgs e)
|
||||
{
|
||||
var vses = (from x in Funs.DB.EMC_Punishment
|
||||
where (x.RelatedSesMailIsSend2 == null || x.RelatedSesMailIsSend2 == false)
|
||||
&& x.BYC_RU != null && x.BYC_RU.ToUpper() != "NA" && x.Flag == "2"
|
||||
&& (x.ViolationRelatedSes == null || x.ViolationRelatedSes == "")
|
||||
&& x.CreateDate.HasValue && x.CreateDate.Value.AddDays(5).Date <= DateTime.Now.Date
|
||||
select x).ToList();
|
||||
if (vses.Count() > 0)
|
||||
{
|
||||
Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
if (pops == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
foreach (var ses in vses)
|
||||
{
|
||||
string[] mailTo = null;
|
||||
string[] mailCC = null;
|
||||
string resultMessage = "";
|
||||
|
||||
var emailTemplate = Funs.DB.SendEmailTemplate.Where(x => x.EmailName.Contains("承包商质量违规关联SES号的填写通知"));
|
||||
if (emailTemplate.Count() > 0)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(ses.BYC_RU);
|
||||
if (dep != null && !string.IsNullOrEmpty(dep.DepartLeader))
|
||||
{
|
||||
var userTo = from x in Funs.DB.Sys_User
|
||||
where x.UserId == dep.DepartLeader
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
if (userTo != null)
|
||||
{
|
||||
mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
}
|
||||
|
||||
if (mailTo.Length > 0)
|
||||
{
|
||||
NameValueCollection myPram = new NameValueCollection();
|
||||
myPram.Add("ContractNo", ses.FO_NO);
|
||||
myPram.Add("Contractor", ses.Contractor);
|
||||
myPram.Add("Date", ses.PunishDate != null ? ses.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
myPram.Add("Time", ses.PunishDate != null ? ses.PunishDate.Value.ToString("HH:mm") : "");
|
||||
myPram.Add("Violation Description", ses.Description);
|
||||
bool result = MailHelper.SendPunishSesMail(pops, myPram, "承包商质量违规关联SES号的填写通知", mailTo, mailCC, out resultMessage);
|
||||
|
||||
if (result)
|
||||
{
|
||||
ses.RelatedSesMailIsSend2 = true;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<body>
|
||||
<div id="wrapper" class="dec-login bi-absolute-layout dec-login-fresh">
|
||||
<img alt="" class="bi-single bi-img display-block"
|
||||
src="./images/login.png"
|
||||
src="res/index/images/login.png"
|
||||
style="width: 100%; left: 0px; top: 0px; bottom: 0px; position: absolute; display: none;" />
|
||||
<img alt=""
|
||||
src="res/index/images/iconlogo.png"
|
||||
|
|
|
@ -5,7 +5,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<Project>
|
||||
<PropertyGroup>
|
||||
<_PublishTargetUrl>E:\MyProject\FCL\publish</_PublishTargetUrl>
|
||||
<History>True|2024-06-06T06:31:50.5127502Z;False|2024-06-06T14:31:16.3526634+08:00;</History>
|
||||
<History>True|2024-07-31T07:35:50.0766900Z;True|2024-06-06T14:31:50.5127502+08:00;False|2024-06-06T14:31:16.3526634+08:00;</History>
|
||||
<LastFailureDetails />
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
|
@ -88,13 +88,13 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>04/07/2013 11:49:08</publishTime>
|
||||
</File>
|
||||
<File Include="bin/BLL.dll">
|
||||
<publishTime>06/06/2024 14:10:36</publishTime>
|
||||
<publishTime>07/30/2024 11:40:08</publishTime>
|
||||
</File>
|
||||
<File Include="bin/BLL.dll.config">
|
||||
<publishTime>05/08/2024 17:32:08</publishTime>
|
||||
<publishTime>06/07/2024 11:50:17</publishTime>
|
||||
</File>
|
||||
<File Include="bin/BLL.pdb">
|
||||
<publishTime>06/06/2024 14:10:36</publishTime>
|
||||
<publishTime>07/30/2024 11:40:08</publishTime>
|
||||
</File>
|
||||
<File Include="bin/BouncyCastle.Crypto.dll">
|
||||
<publishTime>12/17/2020 21:32:28</publishTime>
|
||||
|
@ -145,10 +145,10 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>01/25/2021 00:01:36</publishTime>
|
||||
</File>
|
||||
<File Include="bin/FineUIPro.Web.dll">
|
||||
<publishTime>06/06/2024 14:31:13</publishTime>
|
||||
<publishTime>07/30/2024 11:40:17</publishTime>
|
||||
</File>
|
||||
<File Include="bin/FineUIPro.Web.pdb">
|
||||
<publishTime>06/06/2024 14:31:13</publishTime>
|
||||
<publishTime>07/30/2024 11:40:17</publishTime>
|
||||
</File>
|
||||
<File Include="bin/fr/Microsoft.ReportViewer.Common.resources.dll">
|
||||
<publishTime>09/25/2021 22:14:24</publishTime>
|
||||
|
@ -228,6 +228,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="bin/ko/Microsoft.ReportViewer.WinForms.resources.dll">
|
||||
<publishTime>09/25/2021 22:14:24</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.Bcl.AsyncInterfaces.dll">
|
||||
<publishTime>11/15/2019 16:38:12</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.Build.Framework.dll">
|
||||
<publishTime>07/07/2015 00:51:38</publishTime>
|
||||
</File>
|
||||
|
@ -237,6 +240,18 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="bin/Microsoft.Build.Utilities.Core.dll">
|
||||
<publishTime>07/07/2015 00:51:38</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.IdentityModel.Abstractions.dll">
|
||||
<publishTime>05/27/2024 11:42:00</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.IdentityModel.JsonWebTokens.dll">
|
||||
<publishTime>08/26/2022 03:31:30</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.IdentityModel.Logging.dll">
|
||||
<publishTime>05/27/2024 11:42:12</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.IdentityModel.Tokens.dll">
|
||||
<publishTime>08/26/2022 03:39:42</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Microsoft.MSXML.dll">
|
||||
<publishTime>10/22/2009 19:51:18</publishTime>
|
||||
</File>
|
||||
|
@ -301,10 +316,10 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>04/22/2008 00:08:00</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Model.dll">
|
||||
<publishTime>06/06/2024 14:10:35</publishTime>
|
||||
<publishTime>07/30/2024 11:40:08</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Model.pdb">
|
||||
<publishTime>06/06/2024 14:10:35</publishTime>
|
||||
<publishTime>07/30/2024 11:40:08</publishTime>
|
||||
</File>
|
||||
<File Include="bin/Newtonsoft.Json.dll">
|
||||
<publishTime>03/17/2021 20:03:36</publishTime>
|
||||
|
@ -372,6 +387,33 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="bin/stdole.dll">
|
||||
<publishTime>12/21/2009 11:40:04</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Buffers.dll">
|
||||
<publishTime>02/19/2020 10:05:18</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.IdentityModel.Tokens.Jwt.dll">
|
||||
<publishTime>08/26/2022 03:28:28</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Memory.dll">
|
||||
<publishTime>05/08/2022 03:31:02</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Numerics.Vectors.dll">
|
||||
<publishTime>05/15/2018 21:29:44</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Runtime.CompilerServices.Unsafe.dll">
|
||||
<publishTime>09/13/2019 10:28:42</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Text.Encodings.Web.dll">
|
||||
<publishTime>02/17/2021 03:13:28</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Text.Json.dll">
|
||||
<publishTime>09/13/2019 10:29:04</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.Threading.Tasks.Extensions.dll">
|
||||
<publishTime>02/19/2020 10:05:18</publishTime>
|
||||
</File>
|
||||
<File Include="bin/System.ValueTuple.dll">
|
||||
<publishTime>05/15/2018 21:29:52</publishTime>
|
||||
</File>
|
||||
<File Include="bin/ThoughtWorks.QRCode.dll">
|
||||
<publishTime>03/25/2012 12:12:28</publishTime>
|
||||
</File>
|
||||
|
@ -430,7 +472,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>07/07/2015 01:25:08</publishTime>
|
||||
</File>
|
||||
<File Include="CCP/CcpEdit.aspx">
|
||||
<publishTime>08/31/2022 15:13:42</publishTime>
|
||||
<publishTime>07/29/2024 15:12:33</publishTime>
|
||||
</File>
|
||||
<File Include="CCP/CcpList.aspx">
|
||||
<publishTime>01/11/2024 15:40:17</publishTime>
|
||||
|
@ -451,7 +493,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>06/11/2020 19:37:26</publishTime>
|
||||
</File>
|
||||
<File Include="common/Main.aspx">
|
||||
<publishTime>06/19/2023 08:30:20</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="common/MainSearch.aspx">
|
||||
<publishTime>04/15/2021 11:11:21</publishTime>
|
||||
|
@ -847,7 +889,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>01/11/2024 14:30:56</publishTime>
|
||||
</File>
|
||||
<File Include="CPT/SESReportToCPTEdit.aspx">
|
||||
<publishTime>06/19/2023 08:30:11</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="default.htm">
|
||||
<publishTime>12/12/2019 17:18:47</publishTime>
|
||||
|
@ -868,10 +910,10 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>05/15/2024 14:29:29</publishTime>
|
||||
</File>
|
||||
<File Include="Evaluation/Evaluation.aspx">
|
||||
<publishTime>06/19/2023 08:30:05</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="Evaluation/EvaluationNew.aspx">
|
||||
<publishTime>06/06/2024 12:35:26</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="Evaluation/EvaluationReport.aspx">
|
||||
<publishTime>09/25/2023 09:09:25</publishTime>
|
||||
|
@ -889,7 +931,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>03/25/2024 15:29:42</publishTime>
|
||||
</File>
|
||||
<File Include="Evaluation/SafetyEvaluation.aspx">
|
||||
<publishTime>09/04/2023 15:00:51</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="favicon.ico">
|
||||
<publishTime>04/15/2016 14:48:15</publishTime>
|
||||
|
@ -930,6 +972,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="Images/focus.swf">
|
||||
<publishTime>12/10/2019 21:41:32</publishTime>
|
||||
</File>
|
||||
<File Include="Images/Login.jpg">
|
||||
<publishTime>09/21/2020 13:22:38</publishTime>
|
||||
</File>
|
||||
<File Include="Images/LoginHSSE.jpg">
|
||||
<publishTime>01/17/2020 14:44:26</publishTime>
|
||||
</File>
|
||||
|
@ -1006,10 +1051,13 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>01/26/2021 10:54:06</publishTime>
|
||||
</File>
|
||||
<File Include="KPI/KPI.aspx">
|
||||
<publishTime>06/19/2023 08:29:47</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="Login.aspx">
|
||||
<publishTime>06/04/2024 14:04:00</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="loginApi.aspx">
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="LogOff.aspx">
|
||||
<publishTime>12/12/2019 10:59:58</publishTime>
|
||||
|
@ -6387,6 +6435,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="res/images/f.png">
|
||||
<publishTime>12/12/2019 15:20:16</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/face_happy_top.png">
|
||||
<publishTime>12/10/2019 21:41:32</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/fa_png/chevron-down_ffffff_16.png">
|
||||
<publishTime>12/12/2019 15:20:16</publishTime>
|
||||
</File>
|
||||
|
@ -6516,6 +6567,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="res/images/login.png">
|
||||
<publishTime>12/12/2019 15:20:16</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/loginpwd.png">
|
||||
<publishTime>04/23/2024 11:14:54</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/logo/favicon.gif">
|
||||
<publishTime>12/12/2019 15:20:16</publishTime>
|
||||
</File>
|
||||
|
@ -6609,6 +6663,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="res/images/pkg.gif">
|
||||
<publishTime>12/12/2019 15:20:16</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/sanjiao.png">
|
||||
<publishTime>04/23/2024 11:41:36</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/snapshot/1.png">
|
||||
<publishTime>12/12/2019 15:20:16</publishTime>
|
||||
</File>
|
||||
|
@ -7023,6 +7080,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="res/images/zsxq.jpg">
|
||||
<publishTime>12/12/2019 15:20:17</publishTime>
|
||||
</File>
|
||||
<File Include="res/images/账号密码登录.png">
|
||||
<publishTime>04/23/2024 11:14:46</publishTime>
|
||||
</File>
|
||||
<File Include="res/index/css/font/digifacewide.ttf">
|
||||
<publishTime>03/12/2021 09:15:30</publishTime>
|
||||
</File>
|
||||
|
@ -7371,6 +7431,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="res/themes/pure_red/theme.css">
|
||||
<publishTime>12/12/2019 15:20:18</publishTime>
|
||||
</File>
|
||||
<File Include="Scripts/ajax.js">
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="Scripts/echarts/dist/chart/bar.js">
|
||||
<publishTime>01/05/2020 18:07:23</publishTime>
|
||||
</File>
|
||||
|
@ -7452,6 +7515,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="Scripts/jquery-3.6.4.min.js">
|
||||
<publishTime>06/19/2023 08:28:09</publishTime>
|
||||
</File>
|
||||
<File Include="Scripts/jquery-3.7.1.min.js">
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="Scripts/jquery.autocomplete.js">
|
||||
<publishTime>12/10/2019 21:41:53</publishTime>
|
||||
</File>
|
||||
|
@ -7485,6 +7551,9 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<File Include="Scripts/markingSystem.js">
|
||||
<publishTime>12/10/2019 21:41:53</publishTime>
|
||||
</File>
|
||||
<File Include="Scripts/md5.js">
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="Scripts/startScore.js">
|
||||
<publishTime>12/17/2019 11:26:16</publishTime>
|
||||
</File>
|
||||
|
@ -7519,10 +7588,10 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>05/24/2024 10:47:58</publishTime>
|
||||
</File>
|
||||
<File Include="SES/CQualityPunish.aspx">
|
||||
<publishTime>08/28/2023 15:59:09</publishTime>
|
||||
<publishTime>07/25/2024 11:53:43</publishTime>
|
||||
</File>
|
||||
<File Include="SES/CQualityPunishEdit.aspx">
|
||||
<publishTime>07/17/2023 10:43:13</publishTime>
|
||||
<publishTime>07/25/2024 11:18:59</publishTime>
|
||||
</File>
|
||||
<File Include="SES/CSafePunish.aspx">
|
||||
<publishTime>05/09/2024 14:27:40</publishTime>
|
||||
|
@ -7561,7 +7630,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>05/26/2021 15:41:19</publishTime>
|
||||
</File>
|
||||
<File Include="SES/SESEvaluateList.aspx">
|
||||
<publishTime>06/19/2023 08:29:35</publishTime>
|
||||
<publishTime>07/01/2024 10:13:54</publishTime>
|
||||
</File>
|
||||
<File Include="SES/SESRelatedData.aspx">
|
||||
<publishTime>03/20/2024 17:07:45</publishTime>
|
||||
|
@ -7651,7 +7720,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<publishTime>12/18/2019 14:31:02</publishTime>
|
||||
</File>
|
||||
<File Include="Web.config">
|
||||
<publishTime>06/06/2024 14:31:15</publishTime>
|
||||
<publishTime>07/31/2024 15:35:45</publishTime>
|
||||
</File>
|
||||
</ItemGroup>
|
||||
</Project>
|
|
@ -33,6 +33,8 @@
|
|||
</f:Button>
|
||||
<f:Button ID="btnEdit" ToolTip="Modify" Text="Modify" Icon="Pencil" runat="server" OnClick="btnEdit_Click" Hidden="true">
|
||||
</f:Button>
|
||||
<f:Button ID="btnAudit" ToolTip="Audit" Text="Audit" Icon="Pencil" runat="server" OnClick="btnAudit_Click" >
|
||||
</f:Button>
|
||||
<f:Button ID="btnDelete" ToolTip="Delete" Text="Delete" Icon="Delete" ConfirmText="Make sure to delete the current data?" OnClick="btnDelete_Click"
|
||||
runat="server" Hidden="true">
|
||||
</f:Button>
|
||||
|
@ -56,6 +58,8 @@
|
|||
<f:RenderField Width="130px" ColumnID="FO_NO" DataField="FO_NO"
|
||||
SortField="FO_NO" FieldType="String" HeaderText="Contract No." HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderCheckField Width="80px" ColumnID="IsFrame" DataField="IsFrame" HeaderText="是否框架合同">
|
||||
</f:RenderCheckField>
|
||||
<f:RenderField Width="360px" ColumnID="Discipline" DataField="Discipline"
|
||||
HeaderText="Discipline" HeaderTextAlign="Center" FieldType="String">
|
||||
</f:RenderField>
|
||||
|
@ -65,9 +69,15 @@
|
|||
<f:RenderField Width="180px" ColumnID="Location" DataField="Location"
|
||||
FieldType="String" HeaderText="Location" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="ViolationPerson" DataField="ViolationPerson"
|
||||
FieldType="String" HeaderText="Violation Person" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="180px" ColumnID="Description" DataField="Description"
|
||||
HeaderText="Violation Description" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="220px" ColumnID="ClauseDef" DataField="ClauseDef"
|
||||
HeaderText="Violation Clause" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="Company" DataField="Company"
|
||||
FieldType="Float" HeaderText="Company</br>(RMB)" HeaderTextAlign="Center" RendererFunction="renderSalary">
|
||||
</f:RenderField>
|
||||
|
@ -93,21 +103,29 @@
|
|||
FieldType="String" HeaderText="User </br>Representative" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="100px" ColumnID="BYCRU" DataField="BYCRU"
|
||||
FieldType="String" HeaderText="BYC RU" HeaderTextAlign="Center">
|
||||
FieldType="String" HeaderText="BYC Resp. Dept" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="Violation_Inspector_Name" DataField="Violation_Inspector_Name"
|
||||
FieldType="String" HeaderText="Violation </br>Inspector" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
|
||||
<f:RenderField Width="100px" ColumnID="InspectionDep" DataField="InspectionDep"
|
||||
FieldType="String" HeaderText="Inspection </br>Department" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="100px" ColumnID="RequisitionerName" DataField="RequisitionerName"
|
||||
FieldType="String" HeaderText="Requisitioner" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="SES_No" DataField="SES_No"
|
||||
FieldType="String" HeaderText="Backcharge </br>SES No." HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="130px" ColumnID="CompletionDate" DataField="CompletionDate"
|
||||
FieldType="Date" Renderer="Date" HeaderText="Backcharge</br>Completion Date" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:TemplateField ColumnID="tfAttachUrl" HeaderText="附件查看" Width="300px" HeaderTextAlign="Center" TextAlign="Left">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="lbtnUrl" runat="server" CommandArgument='<%# Bind("AttachUrl") %>'
|
||||
ToolTip="附件查看" EnableAjax="false" Height="20px"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
</Columns>
|
||||
<Listeners>
|
||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />
|
||||
|
@ -129,7 +147,7 @@
|
|||
</f:Panel>
|
||||
<f:Window ID="Window1" Title="Contractor Quality Punishment Edit" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
||||
Target="Parent" EnableResize="true" runat="server" OnClose="Window1_Close" IsModal="true"
|
||||
Width="960px" Height="600px">
|
||||
Width="1080px" Height="800px">
|
||||
</f:Window>
|
||||
|
||||
<f:Menu ID="Menu1" runat="server">
|
||||
|
|
|
@ -9,6 +9,7 @@ using System.IO;
|
|||
using System.Linq;
|
||||
using System.Text;
|
||||
using AspNet = System.Web.UI.WebControls;
|
||||
using System.Web.UI.DataVisualization.Charting;
|
||||
|
||||
namespace FineUIPro.Web.SES
|
||||
{
|
||||
|
@ -42,7 +43,7 @@ namespace FineUIPro.Web.SES
|
|||
|
||||
private void BindGrid()
|
||||
{
|
||||
string strSql = @"SELECT * FROM dbo.View_EMC_Punishment WHERE Flag='2' ";
|
||||
string strSql = @"SELECT * FROM dbo.View_EMC_Que_Punishment WHERE Flag='2' ";
|
||||
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
if (!string.IsNullOrEmpty(this.txtFO_NO.Text.Trim()))
|
||||
|
@ -50,7 +51,7 @@ namespace FineUIPro.Web.SES
|
|||
strSql += " AND FO_NO LIKE @FO_NO";
|
||||
listStr.Add(new SqlParameter("@FO_NO", "%" + this.txtFO_NO.Text.Trim() + "%"));
|
||||
}
|
||||
if (drpContractAdmin.SelectedValue != Const._Null)
|
||||
if (drpContractAdmin.SelectedValue != Const._Null && drpContractAdmin.SelectedValue != null)
|
||||
{
|
||||
strSql += " AND Contract_AdminId = @Contract_AdminId";
|
||||
listStr.Add(new SqlParameter("@Contract_AdminId", drpContractAdmin.SelectedValue));
|
||||
|
@ -73,6 +74,17 @@ namespace FineUIPro.Web.SES
|
|||
var table = this.GetPagedDataTable(Grid1, tb);
|
||||
Grid1.DataSource = table;
|
||||
Grid1.DataBind();
|
||||
|
||||
for (int i = 0; i < Grid1.Rows.Count; i++)
|
||||
{
|
||||
System.Web.UI.WebControls.LinkButton lbtnUrl = ((System.Web.UI.WebControls.LinkButton)(Grid1.Rows[i].FindControl("lbtnUrl")));
|
||||
string url = lbtnUrl.CommandArgument.ToString();
|
||||
if (!string.IsNullOrEmpty(url))
|
||||
{
|
||||
url = url.Replace('\\', '/');
|
||||
lbtnUrl.Text = BLL.UploadAttachmentService.ShowAttachment("../", url);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#region 编辑
|
||||
|
@ -88,8 +100,157 @@ namespace FineUIPro.Web.SES
|
|||
Alert.ShowInParent("Please select at least one record!");
|
||||
return;
|
||||
}
|
||||
string Id = Grid1.SelectedRowID;
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CQualityPunishEdit.aspx?punishmentId={0}", Id, "编辑 - ")));
|
||||
string rowID = Grid1.SelectedRowID;
|
||||
var pun = BLL.PunishmentService.GetPunishmentById(rowID);
|
||||
if (pun != null)
|
||||
{
|
||||
if (pun.IsAudit == true)
|
||||
{
|
||||
if (CurrUser.UserId == pun.AuditMan)
|
||||
{
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CQualityPunishEdit.aspx?punishmentId={0}", rowID, "编辑 - ")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("已批准!只有批准人有修改权限!", MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (pun.IsFrame == true)
|
||||
{
|
||||
var datas = BLL.SESRelatedDataService.GetSESRelatedDataByFoNo(pun.FO_NO);
|
||||
if (CurrUser.UserId == datas.Main_Coordinator || CurrUser.UserId == pun.Violation_Inspector || CurrUser.UserId == Const.GlyId)
|
||||
{
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CQualityPunishEdit.aspx?punishmentId={0}", rowID, "编辑 - ")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("只有主协调员,发起人(违章检查人)有修改权限!", MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (CurrUser.UserId == pun.Requisitioner || CurrUser.UserId == pun.Violation_Inspector || CurrUser.UserId == Const.GlyId)
|
||||
{
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CQualityPunishEdit.aspx?punishmentId={0}", rowID, "编辑 - ")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("只有合同请购人,发起人(违章检查人)有修改权限!", MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnAudit_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length == 0)
|
||||
{
|
||||
Alert.ShowInParent("Please select at least one record!");
|
||||
return;
|
||||
}
|
||||
string rowID = Grid1.SelectedRowID;
|
||||
var pun = BLL.PunishmentService.GetPunishmentById(rowID);
|
||||
string auditMan=string.Empty;
|
||||
|
||||
if (pun != null)
|
||||
{
|
||||
if (pun.IsFrame == true)
|
||||
{
|
||||
var fc = BLL.SESRelatedDataService.GetSESRelatedDataByFoNo(pun.FO_NO);
|
||||
string curUser = this.CurrUser.UserId; // 当前用户
|
||||
string violationInspector = pun.Violation_Inspector; // 发起人
|
||||
string leader = string.Empty; // 主协调员部门领导
|
||||
string mainCoordinator = fc.Main_Coordinator;
|
||||
|
||||
var userInfo = BLL.Sys_UserService.GetUsersByUserId(fc.Main_Coordinator);
|
||||
if (userInfo != null)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(userInfo.DepartId);
|
||||
if (dep != null)
|
||||
{
|
||||
leader = dep.DepartLeader;
|
||||
}
|
||||
}
|
||||
|
||||
// 当前用户不是主调协员
|
||||
if (curUser != mainCoordinator)
|
||||
{
|
||||
// 当前用户是主调协员部门领导 不发邮件
|
||||
if (curUser == leader)
|
||||
{
|
||||
auditMan = leader;
|
||||
}
|
||||
else if(curUser==Const.GlyId)
|
||||
{
|
||||
auditMan = Const.GlyId;
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("您没有审核权限,请与管理员联系!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else // 当前用户是主调协员
|
||||
{
|
||||
auditMan = mainCoordinator;
|
||||
// 发邮件给主调协员部门领导
|
||||
}
|
||||
}
|
||||
|
||||
// 非框架合同
|
||||
else
|
||||
{
|
||||
string curUser = this.CurrUser.UserId; // 当前用户
|
||||
string violationInspector = pun.Violation_Inspector; // 发起人
|
||||
string leader = string.Empty; // 请购人部门领导
|
||||
string requisitioner = pun.Requisitioner; // 请购人
|
||||
|
||||
var userInfo = BLL.Sys_UserService.GetUsersByUserId(pun.Requisitioner);
|
||||
if (userInfo != null)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(userInfo.DepartId);
|
||||
if (dep != null)
|
||||
{
|
||||
leader = dep.DepartLeader;
|
||||
}
|
||||
}
|
||||
|
||||
// 当前用户不是请购人
|
||||
if (curUser != requisitioner)
|
||||
{
|
||||
// 当前用户是请购人部门领导 不发邮件
|
||||
if (curUser == leader)
|
||||
{
|
||||
auditMan = leader;
|
||||
}
|
||||
else if (curUser == Const.GlyId)
|
||||
{
|
||||
auditMan = Const.GlyId;
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("您没有审核权限,请与管理员联系!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else // 当前用户是请购人
|
||||
{
|
||||
auditMan = requisitioner;
|
||||
// 发邮件给请购人部门领导
|
||||
}
|
||||
}
|
||||
if (auditMan != string.Empty)
|
||||
{
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CQualityPunishEdit.aspx?punishmentId={0}&auditMan={1}&audit=audit", rowID, auditMan, "编辑 - ")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("您没有审核权限,请与管理员联系!", MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -140,20 +301,85 @@ namespace FineUIPro.Web.SES
|
|||
/// </summary>
|
||||
private void DeleteData()
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length > 0)
|
||||
if (!string.IsNullOrEmpty(Grid1.SelectedRowID))
|
||||
{
|
||||
foreach (int rowIndex in Grid1.SelectedRowIndexArray)
|
||||
string rowID = Grid1.SelectedRowID;
|
||||
var pun = BLL.PunishmentService.GetPunishmentById(rowID);
|
||||
if (pun != null)
|
||||
{
|
||||
string rowID = Grid1.DataKeys[rowIndex][0].ToString();
|
||||
var pun = BLL.PunishmentService.GetPunishmentById(rowID);
|
||||
if (pun != null)
|
||||
if (pun.IsFrame == true)
|
||||
{
|
||||
if (judgementDelete(rowID, false))
|
||||
var datas = BLL.SESRelatedDataService.GetSESRelatedDataByFoNo(pun.FO_NO);
|
||||
if (pun.IsAudit == true) // 审核后只有批准人可删除
|
||||
{
|
||||
BLL.PunishmentService.DeletePunishmentById(rowID);
|
||||
if (CurrUser.UserId == pun.AuditMan)
|
||||
{
|
||||
if (judgementDelete(rowID, false))
|
||||
{
|
||||
BLL.PunishmentService.DeletePunishmentById(rowID);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("已批准!只有批准人有删除权限!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (CurrUser.UserId == datas.Main_Coordinator || CurrUser.UserId == pun.Violation_Inspector || CurrUser.UserId == Const.GlyId)
|
||||
{
|
||||
if (judgementDelete(rowID, false))
|
||||
{
|
||||
BLL.PunishmentService.DeletePunishmentById(rowID);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("只有主协调员,发起人(违章检查人)有删除权限!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
if (pun.IsAudit == true)
|
||||
{
|
||||
if (CurrUser.UserId == pun.AuditMan)
|
||||
{
|
||||
if (judgementDelete(rowID, false))
|
||||
{
|
||||
BLL.PunishmentService.DeletePunishmentById(rowID);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("已批准!只有批准人有删除权限!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
if (CurrUser.UserId == pun.Requisitioner || CurrUser.UserId == pun.Violation_Inspector || CurrUser.UserId == Const.GlyId)
|
||||
{
|
||||
if (judgementDelete(rowID, false))
|
||||
{
|
||||
BLL.PunishmentService.DeletePunishmentById(rowID);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("只有合同请购人,发起人(违章检查人)有删除权限!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
BindGrid();
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Delete Contractor Safety Punishment");
|
||||
ShowNotify("Deleted successfully!");
|
||||
|
@ -194,11 +420,7 @@ namespace FineUIPro.Web.SES
|
|||
private bool judgementDelete(string id, bool isShow)
|
||||
{
|
||||
string content = string.Empty;
|
||||
//if (Funs.DB.Sys_User.FirstOrDefault(x => x.RoleId == id) != null)
|
||||
//{
|
||||
// content = "This role is already in use in [user information] and cannot be deleted!";
|
||||
//}
|
||||
|
||||
|
||||
if (string.IsNullOrEmpty(content))
|
||||
{
|
||||
return true;
|
||||
|
|
|
@ -7,11 +7,13 @@
|
|||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.SES {
|
||||
|
||||
|
||||
public partial class CQualityPunish {
|
||||
|
||||
namespace FineUIPro.Web.SES
|
||||
{
|
||||
|
||||
|
||||
public partial class CQualityPunish
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
|
@ -20,7 +22,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
|
@ -29,7 +31,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
|
@ -38,7 +40,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel Panel1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
|
@ -47,7 +49,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar2 控件。
|
||||
/// </summary>
|
||||
|
@ -56,7 +58,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar2;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// hdID 控件。
|
||||
/// </summary>
|
||||
|
@ -65,7 +67,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.HiddenField hdID;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtFO_NO 控件。
|
||||
/// </summary>
|
||||
|
@ -74,7 +76,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtFO_NO;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpContractAdmin 控件。
|
||||
/// </summary>
|
||||
|
@ -83,7 +85,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpContractAdmin;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtPunishDate 控件。
|
||||
/// </summary>
|
||||
|
@ -92,7 +94,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtPunishDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch 控件。
|
||||
/// </summary>
|
||||
|
@ -101,7 +103,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnSearch;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarFill1 控件。
|
||||
/// </summary>
|
||||
|
@ -110,7 +112,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarFill ToolbarFill1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnNew 控件。
|
||||
/// </summary>
|
||||
|
@ -119,7 +121,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnNew;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnEdit 控件。
|
||||
/// </summary>
|
||||
|
@ -128,7 +130,16 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnEdit;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnAudit 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnAudit;
|
||||
|
||||
/// <summary>
|
||||
/// btnDelete 控件。
|
||||
/// </summary>
|
||||
|
@ -137,7 +148,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnDelete;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnExport 控件。
|
||||
/// </summary>
|
||||
|
@ -146,7 +157,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnExport;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// lblNumber 控件。
|
||||
/// </summary>
|
||||
|
@ -155,7 +166,16 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lblNumber;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// lbtnUrl 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbtnUrl;
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarSeparator1 控件。
|
||||
/// </summary>
|
||||
|
@ -164,7 +184,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarText1 控件。
|
||||
/// </summary>
|
||||
|
@ -173,7 +193,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarText ToolbarText1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ddlPageSize 控件。
|
||||
/// </summary>
|
||||
|
@ -182,7 +202,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlPageSize;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Window1 控件。
|
||||
/// </summary>
|
||||
|
@ -191,7 +211,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Menu1 控件。
|
||||
/// </summary>
|
||||
|
@ -200,7 +220,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Menu Menu1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuEdit 控件。
|
||||
/// </summary>
|
||||
|
@ -209,7 +229,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.MenuButton btnMenuEdit;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuDelete 控件。
|
||||
/// </summary>
|
||||
|
@ -218,7 +238,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.MenuButton btnMenuDelete;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuView 控件。
|
||||
/// </summary>
|
||||
|
|
|
@ -15,88 +15,172 @@
|
|||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DatePicker ID="txtPunishDate" runat="server" Label="Date" LabelAlign="Right" LabelWidth="160px" DateFormatString="yyyy-MM-dd"></f:DatePicker>
|
||||
<f:DatePicker ID="txtPunishTime" runat="server" Label="Time" LabelAlign="Right" LabelWidth="160px" DateFormatString="HH:mm" DisplayType="Time"></f:DatePicker>
|
||||
<f:DatePicker ID="txtPunishDate" runat="server" Label="Date" LabelAlign="Right" LabelWidth="180px" DateFormatString="yyyy-MM-dd" ShowRedStar="true" Required="true"></f:DatePicker>
|
||||
<f:DatePicker ID="txtPunishTime" runat="server" Label="Time" LabelAlign="Right" LabelWidth="180px" DateFormatString="HH:mm" DisplayType="Time" ShowRedStar="true" Required="true"></f:DatePicker>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow ColumnWidths="50% 23% 27%">
|
||||
<Items>
|
||||
|
||||
<f:TextBox ID="txtFO_No" runat="server" Label="Contract No." LabelAlign="Right" LabelWidth="180px" ShowRedStar="true" Required="true" AutoPostBack="true" OnTextChanged="txtText_TextChanged"></f:TextBox>
|
||||
<f:TextBox ID="txtItemNo" runat="server" Label="序号" LabelWidth="180px" Readonly="true" ></f:TextBox>
|
||||
<f:RadioButtonList ID="rbIsFrame" runat="server" Label="Is Frame Contract" LabelAlign="Right" LabelWidth="160px" Readonly="true">
|
||||
<f:RadioItem Text="是" Value="1" />
|
||||
<f:RadioItem Text="否" Value="0" />
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DropDownList ID="drpContractor" runat="server" Label="Contractor" EnableEdit="true" LabelAlign="Right" LabelWidth="160px" ShowRedStar="true" AutoPostBack="true" OnSelectedIndexChanged="drpContractor_SelectedIndexChanged">
|
||||
</f:DropDownList>
|
||||
<f:DropDownList ID="drpFO_No" runat="server" Label="Contract No." EnableEdit="true" LabelAlign="Right" LabelWidth="160px" ShowRedStar="true" AutoPostBack="true" OnSelectedIndexChanged="drpFO_No_SelectedIndexChanged"></f:DropDownList>
|
||||
<f:TextBox ID="txtContractor" runat="server" Label="Contractor" LabelAlign="Right" LabelWidth="180px" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:TextBox ID="txtDiscispline" runat="server" Label="Discispline" LabelWidth="180px" ShowRedStar="true" Required="true"></f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtDiscispline" runat="server" Label="Discispline" LabelWidth="160px" Readonly="true"></f:TextBox>
|
||||
<f:TextBox ID="txtLocation" runat="server" Label="Location" LabelAlign="Right" MaxLength="500" LabelWidth="160px">
|
||||
<f:TextBox ID="txtLocation" runat="server" Label="Location" LabelAlign="Right" MaxLength="500" LabelWidth="180px" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:TextBox ID="txtViolationPerson" runat="server" Label="Violation Person" LabelAlign="Right" LabelWidth="180px">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtDescription" runat="server" Label="Violation Description" LabelAlign="Right" MaxLength="500" LabelWidth="160px">
|
||||
<f:TextBox ID="txtDescription" runat="server" Label="Violation Description" LabelAlign="Right" MaxLength="500" LabelWidth="180px" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:NumberBox ID="txtCompany" runat="server" Label="Company (RMB)" LabelAlign="Right" LabelWidth="160px" DecimalPrecision="2" AutoPostBack="true" OnTextChanged="txtPunish_OnTextChanged"></f:NumberBox>
|
||||
<f:DropDownList ID="drpViolationClause" runat="server" Label="Violation Clause" EnableEdit="true" LabelAlign="Right" LabelWidth="180px" EnableGroup="true"
|
||||
AutoPostBack="true" OnSelectedIndexChanged="drpViolationClause_OnSelectedIndexChanged" ShowRedStar="true" Required="true"></f:DropDownList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="txtIndividual" runat="server" Label="Individual (RMB)" LabelAlign="Right" DecimalPrecision="2" LabelWidth="160px" AutoPostBack="true" OnTextChanged="txtPunish_OnTextChanged"></f:NumberBox>
|
||||
<f:NumberBox ID="txtBackcharge" runat="server" Label="Backcharge (RMB)" LabelAlign="Right" DecimalPrecision="2" LabelWidth="160px" Readonly="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DropDownList ID="drpViolationDegree" runat="server" Label="Violation Degree" LabelAlign="Right" LabelWidth="160px">
|
||||
<Items>
|
||||
<f:DropDownList ID="drpViolationDegree" runat="server" Label="Violation Degree" LabelAlign="Right" LabelWidth="180px">
|
||||
<f:ListItem Value="1" Text="一般违章" />
|
||||
<f:ListItem Value="2" Text="严重违章" />
|
||||
<f:ListItem Value="3" Text="零容忍违章" />
|
||||
</f:DropDownList>
|
||||
<f:TextBox ID="txtContractAdmin" runat="server" Label="Contract Admin" LabelAlign="Right" LabelWidth="160px" Readonly="true">
|
||||
</f:TextBox>
|
||||
<f:NumberBox ID="txtCompany" runat="server" Label="Company (RMB)" LabelAlign="Right" LabelWidth="180px" DecimalPrecision="2" AutoPostBack="true" OnTextChanged="txtPunish_OnTextChanged" ShowRedStar="true" Required="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="txtIndividual" runat="server" Label="Individual (RMB)" LabelAlign="Right" DecimalPrecision="2" LabelWidth="180px" AutoPostBack="true" OnTextChanged="txtPunish_OnTextChanged" ShowRedStar="true" Required="true"></f:NumberBox>
|
||||
<f:NumberBox ID="txtBackcharge" runat="server" Label="Backcharge (RMB)" LabelAlign="Right" DecimalPrecision="2" LabelWidth="180px" Readonly="true"></f:NumberBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtMainCoordinator" runat="server" Label="Main Coordinator" LabelAlign="Right" LabelWidth="160px" Readonly="true">
|
||||
<f:TextBox ID="txtContractAdmin" runat="server" Label="Contract Admin" LabelAlign="Right" LabelWidth="180px" Readonly="true">
|
||||
</f:TextBox>
|
||||
<f:TextBox ID="txtMCDept" runat="server" Label="M.C.Dept" LabelAlign="Right" LabelWidth="160px" Readonly="true">
|
||||
<f:TextBox ID="txtMainCoordinator" runat="server" Label="Main Coordinator" LabelAlign="Right" LabelWidth="180px" Readonly="true">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtMCDept" runat="server" Label="M.C.Dept" LabelAlign="Right" LabelWidth="180px" Readonly="true">
|
||||
</f:TextBox>
|
||||
<f:TextBox ID="txtUserRepresentative" runat="server" Label="User Representative" LabelAlign="Right" LabelWidth="180px" Readonly="true">
|
||||
</f:TextBox>
|
||||
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DropDownList ID="drpViolationInspector" runat="server" Label="Violation Inspector" EnableEdit="true" EnableGroup="true" LabelAlign="Right" LabelWidth="180px"
|
||||
Readonly="true"></f:DropDownList>
|
||||
<f:TextBox ID="txtInspectionDep" runat="server" Label="Inspection Department" LabelAlign="Right" LabelWidth="180px" Readonly="true">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtUserRepresentative" runat="server" Label="User Representative" LabelAlign="Right" LabelWidth="160px" Readonly="true">
|
||||
<f:DropDownList ID="drpBYC_RU" runat="server" Label="BYC Resp. Dept" LabelAlign="Right" LabelWidth="180px" ShowRedStar="true" Required="true"></f:DropDownList>
|
||||
<f:TextBox ID="txtViolationRelatedSes" runat="server" Label="Violation Related SES" LabelAlign="Right" LabelWidth="180px" >
|
||||
</f:TextBox>
|
||||
<f:DropDownList ID="drpBYC_RU" runat="server" Label="BYC RU" EnableGroup="true" EnableEdit="true" LabelAlign="Right" LabelWidth="160px"></f:DropDownList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DropDownList ID="drpViolationInspector" runat="server" Label="Violation Inspector" EnableEdit="true" EnableGroup="true" LabelAlign="Right" LabelWidth="160px"
|
||||
AutoPostBack="true" OnSelectedIndexChanged="drpViolationInspector_SelectedIndexChanged"></f:DropDownList>
|
||||
<f:TextBox ID="txtInspectionDep" runat="server" Label="Inspection Department" LabelAlign="Right" LabelWidth="160px" Readonly="true">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
<f:DropDownList ID="drpRequisitioner" runat="server" Label="Contract Requisitioner" EnableEdit="true" EnableGroup="true" LabelAlign="Right" LabelWidth="180px"></f:DropDownList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:Panel ID="Panel3" Width="500px" ShowHeader="false" ShowBorder="false" Layout="Column" CssClass="" runat="server">
|
||||
<Items>
|
||||
<f:Label ID="lblAttach" runat="server" Label="Upload Attach" LabelAlign="Right" LabelWidth="180px">
|
||||
</f:Label>
|
||||
<f:Button ID="btnAttach" Icon="TableCell" EnablePostBack="true" Text="Upload File" runat="server" OnClick="btnAttach_Click">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:GroupPanel ID="GPRole" Title="由 Contract Administrator 角色填写" Layout="Table" runat="server" >
|
||||
|
||||
<Items>
|
||||
<f:TextBox ID="txtSESNo" runat="server" Label="Backcharge SES No." LabelAlign="Right" LabelWidth="170px" Width="455px" ShowRedStar="true" >
|
||||
<f:TextBox ID="txtSESNo" runat="server" Label="Backcharge SES No." LabelAlign="Right" LabelWidth="180px" Width="510px" ShowRedStar="true" >
|
||||
</f:TextBox>
|
||||
<f:DatePicker ID="txtCompletionDate" runat="server" Label="Backcharge Completion Date" LabelAlign="Right" LabelWidth="230px" Width="470px" ShowRedStar="true"></f:DatePicker>
|
||||
</Items>
|
||||
</f:GroupPanel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:GroupPanel ID="GPDep" Title="End User(BYC Resp. Dept.部门)填写" Layout="Anchor" runat="server">
|
||||
<Items>
|
||||
<f:Form ShowBorder="false" ShowHeader="false" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtViolationRelatedSes1" runat="server" Label="Violation Related SES" LabelAlign="Right" LabelWidth="180px" Width="510px">
|
||||
</f:TextBox>
|
||||
<f:Label runat="server"></f:Label>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</Items>
|
||||
</f:GroupPanel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:GroupPanel ID="GPAudit" Title="审核" Layout="Anchor" runat="server" Hidden="true">
|
||||
<Items>
|
||||
<f:Form ShowBorder="false" ShowHeader="false" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Rows>
|
||||
<f:FormRow ColumnWidths="33% 67%">
|
||||
<Items>
|
||||
<f:RadioButtonList ID="rbIsPass" runat="server" Label="审核结果" LabelWidth="140px" Width="240px">
|
||||
<f:RadioItem Value="1" Text="通过" Selected="true" />
|
||||
<f:RadioItem Value="0" Text="拒绝" />
|
||||
</f:RadioButtonList>
|
||||
<f:Label runat="server"></f:Label>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtAuditResult" runat="server" Label="通过/拒绝描述" LabelWidth="140px"></f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</Items>
|
||||
</f:GroupPanel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
</Rows>
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar1" Position="Bottom" ToolbarAlign="Right" runat="server">
|
||||
<Items>
|
||||
<f:HiddenField ID="hdId" runat="server"></f:HiddenField>
|
||||
<f:Button ID="btnSave" Icon="SystemSave" runat="server" Text="Save" ToolTip="Save" ValidateForms="SimpleForm1"
|
||||
OnClick="btnSave_Click" Hidden="true">
|
||||
</f:Button>
|
||||
|
@ -107,5 +191,9 @@
|
|||
</Toolbars>
|
||||
</f:Form>
|
||||
</form>
|
||||
<f:Window ID="WindowAtt" Title="弹出窗体" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
||||
Target="Parent" EnableResize="false" runat="server" IsModal="true" Width="700px"
|
||||
Height="500px">
|
||||
</f:Window>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -1,10 +1,14 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Specialized;
|
||||
using System.Diagnostics.Contracts;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using BLL;
|
||||
using BLL.Common;
|
||||
using Model;
|
||||
|
||||
namespace FineUIPro.Web.SES
|
||||
{
|
||||
|
@ -17,6 +21,11 @@ namespace FineUIPro.Web.SES
|
|||
{
|
||||
this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
|
||||
string view = Request.Params["view"];
|
||||
string audit = Request.Params["audit"];
|
||||
if (!string.IsNullOrEmpty(audit))
|
||||
{
|
||||
GPAudit.Hidden = false;
|
||||
}
|
||||
if (view == "1")
|
||||
{
|
||||
this.btnSave.Hidden = true;
|
||||
|
@ -42,30 +51,28 @@ namespace FineUIPro.Web.SES
|
|||
txtCompletionDate.Enabled = false;
|
||||
}
|
||||
|
||||
BLL.ViolationClauseService.InitViolationClause(this.drpViolationClause, true);//违章条款
|
||||
//BLL.SESRelatedDataService.InitFONoDropDownList(this.drpFO_No, true);//合同号
|
||||
BLL.ContractorService.InitDropDownList(drpContractor, true); //承包商;
|
||||
//BLL.ContractorService.InitDropDownList(drpContractor, true); //承包商;
|
||||
BLL.DepartService.InitDropDownList(this.drpBYC_RU, true);//BYC负责部门
|
||||
BLL.Sys_UserService.InitUserDropDownList(this.drpViolationInspector, true);//违章检查人
|
||||
|
||||
//BLL.Sys_UserService.InitUserDropDownList(this.drpBYC_Person, true);//
|
||||
BLL.Sys_UserService.InitUserDropDownList(this.drpRequisitioner, true);//合同请购人
|
||||
|
||||
string punishmentId = Request.Params["punishmentId"];
|
||||
if (!string.IsNullOrEmpty(punishmentId))
|
||||
{
|
||||
Model.View_EMC_Punishment punishment = BLL.PunishmentService.GetPunishmentViewById(punishmentId);
|
||||
Model.View_EMC_Que_Punishment punishment = BLL.PunishmentService.GetQuePunishmentViewById(punishmentId);
|
||||
Model.EMC_Punishment pun = BLL.PunishmentService.GetPunishmentById(punishmentId);
|
||||
if (punishment != null)
|
||||
if (punishment != null && pun!=null)
|
||||
{
|
||||
this.txtPunishDate.Text = punishment.PunishDate != null ? string.Format("{0:yyyy-MM-dd}", punishment.PunishDate) : "";
|
||||
this.txtPunishTime.Text = punishment.PunishDate != null ? punishment.PunishDate.Value.ToShortTimeString() : "";
|
||||
this.txtFO_No.Text = punishment.FO_NO;
|
||||
txtItemNo.Text = pun.ItemNo;
|
||||
txtContractor.Text = punishment.Contractor;
|
||||
txtDiscispline.Text = punishment.Discipline;
|
||||
|
||||
if (!string.IsNullOrEmpty(punishment.ContractorId))
|
||||
{
|
||||
this.drpContractor.SelectedValue = punishment.ContractorId;
|
||||
BLL.SESRelatedDataService.InitFONoDropDownList(this.drpFO_No, drpContractor.SelectedValue, true);//合同号
|
||||
this.drpFO_No.SelectedValue = punishment.FO_NO;
|
||||
}
|
||||
|
||||
this.txtDiscispline.Text = punishment.Discipline;
|
||||
this.txtLocation.Text = punishment.Location;
|
||||
this.txtDescription.Text = punishment.Description;
|
||||
|
||||
|
@ -73,7 +80,7 @@ namespace FineUIPro.Web.SES
|
|||
this.txtIndividual.Text = punishment.Individual.HasValue ? punishment.Individual.ToString() : "";
|
||||
this.txtBackcharge.Text = punishment.Backcharge.HasValue ? punishment.Backcharge.Value.ToString("0.00") : "";
|
||||
|
||||
if (pun != null && !string.IsNullOrEmpty(pun.ViolationDegree))
|
||||
if (!string.IsNullOrEmpty(pun.ViolationDegree))
|
||||
{
|
||||
drpViolationDegree.SelectedValue = pun.ViolationDegree;
|
||||
}
|
||||
|
@ -93,14 +100,78 @@ namespace FineUIPro.Web.SES
|
|||
string depName = BLL.DepartService.GetDepartNameById(user.DepartId);
|
||||
txtInspectionDep.Text = depName;
|
||||
}
|
||||
|
||||
|
||||
if (pun.IsFrame == true)
|
||||
{
|
||||
rbIsFrame.SelectedValue = "1";
|
||||
}
|
||||
else
|
||||
{
|
||||
rbIsFrame.SelectedValue = "0";
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(pun.ViolationClauseId))
|
||||
{
|
||||
drpViolationClause.SelectedValue = pun.ViolationClauseId;
|
||||
}
|
||||
txtViolationPerson.Text = pun.ViolationPerson;
|
||||
|
||||
if (!string.IsNullOrEmpty(punishment.Requisitioner))
|
||||
{
|
||||
drpRequisitioner.SelectedValue = punishment.Requisitioner;
|
||||
}
|
||||
|
||||
if (pun.IsFrame == true && (this.CurrUser.DepartId == punishment.BYC_RU || this.CurrUser.Account == Const.Gly))
|
||||
{
|
||||
GPDep.Hidden= false;
|
||||
}
|
||||
else
|
||||
{
|
||||
GPDep.Hidden = true;
|
||||
}
|
||||
|
||||
this.txtCompletionDate.Text = punishment.CompletionDate != null ? string.Format("{0:yyyy-MM-dd}", punishment.CompletionDate) : "";
|
||||
this.txtSESNo.Text = punishment.SES_No;
|
||||
txtViolationRelatedSes.Text = punishment.ViolationRelatedSes;
|
||||
txtViolationRelatedSes1.Text = punishment.ViolationRelatedSes;
|
||||
hdId.Text = punishmentId;
|
||||
|
||||
// 审核
|
||||
if (pun.IsPass != null)
|
||||
{
|
||||
if (pun.IsPass == true)
|
||||
{
|
||||
rbIsPass.SelectedValue = "1";
|
||||
}
|
||||
else
|
||||
{
|
||||
rbIsPass.SelectedValue = "0";
|
||||
}
|
||||
}
|
||||
txtAuditResult.Text = pun.AuditResult;
|
||||
|
||||
if (punishment.IsFrame == true)
|
||||
{
|
||||
txtDiscispline.Readonly = true;
|
||||
drpRequisitioner.Hidden = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
txtDiscispline.Readonly = false;
|
||||
txtContractAdmin.Hidden = true;
|
||||
txtMainCoordinator.Hidden = true;
|
||||
txtUserRepresentative.Hidden = true;
|
||||
txtMCDept.Hidden = true;
|
||||
drpBYC_RU.Hidden = true;
|
||||
GPRole.Hidden = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
this.drpViolationInspector.SelectedValue = CurrUser.UserId;
|
||||
string depName = BLL.DepartService.GetDepartNameById(CurrUser.DepartId);
|
||||
txtInspectionDep.Text = depName;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -115,19 +186,9 @@ namespace FineUIPro.Web.SES
|
|||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
string punishmentId = Request.Params["punishmentId"];
|
||||
string audit = Request.Params["audit"];
|
||||
Model.EMC_Punishment punishment = new Model.EMC_Punishment();
|
||||
|
||||
if (this.drpContractor.SelectedValue == BLL.Const._Null)
|
||||
{
|
||||
Alert.ShowInTop("Please select Contractor!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.drpFO_No.SelectedValue == BLL.Const._Null)
|
||||
{
|
||||
Alert.ShowInTop("Please select Contract No.!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
if (punishmentId == null)
|
||||
{
|
||||
punishmentId = string.Empty;
|
||||
|
@ -138,12 +199,19 @@ namespace FineUIPro.Web.SES
|
|||
return;
|
||||
}
|
||||
|
||||
if (drpViolationClause.SelectedValue == Const._Null)
|
||||
{
|
||||
Alert.ShowInTop("Please select Violation Clause!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
|
||||
punishment.PunishDate = Funs.GetNewDateTime(this.txtPunishDate.Text.Trim() + " " + txtPunishTime.Text.Trim());
|
||||
punishment.FO_NO = drpFO_No.SelectedValue;
|
||||
punishment.FO_NO = txtFO_No.Text.Trim(); //drpFO_No.SelectedValue;
|
||||
if (txtSESNo.Text.Trim() != string.Empty)
|
||||
{
|
||||
punishment.SES_No = txtSESNo.Text.Trim();
|
||||
}
|
||||
punishment.ItemNo = txtItemNo.Text.Trim();
|
||||
punishment.Location = txtLocation.Text.Trim();
|
||||
punishment.Description = txtDescription.Text.Trim();
|
||||
if (txtCompany.Text != string.Empty)
|
||||
|
@ -166,60 +234,486 @@ namespace FineUIPro.Web.SES
|
|||
punishment.CompletionDate = Funs.GetNewDateTime(this.txtCompletionDate.Text.Trim());
|
||||
punishment.Flag = "2";
|
||||
|
||||
if (!string.IsNullOrEmpty(punishmentId))
|
||||
punishment.Contractor=txtContractor.Text.Trim();
|
||||
punishment.Discipline=txtDiscispline.Text.Trim();
|
||||
punishment.ViolationClauseId = drpViolationClause.SelectedValue;
|
||||
if (rbIsFrame.SelectedValue == "1")
|
||||
{
|
||||
punishment.PunishmentId = punishmentId;
|
||||
BLL.PunishmentService.UpdatePunishment(punishment);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Modify Contractor Quality Punishment!");
|
||||
ShowNotify("Save successfully!", MessageBoxIcon.Success);
|
||||
punishment.IsFrame = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
punishment.PunishmentId = SQLHelper.GetNewID(typeof(Model.EMC_Punishment));
|
||||
BLL.PunishmentService.AddPunishment(punishment);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Add Contractor Quality Punishment!");
|
||||
punishment.IsFrame=false;
|
||||
}
|
||||
punishment.ViolationPerson=txtViolationPerson.Text.Trim();
|
||||
|
||||
if (drpRequisitioner.SelectedValue != Const._Null)
|
||||
{
|
||||
punishment.Requisitioner = drpRequisitioner.SelectedValue;
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(txtViolationRelatedSes1.Text))
|
||||
{
|
||||
punishment.ViolationRelatedSes = txtViolationRelatedSes1.Text.Trim();
|
||||
}
|
||||
else if (!string.IsNullOrEmpty(txtViolationRelatedSes.Text))
|
||||
{
|
||||
punishment.ViolationRelatedSes = txtViolationRelatedSes.Text.Trim();
|
||||
}
|
||||
// 保存
|
||||
if (string.IsNullOrEmpty(audit))
|
||||
{
|
||||
if (!string.IsNullOrEmpty(punishmentId))
|
||||
{
|
||||
punishment.PunishmentId = punishmentId;
|
||||
var att = from x in Funs.DB.AttachFile where x.ToKeyId == punishmentId select x;
|
||||
if (att.Count() > 0)
|
||||
{
|
||||
punishment.AttachUrl = att.First().AttachUrl;
|
||||
}
|
||||
BLL.PunishmentService.UpdatePunishment(punishment);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Modify Contractor Quality Punishment!");
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!string.IsNullOrEmpty(this.hdId.Text))
|
||||
{
|
||||
punishment.PunishmentId = this.hdId.Text.Trim();
|
||||
}
|
||||
else
|
||||
{
|
||||
punishment.PunishmentId = SQLHelper.GetNewID(typeof(Model.EMC_Punishment));
|
||||
this.hdId.Text = punishment.PunishmentId;
|
||||
}
|
||||
var att = from x in Funs.DB.AttachFile where x.ToKeyId == punishment.PunishmentId select x;
|
||||
if (att.Count() > 0)
|
||||
{
|
||||
punishment.AttachUrl = att.First().AttachUrl;
|
||||
}
|
||||
punishment.CreateDate = DateTime.Now;
|
||||
BLL.PunishmentService.AddPunishment(punishment);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Add Contractor Quality Punishment!");
|
||||
}
|
||||
|
||||
#region 发邮件给审核人通知审核
|
||||
var pun = BLL.PunishmentService.GetPunishmentById(punishment.PunishmentId);
|
||||
string auditMan = string.Empty;
|
||||
if (pun != null)
|
||||
{
|
||||
if (pun.IsFrame == true)
|
||||
{
|
||||
var fc = BLL.SESRelatedDataService.GetSESRelatedDataByFoNo(pun.FO_NO);
|
||||
string curUser = this.CurrUser.UserId; // 当前用户
|
||||
string violationInspector = pun.Violation_Inspector; // 发起人
|
||||
string leader = string.Empty; // 主协调员部门领导
|
||||
string mainCoordinator = fc.Main_Coordinator;
|
||||
|
||||
var userInfo = BLL.Sys_UserService.GetUsersByUserId(fc.Main_Coordinator);
|
||||
if (userInfo != null)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(userInfo.DepartId);
|
||||
if (dep != null)
|
||||
{
|
||||
leader = dep.DepartLeader;
|
||||
}
|
||||
}
|
||||
|
||||
// 当前用户不是主调协员
|
||||
if (curUser != mainCoordinator)
|
||||
{
|
||||
// 当前用户不是主调协员部门领导 发邮件给主调协员
|
||||
if (curUser != leader)
|
||||
{
|
||||
auditMan = mainCoordinator;
|
||||
}
|
||||
}
|
||||
else // 当前用户是主调协员
|
||||
{
|
||||
// 该主调协员不是部门领导时发邮件
|
||||
if (curUser != leader)
|
||||
{
|
||||
auditMan = leader;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 非框架合同
|
||||
else
|
||||
{
|
||||
string curUser = this.CurrUser.UserId; // 当前用户
|
||||
string violationInspector = pun.Violation_Inspector; // 发起人
|
||||
string leader = string.Empty; // 请购人部门领导
|
||||
string requisitioner = pun.Requisitioner; // 请购人
|
||||
|
||||
var userInfo = BLL.Sys_UserService.GetUsersByUserId(pun.Requisitioner);
|
||||
if (userInfo != null)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(userInfo.DepartId);
|
||||
if (dep != null)
|
||||
{
|
||||
leader = dep.DepartLeader;
|
||||
}
|
||||
}
|
||||
|
||||
// 当前用户不是请购人
|
||||
if (curUser != requisitioner)
|
||||
{
|
||||
// 当前用户是请购人部门领导 不发邮件
|
||||
if (curUser != leader)
|
||||
{
|
||||
auditMan = requisitioner;
|
||||
}
|
||||
}
|
||||
else // 当前用户是请购人
|
||||
{
|
||||
if (curUser != leader)
|
||||
{
|
||||
auditMan = leader;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (pun.EmailIsSend == null || pun.EmailIsSend == false)
|
||||
{
|
||||
Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
if (pops == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
string[] mailTo = null;
|
||||
string[] mailCC = null;
|
||||
string resultMessage = "";
|
||||
|
||||
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 == auditMan
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
if (userTo != null)
|
||||
{
|
||||
mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
}
|
||||
|
||||
if (mailTo.Length > 0)
|
||||
{
|
||||
NameValueCollection myPram = new NameValueCollection();
|
||||
myPram.Add("ContractNo", pun.FO_NO);
|
||||
myPram.Add("Contractor", txtContractor.Text);
|
||||
myPram.Add("编号", pun.FO_NO + "-" + pun.ItemNo);
|
||||
myPram.Add("Date", pun.PunishDate != null ? pun.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
myPram.Add("Time", pun.PunishDate != null ? pun.PunishDate.Value.ToString("HH:mm") : "");
|
||||
myPram.Add("Violation Description", pun.Description);
|
||||
bool result = MailHelper.SendPunishSesMail(pops, myPram, "承包商质量违规审核通知", mailTo, mailCC, out resultMessage);
|
||||
|
||||
if (result)
|
||||
{
|
||||
pun.EmailIsSend = true;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
ShowNotify("Save successfully!", MessageBoxIcon.Success);
|
||||
}
|
||||
// 审核
|
||||
else
|
||||
{
|
||||
var pun = BLL.PunishmentService.GetPunishmentById(punishmentId);
|
||||
if (pun.AuditEmailIsSend == null || pun.AuditEmailIsSend == false)
|
||||
{
|
||||
// 发起人即违章检查人
|
||||
string createMan = pun.Violation_Inspector;
|
||||
string auditMan = Request.Params["auditMan"];
|
||||
pun.AuditMan = auditMan;
|
||||
pun.IsAudit = true;
|
||||
if (rbIsPass.SelectedValue == "1")
|
||||
{
|
||||
pun.IsPass = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
pun.IsPass = false;
|
||||
}
|
||||
|
||||
pun.AuditResult = txtAuditResult.Text.Trim();
|
||||
|
||||
// 发邮件
|
||||
#region 发邮件给发起人通知审核结果
|
||||
if (rbIsPass.SelectedValue != null)
|
||||
{
|
||||
Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
if (pops == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
string[] mailTo = null;
|
||||
string[] mailCC = null;
|
||||
string resultMessage = "";
|
||||
bool result = false;
|
||||
|
||||
// 承包商质量违规审核通过
|
||||
if (rbIsPass.SelectedValue == "1")
|
||||
{
|
||||
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 == createMan || x.Account == "suny2")
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
if (userTo != null)
|
||||
{
|
||||
mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
}
|
||||
|
||||
if (mailTo.Length > 0)
|
||||
{
|
||||
NameValueCollection myPram = new NameValueCollection();
|
||||
myPram.Add("ContractNo", pun.FO_NO);
|
||||
myPram.Add("Contractor", txtContractor.Text);
|
||||
myPram.Add("编号", pun.FO_NO + "-" + pun.ItemNo);
|
||||
myPram.Add("Date", pun.PunishDate != null ? pun.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
myPram.Add("Time", pun.PunishDate != null ? pun.PunishDate.Value.ToString("HH:mm") : "");
|
||||
myPram.Add("Violation Description", pun.Description);
|
||||
result = MailHelper.SendPunishSesMail(pops, myPram, "承包商质量违规审核通过", mailTo, mailCC, out resultMessage);
|
||||
|
||||
}
|
||||
}
|
||||
if (result)
|
||||
{
|
||||
pun.AuditEmailIsSend = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// 承包商质量违规审核被拒绝
|
||||
else
|
||||
{
|
||||
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 == createMan
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
if (userTo != null)
|
||||
{
|
||||
mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
}
|
||||
|
||||
if (mailTo.Length > 0)
|
||||
{
|
||||
NameValueCollection myPram = new NameValueCollection();
|
||||
myPram.Add("ContractNo", pun.FO_NO);
|
||||
myPram.Add("Contractor", txtContractor.Text);
|
||||
myPram.Add("编号", pun.FO_NO + "-" + pun.ItemNo);
|
||||
myPram.Add("Date", pun.PunishDate != null ? pun.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
myPram.Add("Time", pun.PunishDate != null ? pun.PunishDate.Value.ToString("HH:mm") : "");
|
||||
myPram.Add("Violation Description", pun.Description);
|
||||
myPram.Add("拒绝描述", txtAuditResult.Text.Trim());
|
||||
result = MailHelper.SendPunishSesMail(pops, myPram, "承包商质量违规审核被拒绝", mailTo, mailCC, out resultMessage);
|
||||
}
|
||||
}
|
||||
if (result)
|
||||
{
|
||||
pun.AuditEmailIsSend = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 当ViolationRelatedSes为空时发送邮件提醒BYC Resp. Dept的部门经理
|
||||
if (rbIsPass.SelectedValue == "1")
|
||||
{
|
||||
var vses = (from x in Funs.DB.EMC_Punishment
|
||||
where x.PunishmentId == punishmentId
|
||||
&& x.IsFrame == true
|
||||
&& x.BYC_RU != null && x.BYC_RU.ToUpper() != "NA"
|
||||
&& (x.ViolationRelatedSes == "" || x.ViolationRelatedSes == null)
|
||||
//x.Flag == "2"
|
||||
//&& (x.RelatedSesMailIsSend == null || x.RelatedSesMailIsSend == false)
|
||||
select x).ToList();
|
||||
if (vses.Count() > 0)
|
||||
{
|
||||
Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
if (pops == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
foreach (var ses in vses)
|
||||
{
|
||||
string[] mailTo = null;
|
||||
string[] mailCC = null;
|
||||
string resultMessage = "";
|
||||
|
||||
var emailTemplate = Funs.DB.SendEmailTemplate.Where(x => x.EmailName.Contains("承包商质量违规关联SES号的填写通知"));
|
||||
if (emailTemplate.Count() > 0)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(ses.BYC_RU);
|
||||
if (dep != null && !string.IsNullOrEmpty(dep.DepartLeader))
|
||||
{
|
||||
var userTo = from x in Funs.DB.Sys_User
|
||||
where x.UserId == dep.DepartLeader
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
if (userTo != null)
|
||||
{
|
||||
mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
}
|
||||
|
||||
if (mailTo.Length > 0)
|
||||
{
|
||||
NameValueCollection myPram = new NameValueCollection();
|
||||
myPram.Add("ContractNo", ses.FO_NO);
|
||||
myPram.Add("Contractor", ses.Contractor);
|
||||
myPram.Add("Date", ses.PunishDate != null ? ses.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
myPram.Add("Time", ses.PunishDate != null ? ses.PunishDate.Value.ToString("HH:mm") : "");
|
||||
myPram.Add("Violation Description", ses.Description);
|
||||
bool result = MailHelper.SendPunishSesMail(pops, myPram, "承包商质量违规关联SES号的填写通知", mailTo, mailCC, out resultMessage);
|
||||
|
||||
if (result)
|
||||
{
|
||||
ses.RelatedSesMailIsSend = true;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
|
||||
}
|
||||
#endregion
|
||||
|
||||
protected void drpContractor_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (this.drpContractor.SelectedValue != BLL.Const._Null)
|
||||
{
|
||||
this.drpFO_No.Items.Clear();
|
||||
BLL.SESRelatedDataService.InitFONoDropDownList(this.drpFO_No, drpContractor.SelectedValue, true);//合同号
|
||||
drpFO_No.SelectedValue = BLL.Const._Null;
|
||||
txtDiscispline.Text = string.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
protected void drpFO_No_SelectedIndexChanged(object sender, EventArgs e)
|
||||
protected void txtText_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (drpFO_No.SelectedValue != Const._Null)
|
||||
if (!string.IsNullOrEmpty(txtFO_No.Text))
|
||||
{
|
||||
string foNO = drpFO_No.SelectedValue;
|
||||
string foNO = txtFO_No.Text.Trim();
|
||||
Model.View_FC_SESRelatedData fc = BLL.SESRelatedDataService.GetSESRelatedDataViewByFO(foNO);
|
||||
if (fc != null)
|
||||
{
|
||||
{
|
||||
txtContractor.Text = fc.Contractor;
|
||||
txtDiscispline.Text = fc.Discipline;
|
||||
txtContractAdmin.Text = fc.Contract_Admin;
|
||||
txtMainCoordinator.Text = fc.Main_Coordinator;
|
||||
txtUserRepresentative.Text = fc.User_Representative;
|
||||
txtMCDept.Text = fc.MCDept;
|
||||
|
||||
txtContractAdmin.Hidden = false;
|
||||
txtMainCoordinator.Hidden = false;
|
||||
txtUserRepresentative.Hidden = false;
|
||||
txtMCDept.Hidden = false;
|
||||
drpBYC_RU.Hidden = false;
|
||||
GPRole.Hidden = false;
|
||||
drpRequisitioner.Hidden = true;
|
||||
txtViolationRelatedSes.Hidden = false;
|
||||
GPDep.Hidden = false;
|
||||
|
||||
txtDiscispline.Readonly = true;
|
||||
drpRequisitioner.Required= false;
|
||||
drpRequisitioner.ShowRedStar = false;
|
||||
rbIsFrame.SelectedValue = "1";
|
||||
}
|
||||
else
|
||||
{
|
||||
txtDiscispline.Text = string.Empty;
|
||||
txtContractor.Text = string.Empty;
|
||||
txtContractAdmin.Text = string.Empty;
|
||||
txtMainCoordinator.Text = string.Empty;
|
||||
txtUserRepresentative.Text = string.Empty;
|
||||
txtMCDept.Text = string.Empty;
|
||||
|
||||
txtDiscispline.Readonly = false;
|
||||
txtContractAdmin.Hidden = true;
|
||||
txtMainCoordinator.Hidden = true;
|
||||
txtUserRepresentative.Hidden = true;
|
||||
txtMCDept.Hidden = true;
|
||||
drpBYC_RU.Hidden = true;
|
||||
GPRole.Hidden = true;
|
||||
rbIsFrame.SelectedValue = "0";
|
||||
drpRequisitioner.Required = true;
|
||||
drpRequisitioner.ShowRedStar = true;
|
||||
txtViolationRelatedSes.Hidden = true;
|
||||
GPDep.Hidden = true;
|
||||
}
|
||||
|
||||
// 序号
|
||||
var pun=from x in Funs.DB.EMC_Punishment where x.FO_NO== foNO && x.Flag=="2" select x;
|
||||
if (pun.Count() == 0)
|
||||
{
|
||||
txtItemNo.Text = "001";
|
||||
}
|
||||
else
|
||||
{
|
||||
var max = pun.Max(x=>x.ItemNo);
|
||||
if (!string.IsNullOrEmpty(max))
|
||||
{
|
||||
int maxNo = Convert.ToInt32(max) + 1;
|
||||
txtItemNo.Text = "00" + maxNo.ToString();
|
||||
}
|
||||
else
|
||||
{
|
||||
txtItemNo.Text = "001";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
protected void drpViolationInspector_SelectedIndexChanged(object sender, EventArgs e)
|
||||
|
||||
//protected void drpViolationInspector_SelectedIndexChanged(object sender, EventArgs e)
|
||||
//{
|
||||
// if (drpViolationInspector.SelectedValue != Const._Null)
|
||||
// {
|
||||
// string manId = drpViolationInspector.SelectedValue;
|
||||
// var user = BLL.Sys_UserService.GetUsersByUserId(manId);
|
||||
// string depName = BLL.DepartService.GetDepartNameById(user.DepartId);
|
||||
// txtInspectionDep.Text = depName;
|
||||
// }
|
||||
//}
|
||||
|
||||
protected void drpViolationClause_OnSelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (drpViolationInspector.SelectedValue != Const._Null)
|
||||
{
|
||||
string manId = drpViolationInspector.SelectedValue;
|
||||
var user = BLL.Sys_UserService.GetUsersByUserId(manId);
|
||||
string depName = BLL.DepartService.GetDepartNameById(user.DepartId);
|
||||
txtInspectionDep.Text = depName;
|
||||
if (drpViolationClause.SelectedValue != Const._Null)
|
||||
{
|
||||
var vio=BLL.ViolationClauseService.GetViolationClause(drpViolationClause.SelectedValue);
|
||||
if (vio.DeductionComPany1 != 0)
|
||||
{
|
||||
drpViolationDegree.SelectedValue = "1";
|
||||
txtCompany.Text = vio.DeductionComPany1.ToString();
|
||||
txtIndividual.Text = vio.DeductionIndividual1.ToString();
|
||||
txtBackcharge.Text = (vio.DeductionComPany1 + vio.DeductionIndividual1).ToString();
|
||||
}
|
||||
if (vio.DeductionComPany2 != 0)
|
||||
{
|
||||
drpViolationDegree.SelectedValue = "2";
|
||||
txtCompany.Text = vio.DeductionComPany2.ToString();
|
||||
txtIndividual.Text = vio.DeductionIndividual2.ToString();
|
||||
txtBackcharge.Text = (vio.DeductionComPany2 + vio.DeductionIndividual2).ToString();
|
||||
}
|
||||
if (vio.DeductionComPany3 != 0)
|
||||
{
|
||||
drpViolationDegree.SelectedValue = "3";
|
||||
txtCompany.Text = vio.DeductionComPany3.ToString();
|
||||
txtIndividual.Text = vio.DeductionIndividual3.ToString();
|
||||
txtBackcharge.Text = (vio.DeductionComPany2 + vio.DeductionIndividual3).ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -239,6 +733,23 @@ namespace FineUIPro.Web.SES
|
|||
txtBackcharge.Text = (numCompany + numIndividual).Value.ToString("0.00");
|
||||
}
|
||||
|
||||
|
||||
#region 附件上传
|
||||
/// <summary>
|
||||
/// 附件上传
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnAttach_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (string.IsNullOrEmpty(this.hdId.Text)) //新增记录
|
||||
{
|
||||
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.CQualityPunishMenuId)));
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 权限设置
|
||||
/// <summary>
|
||||
/// 菜单按钮权限
|
||||
|
|
|
@ -7,11 +7,13 @@
|
|||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.SES {
|
||||
|
||||
|
||||
public partial class CQualityPunishEdit {
|
||||
|
||||
namespace FineUIPro.Web.SES
|
||||
{
|
||||
|
||||
|
||||
public partial class CQualityPunishEdit
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
|
@ -20,7 +22,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
|
@ -29,7 +31,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// SimpleForm1 控件。
|
||||
/// </summary>
|
||||
|
@ -38,7 +40,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form SimpleForm1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtPunishDate 控件。
|
||||
/// </summary>
|
||||
|
@ -47,7 +49,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtPunishDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtPunishTime 控件。
|
||||
/// </summary>
|
||||
|
@ -56,25 +58,43 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtPunishTime;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpContractor 控件。
|
||||
/// txtFO_No 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpContractor;
|
||||
|
||||
protected global::FineUIPro.TextBox txtFO_No;
|
||||
|
||||
/// <summary>
|
||||
/// drpFO_No 控件。
|
||||
/// txtItemNo 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpFO_No;
|
||||
|
||||
protected global::FineUIPro.TextBox txtItemNo;
|
||||
|
||||
/// <summary>
|
||||
/// rbIsFrame 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.RadioButtonList rbIsFrame;
|
||||
|
||||
/// <summary>
|
||||
/// txtContractor 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtContractor;
|
||||
|
||||
/// <summary>
|
||||
/// txtDiscispline 控件。
|
||||
/// </summary>
|
||||
|
@ -83,7 +103,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtDiscispline;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtLocation 控件。
|
||||
/// </summary>
|
||||
|
@ -92,7 +112,16 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtLocation;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtViolationPerson 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtViolationPerson;
|
||||
|
||||
/// <summary>
|
||||
/// txtDescription 控件。
|
||||
/// </summary>
|
||||
|
@ -101,34 +130,16 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtDescription;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtCompany 控件。
|
||||
/// drpViolationClause 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox txtCompany;
|
||||
|
||||
/// <summary>
|
||||
/// txtIndividual 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox txtIndividual;
|
||||
|
||||
/// <summary>
|
||||
/// txtBackcharge 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox txtBackcharge;
|
||||
|
||||
protected global::FineUIPro.DropDownList drpViolationClause;
|
||||
|
||||
/// <summary>
|
||||
/// drpViolationDegree 控件。
|
||||
/// </summary>
|
||||
|
@ -137,7 +148,34 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpViolationDegree;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtCompany 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox txtCompany;
|
||||
|
||||
/// <summary>
|
||||
/// txtIndividual 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox txtIndividual;
|
||||
|
||||
/// <summary>
|
||||
/// txtBackcharge 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.NumberBox txtBackcharge;
|
||||
|
||||
/// <summary>
|
||||
/// txtContractAdmin 控件。
|
||||
/// </summary>
|
||||
|
@ -146,7 +184,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtContractAdmin;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtMainCoordinator 控件。
|
||||
/// </summary>
|
||||
|
@ -155,7 +193,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtMainCoordinator;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtMCDept 控件。
|
||||
/// </summary>
|
||||
|
@ -164,7 +202,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtMCDept;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtUserRepresentative 控件。
|
||||
/// </summary>
|
||||
|
@ -173,16 +211,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtUserRepresentative;
|
||||
|
||||
/// <summary>
|
||||
/// drpBYC_RU 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpBYC_RU;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpViolationInspector 控件。
|
||||
/// </summary>
|
||||
|
@ -191,7 +220,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpViolationInspector;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtInspectionDep 控件。
|
||||
/// </summary>
|
||||
|
@ -200,7 +229,61 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtInspectionDep;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpBYC_RU 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpBYC_RU;
|
||||
|
||||
/// <summary>
|
||||
/// txtViolationRelatedSes 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtViolationRelatedSes;
|
||||
|
||||
/// <summary>
|
||||
/// drpRequisitioner 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpRequisitioner;
|
||||
|
||||
/// <summary>
|
||||
/// Panel3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel Panel3;
|
||||
|
||||
/// <summary>
|
||||
/// lblAttach 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label lblAttach;
|
||||
|
||||
/// <summary>
|
||||
/// btnAttach 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnAttach;
|
||||
|
||||
/// <summary>
|
||||
/// GPRole 控件。
|
||||
/// </summary>
|
||||
|
@ -209,7 +292,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.GroupPanel GPRole;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtSESNo 控件。
|
||||
/// </summary>
|
||||
|
@ -218,7 +301,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtSESNo;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtCompletionDate 控件。
|
||||
/// </summary>
|
||||
|
@ -227,7 +310,52 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtCompletionDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// GPDep 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.GroupPanel GPDep;
|
||||
|
||||
/// <summary>
|
||||
/// txtViolationRelatedSes1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtViolationRelatedSes1;
|
||||
|
||||
/// <summary>
|
||||
/// GPAudit 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.GroupPanel GPAudit;
|
||||
|
||||
/// <summary>
|
||||
/// rbIsPass 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.RadioButtonList rbIsPass;
|
||||
|
||||
/// <summary>
|
||||
/// txtAuditResult 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtAuditResult;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar1 控件。
|
||||
/// </summary>
|
||||
|
@ -236,7 +364,16 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// hdId 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.HiddenField hdId;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控件。
|
||||
/// </summary>
|
||||
|
@ -245,7 +382,7 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnSave;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnClose 控件。
|
||||
/// </summary>
|
||||
|
@ -254,5 +391,14 @@ namespace FineUIPro.Web.SES {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnClose;
|
||||
|
||||
/// <summary>
|
||||
/// WindowAtt 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window WindowAtt;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -302,7 +302,6 @@ namespace FineUIPro.Web.SES
|
|||
punishment.PunishmentId = PunishmentId;
|
||||
BLL.PunishmentService.UpdatePunishment(punishment);
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Modify Contractor Safety Punishment!");
|
||||
ShowNotify("Save successfully!", MessageBoxIcon.Success);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -310,59 +309,83 @@ namespace FineUIPro.Web.SES
|
|||
punishment.PunishmentId = PunishmentId;
|
||||
punishment.CreateDate = DateTime.Now;
|
||||
BLL.PunishmentService.AddPunishment(punishment);
|
||||
|
||||
#region 承包商EHSS违规关联SES号的填写通知 改在Golbal里触发
|
||||
//Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
//if (pops == null)
|
||||
//{
|
||||
// return;
|
||||
//}
|
||||
//string[] mailTo = null;
|
||||
//string[] mailCC = null;
|
||||
//string resultMessage = "";
|
||||
|
||||
//var emailTemplate = Funs.DB.SendEmailTemplate.Where(x => x.EmailName.Contains("承包商EHSS违规关联SES号的填写通知"));
|
||||
//if (emailTemplate.Count() > 0)
|
||||
//{
|
||||
// var dep = BLL.DepartService.GetDepartById(drpBYC_RU.SelectedValue);
|
||||
// if (dep != null && !string.IsNullOrEmpty(dep.DepartLeader))
|
||||
// {
|
||||
// var userTo = from x in Funs.DB.Sys_User
|
||||
// where x.UserId == dep.DepartLeader
|
||||
// && x.Email != null && x.Email != ""
|
||||
// select x;
|
||||
// if (userTo != null)
|
||||
// {
|
||||
// mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
// }
|
||||
|
||||
// var fo = BLL.SESRelatedDataService.GetSESRelatedDataByFoNo(drpFO_No.SelectedValue);
|
||||
// if (fo != null)
|
||||
// {
|
||||
// var userCC = from x in Funs.DB.Sys_User
|
||||
// where (x.UserId == fo.Contract_Admin || x.UserId == fo.Main_Coordinator)
|
||||
// && x.Email != null && x.Email != ""
|
||||
// select x;
|
||||
// mailCC = userCC.Select(x => x.Email).Distinct().ToArray();
|
||||
// }
|
||||
|
||||
// if (mailTo.Length > 0)
|
||||
// {
|
||||
// NameValueCollection myPram = new NameValueCollection();
|
||||
// myPram.Add("ContractNo", fo.FO_NO);
|
||||
// myPram.Add("Contractor", drpContractor.SelectedText);
|
||||
// myPram.Add("Date", punishment.PunishDate != null ? punishment.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
// myPram.Add("Time", punishment.PunishDate != null ? punishment.PunishDate.Value.ToString("HH:mm") : "");
|
||||
// myPram.Add("Violation Description", punishment.Description);
|
||||
// MailHelper.SendPunishSesMail(pops, myPram, "承包商EHSS违规关联SES号的填写通知", mailTo, mailCC, out resultMessage);
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
#endregion
|
||||
|
||||
BLL.Sys_LogService.AddLog(this.CurrUser.UserId, "Add Contractor Safety Punishment!");
|
||||
ShowNotify("Save successfully!", MessageBoxIcon.Success);
|
||||
}
|
||||
|
||||
#region 承包商EHSS违规关联SES号的填写通知
|
||||
var vses = (from x in Funs.DB.EMC_Punishment
|
||||
where (x.RelatedSesMailIsSend == null || x.RelatedSesMailIsSend == false)
|
||||
&& x.BYC_RU != null && x.BYC_RU.ToUpper() != "NA" && x.Flag == "1"
|
||||
&& x.PunishmentId== punishment.PunishmentId
|
||||
select x).ToList();
|
||||
if (vses.Count() > 0)
|
||||
{
|
||||
Model.EmailPop pops = Funs.DB.EmailPop.FirstOrDefault(x => x.EmailID == BLL.Const.EmailPopId);
|
||||
if (pops == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
foreach (var ses in vses)
|
||||
{
|
||||
string[] mailTo = null;
|
||||
string[] mailCC = null;
|
||||
string resultMessage = "";
|
||||
|
||||
var emailTemplate = Funs.DB.SendEmailTemplate.Where(x => x.EmailName.Contains("承包商EHSS违规关联SES号的填写通知"));
|
||||
if (emailTemplate.Count() > 0)
|
||||
{
|
||||
var dep = BLL.DepartService.GetDepartById(ses.BYC_RU);
|
||||
if (dep != null && !string.IsNullOrEmpty(dep.DepartLeader))
|
||||
{
|
||||
var userTo = from x in Funs.DB.Sys_User
|
||||
where x.UserId == dep.DepartLeader
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
if (userTo != null)
|
||||
{
|
||||
mailTo = userTo.Select(x => x.Email).ToArray();
|
||||
}
|
||||
|
||||
string contractor = string.Empty;
|
||||
var fo = BLL.SESRelatedDataService.GetSESRelatedDataByFoNo(ses.FO_NO);
|
||||
if (fo != null)
|
||||
{
|
||||
var userCC = from x in Funs.DB.Sys_User
|
||||
where (x.UserId == fo.Contract_Admin || x.UserId == fo.Main_Coordinator)
|
||||
&& x.Email != null && x.Email != ""
|
||||
select x;
|
||||
mailCC = userCC.Select(x => x.Email).Distinct().ToArray();
|
||||
|
||||
var con = Funs.DB.View_Contractor_DropDownValue.FirstOrDefault(x => x.ContractorId == fo.Contractor);
|
||||
if (con != null)
|
||||
{
|
||||
contractor = con.Contractor;
|
||||
}
|
||||
}
|
||||
|
||||
if (mailTo.Length > 0)
|
||||
{
|
||||
NameValueCollection myPram = new NameValueCollection();
|
||||
myPram.Add("ContractNo", fo.FO_NO);
|
||||
myPram.Add("Contractor", contractor);
|
||||
myPram.Add("Date", ses.PunishDate != null ? ses.PunishDate.Value.ToString("yyyy-MM-dd") : "");
|
||||
myPram.Add("Time", ses.PunishDate != null ? ses.PunishDate.Value.ToString("HH:mm") : "");
|
||||
myPram.Add("Violation Description", ses.Description);
|
||||
bool result = MailHelper.SendPunishSesMail(pops, myPram, "承包商EHSS违规关联SES号的填写通知", mailTo, mailCC, out resultMessage);
|
||||
|
||||
if (result)
|
||||
{
|
||||
ses.RelatedSesMailIsSend = true;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
ShowNotify("Save successfully!", MessageBoxIcon.Success);
|
||||
PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
|
||||
}
|
||||
#endregion
|
||||
|
|
|
@ -90,17 +90,17 @@
|
|||
LabelAlign="Right">
|
||||
</f:DropDownList>
|
||||
<f:Button ID="btnNCRExport" OnClick="btnNCRExport_Click" runat="server" Text="Export" ToolTip="Export"
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false">
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false" Hidden="true">
|
||||
</f:Button>
|
||||
|
||||
<f:Button ID="btnExport" OnClick="btnExport_Click" runat="server" Text="FCExport" ToolTip="FCExport"
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false">
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false" Hidden="true">
|
||||
</f:Button>
|
||||
<f:Button ID="btnExport1" OnClick="btnExport1_Click" runat="server" Text="PersonExport" ToolTip="PersonExport"
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false">
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false" Hidden="true">
|
||||
</f:Button>
|
||||
<f:Button ID="btnFoExport" OnClick="btnFoExport_Click" runat="server" Text="FoExport" ToolTip="FO Report Export"
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false">
|
||||
Icon="DoorOut" EnableAjax="false" DisableControlBeforePostBack="false" Hidden="true">
|
||||
</f:Button>
|
||||
|
||||
</Items>
|
||||
|
|
|
@ -2034,9 +2034,21 @@ namespace FineUIPro.Web.SES
|
|||
#endregion
|
||||
|
||||
if (buttonList.Contains(BLL.Const.BtnOut))
|
||||
{
|
||||
this.btnNCRExport.Hidden = false;
|
||||
}
|
||||
if (buttonList.Contains(BLL.Const.FCExport))
|
||||
{
|
||||
this.btnExport.Hidden = false;
|
||||
}
|
||||
if (buttonList.Contains(BLL.Const.PersonExport))
|
||||
{
|
||||
this.btnExport1.Hidden = false;
|
||||
}
|
||||
if (buttonList.Contains(BLL.Const.FoExport))
|
||||
{
|
||||
this.btnFoExport.Hidden = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
|
|
@ -30,7 +30,7 @@ namespace FineUIPro.Web.SES
|
|||
{
|
||||
this.tvStandardTemp.Nodes.Clear();
|
||||
TreeNode rootRole = new TreeNode();
|
||||
rootRole.Text = "TemplateType";
|
||||
rootRole.Text = "Template Type";
|
||||
rootRole.NodeID = "0";
|
||||
rootRole.Expanded = true;
|
||||
this.tvStandardTemp.Nodes.Add(rootRole);
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<section name="FineUIPro" type="FineUIPro.ConfigSection, FineUIPro" requirePermission="false"/>
|
||||
</configSections>
|
||||
<connectionStrings>
|
||||
<add name="FCLDBConnectionString" connectionString="Data Source=.;Initial Catalog=FCLDB;uid=sa;pwd=Sh@nghai9;" providerName="System.Data.SqlClient"/>
|
||||
<add name="FCLDBConnectionString" connectionString="Data Source=.\sql2016;Initial Catalog=FCLDB;uid=sa;pwd=1111;" providerName="System.Data.SqlClient"/>
|
||||
</connectionStrings>
|
||||
<FineUIPro DebugMode="false" CustomTheme="Metro_Dark_Blue" EnableAnimation="true" JSLibrary="All"/>
|
||||
<appSettings>
|
||||
|
|
1434
FCL/Model/Model.cs
1434
FCL/Model/Model.cs
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue