20250609 排产计划
This commit is contained in:
@@ -0,0 +1,183 @@
|
||||
|
||||
ALTER TABLE [dbo].[HJGL_ProductionSchedulingPlan] DROP CONSTRAINT [FK_HJGL_ProductionSchedulingPlan_HJGL_Pipeline]
|
||||
GO
|
||||
|
||||
ALTER TABLE [dbo].[HJGL_ProductionSchedulingPlan] WITH CHECK ADD CONSTRAINT [FK_HJGL_ProductionSchedulingPlan_WBS_UnitWork] FOREIGN KEY([PipelineId])
|
||||
REFERENCES [dbo].[WBS_UnitWork] ([UnitWorkId])
|
||||
GO
|
||||
|
||||
ALTER TABLE [dbo].[HJGL_ProductionSchedulingPlan] CHECK CONSTRAINT [FK_HJGL_ProductionSchedulingPlan_WBS_UnitWork]
|
||||
GO
|
||||
|
||||
alter table HJGL_ProductionSchedulingPlan add CompletedCount int
|
||||
alter table HJGL_ProductionSchedulingPlan add CompletedRate decimal(18,2)
|
||||
alter table HJGL_ProductionSchedulingPlan add TotalCompletedRate decimal(18,2)
|
||||
go
|
||||
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'已完成量' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'HJGL_ProductionSchedulingPlan', @level2type=N'COLUMN',@level2name=N'CompletedCount'
|
||||
GO
|
||||
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'已完成百分比' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'HJGL_ProductionSchedulingPlan', @level2type=N'COLUMN',@level2name=N'CompletedRate'
|
||||
GO
|
||||
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'已完成百分比汇总' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'HJGL_ProductionSchedulingPlan', @level2type=N'COLUMN',@level2name=N'TotalCompletedRate'
|
||||
GO
|
||||
|
||||
drop view View_HJGL_ProductionSchedulingPlanStatistics
|
||||
go
|
||||
|
||||
|
||||
CREATE PROCEDURE [dbo].[Sp_ProductionSchedulingPlanStatistics]
|
||||
@projectId nvarchar(50)=null,
|
||||
@unitWorkId nvarchar(50)=null,
|
||||
@flowingSection nvarchar(50)=null,
|
||||
@caliber nvarchar(50)=null
|
||||
AS
|
||||
/************排产计划统计**********/
|
||||
SELECT distinct unitWork.UnitWorkId,
|
||||
unitWork.UnitWorkCode,
|
||||
unitWork.UnitWorkName,
|
||||
unitWork.ProjectId,
|
||||
pipeline.FlowingSection,
|
||||
(case p.SteelType when '1' then '碳钢' when '2' then '不锈钢' when '3' then '铬钼钢' when '4' then '低合金钢' when '5' then '镍合金钢' when '6' then '钛合金钢' when '7' then '其他' end) as Material,
|
||||
'<'+ @caliber as Caliber,
|
||||
isnull(weldJoint.Dia,0) as Dia,
|
||||
isnull(maxDia.maxTotalDia+weldJoint.Dia,0) as totalDia,
|
||||
isnull(cTotal.cTotalCount,0) as cTotalCount,
|
||||
(case when isnull(total.totalCount,0)>0 then
|
||||
isnull(cTotal.cTotalCount,0) / isnull(cast(total.totalCount as decimal(18,2)),0)*100.0 else 0 end) as rate,
|
||||
(case when isnull(ScTotal.ScTotalCount,0)>0 then
|
||||
isnull(Stotal.StotalCount,0)/isnull(cast(ScTotal.ScTotalCount as decimal(18,2)),0)*100.0 else 0 end)as Srate
|
||||
FROM WBS_UnitWork AS unitWork
|
||||
LEFT JOIN (select FlowingSection,UnitWorkId from HJGL_Pipeline where PipeArea='1') as pipeline on pipeline.UnitWorkId = unitWork.UnitWorkId
|
||||
--材质
|
||||
LEFT JOIN (select distinct Base_Material.SteelType,UnitWorkId from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口') as p on p.UnitWorkId = unitWork.UnitWorkId
|
||||
--达因
|
||||
LEFT JOIN (select sum(Dia) as Dia,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)<@caliber
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as weldJoint on weldJoint.UnitWorkId =unitWork.UnitWorkId
|
||||
and weldJoint.FlowingSection = pipeline.FlowingSection
|
||||
--大于口径的达因
|
||||
LEFT JOIN (select sum(Dia) as maxTotalDia,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)>=@caliber
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as maxDia on maxDia.UnitWorkId =unitWork.UnitWorkId
|
||||
and maxDia.FlowingSection = pipeline.FlowingSection
|
||||
--总焊口数
|
||||
LEFT JOIN (select count(*) as totalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)<@caliber
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as total on total.UnitWorkId =unitWork.UnitWorkId
|
||||
and total.FlowingSection = pipeline.FlowingSection
|
||||
--完成焊口数
|
||||
LEFT JOIN (select count(*) as cTotalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)<@caliber
|
||||
and HJGL_WeldJoint.WeldingDailyId is not null
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as cTotal on cTotal.UnitWorkId =unitWork.UnitWorkId
|
||||
and cTotal.FlowingSection = pipeline.FlowingSection
|
||||
--汇总总焊口
|
||||
LEFT JOIN (select count(*) as StotalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection) as Stotal on Stotal.UnitWorkId =unitWork.UnitWorkId
|
||||
and total.FlowingSection = pipeline.FlowingSection
|
||||
--完成焊口数
|
||||
LEFT JOIN (select count(*) as ScTotalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and HJGL_WeldJoint.WeldingDailyId is not null
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection) as ScTotal on ScTotal.UnitWorkId =unitWork.UnitWorkId
|
||||
and cTotal.FlowingSection = pipeline.FlowingSection
|
||||
where (unitWork.ProjectId=@projectId or @projectId is null)
|
||||
and (unitWork.UnitWorkId=@unitWorkId or @unitWorkId is null)
|
||||
and (pipeline.FlowingSection=@flowingSection or @flowingSection is null)
|
||||
union
|
||||
|
||||
SELECT distinct unitWork.UnitWorkId,
|
||||
unitWork.UnitWorkCode,
|
||||
unitWork.UnitWorkName,
|
||||
unitWork.ProjectId,
|
||||
pipeline.FlowingSection,
|
||||
(case p.SteelType when '1' then '碳钢' when '2' then '不锈钢' when '3' then '铬钼钢' when '4' then '低合金钢' when '5' then '镍合金钢' when '6' then '钛合金钢' when '7' then '其他' end) as Material,
|
||||
'≥'+@caliber as Caliber,
|
||||
isnull(weldJoint.Dia,0) as Dia,
|
||||
isnull(weldJoint.Dia+minDia.minTotalDia,0) as TotalDia,
|
||||
isnull(cTotal.cTotalCount,0) as cTotalCount,
|
||||
(case when isnull(total.totalCount,0)>0 then
|
||||
isnull(cTotal.cTotalCount,0) / isnull(cast(total.totalCount as decimal(18,2)),0)*100.0 else 0 end) as rate,
|
||||
(case when isnull(ScTotal.ScTotalCount,0)>0 then
|
||||
isnull(Stotal.StotalCount,0)/isnull(cast(ScTotal.ScTotalCount as decimal(18,2)),0)*100.0 else 0 end)as Srate
|
||||
FROM WBS_UnitWork AS unitWork
|
||||
LEFT JOIN (select FlowingSection,UnitWorkId from HJGL_Pipeline where PipeArea='1') as pipeline on pipeline.UnitWorkId = unitWork.UnitWorkId
|
||||
|
||||
LEFT JOIN (select distinct Base_Material.SteelType,UnitWorkId from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口') as p on p.UnitWorkId = unitWork.UnitWorkId
|
||||
|
||||
LEFT JOIN (select sum(Dia) as Dia,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)>=@caliber
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as weldJoint on weldJoint.UnitWorkId =unitWork.UnitWorkId
|
||||
and weldJoint.FlowingSection = pipeline.FlowingSection
|
||||
--小于口径的达因
|
||||
LEFT JOIN (select sum(Dia) as minTotalDia,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)<@caliber
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as minDia on minDia.UnitWorkId =unitWork.UnitWorkId
|
||||
and minDia.FlowingSection = pipeline.FlowingSection
|
||||
|
||||
--总焊口数
|
||||
LEFT JOIN (select count(*) as totalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)>=@caliber
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as total on total.UnitWorkId =unitWork.UnitWorkId
|
||||
and total.FlowingSection = pipeline.FlowingSection
|
||||
--完成焊口数
|
||||
LEFT JOIN (select count(*) as cTotalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
left join Base_Material on Base_Material.MaterialId = HJGL_WeldJoint.Material1Id
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and cast(SUBSTRING(HJGL_WeldJoint.DNDia,CHARINDEX('N',HJGL_WeldJoint.DNDia)+1,len(HJGL_WeldJoint.DNDia)-charindex('N',HJGL_WeldJoint.DNDia)) as int)>=@caliber
|
||||
and HJGL_WeldJoint.WeldingDailyId is not null
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection,Base_Material.SteelType,HJGL_WeldJoint.DNDia) as cTotal on cTotal.UnitWorkId =unitWork.UnitWorkId
|
||||
and cTotal.FlowingSection = pipeline.FlowingSection
|
||||
|
||||
--汇总总焊口
|
||||
LEFT JOIN (select count(*) as StotalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection) as Stotal on Stotal.UnitWorkId =unitWork.UnitWorkId
|
||||
and total.FlowingSection = pipeline.FlowingSection
|
||||
--完成焊口数
|
||||
LEFT JOIN (select count(*) as ScTotalCount,HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection from HJGL_WeldJoint
|
||||
left join HJGL_Pipeline on HJGL_Pipeline.PipelineId = HJGL_WeldJoint.PipelineId
|
||||
where HJGL_Pipeline.PipeArea='1' and HJGL_WeldJoint.JointAttribute='预制口'
|
||||
and HJGL_WeldJoint.WeldingDailyId is not null
|
||||
group by HJGL_Pipeline.UnitWorkId,HJGL_Pipeline.FlowingSection) as ScTotal on ScTotal.UnitWorkId =unitWork.UnitWorkId
|
||||
and cTotal.FlowingSection = pipeline.FlowingSection
|
||||
where (unitWork.ProjectId=@projectId or @projectId is null)
|
||||
and (unitWork.UnitWorkId=@unitWorkId or @unitWorkId is null)
|
||||
and (pipeline.FlowingSection=@flowingSection or @flowingSection is null)
|
||||
GO
|
||||
|
||||
|
||||
@@ -24,16 +24,16 @@ namespace BLL
|
||||
}
|
||||
|
||||
|
||||
public static Model.HJGL_ProductionSchedulingPlan GetProductionSchedulingPlan(string loginProjectId, string flowingSection, string unitWorkName, string material, string caliber)
|
||||
public static Model.HJGL_ProductionSchedulingPlan GetProductionSchedulingPlan(string loginProjectId, string flowingSection, string unitWorkId, string material, string caliber)
|
||||
{
|
||||
return Funs.DB.HJGL_ProductionSchedulingPlan.FirstOrDefault(e => e.ProjectId == loginProjectId && e.FlowNum == flowingSection && e.MainItemName == unitWorkName && e.Caliber == caliber);
|
||||
return Funs.DB.HJGL_ProductionSchedulingPlan.FirstOrDefault(e => e.ProjectId == loginProjectId && e.FlowNum == flowingSection && e.PipelineId == unitWorkId && e.Caliber == caliber);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 增加排产计划
|
||||
/// </summary>
|
||||
/// <param name="plan"></param>
|
||||
public static void AddProductionSchedulingPlan(Model.HJGL_ProductionSchedulingPlan plan)
|
||||
/// <summary>
|
||||
/// 增加排产计划
|
||||
/// </summary>
|
||||
/// <param name="plan"></param>
|
||||
public static void AddProductionSchedulingPlan(Model.HJGL_ProductionSchedulingPlan plan)
|
||||
{
|
||||
SGGLDB db = Funs.DB;
|
||||
Model.HJGL_ProductionSchedulingPlan newPlan = new HJGL_ProductionSchedulingPlan();
|
||||
@@ -52,6 +52,9 @@ namespace BLL
|
||||
newPlan.PlanEndDate = plan.PlanEndDate;
|
||||
newPlan.Days = plan.Days;
|
||||
newPlan.AvgDailyWorkload = plan.Days;
|
||||
newPlan.CompletedCount = plan.CompletedCount;
|
||||
newPlan.CompletedRate = plan.CompletedRate;
|
||||
newPlan.TotalCompletedRate = plan.TotalCompletedRate;
|
||||
db.HJGL_ProductionSchedulingPlan.InsertOnSubmit(newPlan);
|
||||
db.SubmitChanges();
|
||||
}
|
||||
@@ -79,6 +82,9 @@ namespace BLL
|
||||
newPlan.PlanEndDate = plan.PlanEndDate;
|
||||
newPlan.Days = plan.Days;
|
||||
newPlan.AvgDailyWorkload = plan.AvgDailyWorkload;
|
||||
newPlan.CompletedCount = plan.CompletedCount;
|
||||
newPlan.CompletedRate = plan.CompletedRate;
|
||||
newPlan.TotalCompletedRate = plan.TotalCompletedRate;
|
||||
try
|
||||
{
|
||||
db.SubmitChanges(System.Data.Linq.ConflictMode.ContinueOnConflict);
|
||||
|
||||
@@ -90,6 +90,12 @@ namespace BLL
|
||||
{
|
||||
return Funs.DB.HJGL_Pipeline.FirstOrDefault(e => e.FlowingSection == flowingSection);
|
||||
}
|
||||
|
||||
public static Model.HJGL_Pipeline GetPipelineByUnitWorkId(string unitWorkId)
|
||||
{
|
||||
return Funs.DB.HJGL_Pipeline.FirstOrDefault(e => e.UnitWorkId == unitWorkId);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据管线id获取管线状态
|
||||
/// </summary>
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
using FineUIPro;
|
||||
using RestSharp;
|
||||
using Model;
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Model;
|
||||
using Newtonsoft.Json;
|
||||
using Microsoft.SqlServer.Dts.Runtime;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
|
||||
Binary file not shown.
@@ -16583,7 +16583,7 @@
|
||||
</COMReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v15.0\WebApplications\Microsoft.WebApplication.targets" />
|
||||
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v17.0\WebApplications\Microsoft.WebApplication.targets" />
|
||||
<ProjectExtensions>
|
||||
<VisualStudio>
|
||||
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
|
||||
|
||||
@@ -12,60 +12,52 @@
|
||||
<form id="form1" runat="server">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="Panel1" runat="server" />
|
||||
<f:Panel ID="Panel1" runat="server" ShowBorder="false" ShowHeader="false" Layout="Region">
|
||||
<Items>
|
||||
<items>
|
||||
<f:Panel runat="server" ID="panelLeftRegion" RegionPosition="Left" RegionSplit="true"
|
||||
EnableCollapse="true" Width="300px" Title="WBS目录"
|
||||
ShowBorder="true" Layout="VBox" ShowHeader="true" AutoScroll="true" BodyPadding="5px"
|
||||
IconFont="ArrowCircleLeft">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar1" Position="Top" runat="server" ToolbarAlign="Left">
|
||||
<Items>
|
||||
<f:TextBox ID="txtPipelineCode" runat="server" Label="管线"
|
||||
EmptyText="输入查询条件" Width="280px" LabelWidth="60px">
|
||||
</f:TextBox>
|
||||
<f:HiddenField runat="server" ID="hdUnitWorkId"></f:HiddenField>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
<toolbars>
|
||||
<f:Toolbar runat="server" ToolbarAlign="Right">
|
||||
<Items>
|
||||
<items>
|
||||
<f:NumberBox ID="txtSize" runat="server" Label="口径" Width="180px" LabelWidth="60px" LabelAlign="Right" NoDecimal="true" NoNegative="true"></f:NumberBox>
|
||||
<f:Button ID="btnStatics" runat="server" Text="统计" Icon="ChartPie" OnClick="btnStatics_Click"></f:Button>
|
||||
<f:HiddenField runat="server" ID="hdUnitWorkId"></f:HiddenField>
|
||||
<f:ToolbarFill runat="server"></f:ToolbarFill>
|
||||
<f:Button ID="btnTreeFind" ToolTip="查询" Icon="SystemSearch"
|
||||
EnablePostBack="true" OnClick="btnTreeFind_Click" runat="server">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Items>
|
||||
</toolbars>
|
||||
<items>
|
||||
<f:Tree ID="tvControlItem" ShowHeader="false" Height="560px" Title="单位工程"
|
||||
OnNodeCommand="tvControlItem_NodeCommand" runat="server" ShowBorder="false" EnableCollapse="true"
|
||||
EnableSingleClickExpand="false" AutoLeafIdentification="true" OnNodeExpand="tvControlItem_TreeNodeExpanded"
|
||||
EnableTextSelection="true">
|
||||
</f:Tree>
|
||||
</Items>
|
||||
</items>
|
||||
</f:Panel>
|
||||
<f:Panel runat="server" ID="panelCenterRegion" RegionPosition="Center" ShowBorder="true"
|
||||
Layout="VBox" ShowHeader="false" BodyPadding="5px" IconFont="PlusCircle" Title="排产计划"
|
||||
TitleToolTip="排产计划" AutoScroll="true">
|
||||
<Toolbars>
|
||||
<toolbars>
|
||||
<f:Toolbar ID="Toolbar3" Position="Top" runat="server" ToolbarAlign="Left">
|
||||
<Items>
|
||||
<items>
|
||||
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
||||
</f:ToolbarFill>
|
||||
<f:Button ID="btnSave" runat="server" OnClick="btnSave_Click" Text="保存" Icon="SystemSave"></f:Button>
|
||||
<f:Button ID="btnOut" OnClick="btnOut_Click" runat="server" Text="导出"
|
||||
Icon="TableGo" EnableAjax="false" EnablePostBack="true" >
|
||||
Icon="TableGo" EnableAjax="false" EnablePostBack="true">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Items>
|
||||
</toolbars>
|
||||
<items>
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="排产计划" ForceFit="false"
|
||||
EnableCollapse="true" runat="server" BoxFlex="1" DataKeyNames="ProductionSchedulingPlanId" AllowCellEditing="true"
|
||||
AllowColumnLocking="true" EnableColumnLines="true" ClicksToEdit="1" DataIDField="ProductionSchedulingPlanId"
|
||||
AllowSorting="true" SortField="FlowNum" SortDirection="ASC" OnSort="Grid1_Sort"
|
||||
AllowPaging="true" IsDatabasePaging="true" PageSize="15" OnPageIndexChange="Grid1_PageIndexChange"
|
||||
EnableTextSelection="True">
|
||||
<Columns>
|
||||
<columns>
|
||||
<f:RowNumberField EnablePagingNumber="true" HeaderText="序号"
|
||||
Width="60px" HeaderTextAlign="Center" TextAlign="Center" />
|
||||
<f:RenderField HeaderText="流水段号" ColumnID="FlowNum"
|
||||
@@ -95,50 +87,65 @@
|
||||
<f:RenderField HeaderText="总优先级" ColumnID="TotalPriority"
|
||||
DataField="TotalPriority" SortField="TotalPriority" FieldType="String" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="100px">
|
||||
<Editor>
|
||||
<editor>
|
||||
<f:TextBox ID="txtTotalPriority" runat="server"></f:TextBox>
|
||||
</Editor>
|
||||
</editor>
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="优先级总达因" ColumnID="PriorityTotalDyne"
|
||||
DataField="PriorityTotalDyne" SortField="PriorityTotalDyne" FieldType="Float" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
<Editor>
|
||||
<editor>
|
||||
<f:NumberBox ID="txtPriorityTotalDyne" runat="server"></f:NumberBox>
|
||||
</Editor>
|
||||
</editor>
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="计划开始时间" ColumnID="PlanStartDate"
|
||||
DataField="PlanStartDate" SortField="PlanStartDate" FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
<Editor>
|
||||
<editor>
|
||||
<f:DatePicker ID="txtPlanStartDate" runat="server"></f:DatePicker>
|
||||
</Editor>
|
||||
</editor>
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="计划结束时间" ColumnID="PlanEndDate"
|
||||
DataField="PlanEndDate" SortField="PlanEndDate" FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
<Editor>
|
||||
<editor>
|
||||
<f:DatePicker ID="txtPlanEndDate" runat="server"></f:DatePicker>
|
||||
</Editor>
|
||||
</editor>
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="天数" ColumnID="Days"
|
||||
DataField="Days" SortField="Days" FieldType="Int" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="90px">
|
||||
<Editor>
|
||||
<editor>
|
||||
<f:NumberBox ID="txtDays" runat="server" NoDecimal="true" NoNegative="true"></f:NumberBox>
|
||||
</Editor>
|
||||
</editor>
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="平均每天工作量" ColumnID="AvgDailyWorkload"
|
||||
DataField="AvgDailyWorkload" SortField="AvgDailyWorkload" FieldType="Float" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
<Editor>
|
||||
<editor>
|
||||
<f:NumberBox ID="txtAvgDailyWorkload" runat="server" NoNegative="true"></f:NumberBox>
|
||||
</Editor>
|
||||
</editor>
|
||||
</f:RenderField>
|
||||
</Columns>
|
||||
<Listeners>
|
||||
<f:RenderField HeaderText="已完成量" ColumnID="CompletedCount"
|
||||
DataField="CompletedCount" SortField="CompletedCount" FieldType="String" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="已完成百分比" ColumnID="CompletedRate"
|
||||
DataField="CompletedRate" SortField="CompletedRate" FieldType="String" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
</f:RenderField>
|
||||
<f:RenderField HeaderText="已完成百分比汇总" ColumnID="TotalCompletedRate"
|
||||
DataField="TotalCompletedRate" SortField="TotalCompletedRate" FieldType="String" HeaderTextAlign="Center" TextAlign="Left"
|
||||
Width="120px">
|
||||
</f:RenderField>
|
||||
</columns>
|
||||
<listeners>
|
||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />
|
||||
</listeners>
|
||||
<listeners>
|
||||
<f:Listener Event="dataload" Handler="onGridDataLoad" />
|
||||
</Listeners>
|
||||
<PageItems>
|
||||
</listeners>
|
||||
<pageitems>
|
||||
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
||||
</f:ToolbarSeparator>
|
||||
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
||||
@@ -151,14 +158,26 @@
|
||||
<f:ListItem Text="25" Value="25" />
|
||||
<f:ListItem Text="所有行" Value="10000" />
|
||||
</f:DropDownList>
|
||||
</PageItems>
|
||||
</pageitems>
|
||||
</f:Grid>
|
||||
</Items>
|
||||
</items>
|
||||
</f:Panel>
|
||||
</Items>
|
||||
</items>
|
||||
</f:Panel>
|
||||
<f:Menu ID="Menu1" runat="server">
|
||||
<f:MenuButton ID="btnMenuDelete" OnClick="btnMenuDelete_Click" EnablePostBack="true" Icon="Delete"
|
||||
ConfirmText="删除选中行?" ConfirmTarget="Parent" runat="server" Text="删除">
|
||||
</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');
|
||||
}
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
using BLL;
|
||||
using FineUIPro.Web.ProjectData;
|
||||
using MiniExcelLibs;
|
||||
using Model;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using NPOI.SS.Formula.Functions;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
@@ -11,6 +13,7 @@ using System.Drawing;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security.Cryptography;
|
||||
using System.Web;
|
||||
using System.Web.WebSockets;
|
||||
|
||||
@@ -83,7 +86,7 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
{
|
||||
foreach (var q in unitWork1)
|
||||
{
|
||||
int a = (from x in Funs.DB.HJGL_Pipeline where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitWorkId == q.UnitWorkId && x.PipeArea == "1" && x.PipelineCode.Contains(txtPipelineCode.Text.Trim()) select x.FlowingSection).Distinct().Count();
|
||||
int a = (from x in Funs.DB.HJGL_Pipeline where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitWorkId == q.UnitWorkId && x.PipeArea == "1" select x.FlowingSection).Distinct().Count();
|
||||
var unitNamesUnitIds = BLL.UnitService.getUnitNamesUnitIds(q.UnitId);
|
||||
TreeNode tn1 = new TreeNode();
|
||||
tn1.NodeID = q.UnitWorkId;
|
||||
@@ -112,7 +115,7 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
{
|
||||
foreach (var q in unitWork2)
|
||||
{
|
||||
int a = (from x in Funs.DB.HJGL_Pipeline where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitWorkId == q.UnitWorkId && x.PipeArea == "1" && x.PipelineCode.Contains(txtPipelineCode.Text.Trim()) select x.FlowingSection).Distinct().Count();
|
||||
int a = (from x in Funs.DB.HJGL_Pipeline where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitWorkId == q.UnitWorkId && x.PipeArea == "1" select x.FlowingSection).Distinct().Count();
|
||||
var unitNamesUnitIds = BLL.UnitService.getUnitNamesUnitIds(q.UnitId);
|
||||
TreeNode tn2 = new TreeNode();
|
||||
tn2.NodeID = q.UnitWorkId;
|
||||
@@ -147,7 +150,7 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
{
|
||||
List<string> flowingSection = new List<string>();
|
||||
//List<Model.HJGL_Pipeline> pipeline = new List<Model.HJGL_Pipeline>();
|
||||
var list = (from x in Funs.DB.HJGL_Pipeline where x.ProjectId == this.CurrUser.LoginProjectId && x.PipeArea == "1" && x.UnitWorkId == node.NodeID && x.PipelineCode.Contains(this.txtPipelineCode.Text.Trim()) select x.FlowingSection).ToList();
|
||||
var list = (from x in Funs.DB.HJGL_Pipeline where x.ProjectId == this.CurrUser.LoginProjectId && x.PipeArea == "1" && x.UnitWorkId == node.NodeID select x.FlowingSection).ToList();
|
||||
flowingSection = list.Where(x => !string.IsNullOrWhiteSpace(x) == true).Distinct().OrderBy(x => x).ToList();
|
||||
//int pageindex = int.Parse(node.CommandName.Split('|')[0]);
|
||||
//int pageCount = int.Parse(node.CommandName.Split('|')[1]);
|
||||
@@ -199,16 +202,16 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
/// <param name="e"></param>
|
||||
protected void tvControlItem_NodeCommand(object sender, TreeCommandEventArgs e)
|
||||
{
|
||||
if (e.CommandName == "流水段")
|
||||
{
|
||||
Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByFlowingSection(this.tvControlItem.SelectedNode.Text);
|
||||
this.hdUnitWorkId.Text = string.Empty;
|
||||
if (pipeline != null)
|
||||
{
|
||||
this.hdUnitWorkId.Text = this.tvControlItem.SelectedNode.ParentNode.NodeID;
|
||||
SaveProductionSchedulingPlan();
|
||||
}
|
||||
}
|
||||
//if (e.CommandName == "流水段")
|
||||
//{
|
||||
// Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByFlowingSection(this.tvControlItem.SelectedNode.Text);
|
||||
// this.hdUnitWorkId.Text = string.Empty;
|
||||
// if (pipeline != null)
|
||||
// {
|
||||
// this.hdUnitWorkId.Text = this.tvControlItem.SelectedNode.ParentNode.NodeID;
|
||||
// SaveProductionSchedulingPlan();
|
||||
// }
|
||||
//}
|
||||
this.BindGrid();
|
||||
}
|
||||
|
||||
@@ -220,23 +223,145 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
{
|
||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
|
||||
{
|
||||
List<Model.View_HJGL_ProductionSchedulingPlanStatistics> lists = (from x in Funs.DB.View_HJGL_ProductionSchedulingPlanStatistics.Where(x => x.ProjectId == this.CurrUser.LoginProjectId && x.FlowingSection == this.tvControlItem.SelectedNode.Text) select x).ToList();
|
||||
foreach (var item in lists)
|
||||
if (tvControlItem.SelectedNode.CommandName == "流水段")
|
||||
{
|
||||
var plan = BLL.ProductionSchedulingPlanService.GetProductionSchedulingPlan(this.CurrUser.LoginProjectId, item.FlowingSection, item.UnitWorkName, item.Material, item.Caliber);
|
||||
if (plan == null)
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
listStr.Add(new SqlParameter("@projectId", this.CurrUser.LoginProjectId));
|
||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNode.ParentNode.NodeID))
|
||||
{
|
||||
Model.HJGL_ProductionSchedulingPlan newPlan = new HJGL_ProductionSchedulingPlan();
|
||||
newPlan.ProductionSchedulingPlanId = SQLHelper.GetNewID(typeof(Model.HJGL_ProductionSchedulingPlan));
|
||||
newPlan.ProjectId = this.CurrUser.LoginProjectId;
|
||||
//newPlan.PipelineId = this.tvControlItem.SelectedNodeID;
|
||||
newPlan.FlowNum = item.FlowingSection;
|
||||
newPlan.MainItemName = item.UnitWorkName;
|
||||
newPlan.Material = item.Material;
|
||||
newPlan.Caliber = item.Caliber;
|
||||
newPlan.Dain = item.Dia;
|
||||
newPlan.TotalDyne = lists.Sum(x => x.Dia);
|
||||
BLL.ProductionSchedulingPlanService.AddProductionSchedulingPlan(newPlan);
|
||||
listStr.Add(new SqlParameter("@unitWorkId", this.tvControlItem.SelectedNode.ParentNode.NodeID));
|
||||
}
|
||||
else
|
||||
{
|
||||
listStr.Add(new SqlParameter("@unitWorkId", null));
|
||||
}
|
||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNode.Text))
|
||||
{
|
||||
listStr.Add(new SqlParameter("@flowingSection", this.tvControlItem.SelectedNode.Text));
|
||||
}
|
||||
else
|
||||
{
|
||||
listStr.Add(new SqlParameter("@flowingSection", null));
|
||||
}
|
||||
if (!string.IsNullOrEmpty(this.txtSize.Text.Trim()))
|
||||
{
|
||||
listStr.Add(new SqlParameter("@caliber", this.txtSize.Text.Trim()));
|
||||
}
|
||||
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
DataTable tb = SQLHelper.GetDataTableRunProc("Sp_ProductionSchedulingPlanStatistics", parameter);
|
||||
|
||||
for (int i = 0; i < tb.Rows.Count; i++)
|
||||
{
|
||||
//decimal totalDia = 0;
|
||||
//totalDia += Convert.ToDecimal(tb.Rows[i]["Dia"].ToString());//总达因
|
||||
|
||||
var plan = BLL.ProductionSchedulingPlanService.GetProductionSchedulingPlan(this.CurrUser.LoginProjectId, tb.Rows[i]["FlowingSection"].ToString(), tb.Rows[i]["UnitWorkId"].ToString(), tb.Rows[i]["Material"].ToString(), tb.Rows[i]["Caliber"].ToString());
|
||||
if (plan == null)
|
||||
{
|
||||
Model.HJGL_ProductionSchedulingPlan newPlan = new HJGL_ProductionSchedulingPlan();
|
||||
newPlan.ProductionSchedulingPlanId = SQLHelper.GetNewID(typeof(Model.HJGL_ProductionSchedulingPlan));
|
||||
newPlan.ProjectId = this.CurrUser.LoginProjectId;
|
||||
newPlan.PipelineId = tb.Rows[i]["UnitWorkId"].ToString();//装置ID
|
||||
newPlan.FlowNum = tb.Rows[i]["FlowingSection"].ToString();
|
||||
newPlan.MainItemName = tb.Rows[i]["UnitWorkName"].ToString();
|
||||
newPlan.Material = tb.Rows[i]["Material"].ToString();
|
||||
newPlan.Caliber = tb.Rows[i]["Caliber"].ToString();
|
||||
newPlan.Dain = Funs.GetNewDecimalOrZero(tb.Rows[i]["Dia"].ToString());
|
||||
newPlan.TotalDyne = Funs.GetNewDecimalOrZero(tb.Rows[i]["TotalDia"].ToString());
|
||||
newPlan.CompletedCount = Funs.GetNewIntOrZero(tb.Rows[i]["cTotalCount"].ToString());
|
||||
newPlan.CompletedRate = Funs.GetNewDecimalOrZero(tb.Rows[i]["rate"].ToString());
|
||||
newPlan.TotalCompletedRate = Funs.GetNewDecimalOrZero(tb.Rows[i]["Srate"].ToString());
|
||||
BLL.ProductionSchedulingPlanService.AddProductionSchedulingPlan(newPlan);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (tvControlItem.SelectedNode.CommandName.Split('|').Length == 2)//单位工程
|
||||
{
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
listStr.Add(new SqlParameter("@projectId", this.CurrUser.LoginProjectId));
|
||||
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNode.NodeID))
|
||||
{
|
||||
listStr.Add(new SqlParameter("@unitWorkId", this.tvControlItem.SelectedNode.NodeID));
|
||||
}
|
||||
else
|
||||
{
|
||||
listStr.Add(new SqlParameter("@unitWorkId", null));
|
||||
}
|
||||
if (!string.IsNullOrEmpty(this.txtSize.Text.Trim()))
|
||||
{
|
||||
listStr.Add(new SqlParameter("@caliber", this.txtSize.Text.Trim()));
|
||||
}
|
||||
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
DataTable tb = SQLHelper.GetDataTableRunProc("Sp_ProductionSchedulingPlanStatistics", parameter);
|
||||
|
||||
|
||||
for (int i = 0; i < tb.Rows.Count; i++)
|
||||
{
|
||||
var plan = BLL.ProductionSchedulingPlanService.GetProductionSchedulingPlan(this.CurrUser.LoginProjectId, tb.Rows[i]["FlowingSection"].ToString(), tb.Rows[i]["UnitWorkId"].ToString(), tb.Rows[i]["Material"].ToString(), tb.Rows[i]["Caliber"].ToString());
|
||||
if (plan == null)
|
||||
{
|
||||
Model.HJGL_ProductionSchedulingPlan newPlan = new HJGL_ProductionSchedulingPlan();
|
||||
newPlan.ProductionSchedulingPlanId = SQLHelper.GetNewID(typeof(Model.HJGL_ProductionSchedulingPlan));
|
||||
newPlan.ProjectId = this.CurrUser.LoginProjectId;
|
||||
newPlan.PipelineId = tb.Rows[i]["UnitWorkId"].ToString();//装置ID
|
||||
newPlan.FlowNum = tb.Rows[i]["FlowingSection"].ToString();
|
||||
newPlan.MainItemName = tb.Rows[i]["UnitWorkName"].ToString();
|
||||
newPlan.Material = tb.Rows[i]["Material"].ToString();
|
||||
newPlan.Caliber = tb.Rows[i]["Caliber"].ToString();
|
||||
newPlan.Dain = Funs.GetNewDecimalOrZero(tb.Rows[i]["Dia"].ToString());
|
||||
newPlan.TotalDyne = Funs.GetNewDecimalOrZero(tb.Rows[i]["TotalDia"].ToString());
|
||||
newPlan.CompletedCount = Funs.GetNewIntOrZero(tb.Rows[i]["cTotalCount"].ToString());
|
||||
newPlan.CompletedRate = Funs.GetNewDecimalOrZero(tb.Rows[i]["rate"].ToString());
|
||||
newPlan.TotalCompletedRate = Funs.GetNewDecimalOrZero(tb.Rows[i]["Srate"].ToString());
|
||||
BLL.ProductionSchedulingPlanService.AddProductionSchedulingPlan(newPlan);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (this.tvControlItem.SelectedNodeID == "1" || this.tvControlItem.SelectedNodeID == "2")
|
||||
{
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
listStr.Add(new SqlParameter("@projectId", this.CurrUser.LoginProjectId));
|
||||
if (!string.IsNullOrEmpty(this.hdUnitWorkId.Text))
|
||||
{
|
||||
listStr.Add(new SqlParameter("@unitWorkId", this.hdUnitWorkId.Text));
|
||||
}
|
||||
else
|
||||
{
|
||||
listStr.Add(new SqlParameter("@unitWorkId", null));
|
||||
}
|
||||
if (!string.IsNullOrEmpty(this.txtSize.Text.Trim()))
|
||||
{
|
||||
listStr.Add(new SqlParameter("@caliber", this.txtSize.Text.Trim()));
|
||||
}
|
||||
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
DataTable tb = SQLHelper.GetDataTableRunProc("Sp_ProductionSchedulingPlanStatistics", parameter);
|
||||
|
||||
for (int i = 0; i < tb.Rows.Count; i++)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(tb.Rows[i]["FlowingSection"].ToString()))
|
||||
{
|
||||
var plan = BLL.ProductionSchedulingPlanService.GetProductionSchedulingPlan(this.CurrUser.LoginProjectId, tb.Rows[i]["FlowingSection"].ToString(), tb.Rows[i]["UnitWorkId"].ToString(), tb.Rows[i]["Material"].ToString(), tb.Rows[i]["Caliber"].ToString());
|
||||
if (plan == null)
|
||||
{
|
||||
Model.HJGL_ProductionSchedulingPlan newPlan = new HJGL_ProductionSchedulingPlan();
|
||||
newPlan.ProductionSchedulingPlanId = SQLHelper.GetNewID(typeof(Model.HJGL_ProductionSchedulingPlan));
|
||||
newPlan.ProjectId = this.CurrUser.LoginProjectId;
|
||||
newPlan.PipelineId = tb.Rows[i]["UnitWorkId"].ToString();//装置ID
|
||||
newPlan.FlowNum = tb.Rows[i]["FlowingSection"].ToString();
|
||||
newPlan.MainItemName = tb.Rows[i]["UnitWorkName"].ToString();
|
||||
newPlan.Material = tb.Rows[i]["Material"].ToString();
|
||||
newPlan.Caliber = tb.Rows[i]["Caliber"].ToString();
|
||||
newPlan.Dain = Funs.GetNewDecimalOrZero(tb.Rows[i]["Dia"].ToString());
|
||||
newPlan.TotalDyne = Funs.GetNewDecimalOrZero(tb.Rows[i]["TotalDia"].ToString());
|
||||
newPlan.CompletedCount = Funs.GetNewIntOrZero(tb.Rows[i]["cTotalCount"].ToString());
|
||||
newPlan.CompletedRate = Funs.GetNewDecimalOrZero(tb.Rows[i]["rate"].ToString());
|
||||
newPlan.TotalCompletedRate = Funs.GetNewDecimalOrZero(tb.Rows[i]["Srate"].ToString());
|
||||
BLL.ProductionSchedulingPlanService.AddProductionSchedulingPlan(newPlan);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -264,22 +389,35 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
p.PlanStartDate,
|
||||
p.PlanEndDate,
|
||||
p.Days,
|
||||
p.AvgDailyWorkload
|
||||
p.AvgDailyWorkload,
|
||||
w.ProjectType,
|
||||
p.CompletedCount,
|
||||
p.CompletedRate,
|
||||
p.TotalCompletedRate
|
||||
FROM HJGL_ProductionSchedulingPlan p
|
||||
left join WBS_UnitWork w on w.UnitWorkId=p.PipelineId
|
||||
WHERE 1=1 ";
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
|
||||
if (tvControlItem.SelectedNode.CommandName.Split('|').Length == 2)
|
||||
{
|
||||
strSql += " and p.MainItemName =@UnitWorkId";
|
||||
listStr.Add(new SqlParameter("@UnitWorkId", this.tvControlItem.SelectedNode.Text));
|
||||
strSql += " and p.PipelineId =@UnitWorkId";
|
||||
listStr.Add(new SqlParameter("@UnitWorkId", this.tvControlItem.SelectedNode.NodeID));
|
||||
|
||||
}
|
||||
else if (tvControlItem.SelectedNode.CommandName == "流水段")
|
||||
{
|
||||
strSql += " and p.FlowNum = @FlowNum ";
|
||||
strSql += "and p.PipelineId =@UnitWorkId and p.FlowNum = @FlowNum ";
|
||||
listStr.Add(new SqlParameter("@UnitWorkId", this.tvControlItem.SelectedNode.ParentNode.NodeID));
|
||||
listStr.Add(new SqlParameter("@FlowNum", this.tvControlItem.SelectedNode.Text));
|
||||
|
||||
}
|
||||
else if (tvControlItem.SelectedNodeID == "1")
|
||||
{
|
||||
strSql += "and w.ProjectType ='1' ";
|
||||
}
|
||||
else if (tvControlItem.SelectedNodeID == "2")
|
||||
{
|
||||
strSql += "and w.ProjectType ='2' ";
|
||||
}
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
||||
@@ -332,10 +470,10 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
#endregion
|
||||
|
||||
#region 维护事件
|
||||
protected void btnSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
//protected void btnSearch_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// BindGrid();
|
||||
//}
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -345,15 +483,15 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void TextBox_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
this.BindGrid();
|
||||
}
|
||||
protected void btnTreeFind_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.InitTreeMenu();
|
||||
//protected void TextBox_TextChanged(object sender, EventArgs e)
|
||||
//{
|
||||
// this.BindGrid();
|
||||
//}
|
||||
//protected void btnTreeFind_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// this.InitTreeMenu();
|
||||
|
||||
}
|
||||
//}
|
||||
#endregion
|
||||
|
||||
#region 保存
|
||||
@@ -470,7 +608,7 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
|
||||
cell = row.CreateCell(5);
|
||||
cell.CellStyle = cellStyle;
|
||||
cell.SetCellValue(item.TotalDyne.HasValue?item.TotalDyne.ToString():"");//总达因数
|
||||
cell.SetCellValue(item.TotalDyne.HasValue ? item.TotalDyne.ToString() : "");//总达因数
|
||||
|
||||
cell = row.CreateCell(6);
|
||||
cell.CellStyle = cellStyle;
|
||||
@@ -490,12 +628,24 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
|
||||
cell = row.CreateCell(10);
|
||||
cell.CellStyle = cellStyle;
|
||||
cell.SetCellValue(item.Days.HasValue?item.Days.ToString():"");//天数
|
||||
cell.SetCellValue(item.Days.HasValue ? item.Days.ToString() : "");//天数
|
||||
|
||||
cell = row.CreateCell(11);
|
||||
cell.CellStyle = cellStyle;
|
||||
cell.SetCellValue(item.AvgDailyWorkload.HasValue ? item.AvgDailyWorkload.ToString():"");//平均每天工作量
|
||||
|
||||
cell.SetCellValue(item.AvgDailyWorkload.HasValue ? item.AvgDailyWorkload.ToString() : "");//平均每天工作量
|
||||
|
||||
cell = row.CreateCell(12);
|
||||
cell.CellStyle = cellStyle;
|
||||
cell.SetCellValue(item.CompletedCount.HasValue ? item.CompletedCount.ToString() : "");//已完成量
|
||||
|
||||
cell = row.CreateCell(13);
|
||||
cell.CellStyle = cellStyle;
|
||||
cell.SetCellValue(item.CompletedRate.HasValue ? item.CompletedRate.ToString() : "");//已完成百分比
|
||||
|
||||
cell = row.CreateCell(14);
|
||||
cell.CellStyle = cellStyle;
|
||||
cell.SetCellValue(item.TotalCompletedRate.HasValue ? item.TotalCompletedRate.ToString() : "");//已完成百分比汇总
|
||||
|
||||
i++;
|
||||
}
|
||||
// 第三步:写入文件流
|
||||
@@ -522,5 +672,103 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 统计
|
||||
/// <summary>
|
||||
/// 统计
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnStatics_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(this.txtSize.Text.Trim()))
|
||||
{
|
||||
//单位工程
|
||||
if (tvControlItem.SelectedNode.CommandName.Split('|').Length == 2)
|
||||
{
|
||||
///根据流水段获取管线信息
|
||||
Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByUnitWorkId(this.tvControlItem.SelectedNode.NodeID);
|
||||
this.hdUnitWorkId.Text = string.Empty;
|
||||
if (pipeline != null)
|
||||
{
|
||||
this.hdUnitWorkId.Text = this.tvControlItem.SelectedNode.NodeID;
|
||||
SaveProductionSchedulingPlan();
|
||||
}
|
||||
|
||||
}
|
||||
else if (tvControlItem.SelectedNode.CommandName == "流水段")
|
||||
{
|
||||
///根据流水段获取管线信息
|
||||
Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByFlowingSection(this.tvControlItem.SelectedNode.Text);
|
||||
this.hdUnitWorkId.Text = string.Empty;
|
||||
if (pipeline != null)
|
||||
{
|
||||
this.hdUnitWorkId.Text = this.tvControlItem.SelectedNode.ParentNode.NodeID;
|
||||
SaveProductionSchedulingPlan();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
var unitWorkList = (from x in Funs.DB.WBS_UnitWork
|
||||
where x.ProjectId == this.CurrUser.LoginProjectId
|
||||
&& x.SuperUnitWork == null && x.UnitId != null && x.ProjectType != null
|
||||
select x).ToList();
|
||||
|
||||
List<Model.WBS_UnitWork> unitWorks = null;
|
||||
//List<Model.WBS_UnitWork> unitWork2 = null;
|
||||
//
|
||||
if (this.tvControlItem.SelectedNodeID == "1")
|
||||
{
|
||||
unitWorks = (from x in unitWorkList where x.ProjectType == "1" select x).ToList();
|
||||
}
|
||||
else if (this.tvControlItem.SelectedNodeID == "2")
|
||||
{
|
||||
unitWorks = (from x in unitWorkList where x.ProjectType == "2" select x).ToList();
|
||||
}
|
||||
foreach (var item in unitWorks)
|
||||
{
|
||||
Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByUnitWorkId(item.UnitWorkId);
|
||||
this.hdUnitWorkId.Text = string.Empty;
|
||||
if (pipeline != null)
|
||||
{
|
||||
this.hdUnitWorkId.Text = item.UnitWorkId;
|
||||
SaveProductionSchedulingPlan();
|
||||
}
|
||||
}
|
||||
}
|
||||
this.BindGrid();
|
||||
}
|
||||
else
|
||||
{
|
||||
Alert.ShowInTop("请输入口径!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 右键删除
|
||||
/// <summary>
|
||||
/// 删除
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnMenuDelete_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length > 0)
|
||||
{
|
||||
foreach (int rowIndex in Grid1.SelectedRowIndexArray)
|
||||
{
|
||||
string rowID = Grid1.DataKeys[rowIndex][0].ToString();
|
||||
var model = BLL.ProductionSchedulingPlanService.GetProductionSchedulingPlanById(rowID);
|
||||
if (model != null)
|
||||
{
|
||||
BLL.ProductionSchedulingPlanService.DeleteProductionSchedulingPlanById(rowID);
|
||||
}
|
||||
}
|
||||
BindGrid();
|
||||
ShowNotify("删除数据成功!", MessageBoxIcon.Success);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
+22
-13
@@ -51,22 +51,22 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
protected global::FineUIPro.Panel panelLeftRegion;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar1 控件。
|
||||
/// txtSize 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar1;
|
||||
protected global::FineUIPro.NumberBox txtSize;
|
||||
|
||||
/// <summary>
|
||||
/// txtPipelineCode 控件。
|
||||
/// btnStatics 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtPipelineCode;
|
||||
protected global::FineUIPro.Button btnStatics;
|
||||
|
||||
/// <summary>
|
||||
/// hdUnitWorkId 控件。
|
||||
@@ -77,15 +77,6 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.HiddenField hdUnitWorkId;
|
||||
|
||||
/// <summary>
|
||||
/// btnTreeFind 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnTreeFind;
|
||||
|
||||
/// <summary>
|
||||
/// tvControlItem 控件。
|
||||
/// </summary>
|
||||
@@ -229,5 +220,23 @@ namespace FineUIPro.Web.HJGL.PreDesign
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlPageSize;
|
||||
|
||||
/// <summary>
|
||||
/// Menu1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Menu Menu1;
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuDelete 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.MenuButton btnMenuDelete;
|
||||
}
|
||||
}
|
||||
|
||||
+271
-360
@@ -6857,14 +6857,6 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
public System.Data.Linq.Table<View_HJGL_ProductionSchedulingPlanStatistics> View_HJGL_ProductionSchedulingPlanStatistics
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.GetTable<View_HJGL_ProductionSchedulingPlanStatistics>();
|
||||
}
|
||||
}
|
||||
|
||||
public System.Data.Linq.Table<View_HJGL_WeldingTask> View_HJGL_WeldingTask
|
||||
{
|
||||
get
|
||||
@@ -12163,7 +12155,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveIdea", DbType="NVarChar(2000)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveIdea", DbType="NVarChar(200)")]
|
||||
public string ApproveIdea
|
||||
{
|
||||
get
|
||||
@@ -95762,10 +95754,10 @@ namespace Model
|
||||
|
||||
private string _TrainNumber;
|
||||
|
||||
private System.Nullable<int> _TypeInt;
|
||||
|
||||
private string _TrainNumberId;
|
||||
|
||||
private System.Nullable<int> _TypeInt;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
partial void OnValidate(System.Data.Linq.ChangeAction action);
|
||||
@@ -95794,10 +95786,10 @@ namespace Model
|
||||
partial void OnReceiveDateChanged();
|
||||
partial void OnTrainNumberChanging(string value);
|
||||
partial void OnTrainNumberChanged();
|
||||
partial void OnTypeIntChanging(System.Nullable<int> value);
|
||||
partial void OnTypeIntChanged();
|
||||
partial void OnTrainNumberIdChanging(string value);
|
||||
partial void OnTrainNumberIdChanged();
|
||||
partial void OnTypeIntChanging(System.Nullable<int> value);
|
||||
partial void OnTypeIntChanged();
|
||||
#endregion
|
||||
|
||||
public HJGL_PackagingManage()
|
||||
@@ -96045,26 +96037,6 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TypeInt", DbType="Int")]
|
||||
public System.Nullable<int> TypeInt
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._TypeInt;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._TypeInt != value))
|
||||
{
|
||||
this.OnTypeIntChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._TypeInt = value;
|
||||
this.SendPropertyChanged("TypeInt");
|
||||
this.OnTypeIntChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TrainNumberId", DbType="VarChar(50)")]
|
||||
public string TrainNumberId
|
||||
{
|
||||
@@ -96085,6 +96057,26 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TypeInt", DbType="Int")]
|
||||
public System.Nullable<int> TypeInt
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._TypeInt;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._TypeInt != value))
|
||||
{
|
||||
this.OnTypeIntChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._TypeInt = value;
|
||||
this.SendPropertyChanged("TypeInt");
|
||||
this.OnTypeIntChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public event PropertyChangingEventHandler PropertyChanging;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
@@ -97830,8 +97822,6 @@ namespace Model
|
||||
|
||||
private EntitySet<HJGL_PipeLineMat> _HJGL_PipeLineMat;
|
||||
|
||||
private EntitySet<HJGL_ProductionSchedulingPlan> _HJGL_ProductionSchedulingPlan;
|
||||
|
||||
private EntitySet<HJGL_WeldJoint> _HJGL_WeldJoint;
|
||||
|
||||
private EntitySet<PTP_BItemEndCheck> _PTP_BItemEndCheck;
|
||||
@@ -97927,7 +97917,6 @@ namespace Model
|
||||
this._HJGL_Pipeline_Component = new EntitySet<HJGL_Pipeline_Component>(new Action<HJGL_Pipeline_Component>(this.attach_HJGL_Pipeline_Component), new Action<HJGL_Pipeline_Component>(this.detach_HJGL_Pipeline_Component));
|
||||
this._WBS_UnitWork = default(EntityRef<WBS_UnitWork>);
|
||||
this._HJGL_PipeLineMat = new EntitySet<HJGL_PipeLineMat>(new Action<HJGL_PipeLineMat>(this.attach_HJGL_PipeLineMat), new Action<HJGL_PipeLineMat>(this.detach_HJGL_PipeLineMat));
|
||||
this._HJGL_ProductionSchedulingPlan = new EntitySet<HJGL_ProductionSchedulingPlan>(new Action<HJGL_ProductionSchedulingPlan>(this.attach_HJGL_ProductionSchedulingPlan), new Action<HJGL_ProductionSchedulingPlan>(this.detach_HJGL_ProductionSchedulingPlan));
|
||||
this._HJGL_WeldJoint = new EntitySet<HJGL_WeldJoint>(new Action<HJGL_WeldJoint>(this.attach_HJGL_WeldJoint), new Action<HJGL_WeldJoint>(this.detach_HJGL_WeldJoint));
|
||||
this._PTP_BItemEndCheck = new EntitySet<PTP_BItemEndCheck>(new Action<PTP_BItemEndCheck>(this.attach_PTP_BItemEndCheck), new Action<PTP_BItemEndCheck>(this.detach_PTP_BItemEndCheck));
|
||||
this._PTP_ItemEndCheck = new EntitySet<PTP_ItemEndCheck>(new Action<PTP_ItemEndCheck>(this.attach_PTP_ItemEndCheck), new Action<PTP_ItemEndCheck>(this.detach_PTP_ItemEndCheck));
|
||||
@@ -98964,19 +98953,6 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_ProductionSchedulingPlan_HJGL_Pipeline", Storage="_HJGL_ProductionSchedulingPlan", ThisKey="PipelineId", OtherKey="PipelineId", DeleteRule="NO ACTION")]
|
||||
public EntitySet<HJGL_ProductionSchedulingPlan> HJGL_ProductionSchedulingPlan
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._HJGL_ProductionSchedulingPlan;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._HJGL_ProductionSchedulingPlan.Assign(value);
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_WeldJoint_HJGL_Pipeline", Storage="_HJGL_WeldJoint", ThisKey="PipelineId", OtherKey="PipelineId", DeleteRule="NO ACTION")]
|
||||
public EntitySet<HJGL_WeldJoint> HJGL_WeldJoint
|
||||
{
|
||||
@@ -99109,18 +99085,6 @@ namespace Model
|
||||
entity.HJGL_Pipeline = null;
|
||||
}
|
||||
|
||||
private void attach_HJGL_ProductionSchedulingPlan(HJGL_ProductionSchedulingPlan entity)
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
entity.HJGL_Pipeline = this;
|
||||
}
|
||||
|
||||
private void detach_HJGL_ProductionSchedulingPlan(HJGL_ProductionSchedulingPlan entity)
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
entity.HJGL_Pipeline = null;
|
||||
}
|
||||
|
||||
private void attach_HJGL_WeldJoint(HJGL_WeldJoint entity)
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
@@ -100537,9 +100501,15 @@ namespace Model
|
||||
|
||||
private System.Nullable<decimal> _AvgDailyWorkload;
|
||||
|
||||
private System.Nullable<int> _CompletedCount;
|
||||
|
||||
private System.Nullable<decimal> _CompletedRate;
|
||||
|
||||
private System.Nullable<decimal> _TotalCompletedRate;
|
||||
|
||||
private EntityRef<Base_Project> _Base_Project;
|
||||
|
||||
private EntityRef<HJGL_Pipeline> _HJGL_Pipeline;
|
||||
private EntityRef<WBS_UnitWork> _WBS_UnitWork;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
@@ -100575,12 +100545,18 @@ namespace Model
|
||||
partial void OnDaysChanged();
|
||||
partial void OnAvgDailyWorkloadChanging(System.Nullable<decimal> value);
|
||||
partial void OnAvgDailyWorkloadChanged();
|
||||
partial void OnCompletedCountChanging(System.Nullable<int> value);
|
||||
partial void OnCompletedCountChanged();
|
||||
partial void OnCompletedRateChanging(System.Nullable<decimal> value);
|
||||
partial void OnCompletedRateChanged();
|
||||
partial void OnTotalCompletedRateChanging(System.Nullable<decimal> value);
|
||||
partial void OnTotalCompletedRateChanged();
|
||||
#endregion
|
||||
|
||||
public HJGL_ProductionSchedulingPlan()
|
||||
{
|
||||
this._Base_Project = default(EntityRef<Base_Project>);
|
||||
this._HJGL_Pipeline = default(EntityRef<HJGL_Pipeline>);
|
||||
this._WBS_UnitWork = default(EntityRef<WBS_UnitWork>);
|
||||
OnCreated();
|
||||
}
|
||||
|
||||
@@ -100639,7 +100615,7 @@ namespace Model
|
||||
{
|
||||
if ((this._PipelineId != value))
|
||||
{
|
||||
if (this._HJGL_Pipeline.HasLoadedOrAssignedValue)
|
||||
if (this._WBS_UnitWork.HasLoadedOrAssignedValue)
|
||||
{
|
||||
throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
|
||||
}
|
||||
@@ -100892,6 +100868,66 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompletedCount", DbType="Int")]
|
||||
public System.Nullable<int> CompletedCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._CompletedCount;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._CompletedCount != value))
|
||||
{
|
||||
this.OnCompletedCountChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._CompletedCount = value;
|
||||
this.SendPropertyChanged("CompletedCount");
|
||||
this.OnCompletedCountChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompletedRate", DbType="Decimal(18,2)")]
|
||||
public System.Nullable<decimal> CompletedRate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._CompletedRate;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._CompletedRate != value))
|
||||
{
|
||||
this.OnCompletedRateChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._CompletedRate = value;
|
||||
this.SendPropertyChanged("CompletedRate");
|
||||
this.OnCompletedRateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TotalCompletedRate", DbType="Decimal(18,2)")]
|
||||
public System.Nullable<decimal> TotalCompletedRate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._TotalCompletedRate;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._TotalCompletedRate != value))
|
||||
{
|
||||
this.OnTotalCompletedRateChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._TotalCompletedRate = value;
|
||||
this.SendPropertyChanged("TotalCompletedRate");
|
||||
this.OnTotalCompletedRateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_ProductionSchedulingPlan_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)]
|
||||
public Base_Project Base_Project
|
||||
{
|
||||
@@ -100926,36 +100962,36 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_ProductionSchedulingPlan_HJGL_Pipeline", Storage="_HJGL_Pipeline", ThisKey="PipelineId", OtherKey="PipelineId", IsForeignKey=true)]
|
||||
public HJGL_Pipeline HJGL_Pipeline
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_ProductionSchedulingPlan_WBS_UnitWork", Storage="_WBS_UnitWork", ThisKey="PipelineId", OtherKey="UnitWorkId", IsForeignKey=true)]
|
||||
public WBS_UnitWork WBS_UnitWork
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._HJGL_Pipeline.Entity;
|
||||
return this._WBS_UnitWork.Entity;
|
||||
}
|
||||
set
|
||||
{
|
||||
HJGL_Pipeline previousValue = this._HJGL_Pipeline.Entity;
|
||||
WBS_UnitWork previousValue = this._WBS_UnitWork.Entity;
|
||||
if (((previousValue != value)
|
||||
|| (this._HJGL_Pipeline.HasLoadedOrAssignedValue == false)))
|
||||
|| (this._WBS_UnitWork.HasLoadedOrAssignedValue == false)))
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
if ((previousValue != null))
|
||||
{
|
||||
this._HJGL_Pipeline.Entity = null;
|
||||
this._WBS_UnitWork.Entity = null;
|
||||
previousValue.HJGL_ProductionSchedulingPlan.Remove(this);
|
||||
}
|
||||
this._HJGL_Pipeline.Entity = value;
|
||||
this._WBS_UnitWork.Entity = value;
|
||||
if ((value != null))
|
||||
{
|
||||
value.HJGL_ProductionSchedulingPlan.Add(this);
|
||||
this._PipelineId = value.PipelineId;
|
||||
this._PipelineId = value.UnitWorkId;
|
||||
}
|
||||
else
|
||||
{
|
||||
this._PipelineId = default(string);
|
||||
}
|
||||
this.SendPropertyChanged("HJGL_Pipeline");
|
||||
this.SendPropertyChanged("WBS_UnitWork");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -107132,7 +107168,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Rectification", DbType="NVarChar(500)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Rectification", DbType="NVarChar(50)")]
|
||||
public string Rectification
|
||||
{
|
||||
get
|
||||
@@ -107258,7 +107294,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Measures", DbType="NVarChar(500)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Measures", DbType="NVarChar(50)")]
|
||||
public string Measures
|
||||
{
|
||||
get
|
||||
@@ -159493,7 +159529,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AttentPerson", DbType="NVarChar(3000)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AttentPerson", DbType="NVarChar(500)")]
|
||||
public string AttentPerson
|
||||
{
|
||||
get
|
||||
@@ -190476,7 +190512,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectDescription", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectDescription", DbType="VarChar(255)")]
|
||||
public string ProjectDescription
|
||||
{
|
||||
get
|
||||
@@ -190596,7 +190632,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CalculationRule", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CalculationRule", DbType="VarChar(255)")]
|
||||
public string CalculationRule
|
||||
{
|
||||
get
|
||||
@@ -190656,7 +190692,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ConstructionSubcontractor", DbType="VarChar(100)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ConstructionSubcontractor", DbType="VarChar(50)")]
|
||||
public string ConstructionSubcontractor
|
||||
{
|
||||
get
|
||||
@@ -191040,7 +191076,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageEstimate", DbType="Decimal(18,3)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageEstimate", DbType="Decimal(18,2)")]
|
||||
public System.Nullable<decimal> WorkPackageEstimate
|
||||
{
|
||||
get
|
||||
@@ -191345,16 +191381,6 @@ namespace Model
|
||||
|
||||
private string _ProjectId;
|
||||
|
||||
private string _ContractId;
|
||||
|
||||
private string _OrderCode;
|
||||
|
||||
private System.Nullable<System.DateTime> _OrderInDate;
|
||||
|
||||
private System.Nullable<System.DateTime> _OrderOutDate;
|
||||
|
||||
private string _MaterialRequisitionUnit;
|
||||
|
||||
private System.Nullable<int> _State;
|
||||
|
||||
private string _InvoiceCode;
|
||||
@@ -191383,6 +191409,16 @@ namespace Model
|
||||
|
||||
private string _CreateUser;
|
||||
|
||||
private string _ContractId;
|
||||
|
||||
private System.Nullable<System.DateTime> _OrderInDate;
|
||||
|
||||
private string _OrderCode;
|
||||
|
||||
private System.Nullable<System.DateTime> _OrderOutDate;
|
||||
|
||||
private string _MaterialRequisitionUnit;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
partial void OnValidate(System.Data.Linq.ChangeAction action);
|
||||
@@ -191391,16 +191427,6 @@ namespace Model
|
||||
partial void OnInvoiceIdChanged();
|
||||
partial void OnProjectIdChanging(string value);
|
||||
partial void OnProjectIdChanged();
|
||||
partial void OnContractIdChanging(string value);
|
||||
partial void OnContractIdChanged();
|
||||
partial void OnOrderCodeChanging(string value);
|
||||
partial void OnOrderCodeChanged();
|
||||
partial void OnOrderInDateChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnOrderInDateChanged();
|
||||
partial void OnOrderOutDateChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnOrderOutDateChanged();
|
||||
partial void OnMaterialRequisitionUnitChanging(string value);
|
||||
partial void OnMaterialRequisitionUnitChanged();
|
||||
partial void OnStateChanging(System.Nullable<int> value);
|
||||
partial void OnStateChanged();
|
||||
partial void OnInvoiceCodeChanging(string value);
|
||||
@@ -191429,6 +191455,16 @@ namespace Model
|
||||
partial void OnCreateDateChanged();
|
||||
partial void OnCreateUserChanging(string value);
|
||||
partial void OnCreateUserChanged();
|
||||
partial void OnContractIdChanging(string value);
|
||||
partial void OnContractIdChanged();
|
||||
partial void OnOrderInDateChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnOrderInDateChanged();
|
||||
partial void OnOrderCodeChanging(string value);
|
||||
partial void OnOrderCodeChanged();
|
||||
partial void OnOrderOutDateChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnOrderOutDateChanged();
|
||||
partial void OnMaterialRequisitionUnitChanging(string value);
|
||||
partial void OnMaterialRequisitionUnitChanged();
|
||||
#endregion
|
||||
|
||||
public PHTGL_Invoice()
|
||||
@@ -191476,106 +191512,6 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractId", DbType="NVarChar(50)")]
|
||||
public string ContractId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._ContractId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._ContractId != value))
|
||||
{
|
||||
this.OnContractIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._ContractId = value;
|
||||
this.SendPropertyChanged("ContractId");
|
||||
this.OnContractIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderCode", DbType="NVarChar(50)")]
|
||||
public string OrderCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._OrderCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._OrderCode != value))
|
||||
{
|
||||
this.OnOrderCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._OrderCode = value;
|
||||
this.SendPropertyChanged("OrderCode");
|
||||
this.OnOrderCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderInDate", DbType="Date")]
|
||||
public System.Nullable<System.DateTime> OrderInDate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._OrderInDate;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._OrderInDate != value))
|
||||
{
|
||||
this.OnOrderInDateChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._OrderInDate = value;
|
||||
this.SendPropertyChanged("OrderInDate");
|
||||
this.OnOrderInDateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderOutDate", DbType="Date")]
|
||||
public System.Nullable<System.DateTime> OrderOutDate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._OrderOutDate;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._OrderOutDate != value))
|
||||
{
|
||||
this.OnOrderOutDateChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._OrderOutDate = value;
|
||||
this.SendPropertyChanged("OrderOutDate");
|
||||
this.OnOrderOutDateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialRequisitionUnit", DbType="NVarChar(100)")]
|
||||
public string MaterialRequisitionUnit
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._MaterialRequisitionUnit;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._MaterialRequisitionUnit != value))
|
||||
{
|
||||
this.OnMaterialRequisitionUnitChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._MaterialRequisitionUnit = value;
|
||||
this.SendPropertyChanged("MaterialRequisitionUnit");
|
||||
this.OnMaterialRequisitionUnitChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_State", DbType="Int")]
|
||||
public System.Nullable<int> State
|
||||
{
|
||||
@@ -191856,6 +191792,106 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractId", DbType="NVarChar(50)")]
|
||||
public string ContractId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._ContractId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._ContractId != value))
|
||||
{
|
||||
this.OnContractIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._ContractId = value;
|
||||
this.SendPropertyChanged("ContractId");
|
||||
this.OnContractIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderInDate", DbType="Date")]
|
||||
public System.Nullable<System.DateTime> OrderInDate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._OrderInDate;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._OrderInDate != value))
|
||||
{
|
||||
this.OnOrderInDateChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._OrderInDate = value;
|
||||
this.SendPropertyChanged("OrderInDate");
|
||||
this.OnOrderInDateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderCode", DbType="NVarChar(50)")]
|
||||
public string OrderCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._OrderCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._OrderCode != value))
|
||||
{
|
||||
this.OnOrderCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._OrderCode = value;
|
||||
this.SendPropertyChanged("OrderCode");
|
||||
this.OnOrderCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderOutDate", DbType="Date")]
|
||||
public System.Nullable<System.DateTime> OrderOutDate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._OrderOutDate;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._OrderOutDate != value))
|
||||
{
|
||||
this.OnOrderOutDateChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._OrderOutDate = value;
|
||||
this.SendPropertyChanged("OrderOutDate");
|
||||
this.OnOrderOutDateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialRequisitionUnit", DbType="NVarChar(100)")]
|
||||
public string MaterialRequisitionUnit
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._MaterialRequisitionUnit;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._MaterialRequisitionUnit != value))
|
||||
{
|
||||
this.OnMaterialRequisitionUnitChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._MaterialRequisitionUnit = value;
|
||||
this.SendPropertyChanged("MaterialRequisitionUnit");
|
||||
this.OnMaterialRequisitionUnitChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public event PropertyChangingEventHandler PropertyChanging;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
@@ -287577,159 +287613,6 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.View_HJGL_ProductionSchedulingPlanStatistics")]
|
||||
public partial class View_HJGL_ProductionSchedulingPlanStatistics
|
||||
{
|
||||
|
||||
private string _UnitWorkId;
|
||||
|
||||
private string _UnitWorkCode;
|
||||
|
||||
private string _UnitWorkName;
|
||||
|
||||
private string _ProjectId;
|
||||
|
||||
private string _FlowingSection;
|
||||
|
||||
private string _Material;
|
||||
|
||||
private string _Caliber;
|
||||
|
||||
private decimal _Dia;
|
||||
|
||||
public View_HJGL_ProductionSchedulingPlanStatistics()
|
||||
{
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorkId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string UnitWorkId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._UnitWorkId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._UnitWorkId != value))
|
||||
{
|
||||
this._UnitWorkId = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorkCode", DbType="NVarChar(10)")]
|
||||
public string UnitWorkCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._UnitWorkCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._UnitWorkCode != value))
|
||||
{
|
||||
this._UnitWorkCode = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorkName", DbType="NVarChar(30)")]
|
||||
public string UnitWorkName
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._UnitWorkName;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._UnitWorkName != value))
|
||||
{
|
||||
this._UnitWorkName = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")]
|
||||
public string ProjectId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._ProjectId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._ProjectId != value))
|
||||
{
|
||||
this._ProjectId = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FlowingSection", DbType="NVarChar(200)")]
|
||||
public string FlowingSection
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._FlowingSection;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._FlowingSection != value))
|
||||
{
|
||||
this._FlowingSection = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Material", DbType="VarChar(8)")]
|
||||
public string Material
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Material;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Material != value))
|
||||
{
|
||||
this._Material = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Caliber", DbType="VarChar(5) NOT NULL", CanBeNull=false)]
|
||||
public string Caliber
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Caliber;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Caliber != value))
|
||||
{
|
||||
this._Caliber = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Dia", DbType="Decimal(38,3) NOT NULL")]
|
||||
public decimal Dia
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Dia;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Dia != value))
|
||||
{
|
||||
this._Dia = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.View_HJGL_WeldingTask")]
|
||||
public partial class View_HJGL_WeldingTask
|
||||
{
|
||||
@@ -308652,7 +308535,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(200)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(50)")]
|
||||
public string Name
|
||||
{
|
||||
get
|
||||
@@ -309229,7 +309112,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")]
|
||||
public string PackageContent
|
||||
{
|
||||
get
|
||||
@@ -309420,7 +309303,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")]
|
||||
public string PackageContent
|
||||
{
|
||||
get
|
||||
@@ -313311,6 +313194,8 @@ namespace Model
|
||||
|
||||
private EntitySet<HJGL_Pipeline> _HJGL_Pipeline;
|
||||
|
||||
private EntitySet<HJGL_ProductionSchedulingPlan> _HJGL_ProductionSchedulingPlan;
|
||||
|
||||
private EntitySet<HJGL_RepairRecord> _HJGL_RepairRecord;
|
||||
|
||||
private EntitySet<HJGL_WeldingDaily> _HJGL_WeldingDaily;
|
||||
@@ -313398,6 +313283,7 @@ namespace Model
|
||||
this._HJGL_LV_LeakVacuum = new EntitySet<HJGL_LV_LeakVacuum>(new Action<HJGL_LV_LeakVacuum>(this.attach_HJGL_LV_LeakVacuum), new Action<HJGL_LV_LeakVacuum>(this.detach_HJGL_LV_LeakVacuum));
|
||||
this._HJGL_PC_PurgingCleaning = new EntitySet<HJGL_PC_PurgingCleaning>(new Action<HJGL_PC_PurgingCleaning>(this.attach_HJGL_PC_PurgingCleaning), new Action<HJGL_PC_PurgingCleaning>(this.detach_HJGL_PC_PurgingCleaning));
|
||||
this._HJGL_Pipeline = new EntitySet<HJGL_Pipeline>(new Action<HJGL_Pipeline>(this.attach_HJGL_Pipeline), new Action<HJGL_Pipeline>(this.detach_HJGL_Pipeline));
|
||||
this._HJGL_ProductionSchedulingPlan = new EntitySet<HJGL_ProductionSchedulingPlan>(new Action<HJGL_ProductionSchedulingPlan>(this.attach_HJGL_ProductionSchedulingPlan), new Action<HJGL_ProductionSchedulingPlan>(this.detach_HJGL_ProductionSchedulingPlan));
|
||||
this._HJGL_RepairRecord = new EntitySet<HJGL_RepairRecord>(new Action<HJGL_RepairRecord>(this.attach_HJGL_RepairRecord), new Action<HJGL_RepairRecord>(this.detach_HJGL_RepairRecord));
|
||||
this._HJGL_WeldingDaily = new EntitySet<HJGL_WeldingDaily>(new Action<HJGL_WeldingDaily>(this.attach_HJGL_WeldingDaily), new Action<HJGL_WeldingDaily>(this.detach_HJGL_WeldingDaily));
|
||||
this._ProcessControl_InspectionManagement = new EntitySet<ProcessControl_InspectionManagement>(new Action<ProcessControl_InspectionManagement>(this.attach_ProcessControl_InspectionManagement), new Action<ProcessControl_InspectionManagement>(this.detach_ProcessControl_InspectionManagement));
|
||||
@@ -314048,6 +313934,19 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_ProductionSchedulingPlan_WBS_UnitWork", Storage="_HJGL_ProductionSchedulingPlan", ThisKey="UnitWorkId", OtherKey="PipelineId", DeleteRule="NO ACTION")]
|
||||
public EntitySet<HJGL_ProductionSchedulingPlan> HJGL_ProductionSchedulingPlan
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._HJGL_ProductionSchedulingPlan;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._HJGL_ProductionSchedulingPlan.Assign(value);
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_RepairRecord_WBS_UnitWork", Storage="_HJGL_RepairRecord", ThisKey="UnitWorkId", OtherKey="UnitWorkId", DeleteRule="NO ACTION")]
|
||||
public EntitySet<HJGL_RepairRecord> HJGL_RepairRecord
|
||||
{
|
||||
@@ -314396,6 +314295,18 @@ namespace Model
|
||||
entity.WBS_UnitWork = null;
|
||||
}
|
||||
|
||||
private void attach_HJGL_ProductionSchedulingPlan(HJGL_ProductionSchedulingPlan entity)
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
entity.WBS_UnitWork = this;
|
||||
}
|
||||
|
||||
private void detach_HJGL_ProductionSchedulingPlan(HJGL_ProductionSchedulingPlan entity)
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
entity.WBS_UnitWork = null;
|
||||
}
|
||||
|
||||
private void attach_HJGL_RepairRecord(HJGL_RepairRecord entity)
|
||||
{
|
||||
this.SendPropertyChanging();
|
||||
@@ -314731,7 +314642,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")]
|
||||
public string PackageContent
|
||||
{
|
||||
get
|
||||
@@ -316203,7 +316114,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")]
|
||||
public string PackageContent
|
||||
{
|
||||
get
|
||||
@@ -325754,7 +325665,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractNo", DbType="NVarChar(1500)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractNo", DbType="NVarChar(500)")]
|
||||
public string ContractNo
|
||||
{
|
||||
get
|
||||
@@ -325774,7 +325685,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorks", DbType="NVarChar(1500)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorks", DbType="NVarChar(500)")]
|
||||
public string UnitWorks
|
||||
{
|
||||
get
|
||||
|
||||
Reference in New Issue
Block a user