20250408
This commit is contained in:
commit
ddeee081aa
|
@ -19,3 +19,5 @@ bin-release/
|
|||
/HJGL_DS/FineUIPro.Web/FileUpload/HJGL/HotProessManage
|
||||
/HJGL_DS/FineUIPro.Web/FileUploadHJGLHotProessManage
|
||||
/HJGL_DS/FineUIPro.Web/File/Excel
|
||||
/HJGL_DS/.vs/
|
||||
/HJGL_DS/.vs/config/applicationhost.config
|
|
@ -0,0 +1,132 @@
|
|||
|
||||
ALTER PROC [dbo].[HJGL_sp_rpt_welderPerformance]
|
||||
@unitcode VARCHAR(50) = NULL,
|
||||
@steel VARCHAR(50) = NULL,
|
||||
@WED_ID NVARCHAR(50) = NULL,
|
||||
@date1 DATETIME = NULL,
|
||||
@date2 DATETIME = NULL,
|
||||
@projectId NVARCHAR(500) = NULL,
|
||||
@installationId NVARCHAR(50)=NULL
|
||||
AS
|
||||
/*焊工业绩分析*/
|
||||
SELECT
|
||||
NEWID() AS Id,
|
||||
total.ProjectId,
|
||||
project.ProjectCode,--施工号
|
||||
total.Welder,
|
||||
wld.wed_code,-- 焊工代码
|
||||
wld.wed_name,--焊工名称
|
||||
wld.WED_Sex, --性别
|
||||
-------------本期start
|
||||
CAST(ISNULL(total.totalSize,0) AS DECIMAL(19,2)) AS totalSize, --总寸径
|
||||
ISNULL(total.totalJoint,0) AS totalJoint, --总焊口
|
||||
ISNULL(JointNum1.JointNum1,0) AS JointNum1, --一次拍片焊口数
|
||||
|
||||
ISNULL(JointNum1.JointNum1,0)-ISNULL(JointNoPassNum1.JointNoPassNum1,0) AS JointPassNum1, --一次拍片合格焊口数
|
||||
ISNULL(JointNoPassNum1.JointNoPassNum1,0) AS RepairJoint1, --一次返修焊口数
|
||||
ISNULL(RepairJoint2.RepairJoint2,0) AS RepairJoint2, --二次返修焊口数
|
||||
ISNULL(RepairJoint3.RepairJoint3,0) AS RepairJoint3, --三次返修焊口数
|
||||
|
||||
CAST((CASE ISNULL((ISNULL(JointNum1.JointNum1,0)-ISNULL(JointNoPassNum1.JointNoPassNum1,0)),0) WHEN 0 THEN 0
|
||||
ELSE (CASE(ISNULL(JointNum1.JointNum1,0)) WHEN 0 THEN 0
|
||||
ELSE 1.0 * ISNULL((ISNULL(JointNum1.JointNum1,0)-ISNULL(JointNoPassNum1.JointNoPassNum1,0)),0)/(1.0 * JointNum1.JointNum1)
|
||||
END)END) AS DECIMAL(19,3)) AS JointPassRate , ---一次拍片焊口合格率
|
||||
|
||||
ISNULL(JointNum1.totalfilm,0) AS totalfilm, --一次拍片数
|
||||
(ISNULL(JointNum1.totalfilm,0)- ISNULL(JointNoPassNum1.JointNoPassFilmNum1,0)) AS totalPassfilm, --一次拍片合格数
|
||||
ISNULL(JointNoPassNum1.JointNoPassFilmNum1,0) AS repairFilm1, --一次返修片子数
|
||||
|
||||
ISNULL(RepairJoint2.repairFilm2,0) AS repairFilm2, --二次返修片子数
|
||||
ISNULL(RepairJoint3.repairFilm3,0) AS repairFilm3, --三次返修片子数
|
||||
|
||||
CAST((CASE (ISNULL(JointNum1.totalfilm,0)- ISNULL(JointNoPassNum1.JointNoPassFilmNum1,0)) WHEN 0 THEN 0
|
||||
ELSE (CASE(ISNULL(JointNum1.totalfilm,0)) WHEN 0 THEN 0
|
||||
ELSE 1.0 * (ISNULL(JointNum1.totalfilm,0)- ISNULL(JointNoPassNum1.JointNoPassFilmNum1,0))/(1.0 * JointNum1.totalfilm)
|
||||
END) END) AS DECIMAL(19,3)) AS JointFilmPassRate ---一次拍片合格率
|
||||
|
||||
FROM
|
||||
--总达因值 --总焊口
|
||||
(SELECT SUM(joint.JOT_Size) AS totalSize,COUNT(*) AS totalJoint
|
||||
,joint.ProjectId,joint.InstallationId,joint.BSU_ID,joint.Welder
|
||||
FROM View_JointWelder joint
|
||||
LEFT JOIN HJGL_BO_WeldReportMain report ON joint.DReportID = report.DReportID
|
||||
WHERE joint.DReportID IS NOT NULL
|
||||
AND (report.JOT_WeldDate >= @date1 OR @date1 IS NULL) AND (report.JOT_WeldDate <= @date2 OR @date2 IS NULL)
|
||||
AND (joint.ste_id=@steel OR @steel IS NULL)
|
||||
GROUP BY joint.ProjectId,joint.InstallationId,joint.BSU_ID, joint.Welder) AS total
|
||||
|
||||
|
||||
--一次拍片焊口数 , 一次拍片总数,一次拍片合格总数
|
||||
LEFT JOIN (SELECT COUNT(joint.JOT_ID) AS JointNum1, SUM(joint.RT_FilmNum) AS totalfilm,
|
||||
joint.ProjectId,joint.InstallationId,joint.BSU_ID,joint.Welder
|
||||
FROM dbo.View_JointWelder joint
|
||||
WHERE joint.PointType='点口' AND joint.RT_FilmNum IS NOT NULL and joint.RT_FilmNum>0 and (select COUNT(*) from dbo.HJGL_BO_QualityRating where JOT_ID=joint.JOT_ID and FilmNum is not null)>0
|
||||
AND (joint.ste_id=@steel OR @steel IS NULL) AND joint.dreportid IS NOT NULL
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_BO_QualityRating WHERE JOT_ID=joint.JOT_ID)>= @date1 OR @date1 IS NULL)
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_BO_QualityRating WHERE JOT_ID=joint.JOT_ID)<= @date2 OR @date2 IS NULL)
|
||||
GROUP BY joint.ProjectId,joint.InstallationId,joint.BSU_ID, joint.Welder) AS JointNum1
|
||||
ON JointNum1.ProjectId=total.ProjectId AND JointNum1.InstallationId = total.InstallationId
|
||||
AND JointNum1.BSU_ID = total.BSU_ID AND JointNum1.Welder = total.Welder
|
||||
|
||||
--一次拍片不合格焊口数
|
||||
LEFT JOIN (SELECT COUNT(distinct joint.JOT_ID) AS JointNoPassNum1,count(rr.RepairItemRecordId) as JointNoPassFilmNum1,
|
||||
joint.ProjectId,joint.InstallationId,joint.BSU_ID,joint.Welder
|
||||
FROM dbo.View_JointWelder joint
|
||||
left join dbo.HJGL_CH_RepairItemRecord rr on rr.JOT_ID=joint.JOT_ID
|
||||
WHERE joint.PointType='点口' AND (joint.RT1_RepairFilm IS NOT NULL or (select top 1 CH_TrustItemID from dbo.HJGL_CH_TrustItem ti where ti.JOT_ID=joint.JOT_ID and ti.States='4') is not null)
|
||||
AND (joint.ste_id=@steel OR @steel IS NULL) AND joint.dreportid IS NOT NULL and rr.RepairMark='R1'
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_CH_RepairItemRecord WHERE JOT_ID=joint.JOT_ID AND RepairMark='R1')>= @date1 OR @date1 IS NULL)
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_CH_RepairItemRecord WHERE JOT_ID=joint.JOT_ID AND RepairMark='R1')<= @date2 OR @date2 IS NULL)
|
||||
GROUP BY joint.ProjectId,joint.InstallationId,joint.BSU_ID, joint.Welder) AS JointNoPassNum1
|
||||
ON JointNoPassNum1.ProjectId=total.ProjectId AND JointNoPassNum1.InstallationId = total.InstallationId
|
||||
AND JointNoPassNum1.BSU_ID = total.BSU_ID AND JointNoPassNum1.Welder = total.Welder
|
||||
|
||||
--二次返修拍片焊口数,二次返修拍片总数
|
||||
LEFT JOIN (SELECT COUNT(joint.JOT_ID) AS RepairJoint2, SUM(ISNULL(joint.RT2_RepairFilmNum,0)) AS RepairFilm2,
|
||||
joint.ProjectId,joint.InstallationId,joint.BSU_ID,joint.Welder
|
||||
FROM dbo.View_JointWelder joint
|
||||
WHERE joint.PointType='点口' AND joint.RT2_RepairFilm IS NOT NULL
|
||||
AND (joint.ste_id=@steel OR @steel IS NULL) AND joint.dreportid IS NOT NULL
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_CH_RepairItemRecord WHERE JOT_ID=joint.JOT_ID AND RepairMark='R2')>= @date1 OR @date1 IS NULL)
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_CH_RepairItemRecord WHERE JOT_ID=joint.JOT_ID AND RepairMark='R2')<= @date2 OR @date2 IS NULL)
|
||||
GROUP BY joint.ProjectId,joint.InstallationId,joint.BSU_ID, joint.Welder) AS RepairJoint2
|
||||
ON RepairJoint2.ProjectId=total.ProjectId AND RepairJoint2.InstallationId = total.InstallationId
|
||||
AND RepairJoint2.BSU_ID = total.BSU_ID AND RepairJoint2.Welder = total.Welder
|
||||
|
||||
|
||||
|
||||
--三次返修拍片焊口数,三次返修拍片总数
|
||||
LEFT JOIN (SELECT COUNT(joint.JOT_ID) AS RepairJoint3, SUM(ISNULL(joint.RT3_RepairFilmNum,0)) AS RepairFilm3,
|
||||
joint.ProjectId,joint.InstallationId,joint.BSU_ID,joint.Welder
|
||||
FROM dbo.View_JointWelder joint
|
||||
WHERE joint.PointType='点口' AND joint.RT3_RepairFilm IS NOT NULL
|
||||
AND (joint.ste_id=@steel OR @steel IS NULL) AND joint.dreportid IS NOT NULL
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_CH_RepairItemRecord WHERE JOT_ID=joint.JOT_ID AND RepairMark='R3')>= @date1 OR @date1 IS NULL)
|
||||
AND ((SELECT TOP 1 SignDate FROM dbo.HJGL_CH_RepairItemRecord WHERE JOT_ID=joint.JOT_ID AND RepairMark='R3')<= @date2 OR @date2 IS NULL)
|
||||
GROUP BY joint.ProjectId,joint.InstallationId,joint.BSU_ID, joint.Welder) AS RepairJoint3
|
||||
ON RepairJoint3.ProjectId=total.ProjectId AND RepairJoint3.InstallationId = total.InstallationId
|
||||
AND RepairJoint3.BSU_ID = total.BSU_ID AND RepairJoint3.Welder = total.Welder
|
||||
|
||||
LEFT JOIN Base_Project project ON total.ProjectId=project.ProjectId
|
||||
LEFT JOIN dbo.HJGL_BS_Welder wld ON wld.WED_ID=total.Welder
|
||||
|
||||
WHERE
|
||||
(CHARINDEX(total.ProjectId,@projectId)>0 OR @projectId IS NULL)
|
||||
AND (total.InstallationId = @installationId OR @installationId IS NULL)
|
||||
AND (wld.WED_Unit=@unitcode OR @unitcode IS NULL)
|
||||
AND (total.Welder = @WED_ID OR @WED_ID IS NULL)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
GO
|
||||
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,41 +0,0 @@
|
|||
{
|
||||
"Version": 1,
|
||||
"WorkspaceRootPath": "E:\\\u9F0E\u76DB\\HJGL_DS\\HJGL_DS\\",
|
||||
"Documents": [
|
||||
{
|
||||
"AbsoluteMoniker": "D:0:0:{C88D3156-2D56-4DB0-922E-1995FB61C9BD}|FineUIPro.Web\\FineUIPro.Web.csproj|e:\\\u9F0E\u76DB\\hjgl_ds\\hjgl_ds\\fineuipro.web\\web.config||{FA3CD31E-987B-443A-9B81-186104E8DAC1}|",
|
||||
"RelativeMoniker": "D:0:0:{C88D3156-2D56-4DB0-922E-1995FB61C9BD}|FineUIPro.Web\\FineUIPro.Web.csproj|solutionrelative:fineuipro.web\\web.config||{FA3CD31E-987B-443A-9B81-186104E8DAC1}|"
|
||||
}
|
||||
],
|
||||
"DocumentGroupContainers": [
|
||||
{
|
||||
"Orientation": 0,
|
||||
"VerticalTabListWidth": 256,
|
||||
"DocumentGroups": [
|
||||
{
|
||||
"DockedWidth": 200,
|
||||
"SelectedChildIndex": 1,
|
||||
"Children": [
|
||||
{
|
||||
"$type": "Bookmark",
|
||||
"Name": "ST:0:0:{6324226f-61b6-4f28-92ee-18d4b5fe1e48}"
|
||||
},
|
||||
{
|
||||
"$type": "Document",
|
||||
"DocumentIndex": 0,
|
||||
"Title": "Web.config",
|
||||
"DocumentMoniker": "E:\\\u9F0E\u76DB\\HJGL_DS\\HJGL_DS\\FineUIPro.Web\\Web.config",
|
||||
"RelativeDocumentMoniker": "FineUIPro.Web\\Web.config",
|
||||
"ToolTip": "E:\\\u9F0E\u76DB\\HJGL_DS\\HJGL_DS\\FineUIPro.Web\\Web.config",
|
||||
"RelativeToolTip": "FineUIPro.Web\\Web.config",
|
||||
"ViewState": "AgIAACcAAAAAAAAAAADwvzQAAAAdAAAAAAAAAA==",
|
||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000601|",
|
||||
"WhenOpened": "2025-03-02T06:37:41.196Z",
|
||||
"EditorCaption": ""
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
|
@ -1,41 +0,0 @@
|
|||
{
|
||||
"Version": 1,
|
||||
"WorkspaceRootPath": "E:\\\u9F0E\u76DB\\HJGL_DS\\HJGL_DS\\",
|
||||
"Documents": [
|
||||
{
|
||||
"AbsoluteMoniker": "D:0:0:{C88D3156-2D56-4DB0-922E-1995FB61C9BD}|FineUIPro.Web\\FineUIPro.Web.csproj|e:\\\u9F0E\u76DB\\hjgl_ds\\hjgl_ds\\fineuipro.web\\web.config||{FA3CD31E-987B-443A-9B81-186104E8DAC1}|",
|
||||
"RelativeMoniker": "D:0:0:{C88D3156-2D56-4DB0-922E-1995FB61C9BD}|FineUIPro.Web\\FineUIPro.Web.csproj|solutionrelative:fineuipro.web\\web.config||{FA3CD31E-987B-443A-9B81-186104E8DAC1}|"
|
||||
}
|
||||
],
|
||||
"DocumentGroupContainers": [
|
||||
{
|
||||
"Orientation": 0,
|
||||
"VerticalTabListWidth": 256,
|
||||
"DocumentGroups": [
|
||||
{
|
||||
"DockedWidth": 200,
|
||||
"SelectedChildIndex": 1,
|
||||
"Children": [
|
||||
{
|
||||
"$type": "Bookmark",
|
||||
"Name": "ST:0:0:{6324226f-61b6-4f28-92ee-18d4b5fe1e48}"
|
||||
},
|
||||
{
|
||||
"$type": "Document",
|
||||
"DocumentIndex": 0,
|
||||
"Title": "Web.config",
|
||||
"DocumentMoniker": "E:\\\u9F0E\u76DB\\HJGL_DS\\HJGL_DS\\FineUIPro.Web\\Web.config",
|
||||
"RelativeDocumentMoniker": "FineUIPro.Web\\Web.config",
|
||||
"ToolTip": "E:\\\u9F0E\u76DB\\HJGL_DS\\HJGL_DS\\FineUIPro.Web\\Web.config",
|
||||
"RelativeToolTip": "FineUIPro.Web\\Web.config",
|
||||
"ViewState": "AgIAACcAAAAAAAAAAADwvzQAAAAdAAAAAAAAAA==",
|
||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000601|",
|
||||
"WhenOpened": "2025-03-02T06:37:41.196Z",
|
||||
"EditorCaption": ""
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
Binary file not shown.
File diff suppressed because it is too large
Load Diff
|
@ -50,7 +50,7 @@
|
|||
<add path="ChartImg.axd" verb="GET,POST,HEAD" type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler, System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
|
||||
<add path="FastReport.Export.axd" verb="*" type="FastReport.Web.Handlers.WebExport"/>
|
||||
</httpHandlers>
|
||||
<compilation debug="false" targetFramework="4.6.1">
|
||||
<compilation debug="true" targetFramework="4.6.1">
|
||||
<assemblies>
|
||||
<add assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
|
||||
</assemblies>
|
||||
|
|
Loading…
Reference in New Issue