yl
2023-06-17 5b4fb9c56426b5096555560a44dd365b02853ad4
VueWebApi/Controllers/ReportManagerController.cs
@@ -23,6 +23,7 @@
        /// <summary>
        /// 委外报表记录查询
        /// </summary>
        /// <param name="wkshopcode">车间编码</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
        /// <param name="partname">产品名称</param>
@@ -38,7 +39,7 @@
        /// <returns></returns>
        [Route(template: "OutSourceReportSearch")]
        [HttpGet]
        public HttpResponseMessage OutSourceReportSearch(int page, int rows, string prop, string order, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string suppername = null, string type = null,string receivdate=null)
        public HttpResponseMessage OutSourceReportSearch(int page, int rows, string prop, string order,string wkshopcode=null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string suppername = null, string type = null,string receivdate=null)
        {
            string receivopendate = "";  //收料开始时间
            string receivclosedate = "";    //收料结束时间
@@ -49,7 +50,7 @@
            }
            int startNum = rows * (page - 1) + 1;  //起始记录rowNum
            int endNum = rows * page;   //结束记录 rowNum
            mes = ReportManagerBLL.OutSourceReportSearch(wocode, partcode, partname, partspec, stepname, suppername, type, receivopendate, receivclosedate, startNum, endNum, prop, order);
            mes = ReportManagerBLL.OutSourceReportSearch(wkshopcode,wocode, partcode, partname, partspec, stepname, suppername, type, receivopendate, receivclosedate, startNum, endNum, prop, order);
            return TJson.toJson(mes);
        }
        #endregion
@@ -58,6 +59,7 @@
        /// <summary>
        /// 委外报表记录导出
        /// </summary>
        /// <param name="wkshopcode">车间编码</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
        /// <param name="partname">产品名称</param>
@@ -69,7 +71,7 @@
        /// <returns></returns>
        [Route(template: "OutSourceReportExcelSearch")]
        [HttpGet]
        public HttpResponseMessage OutSourceReportExcelSearch(string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string suppername = null, string type = null, string receivdate = null)
        public HttpResponseMessage OutSourceReportExcelSearch(string wkshopcode = null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string suppername = null, string type = null, string receivdate = null)
        {
            string receivopendate = "";  //收料开始时间
            string receivclosedate = "";    //收料结束时间
@@ -78,7 +80,7 @@
                receivopendate = receivdate.Split('~')[0].ToString();
                receivclosedate = receivdate.Split('~')[1].ToString();
            }
            mes = ReportManagerBLL.OutSourceReportExcelSearch(wocode, partcode, partname, partspec, stepname, suppername, type, receivopendate, receivclosedate);
            mes = ReportManagerBLL.OutSourceReportExcelSearch(wkshopcode,wocode, partcode, partname, partspec, stepname, suppername, type, receivopendate, receivclosedate);
            return TJson.toJson(mes);
        }
        #endregion
@@ -89,6 +91,7 @@
        /// <summary>
        /// 班组工资报表记录查询
        /// </summary>
        /// <param name=" wkshopcode">车间编码</param>
        /// <param name="compute">计算方式(逐道/末道)</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
@@ -106,7 +109,7 @@
        /// <returns></returns>
        [Route(template: "GroupSalaryReportSearch")]
        [HttpGet]
        public HttpResponseMessage GroupSalaryReportSearch(int page, int rows, string prop, string order,string compute, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string username = null, string operdate = null,string rejectstepcode=null)
        public HttpResponseMessage GroupSalaryReportSearch(int page, int rows, string prop, string order, string compute, string wkshopcode = null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string username = null, string operdate = null,string rejectstepcode=null)
        {
            string operopendate = "";  //报工开始时间
            string operclosedate = "";    //报工结束时间
@@ -117,7 +120,7 @@
            }
            int startNum = rows * (page - 1) + 1;  //起始记录rowNum
            int endNum = rows * page;   //结束记录 rowNum
            mes = ReportManagerBLL.GroupSalaryReportSearch(compute,wocode, partcode, partname, partspec, stepname, groupcode, username, operopendate, operclosedate, rejectstepcode, startNum, endNum, prop, order);
            mes = ReportManagerBLL.GroupSalaryReportSearch(wkshopcode,compute, wocode, partcode, partname, partspec, stepname, groupcode, username, operopendate, operclosedate, rejectstepcode, startNum, endNum, prop, order);
            return TJson.toJson(mes);
        }
        #endregion
@@ -141,6 +144,7 @@
        /// <summary>
        /// 班组工资报表记录查询
        /// </summary>
        /// <param name=" wkshopcode">车间编码</param>
        /// <param name="compute">计算方式(逐道/末道)</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
@@ -154,7 +158,7 @@
        /// <returns></returns>
        [Route(template: "GroupSalaryReportExcelSearch")]
        [HttpGet]
        public HttpResponseMessage GroupSalaryReportExcelSearch(string compute, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string username = null, string operdate = null,string rejectstepcode=null)
        public HttpResponseMessage GroupSalaryReportExcelSearch(string compute, string wkshopcode = null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string username = null, string operdate = null,string rejectstepcode=null)
        {
            string operopendate = "";  //报工开始时间
            string operclosedate = "";    //报工结束时间
@@ -163,7 +167,7 @@
                operopendate = operdate.Split('~')[0].ToString();
                operclosedate = operdate.Split('~')[1].ToString();
            }
            mes = ReportManagerBLL.GroupSalaryReportExcelSearch(compute,wocode, partcode, partname, partspec, stepname, groupcode, username, operopendate, operclosedate, rejectstepcode);
            mes = ReportManagerBLL.GroupSalaryReportExcelSearch(wkshopcode,compute, wocode, partcode, partname, partspec, stepname, groupcode, username, operopendate, operclosedate, rejectstepcode);
            return TJson.toJson(mes);
        }
        #endregion
@@ -173,6 +177,7 @@
        /// <summary>
        /// 人员工资明细报表
        /// </summary>
        /// <param name=" wkshopcode">车间编码</param>
        /// <param name="compute">计算方式(逐道/末道)</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
@@ -190,7 +195,7 @@
        /// <returns></returns>
        [Route(template: "PeopleSalaryReportSearch")]
        [HttpGet]
        public HttpResponseMessage PeopleSalaryReportSearch(int page, int rows, string prop, string order,string compute, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string reportname = null, string reportdate = null,string rejectstepcode=null)
        public HttpResponseMessage PeopleSalaryReportSearch(int page, int rows, string prop, string order,string compute, string wkshopcode = null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string reportname = null, string reportdate = null,string rejectstepcode=null)
        {
            string reportopendate = "";  //报工开始时间
            string reportclosedate = "";    //报工结束时间
@@ -201,7 +206,7 @@
            }
            int startNum = rows * (page - 1) + 1;  //起始记录rowNum
            int endNum = rows * page;   //结束记录 rowNum
            mes = ReportManagerBLL.PeopleSalaryReportSearch(compute,wocode, partcode, partname, partspec, stepname, groupcode, reportname, reportopendate, reportclosedate, rejectstepcode, startNum, endNum, prop, order);
            mes = ReportManagerBLL.PeopleSalaryReportSearch(wkshopcode,compute, wocode, partcode, partname, partspec, stepname, groupcode, reportname, reportopendate, reportclosedate, rejectstepcode, startNum, endNum, prop, order);
            return TJson.toJson(mes);
        }
        #endregion
@@ -210,6 +215,7 @@
        /// <summary>
        /// 人员工资明细报表导出
        /// </summary>
        /// <param name=" wkshopcode">车间编码</param>
        /// <param name="compute">计算方式(逐道/末道)</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
@@ -223,7 +229,7 @@
        /// <returns></returns>
        [Route(template: "PeopleSalaryReportExcelSearch")]
        [HttpGet]
        public HttpResponseMessage PeopleSalaryReportExcelSearch(string compute, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string reportname = null, string reportdate = null,string rejectstepcode=null)
        public HttpResponseMessage PeopleSalaryReportExcelSearch(string compute, string wkshopcode = null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string groupcode = null, string reportname = null, string reportdate = null,string rejectstepcode=null)
        {
            string reportopendate = "";  //报工开始时间
            string reportclosedate = "";    //报工结束时间
@@ -232,7 +238,7 @@
                reportopendate = reportdate.Split('~')[0].ToString();
                reportclosedate = reportdate.Split('~')[1].ToString();
            }
            mes = ReportManagerBLL.PeopleSalaryReportExcelSearch(compute,wocode, partcode, partname, partspec, stepname, groupcode, reportname, reportopendate, reportclosedate, rejectstepcode);
            mes = ReportManagerBLL.PeopleSalaryReportExcelSearch(wkshopcode,compute, wocode, partcode, partname, partspec, stepname, groupcode, reportname, reportopendate, reportclosedate, rejectstepcode);
            return TJson.toJson(mes);
        }
        #endregion
@@ -242,6 +248,7 @@
        /// <summary>
        /// 不良明细报表 
        /// </summary>
        /// <param name=" wkshopcode">车间编码</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
        /// <param name="partname">产品名称</param>
@@ -258,7 +265,7 @@
        /// <returns></returns>
        [Route(template: "DefectDetailsReportSearch")]
        [HttpGet]
        public HttpResponseMessage DefectDetailsReportSearch(int page, int rows, string prop, string order, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null,string defectcode=null,string defectname=null, string reportname = null, string reportdate = null)
        public HttpResponseMessage DefectDetailsReportSearch(int page, int rows, string prop, string order,string wkshopcode=null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null,string defectcode=null,string defectname=null, string reportname = null, string reportdate = null)
        {
            string reportopendate = "";  //报工开始时间
            string reportclosedate = "";    //报工结束时间
@@ -269,7 +276,7 @@
            }
            int startNum = rows * (page - 1) + 1;  //起始记录rowNum
            int endNum = rows * page;   //结束记录 rowNum
            mes = ReportManagerBLL.DefectDetailsReportSearch(wocode, partcode, partname, partspec, stepname, defectcode, defectname, reportname, reportopendate, reportclosedate, startNum, endNum, prop, order);
            mes = ReportManagerBLL.DefectDetailsReportSearch(wkshopcode,wocode, partcode, partname, partspec, stepname, defectcode, defectname, reportname, reportopendate, reportclosedate, startNum, endNum, prop, order);
            return TJson.toJson(mes);
        }
        #endregion
@@ -278,6 +285,7 @@
        /// <summary>
        /// 不良明细报表导出 
        /// </summary>
        /// <param name=" wkshopcode">车间编码</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
        /// <param name="partname">产品名称</param>
@@ -290,7 +298,7 @@
        /// <returns></returns>
        [Route(template: "DefectDetailsReportExcelSearch")]
        [HttpGet]
        public HttpResponseMessage DefectDetailsReportExcelSearch(string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string defectcode = null, string defectname = null, string reportname = null, string reportdate = null)
        public HttpResponseMessage DefectDetailsReportExcelSearch(string wkshopcode=null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string defectcode = null, string defectname = null, string reportname = null, string reportdate = null)
        {
            string reportopendate = "";  //报工开始时间
            string reportclosedate = "";    //报工结束时间
@@ -299,7 +307,7 @@
                reportopendate = reportdate.Split('~')[0].ToString();
                reportclosedate = reportdate.Split('~')[1].ToString();
            }
            mes = ReportManagerBLL.DefectDetailsReportExcelSearch(wocode, partcode, partname, partspec, stepname, defectcode, defectname, reportname, reportopendate, reportclosedate);
            mes = ReportManagerBLL.DefectDetailsReportExcelSearch(wkshopcode,wocode, partcode, partname, partspec, stepname, defectcode, defectname, reportname, reportopendate, reportclosedate);
            return TJson.toJson(mes);
        }
        #endregion
@@ -324,6 +332,7 @@
        /// <summary>
        /// 维修明细报表 
        /// </summary>
        /// <param name="wkshopcode">车间编号</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
        /// <param name="partname">产品名称</param>
@@ -340,7 +349,7 @@
        /// <returns></returns>
        [Route(template: "MaintenanceDetailsReportSearch")]
        [HttpGet]
        public HttpResponseMessage MaintenanceDetailsReportSearch(int page, int rows, string prop, string order, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string style = null, string defectname = null, string repairname = null, string repairdate = null)
        public HttpResponseMessage MaintenanceDetailsReportSearch(int page, int rows, string prop, string order,string wkshopcode=null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string style = null, string defectname = null, string repairname = null, string repairdate = null)
        {
            string repairopendate = "";  //维修开始时间
            string repairclosedate = "";    //维修结束时间
@@ -351,7 +360,7 @@
            }
            int startNum = rows * (page - 1) + 1;  //起始记录rowNum
            int endNum = rows * page;   //结束记录 rowNum
            mes = ReportManagerBLL.MaintenanceDetailsReportSearch(wocode, partcode, partname, partspec, stepname, style, defectname, repairname, repairopendate, repairclosedate, startNum, endNum, prop, order);
            mes = ReportManagerBLL.MaintenanceDetailsReportSearch(wkshopcode,wocode, partcode, partname, partspec, stepname, style, defectname, repairname, repairopendate, repairclosedate, startNum, endNum, prop, order);
            return TJson.toJson(mes);
        }
        #endregion
@@ -360,6 +369,7 @@
        /// <summary>
        /// 维修明细报表导出 
        /// </summary>
        /// <param name="wkshopcode">车间编号</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="partcode">产品编码</param>
        /// <param name="partname">产品名称</param>
@@ -372,7 +382,7 @@
        /// <returns></returns>
        [Route(template: "MaintenanceDetailsReportExcelSearch")]
        [HttpGet]
        public HttpResponseMessage MaintenanceDetailsReportExcelSearch(string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string style = null, string defectname = null, string repairname = null, string repairdate = null)
        public HttpResponseMessage MaintenanceDetailsReportExcelSearch(string wkshopcode = null, string wocode = null, string partcode = null, string partname = null, string partspec = null, string stepname = null, string style = null, string defectname = null, string repairname = null, string repairdate = null)
        {
            string repairopendate = "";  //维修开始时间
            string repairclosedate = "";    //维修结束时间
@@ -381,7 +391,7 @@
                repairopendate = repairdate.Split('~')[0].ToString();
                repairclosedate = repairdate.Split('~')[1].ToString();
            }
            mes = ReportManagerBLL.MaintenanceDetailsReportExcelSearch(wocode, partcode, partname, partspec, stepname, style, defectname, repairname, repairopendate, repairclosedate);
            mes = ReportManagerBLL.MaintenanceDetailsReportExcelSearch(wkshopcode,wocode, partcode, partname, partspec, stepname, style, defectname, repairname, repairopendate, repairclosedate);
            return TJson.toJson(mes);
        }
        #endregion
@@ -596,6 +606,7 @@
        /// <summary>
        /// 生产进度报表
        /// </summary>
        /// <param name="wkshopcode">车间编码</param>
        /// <param name="status">工单状态</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="routecode">工艺路线编码</param>
@@ -611,7 +622,7 @@
        /// <returns></returns>
        [Route(template: "ProductionScheduleReportSearch")]
        [HttpGet]
        public HttpResponseMessage ProductionScheduleReportSearch(int page, int rows, string prop, string order,string status=null, string wocode = null, string routecode = null, string routename = null, string partcode = null, string partname = null, string partspec = null,string lm_date=null)
        public HttpResponseMessage ProductionScheduleReportSearch(int page, int rows, string prop, string order, string wkshopcode=null, string status=null, string wocode = null, string routecode = null, string routename = null, string partcode = null, string partname = null, string partspec = null,string lm_date=null)
        {
            string opendate = "";     //开始时间
            string closedate = "";    //结束时间
@@ -622,7 +633,7 @@
            }
            int startNum = rows * (page - 1) + 1;  //起始记录rowNum
            int endNum = rows * page;   //结束记录 rowNum
            mes = ReportManagerBLL.ProductionScheduleReportSearch(status,wocode, routecode, routename, partcode, partname, partspec, opendate, closedate, startNum, endNum, prop, order);
            mes = ReportManagerBLL.ProductionScheduleReportSearch(wkshopcode,status, wocode, routecode, routename, partcode, partname, partspec, opendate, closedate, startNum, endNum, prop, order);
            return TJson.toJson(mes);
        }
        #endregion
@@ -631,6 +642,7 @@
        /// <summary>
        /// 生产进度报表导出
        /// </summary>
        /// <param name="wkshopcode">车间编码</param>
        /// <param name="status">工单状态</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="routecode">工艺路线编码</param>
@@ -642,7 +654,7 @@
        /// <returns></returns>
        [Route(template: "ProductionScheduleReportExcelSearch")]
        [HttpGet]
        public HttpResponseMessage ProductionScheduleReportExcelSearch(string status = null, string wocode = null, string routecode = null, string routename = null, string partcode = null, string partname = null, string partspec = null, string lm_date = null)
        public HttpResponseMessage ProductionScheduleReportExcelSearch(string wkshopcode=null, string status = null, string wocode = null, string routecode = null, string routename = null, string partcode = null, string partname = null, string partspec = null, string lm_date = null)
        {
            string opendate = "";     //开始时间
            string closedate = "";    //结束时间
@@ -651,7 +663,7 @@
                opendate = lm_date.Split('~')[0].ToString();
                closedate = lm_date.Split('~')[1].ToString();
            }
            mes = ReportManagerBLL.ProductionScheduleReportExcelSearch(status,wocode, routecode, routename, partcode, partname, partspec, opendate, closedate);
            mes = ReportManagerBLL.ProductionScheduleReportExcelSearch(wkshopcode,status, wocode, routecode, routename, partcode, partname, partspec, opendate, closedate);
            return TJson.toJson(mes);
        }
        #endregion