20260313 管道材料材质标识检查记录
This commit is contained in:
parent
5e156bd0a1
commit
5f72f3f0b0
|
|
@ -1,6 +1,7 @@
|
||||||
using Model;
|
using Model;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Resources;
|
||||||
|
|
||||||
namespace BLL
|
namespace BLL
|
||||||
{
|
{
|
||||||
|
|
@ -18,6 +19,11 @@ namespace BLL
|
||||||
e.RecordId == recordId);
|
e.RecordId == recordId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static List<Model.JGZL_MaterialIdentificationInspectionRecord> GetListsByProjectId(string projectId)
|
||||||
|
{
|
||||||
|
return (from x in Funs.DB.JGZL_MaterialIdentificationInspectionRecord where x.ProjectId == projectId select x).ToList();
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 添加管道材料材质标识检查记录
|
/// 添加管道材料材质标识检查记录
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -86,7 +92,16 @@ namespace BLL
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void DeleteListsByProjectId(string projectId)
|
||||||
|
{
|
||||||
|
SGGLDB db = Funs.DB;
|
||||||
|
var q = (from x in db.JGZL_MaterialIdentificationInspectionRecord where x.ProjectId == projectId select x).ToList();
|
||||||
|
if (q.Count>0)
|
||||||
|
{
|
||||||
|
db.JGZL_MaterialIdentificationInspectionRecord.DeleteAllOnSubmit(q);
|
||||||
|
db.SubmitChanges();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Report ScriptLanguage="CSharp" ReportInfo.Created="01/27/2026 16:57:11" ReportInfo.Modified="02/24/2026 14:28:59" ReportInfo.CreatorVersion="2017.1.16.0">
|
<Report ScriptLanguage="CSharp" ReportInfo.Created="01/27/2026 16:57:11" ReportInfo.Modified="03/13/2026 13:52:52" ReportInfo.CreatorVersion="2017.1.16.0">
|
||||||
<ScriptText>using System;
|
<ScriptText>using System;
|
||||||
using System.Collections;
|
using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
@ -42,7 +42,7 @@ namespace FastReport
|
||||||
}
|
}
|
||||||
</ScriptText>
|
</ScriptText>
|
||||||
<Dictionary>
|
<Dictionary>
|
||||||
<MsSqlDataConnection Name="Connection" ConnectionString="rijcmlqtRsOalcXxDhVt62rPEPNYjaATUoMqziRYvJtgNsyJKYAG7kXKvNAMI/qBkgJNPccFsWrhiII6oyX1HS+uwN7YigxVjqUq3vIet2zpPnmWhwvYEvWOOCZZGx6EC4BfGfWX8aPj6bmoF52Z0fnUA9g71duxa/gvChTW/nzu9qsYVuvlVHliMnnu6jEIF9n+/QFd88UxbEsEkw3wnwqhHPfLg==">
|
<MsSqlDataConnection Name="Connection" ConnectionString="rijcmlqtRsOalcXxDhVt62rPEPNYjaATUoMqziRYvJtgNsyJKYAG7kXKvNAMI/qBkgJNPccFsWrhiII6oyX1HS+uwN7YigxVjqUq3vIet2zpPnmWhwvYEvWOOCZZGx6EC4BfGfWX8aPj6bmoF52Z0fnUA9g71duxa/gvChTW/nzu9qsYVuvlVHliMnnu6jEIF9n+/QFGF4PbRRRnyGgSV2vxImNAA==">
|
||||||
<TableDataSource Name="Data" DataType="System.Int32" PropName="Attach_Image" Enabled="true" TableName="Data">
|
<TableDataSource Name="Data" DataType="System.Int32" PropName="Attach_Image" Enabled="true" TableName="Data">
|
||||||
<Column Name="ISO_IsoNo" DataType="System.String" PropName="attach_image_id"/>
|
<Column Name="ISO_IsoNo" DataType="System.String" PropName="attach_image_id"/>
|
||||||
<Column Name="STE_Code" DataType="System.String" PropName="image_series"/>
|
<Column Name="STE_Code" DataType="System.String" PropName="image_series"/>
|
||||||
|
|
|
||||||
|
|
@ -40,7 +40,7 @@
|
||||||
<%--<f:DatePicker ID="txtStartDate" runat="server" Label="记录时间" LabelAlign="Right" Width="220px" AutoPostBack="true" OnTextChanged="Text_TextChanged"></f:DatePicker>
|
<%--<f:DatePicker ID="txtStartDate" runat="server" Label="记录时间" LabelAlign="Right" Width="220px" AutoPostBack="true" OnTextChanged="Text_TextChanged"></f:DatePicker>
|
||||||
<f:Label ID="lblTo" runat="server" Text="-" Width="10px"></f:Label>
|
<f:Label ID="lblTo" runat="server" Text="-" Width="10px"></f:Label>
|
||||||
<f:DatePicker ID="txtEndDate" runat="server" Width="120px" AutoPostBack="true" OnTextChanged="Text_TextChanged"></f:DatePicker>--%>
|
<f:DatePicker ID="txtEndDate" runat="server" Width="120px" AutoPostBack="true" OnTextChanged="Text_TextChanged"></f:DatePicker>--%>
|
||||||
<f:DropDownList ID="drpIsoId" runat="server" Label="管道编号/单线号" LabelAlign="Right" AutoPostBack="true" OnSelectedIndexChanged="drpIsoId_SelectedIndexChanged" AutoSelectFirstItem="false" LabelWidth="120px"></f:DropDownList>
|
<f:DropDownList ID="drpIsoId" runat="server" Label="管道编号/单线号" LabelAlign="Right" EnableEdit="true" AutoPostBack="true" OnSelectedIndexChanged="drpIsoId_SelectedIndexChanged" AutoSelectFirstItem="false" LabelWidth="120px"></f:DropDownList>
|
||||||
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
||||||
</f:ToolbarFill>
|
</f:ToolbarFill>
|
||||||
<f:Button ID="btnAdd" runat="server" Icon="Add" Text="增加" OnClick="btnAdd_Click"></f:Button>
|
<f:Button ID="btnAdd" runat="server" Icon="Add" Text="增加" OnClick="btnAdd_Click"></f:Button>
|
||||||
|
|
|
||||||
|
|
@ -4,127 +4,135 @@
|
||||||
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head runat="server">
|
<head runat="server">
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||||
<title>管道材料材质标识检查记录</title>
|
<title>管道材料材质标识检查记录</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<form id="form1" runat="server">
|
<form id="form1" runat="server">
|
||||||
<f:PageManager ID="PageManager1" AutoSizePanelID="Panel1" runat="server"/>
|
<f:PageManager ID="PageManager1" AutoSizePanelID="Panel1" runat="server" />
|
||||||
<f:Panel ID="Panel1" runat="server" ShowBorder="false" ShowHeader="false" Layout="Region">
|
<f:Panel ID="Panel1" runat="server" ShowBorder="false" ShowHeader="false" Layout="Region">
|
||||||
<Items>
|
<Items>
|
||||||
<f:Panel runat="server" ID="panelLeftRegion" RegionPosition="Left" RegionSplit="true"
|
<f:Panel runat="server" ID="panelLeftRegion" RegionPosition="Left" RegionSplit="true"
|
||||||
EnableCollapse="true" Width="220px" Title="管道材料材质标识检查记录" ShowBorder="true" Layout="VBox"
|
EnableCollapse="true" Width="220px" Title="管道材料材质标识检查记录" ShowBorder="true" Layout="VBox"
|
||||||
ShowHeader="true" AutoScroll="true" BodyPadding="5px" IconFont="ArrowCircleLeft">
|
ShowHeader="true" AutoScroll="true" BodyPadding="5px" IconFont="ArrowCircleLeft">
|
||||||
<Toolbars>
|
<Toolbars>
|
||||||
<f:Toolbar ID="Toolbar1" Position="Top" runat="server" ToolbarAlign="Left">
|
<f:Toolbar ID="Toolbar1" Position="Top" runat="server" ToolbarAlign="Left">
|
||||||
<Items>
|
<Items>
|
||||||
<f:DropDownList ID="drpProjectId" runat="server" Label="项目" LabelAlign="Right" AutoPostBack="true" EnableEdit="true"
|
<f:DropDownList ID="drpProjectId" runat="server" Label="项目" LabelAlign="Right" AutoPostBack="true" EnableEdit="true"
|
||||||
OnSelectedIndexChanged="drpProjectId_SelectedIndexChanged" LabelWidth="50px">
|
OnSelectedIndexChanged="drpProjectId_SelectedIndexChanged" LabelWidth="50px">
|
||||||
</f:DropDownList>
|
</f:DropDownList>
|
||||||
</Items>
|
</Items>
|
||||||
</f:Toolbar>
|
</f:Toolbar>
|
||||||
</Toolbars>
|
</Toolbars>
|
||||||
<Items>
|
<Items>
|
||||||
<f:Tree ID="tvControlItem" ShowHeader="false" Title="管道材料材质标识检查记录节点树" OnNodeCommand="tvControlItem_NodeCommand"
|
<f:Tree ID="tvControlItem" ShowHeader="false" Title="管道材料材质标识检查记录节点树" OnNodeCommand="tvControlItem_NodeCommand"
|
||||||
runat="server" ShowBorder="false" EnableCollapse="true" EnableSingleClickExpand="true"
|
runat="server" ShowBorder="false" EnableCollapse="true" EnableSingleClickExpand="true"
|
||||||
AutoLeafIdentification="true" EnableSingleExpand="true" EnableTextSelection="true">
|
AutoLeafIdentification="true" EnableSingleExpand="true" EnableTextSelection="true">
|
||||||
</f:Tree>
|
</f:Tree>
|
||||||
</Items>
|
</Items>
|
||||||
</f:Panel>
|
</f:Panel>
|
||||||
<f:Panel runat="server" ID="panelCenterRegion" RegionPosition="Center" ShowBorder="true"
|
<f:Panel runat="server" ID="panelCenterRegion" RegionPosition="Center" ShowBorder="true"
|
||||||
Layout="VBox" ShowHeader="false" BodyPadding="5px" IconFont="PlusCircle" Title="管道材料材质标识检查记录"
|
Layout="VBox" ShowHeader="false" BodyPadding="5px" IconFont="PlusCircle" Title="管道材料材质标识检查记录"
|
||||||
TitleToolTip="管道材料材质标识检查记录" AutoScroll="true">
|
TitleToolTip="管道材料材质标识检查记录" AutoScroll="true">
|
||||||
<Toolbars>
|
<Toolbars>
|
||||||
<f:Toolbar ID="Toolbar2" Position="Top" runat="server" ToolbarAlign="Right">
|
<f:Toolbar ID="Toolbar2" Position="Top" runat="server" ToolbarAlign="Right">
|
||||||
<Items>
|
<Items>
|
||||||
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
<f:DropDownList ID="drpIsoId" runat="server" Label="管道编号/单线号" LabelAlign="Right" EnableEdit="true" AutoPostBack="true" OnSelectedIndexChanged="drpIsoId_SelectedIndexChanged" AutoSelectFirstItem="false" LabelWidth="120px"></f:DropDownList>
|
||||||
</f:ToolbarFill>
|
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
||||||
<f:Button ID="btnAdd" runat="server" Icon="Add" Text="增加" OnClick="btnAdd_Click"></f:Button>
|
</f:ToolbarFill>
|
||||||
<f:Button ID="btnPrint" Text="管道材料材质标识检查记录打印" Icon="Printer" runat="server" OnClick="btnPrint_Click">
|
<f:Button ID="btnAdd" runat="server" Icon="Add" Text="增加" OnClick="btnAdd_Click"></f:Button>
|
||||||
</f:Button>
|
<f:Button ID="btnSave" Text="保存" ToolTip="保存" Icon="SystemSave" runat="server" OnClick="btnSave_Click"></f:Button>
|
||||||
</Items>
|
<f:Button ID="btnPrint" Text="管道材料材质标识检查记录打印" Icon="Printer" runat="server" OnClick="btnPrint_Click">
|
||||||
</f:Toolbar>
|
</f:Button>
|
||||||
</Toolbars>
|
</Items>
|
||||||
<Items>
|
</f:Toolbar>
|
||||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="管道材料材质标识检查记录" EnableCollapse="true"
|
</Toolbars>
|
||||||
|
<Items>
|
||||||
|
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="管道材料材质标识检查记录" EnableCollapse="true"
|
||||||
runat="server" BoxFlex="1" DataKeyNames="RecordId" AllowCellEditing="true"
|
runat="server" BoxFlex="1" DataKeyNames="RecordId" AllowCellEditing="true"
|
||||||
EnableColumnLines="true" ClicksToEdit="1" DataIDField="RecordId" AllowSorting="true"
|
EnableColumnLines="true" ClicksToEdit="1" DataIDField="RecordId" AllowSorting="true"
|
||||||
SortField="CompileDate" SortDirection="DESC" OnSort="Grid1_Sort" AllowPaging="true"
|
SortField="CompileDate" SortDirection="DESC" OnSort="Grid1_Sort" AllowPaging="true"
|
||||||
IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange"
|
IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange"
|
||||||
EnableTextSelection="True" AutoScroll="true" EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick">
|
EnableTextSelection="True" AutoScroll="true" OnPreDataBound="Grid1_PreDataBound">
|
||||||
<Columns>
|
<Columns>
|
||||||
<f:RowNumberField EnablePagingNumber="true" HeaderText="序号" Width="50px" HeaderTextAlign="Center"
|
<f:RowNumberField EnablePagingNumber="true" HeaderText="序号" Width="50px" HeaderTextAlign="Center"
|
||||||
TextAlign="Center"/>
|
TextAlign="Center" />
|
||||||
<f:RenderField HeaderText="管道编号/单线号" ColumnID="ISO_IsoNo" DataField="ISO_IsoNo" SortField="ISO_IsoNo"
|
<f:RenderField HeaderText="管道编号/单线号" ColumnID="ISO_Id" DataField="ISO_Id" SortField="ISO_Id"
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="180px">
|
||||||
</f:RenderField>
|
<Editor>
|
||||||
<f:RenderField HeaderText="材质" ColumnID="STE_Code" DataField="STE_Code" SortField="STE_Code"
|
<f:TextBox ID="txtISO_Id" runat="server"></f:TextBox>
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
</Editor>
|
||||||
</f:RenderField>
|
</f:RenderField>
|
||||||
<f:RenderField HeaderText="规格" ColumnID="Specifications" DataField="Specifications" SortField="Specifications"
|
<f:RenderField HeaderText="材质" ColumnID="STE_ID" DataField="STE_ID" SortField="STE_ID"
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="120px">
|
||||||
</f:RenderField>
|
<Editor>
|
||||||
<f:RenderField HeaderText="规定色标颜色" ColumnID="PrescribedColor" DataField="PrescribedColor" SortField="PrescribedColor"
|
<f:TextBox ID="txtSTE_Code" runat="server"></f:TextBox>
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
</Editor>
|
||||||
</f:RenderField>
|
</f:RenderField>
|
||||||
<f:RenderField HeaderText="管子标识状态" ColumnID="TubeIdentificationStatus" DataField="TubeIdentificationStatus" SortField="TubeIdentificationStatus"
|
<f:RenderField HeaderText="规格" ColumnID="Specifications" DataField="Specifications" SortField="Specifications"
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="120px">
|
||||||
</f:RenderField>
|
<Editor>
|
||||||
<f:RenderField HeaderText="管件名称" ColumnID="PipeFittingName" DataField="PipeFittingName" SortField="PipeFittingName"
|
<f:TextBox ID="txtSpecifications" runat="server"></f:TextBox>
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
</Editor>
|
||||||
</f:RenderField>
|
</f:RenderField>
|
||||||
<f:RenderField HeaderText="管件标识状态" ColumnID="PipeFittingStatus" DataField="PipeFittingStatus" SortField="PipeFittingStatus"
|
<f:RenderField HeaderText="规定色标颜色" ColumnID="PrescribedColor" DataField="PrescribedColor" SortField="PrescribedColor"
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="120px">
|
||||||
</f:RenderField>
|
<Editor>
|
||||||
<f:RenderField HeaderText="结果" ColumnID="Conclusion" DataField="Conclusion" SortField="Conclusion"
|
<f:TextBox ID="txtPrescribedColor" runat="server"></f:TextBox>
|
||||||
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="150px" ExpandUnusedSpace="true">
|
</Editor>
|
||||||
</f:RenderField>
|
</f:RenderField>
|
||||||
</Columns>
|
<f:RenderField HeaderText="管子标识状态" ColumnID="TubeIdentificationStatus" DataField="TubeIdentificationStatus" SortField="TubeIdentificationStatus"
|
||||||
<Listeners>
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="120px">
|
||||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu"/>
|
<Editor>
|
||||||
</Listeners>
|
<f:TextBox ID="txtTubeIdentificationStatus" runat="server"></f:TextBox>
|
||||||
<PageItems>
|
</Editor>
|
||||||
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
</f:RenderField>
|
||||||
</f:ToolbarSeparator>
|
<f:RenderField HeaderText="管件名称" ColumnID="PipeFittingName" DataField="PipeFittingName" SortField="PipeFittingName"
|
||||||
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="120px">
|
||||||
</f:ToolbarText>
|
<Editor>
|
||||||
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
|
<f:TextBox ID="txtPipeFittingName" runat="server"></f:TextBox>
|
||||||
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
|
</Editor>
|
||||||
<f:ListItem Text="10" Value="10"/>
|
</f:RenderField>
|
||||||
<f:ListItem Text="15" Value="15"/>
|
<f:RenderField HeaderText="管件标识状态" ColumnID="PipeFittingStatus" DataField="PipeFittingStatus" SortField="PipeFittingStatus"
|
||||||
<f:ListItem Text="20" Value="20"/>
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="120px">
|
||||||
<f:ListItem Text="25" Value="25"/>
|
<Editor>
|
||||||
</f:DropDownList>
|
<f:TextBox ID="txtPipeFittingStatus" runat="server"></f:TextBox>
|
||||||
</PageItems>
|
</Editor>
|
||||||
</f:Grid>
|
</f:RenderField>
|
||||||
</Items>
|
<f:RenderField HeaderText="结果" ColumnID="Conclusion" DataField="Conclusion" SortField="Conclusion"
|
||||||
</f:Panel>
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="100px">
|
||||||
</Items>
|
<Editor>
|
||||||
</f:Panel>
|
<f:TextBox ID="txtConclusion" runat="server"></f:TextBox>
|
||||||
<f:Window ID="Window1" Title="管道材料材质标识检查记录" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
</Editor>
|
||||||
Target="top" EnableResize="true" runat="server" OnClose="Window1_Close" IsModal="true"
|
</f:RenderField>
|
||||||
Width="1100px" Height="500px">
|
<f:LinkButtonField ColumnID="Delete3" Width="60px" EnablePostBack="false" Icon="Delete"
|
||||||
</f:Window>
|
HeaderTextAlign="Center" HeaderText="删除" />
|
||||||
<f:Window ID="WindowPrint" Title="打印管道材料材质标识检查记录" Hidden="true" EnableIFrame="true" EnableMaximize="false"
|
<f:RenderField HeaderText="主键" ColumnID="RecordId" DataField="RecordId" SortField="RecordId"
|
||||||
Target="Top" EnableResize="true" runat="server" IsModal="true" Width="1024px"
|
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" Width="140px" Hidden="true">
|
||||||
Height="600px">
|
</f:RenderField>
|
||||||
</f:Window>
|
</Columns>
|
||||||
<f:Menu ID="Menu1" runat="server">
|
<PageItems>
|
||||||
<f:MenuButton ID="btnMenuEdit" OnClick="btnMenuEdit_Click" EnablePostBack="true"
|
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
||||||
runat="server" Text="编辑" Icon="TableEdit">
|
</f:ToolbarSeparator>
|
||||||
</f:MenuButton>
|
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
||||||
<f:MenuButton ID="btnMenuDelete" OnClick="btnMenuDelete_Click" EnablePostBack="true"
|
</f:ToolbarText>
|
||||||
ConfirmText="删除选中行?" ConfirmTarget="Top" runat="server" Text="删除" Icon="Delete">
|
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
|
||||||
</f:MenuButton>
|
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
|
||||||
</f:Menu>
|
<f:ListItem Text="10" Value="10" />
|
||||||
</form>
|
<f:ListItem Text="15" Value="15" />
|
||||||
<script type="text/javascript">
|
<f:ListItem Text="20" Value="20" />
|
||||||
var menuID = '<%= Menu1.ClientID %>';
|
<f:ListItem Text="25" Value="25" />
|
||||||
// 返回false,来阻止浏览器右键菜单
|
</f:DropDownList>
|
||||||
function onRowContextMenu(event, rowId) {
|
</PageItems>
|
||||||
F(menuID).show(); //showAt(event.pageX, event.pageY);
|
</f:Grid>
|
||||||
return false;
|
</Items>
|
||||||
}
|
</f:Panel>
|
||||||
</script>
|
</Items>
|
||||||
|
</f:Panel>
|
||||||
|
<f:Window ID="WindowPrint" Title="打印管道材料材质标识检查记录" Hidden="true" EnableIFrame="true" EnableMaximize="false"
|
||||||
|
Target="Top" EnableResize="true" runat="server" IsModal="true" Width="1024px"
|
||||||
|
Height="600px">
|
||||||
|
</f:Window>
|
||||||
|
</form>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,44 @@
|
||||||
using BLL;
|
using BLL;
|
||||||
|
using FastReport.DevComponents.DotNetBar;
|
||||||
|
using Newtonsoft.Json.Linq;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Data.SqlClient;
|
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Linq;
|
using System.Data.SqlClient;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
|
|
||||||
namespace FineUIPro.Web.JGZL
|
namespace FineUIPro.Web.JGZL
|
||||||
{
|
{
|
||||||
public partial class MaterialIdentificationInspectionRecord : PageBase
|
public partial class MaterialIdentificationInspectionRecord : PageBase
|
||||||
{
|
{
|
||||||
|
#region 定义项
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 主键
|
||||||
|
/// </summary>
|
||||||
|
private string RecordId
|
||||||
|
{
|
||||||
|
get { return (string)ViewState["RecordId"]; }
|
||||||
|
set { ViewState["RecordId"] = value; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 项目Id
|
||||||
|
/// </summary>
|
||||||
|
private string ProjectId
|
||||||
|
{
|
||||||
|
get { return (string)ViewState["ProjectId"]; }
|
||||||
|
set { ViewState["ProjectId"] = value; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 定义集合
|
||||||
|
/// </summary>
|
||||||
|
private static List<Model.JGZL_MaterialIdentificationInspectionRecord> items = new List<Model.JGZL_MaterialIdentificationInspectionRecord>();
|
||||||
|
#endregion
|
||||||
|
|
||||||
#region 加载页面
|
#region 加载页面
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 加载页面
|
/// 加载页面
|
||||||
|
|
@ -28,13 +56,78 @@ namespace FineUIPro.Web.JGZL
|
||||||
this.drpProjectId.DataSource = BLL.Base_ProjectService.GetOnProjectListByUserId(this.CurrUser.UserId, "1");
|
this.drpProjectId.DataSource = BLL.Base_ProjectService.GetOnProjectListByUserId(this.CurrUser.UserId, "1");
|
||||||
this.drpProjectId.DataBind();
|
this.drpProjectId.DataBind();
|
||||||
Funs.FineUIPleaseSelect(this.drpProjectId);
|
Funs.FineUIPleaseSelect(this.drpProjectId);
|
||||||
// 默认显示选中的项目
|
this.drpProjectId.SelectedValue = this.CurrUser.LoginProjectId;
|
||||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
|
||||||
{
|
|
||||||
this.drpProjectId.SelectedValue = this.CurrUser.LoginProjectId;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.InitTreeMenu();//加载树
|
this.InitTreeMenu();//加载树
|
||||||
|
this.tvControlItem.SelectedNodeID = this.drpProjectId.SelectedValue;
|
||||||
|
this.ProjectId = this.tvControlItem.SelectedNodeID;
|
||||||
|
|
||||||
|
//管线
|
||||||
|
this.drpIsoId.DataTextField = "ISO_IsoNo";
|
||||||
|
this.drpIsoId.DataValueField = "ISO_IsoNo";
|
||||||
|
this.drpIsoId.DataSource = BLL.HJGL_PW_IsoInfoService.GetIsoInfoByProjectId(this.ProjectId);
|
||||||
|
this.drpIsoId.DataBind();
|
||||||
|
|
||||||
|
PageInfo();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void PageInfo()
|
||||||
|
{
|
||||||
|
items.Clear();
|
||||||
|
if (!string.IsNullOrEmpty(this.ProjectId))
|
||||||
|
{
|
||||||
|
var reportLists = BLL.MaterialIdentificationInspectionRecordService.GetListsByProjectId(this.ProjectId);
|
||||||
|
if (reportLists.Count > 0)
|
||||||
|
{
|
||||||
|
var isoLists = BLL.HJGL_PW_IsoInfoService.GetIsoInfoByProjectId(this.ProjectId);
|
||||||
|
foreach (var item in isoLists)
|
||||||
|
{
|
||||||
|
var iso = (from x in Funs.DB.JGZL_MaterialIdentificationInspectionRecord where x.ProjectId == this.ProjectId && x.ISO_Id == item.ISO_IsoNo select x).FirstOrDefault();
|
||||||
|
if (iso == null)
|
||||||
|
{
|
||||||
|
Model.JGZL_MaterialIdentificationInspectionRecord newReport = new Model.JGZL_MaterialIdentificationInspectionRecord();
|
||||||
|
newReport.RecordId = SQLHelper.GetNewID();
|
||||||
|
newReport.ProjectId = this.ProjectId;
|
||||||
|
newReport.ISO_Id = item.ISO_IsoNo;
|
||||||
|
if (!string.IsNullOrEmpty(item.STE_ID))
|
||||||
|
{
|
||||||
|
newReport.STE_ID = BLL.HJGL_MaterialService.GetSteelBySteID(item.STE_ID).STE_Code;
|
||||||
|
}
|
||||||
|
newReport.Specifications = item.Specification;
|
||||||
|
reportLists.Add(newReport);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!string.IsNullOrEmpty(this.drpIsoId.SelectedValue) && this.drpIsoId.SelectedValue != BLL.Const._Null)
|
||||||
|
{
|
||||||
|
reportLists = reportLists.Where(x => x.ISO_Id.Contains(this.drpIsoId.SelectedValue)).ToList();
|
||||||
|
}
|
||||||
|
this.Grid1.DataSource = reportLists;
|
||||||
|
this.Grid1.DataBind();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var isoLists = BLL.HJGL_PW_IsoInfoService.GetIsoInfoByProjectId(this.ProjectId);
|
||||||
|
foreach (var iso in isoLists)
|
||||||
|
{
|
||||||
|
Model.JGZL_MaterialIdentificationInspectionRecord newReport = new Model.JGZL_MaterialIdentificationInspectionRecord();
|
||||||
|
newReport.RecordId = SQLHelper.GetNewID();
|
||||||
|
newReport.ProjectId = this.ProjectId;
|
||||||
|
newReport.ISO_Id = iso.ISO_IsoNo;
|
||||||
|
if (!string.IsNullOrEmpty(iso.STE_ID))
|
||||||
|
{
|
||||||
|
newReport.STE_ID = BLL.HJGL_MaterialService.GetSteelBySteID(iso.STE_ID).STE_Code;
|
||||||
|
}
|
||||||
|
newReport.Specifications = iso.Specification;
|
||||||
|
items.Add(newReport);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(this.drpIsoId.SelectedValue) && this.drpIsoId.SelectedValue != BLL.Const._Null)
|
||||||
|
{
|
||||||
|
items = items.Where(x => x.ISO_Id.Contains(this.drpIsoId.SelectedValue)).ToList();
|
||||||
|
}
|
||||||
|
this.Grid1.DataSource = items;
|
||||||
|
this.Grid1.DataBind();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
@ -101,6 +194,7 @@ namespace FineUIPro.Web.JGZL
|
||||||
{
|
{
|
||||||
if (this.tvControlItem.SelectedNodeID != "0")
|
if (this.tvControlItem.SelectedNodeID != "0")
|
||||||
{
|
{
|
||||||
|
this.ProjectId = this.tvControlItem.SelectedNodeID;
|
||||||
this.BindGrid();
|
this.BindGrid();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -112,17 +206,10 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void BindGrid()
|
private void BindGrid()
|
||||||
{
|
{
|
||||||
string strSql = @"SELECT a.*,b.ISO_IsoNo,c.STE_Code from JGZL_MaterialIdentificationInspectionRecord a
|
string strSql = @"SELECT * FROM JGZL_MaterialIdentificationInspectionRecord where ProjectId=@projectId";
|
||||||
left join HJGL_PW_IsoInfo b on a.ISO_Id = b.ISO_Id
|
|
||||||
left join HJGL_BS_Steel c on a.STE_ID = c.STE_ID
|
|
||||||
where 1=1 ";
|
|
||||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
|
listStr.Add(new SqlParameter("@projectId", this.ProjectId));
|
||||||
{
|
|
||||||
strSql += " AND a.ProjectId = @ProjectId";
|
|
||||||
listStr.Add(new SqlParameter("@ProjectId", this.tvControlItem.SelectedNodeID));
|
|
||||||
}
|
|
||||||
|
|
||||||
SqlParameter[] parameter = listStr.ToArray();
|
SqlParameter[] parameter = listStr.ToArray();
|
||||||
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
||||||
Grid1.RecordCount = tb.Rows.Count;
|
Grid1.RecordCount = tb.Rows.Count;
|
||||||
|
|
@ -179,8 +266,9 @@ namespace FineUIPro.Web.JGZL
|
||||||
///<param name="e"></param>
|
///<param name="e"></param>
|
||||||
protected void drpProjectId_SelectedIndexChanged(object sender, EventArgs e)
|
protected void drpProjectId_SelectedIndexChanged(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
this.tvControlItem.SelectedNodeID = this.drpProjectId.SelectedValue;
|
this.ProjectId = this.drpProjectId.SelectedValue;
|
||||||
this.InitTreeMenu();
|
this.InitTreeMenu();
|
||||||
|
this.tvControlItem.SelectedNodeID = this.ProjectId;
|
||||||
BindGrid();
|
BindGrid();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -203,17 +291,15 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// <param name="e"></param>
|
/// <param name="e"></param>
|
||||||
protected void btnPrint_Click(object sender, EventArgs e)
|
protected void btnPrint_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
string projectId = this.tvControlItem.SelectedNodeID;
|
if (!string.IsNullOrEmpty(this.ProjectId))
|
||||||
|
|
||||||
if (projectId != null)
|
|
||||||
{
|
{
|
||||||
string initTemplatePath = "";
|
string initTemplatePath = "";
|
||||||
string rootPath = Server.MapPath("~/");
|
string rootPath = Server.MapPath("~/");
|
||||||
BLL.Common.FastReportService.ResetData();
|
BLL.Common.FastReportService.ResetData();
|
||||||
|
|
||||||
string strSql = @"SELECT * from JGZL_MaterialIdentificationInspectionRecord where ProjectId = @projectId order by CompileDate ";
|
string strSql = @"SELECT * from JGZL_MaterialIdentificationInspectionRecord where ProjectId = @projectId order by CompileDate ";
|
||||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||||
listStr.Add(new SqlParameter("@projectId", projectId));
|
listStr.Add(new SqlParameter("@projectId", this.ProjectId));
|
||||||
SqlParameter[] parameter = listStr.ToArray();
|
SqlParameter[] parameter = listStr.ToArray();
|
||||||
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
||||||
|
|
||||||
|
|
@ -232,8 +318,8 @@ namespace FineUIPro.Web.JGZL
|
||||||
foreach (var row in rows)
|
foreach (var row in rows)
|
||||||
{
|
{
|
||||||
var newRow = dt.NewRow();
|
var newRow = dt.NewRow();
|
||||||
newRow["ISO_IsoNo"] = BLL.HJGL_PW_IsoInfoService.GetIsoInfoByIsoInfoId(row["ISO_Id"].ToString()).ISO_IsoNo;
|
newRow["ISO_IsoNo"] = row["ISO_Id"].ToString();
|
||||||
newRow["STE_Code"] = BLL.HJGL_MaterialService.GetSteelBySteID(row["STE_ID"].ToString()).STE_Code;
|
newRow["STE_Code"] = row["STE_ID"].ToString();
|
||||||
newRow["Specifications"] = row["Specifications"].ToString();
|
newRow["Specifications"] = row["Specifications"].ToString();
|
||||||
newRow["PrescribedColor"] = row["PrescribedColor"].ToString();
|
newRow["PrescribedColor"] = row["PrescribedColor"].ToString();
|
||||||
newRow["TubeIdentificationStatus"] = row["TubeIdentificationStatus"].ToString();
|
newRow["TubeIdentificationStatus"] = row["TubeIdentificationStatus"].ToString();
|
||||||
|
|
@ -246,14 +332,14 @@ namespace FineUIPro.Web.JGZL
|
||||||
|
|
||||||
|
|
||||||
Dictionary<string, string> keyValuePairs = new Dictionary<string, string>();
|
Dictionary<string, string> keyValuePairs = new Dictionary<string, string>();
|
||||||
keyValuePairs.Add("ProjectName", BLL.Base_ProjectService.GetProjectByProjectId(projectId).ProjectName);
|
keyValuePairs.Add("ProjectName", BLL.Base_ProjectService.GetProjectByProjectId(this.ProjectId).ProjectName);
|
||||||
BLL.Common.FastReportService.AddFastreportParameter(keyValuePairs);
|
BLL.Common.FastReportService.AddFastreportParameter(keyValuePairs);
|
||||||
|
|
||||||
initTemplatePath = "File\\Fastreport\\JGZL\\管道材料材质标识检查记录.frx";
|
initTemplatePath = "File\\Fastreport\\JGZL\\管道材料材质标识检查记录.frx";
|
||||||
if (File.Exists(rootPath + initTemplatePath))
|
if (File.Exists(rootPath + initTemplatePath))
|
||||||
{
|
{
|
||||||
PageContext.RegisterStartupScript(WindowPrint.GetShowReference(String.Format("../common/ReportPrint/Fastreport.aspx?ReportPath={0}", rootPath + initTemplatePath)));
|
PageContext.RegisterStartupScript(WindowPrint.GetShowReference(String.Format("../common/ReportPrint/Fastreport.aspx?ReportPath={0}", rootPath + initTemplatePath)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
@ -273,7 +359,34 @@ namespace FineUIPro.Web.JGZL
|
||||||
{
|
{
|
||||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
|
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
|
||||||
{
|
{
|
||||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("MaterialIdentificationInspectionRecordEdit.aspx?projectId={0}", this.tvControlItem.SelectedNodeID, "新增 - ")));
|
JArray teamGroupData = Grid1.GetMergedData();
|
||||||
|
List<JObject> list = new List<JObject>();
|
||||||
|
foreach (JObject teamGroupRow in teamGroupData)
|
||||||
|
{
|
||||||
|
JObject values = teamGroupRow.Value<JObject>("values");
|
||||||
|
list.Add(values);
|
||||||
|
}
|
||||||
|
|
||||||
|
JObject defaultObj = new JObject
|
||||||
|
{
|
||||||
|
{ "RecordId", Guid.NewGuid() },
|
||||||
|
{ "ISO_IsoNo", "" },
|
||||||
|
{ "STE_Code", "" },
|
||||||
|
{ "Specifications", "" },
|
||||||
|
{ "PrescribedColor", "" },
|
||||||
|
{ "TubeIdentificationStatus", "" },
|
||||||
|
{ "PipeFittingName", "" },
|
||||||
|
{ "PipeFittingStatus", "" },
|
||||||
|
{ "Conclusion", "" },
|
||||||
|
{
|
||||||
|
"Delete3",
|
||||||
|
String.Format("<a href=\"javascript:;\" onclick=\"{0}\"><img src=\"{1}\"/></a>",
|
||||||
|
GetDeleteScriptGrid1(), IconHelper.GetResolvedIconUrl(Icon.Delete))
|
||||||
|
}
|
||||||
|
};
|
||||||
|
list.Add(defaultObj);
|
||||||
|
Grid1.DataSource = list;
|
||||||
|
Grid1.DataBind();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
@ -281,141 +394,85 @@ namespace FineUIPro.Web.JGZL
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
protected void Grid1_PreDataBound(object sender, EventArgs e)
|
||||||
/// <summary>
|
|
||||||
/// 双击编辑
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="sender"></param>
|
|
||||||
/// <param name="e"></param>
|
|
||||||
protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e)
|
|
||||||
{
|
{
|
||||||
if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.JGZL_MaterialIdentificationInspectionRecordMenuId, BLL.Const.BtnModify))
|
// 设置LinkButtonField的点击客户端事件
|
||||||
{
|
LinkButtonField deleteField = Grid1.FindColumn("Delete3") as LinkButtonField;
|
||||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
|
deleteField.OnClientClick = GetDeleteScriptGrid1();
|
||||||
{
|
|
||||||
if (!string.IsNullOrEmpty(this.Grid1.SelectedRowID))
|
|
||||||
{
|
|
||||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("MaterialIdentificationInspectionRecordEdit.aspx?recordId={0}", this.Grid1.SelectedRowID, "编辑 - ")));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Alert.ShowInTop("请选择一条记录!", MessageBoxIcon.Warning);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Alert.ShowInTop("请选择项目!", MessageBoxIcon.Warning);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
ShowNotify("您没有这个权限,请与管理员联系!", MessageBoxIcon.Warning);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 右键编辑
|
/// 删除提示
|
||||||
/// </summary>
|
|
||||||
/// <param name="sender"></param>
|
|
||||||
/// <param name="e"></param>
|
|
||||||
protected void btnMenuEdit_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.JGZL_MaterialIdentificationInspectionRecordMenuId, BLL.Const.BtnModify))
|
|
||||||
{
|
|
||||||
if (Grid1.SelectedRowIndexArray.Length == 0)
|
|
||||||
{
|
|
||||||
Alert.ShowInTop("请选择一条记录!", MessageBoxIcon.Warning);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("MaterialIdentificationInspectionRecordEdit.aspx?recordId={0}", Grid1.SelectedRowID, "维护 - ")));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Alert.ShowInTop("您没有这个权限,请与管理员联系!", MessageBoxIcon.Warning);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// 右键删除
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="sender"></param>
|
|
||||||
/// <param name="e"></param>
|
|
||||||
protected void btnMenuDelete_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.JGZL_MaterialIdentificationInspectionRecordMenuId, Const.BtnDelete))
|
|
||||||
{
|
|
||||||
if (Grid1.SelectedRowIndexArray.Length == 0)
|
|
||||||
{
|
|
||||||
Alert.ShowInTop("请选择一条记录!", MessageBoxIcon.Warning);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool isShow = true;
|
|
||||||
if (Grid1.SelectedRowIndexArray.Length > 1)
|
|
||||||
{
|
|
||||||
isShow = false;
|
|
||||||
}
|
|
||||||
bool isDelete = false;
|
|
||||||
foreach (int rowIndex in Grid1.SelectedRowIndexArray)
|
|
||||||
{
|
|
||||||
string rowID = Grid1.DataKeys[rowIndex][0].ToString();
|
|
||||||
if (judgementDelete(rowID, isShow))
|
|
||||||
{
|
|
||||||
isDelete = true;
|
|
||||||
BLL.MaterialIdentificationInspectionRecordService.DeleteRecordById(rowID);
|
|
||||||
BLL.Sys_LogService.AddLog(BLL.Const.System_3, this.CurrUser.LoginProjectId, this.CurrUser.UserId, "删除管道材料材质标识检查记录");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (isDelete)
|
|
||||||
{
|
|
||||||
ShowNotify("删除成功!", MessageBoxIcon.Success);
|
|
||||||
}
|
|
||||||
this.BindGrid();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Alert.ShowInTop("您没有这个权限,请与管理员联系!", MessageBoxIcon.Warning);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
#region 判断是否可删除
|
|
||||||
/// <summary>
|
|
||||||
/// 判断是否可以删除
|
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
private bool judgementDelete(string id, bool isShow)
|
private string GetDeleteScriptGrid1()
|
||||||
{
|
{
|
||||||
string content = string.Empty;
|
return Confirm.GetShowReference("删除选中行?", String.Empty, MessageBoxIcon.Question,
|
||||||
|
Grid1.GetDeleteSelectedRowsReference(), String.Empty);
|
||||||
if (string.IsNullOrEmpty(content))
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (isShow)
|
|
||||||
{
|
|
||||||
Alert.ShowInTop(content, MessageBoxIcon.Error);
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
#endregion
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region 关闭弹出窗口及刷新页面
|
#region 提交按钮
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 关闭弹出窗口
|
/// 提交按钮
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="sender"></param>
|
/// <param name="sender"></param>
|
||||||
/// <param name="e"></param>
|
/// <param name="e"></param>
|
||||||
protected void Window1_Close(object sender, WindowCloseEventArgs e)
|
protected void btnSave_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
this.InitTreeMenu();//加载树
|
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.JGZL_MaterialIdentificationInspectionRecordMenuId, Const.BtnSave))
|
||||||
this.BindGrid();
|
{
|
||||||
|
items.Clear();
|
||||||
|
BLL.MaterialIdentificationInspectionRecordService.DeleteListsByProjectId(this.ProjectId);
|
||||||
|
JArray teamGroupData = Grid1.GetMergedData();
|
||||||
|
foreach (JObject teamGroupRow in teamGroupData)
|
||||||
|
{
|
||||||
|
JObject values = teamGroupRow.Value<JObject>("values");
|
||||||
|
int rowIndex = teamGroupRow.Value<int>("index");
|
||||||
|
Model.JGZL_MaterialIdentificationInspectionRecord newDetail = new Model.JGZL_MaterialIdentificationInspectionRecord
|
||||||
|
{
|
||||||
|
RecordId = values.Value<string>("RecordId"),
|
||||||
|
ProjectId = this.ProjectId,
|
||||||
|
ISO_Id = values.Value<string>("ISO_Id"),
|
||||||
|
STE_ID = values.Value<string>("STE_ID"),
|
||||||
|
Specifications = values.Value<string>("Specifications"),
|
||||||
|
PrescribedColor = values.Value<string>("PrescribedColor"),
|
||||||
|
TubeIdentificationStatus = values.Value<string>("TubeIdentificationStatus"),
|
||||||
|
PipeFittingName = values.Value<string>("PipeFittingName"),
|
||||||
|
PipeFittingStatus = values.Value<string>("PipeFittingStatus"),
|
||||||
|
Conclusion = values.Value<string>("Conclusion"),
|
||||||
|
CompileMan = this.CurrUser.UserId,
|
||||||
|
CompileDate = DateTime.Now
|
||||||
|
};
|
||||||
|
items.Add(newDetail);
|
||||||
|
}
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (items.Count > 0)
|
||||||
|
{
|
||||||
|
Funs.DB.JGZL_MaterialIdentificationInspectionRecord.InsertAllOnSubmit(items);
|
||||||
|
}
|
||||||
|
Funs.DB.SubmitChanges();
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
ShowNotify("保存成功!", MessageBoxIcon.Success);
|
||||||
|
//PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Alert.ShowInTop("您没有这个权限,请与管理员联系!", MessageBoxIcon.Warning);
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
protected void drpIsoId_SelectedIndexChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
PageInfo();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -95,6 +95,15 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected global::FineUIPro.Toolbar Toolbar2;
|
protected global::FineUIPro.Toolbar Toolbar2;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// drpIsoId 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.DropDownList drpIsoId;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// ToolbarFill1 控件。
|
/// ToolbarFill1 控件。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -113,6 +122,15 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected global::FineUIPro.Button btnAdd;
|
protected global::FineUIPro.Button btnAdd;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// btnSave 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.Button btnSave;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// btnPrint 控件。
|
/// btnPrint 控件。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -131,6 +149,78 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected global::FineUIPro.Grid Grid1;
|
protected global::FineUIPro.Grid Grid1;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtISO_Id 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtISO_Id;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtSTE_Code 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtSTE_Code;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtSpecifications 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtSpecifications;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtPrescribedColor 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtPrescribedColor;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtTubeIdentificationStatus 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtTubeIdentificationStatus;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtPipeFittingName 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtPipeFittingName;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtPipeFittingStatus 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtPipeFittingStatus;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// txtConclusion 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox txtConclusion;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// ToolbarSeparator1 控件。
|
/// ToolbarSeparator1 控件。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -158,15 +248,6 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected global::FineUIPro.DropDownList ddlPageSize;
|
protected global::FineUIPro.DropDownList ddlPageSize;
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Window1 控件。
|
|
||||||
/// </summary>
|
|
||||||
/// <remarks>
|
|
||||||
/// 自动生成的字段。
|
|
||||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|
||||||
/// </remarks>
|
|
||||||
protected global::FineUIPro.Window Window1;
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// WindowPrint 控件。
|
/// WindowPrint 控件。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -175,32 +256,5 @@ namespace FineUIPro.Web.JGZL
|
||||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected global::FineUIPro.Window WindowPrint;
|
protected global::FineUIPro.Window WindowPrint;
|
||||||
|
|
||||||
/// <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;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -278,8 +278,10 @@ namespace FineUIPro.Web.JGZL
|
||||||
newMainData["ShrinkageHole"] = report.ShrinkageHole;
|
newMainData["ShrinkageHole"] = report.ShrinkageHole;
|
||||||
newMainData["HeavyLeather"] = report.HeavyLeather;
|
newMainData["HeavyLeather"] = report.HeavyLeather;
|
||||||
newMainData["Other"] = report.Other;
|
newMainData["Other"] = report.Other;
|
||||||
newMainData["ImageUrl"] = Funs.RootPath + report.Remark.Substring(report.Remark.IndexOf('/'));
|
if (!string.IsNullOrEmpty(report.Remark))
|
||||||
|
{
|
||||||
|
newMainData["ImageUrl"] = Funs.RootPath + report.Remark.Substring(report.Remark.IndexOf('/'));
|
||||||
|
}
|
||||||
dtMainData.Rows.Add(newMainData);
|
dtMainData.Rows.Add(newMainData);
|
||||||
|
|
||||||
BLL.Common.FastReportService.AddFastreportTable(dtMainData);
|
BLL.Common.FastReportService.AddFastreportTable(dtMainData);
|
||||||
|
|
@ -567,11 +569,14 @@ namespace FineUIPro.Web.JGZL
|
||||||
var r = BLL.SteelPipeCheckRecordService.GetSteelPipeReportById(this.RecordId);
|
var r = BLL.SteelPipeCheckRecordService.GetSteelPipeReportById(this.RecordId);
|
||||||
if (r != null)
|
if (r != null)
|
||||||
{
|
{
|
||||||
string url = r.Remark.Substring(r.Remark.IndexOf('/'));
|
if (!string.IsNullOrEmpty(r.Remark))
|
||||||
if (File.Exists(Funs.RootPath + url))
|
|
||||||
{
|
{
|
||||||
//删除被覆盖的图片
|
string url = r.Remark.Substring(r.Remark.IndexOf('/'));
|
||||||
File.Delete(Funs.RootPath + url);
|
if (File.Exists(Funs.RootPath + url))
|
||||||
|
{
|
||||||
|
//删除被覆盖的图片
|
||||||
|
File.Delete(Funs.RootPath + url);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
newReport.RecordId = this.RecordId;
|
newReport.RecordId = this.RecordId;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue