| | |
| | | /// <summary> |
| | | /// 工序检验标准新增、编辑获取检验项目下拉列表 |
| | | /// </summary> |
| | | /// <param name="WorkShop">车间编码</param> |
| | | /// <returns></returns> |
| | | [Route(template: "StepCheckItemSelect")] |
| | | [HttpGet] |
| | | public HttpResponseMessage StepCheckItemSelect() |
| | | public HttpResponseMessage StepCheckItemSelect(string WorkShop) |
| | | { |
| | | mes = QualityManagementBLL.StepCheckItemSelect(); |
| | | mes = QualityManagementBLL.StepCheckItemSelect(WorkShop); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | [HttpGet] |
| | | public HttpResponseMessage StepCheckItemSearch(string itemcode = null, string itemname = null, string itemdescr = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | var stu_torgcode = HttpContext.Current.Request.Cookies["stu_torgcode"].Value.ToString(); //所属组织 |
| | | var stu_torgtypecode = HttpContext.Current.Request.Cookies["description"].Value.ToString(); //所属组织类型 |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = QualityManagementBLL.StepCheckItemSearch(itemcode, itemname, itemdescr, startNum, endNum, prop, order); |
| | | mes = QualityManagementBLL.StepCheckItemSearch(stu_torgcode, stu_torgtypecode,itemcode, itemname, itemdescr, startNum, endNum, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | [HttpPost] |
| | | public HttpResponseMessage AddUpdateStepCheckItem([FromBody] JObject obj) |
| | | { |
| | | string wkshopcode = obj["wkshopcode"].ToString(); //车间编码 |
| | | string checkitemcode = obj["checkitemcode"].ToString(); //工序检验项目代码 |
| | | string checkitemname = obj["checkitemname"].ToString(); //工序检验项目名称 |
| | | string checkitemdescr = obj["checkitemdescr"].ToString(); //工序检验项目描述 |
| | | string opertype = obj["OperType"].ToString(); //操作类型 |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //操作人员 |
| | | mes = QualityManagementBLL.AddUpdateStepCheckItem(checkitemcode, checkitemname, checkitemdescr, opertype, username); |
| | | mes = QualityManagementBLL.AddUpdateStepCheckItem(wkshopcode,checkitemcode, checkitemname, checkitemdescr, opertype, username); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | [HttpGet] |
| | | public HttpResponseMessage StepCheckTableSearch(string wocode = null, string partcode = null, string partname = null, string partapec = null, string stepname = null,string standname=null, string checktype = null, string checkresult = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | var stu_torgcode = HttpContext.Current.Request.Cookies["stu_torgcode"].Value.ToString(); //所属组织 |
| | | var stu_torgtypecode = HttpContext.Current.Request.Cookies["description"].Value.ToString(); //所属组织类型 |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = QualityManagementBLL.StepCheckTableSearch(wocode, partcode, partname,partapec,stepname,standname,checktype,checkresult, startNum, endNum, prop, order); |
| | | mes = QualityManagementBLL.StepCheckTableSearch(stu_torgcode, stu_torgtypecode,wocode, partcode, partname,partapec,stepname,standname,checktype,checkresult, startNum, endNum, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | [HttpGet] |
| | | public HttpResponseMessage StepCheckTableOutExcel(string wocode = null, string partcode = null, string partname = null, string partapec = null, string stepname = null, string standname = null, string checktype = null, string checkresult = null,string prop = null, string order = null) |
| | | { |
| | | mes = QualityManagementBLL.StepCheckTableOutExcel(wocode, partcode, partname, partapec, stepname, standname, checktype, checkresult, prop, order); |
| | | var stu_torgcode = HttpContext.Current.Request.Cookies["stu_torgcode"].Value.ToString(); //所属组织 |
| | | var stu_torgtypecode = HttpContext.Current.Request.Cookies["description"].Value.ToString(); //所属组织类型 |
| | | mes = QualityManagementBLL.StepCheckTableOutExcel(stu_torgcode, stu_torgtypecode, wocode, partcode, partname, partapec, stepname, standname, checktype, checkresult, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | [HttpGet] |
| | | public HttpResponseMessage QualityInspectionSearch(string qualityinsptcode = null, string qualityinsptname = null, string status=null, string checktype=null,string sampltype=null,string suitobject = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | var stu_torgcode = HttpContext.Current.Request.Cookies["stu_torgcode"].Value.ToString(); //所属组织 |
| | | var stu_torgtypecode = HttpContext.Current.Request.Cookies["description"].Value.ToString(); //所属组织类型 |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = QualityManagementBLL.QualityInspectionSearch(qualityinsptcode, qualityinsptname, status, checktype, sampltype, suitobject, startNum, endNum, prop, order); |
| | | mes = QualityManagementBLL.QualityInspectionSearch(stu_torgcode, stu_torgtypecode,qualityinsptcode, qualityinsptname, status, checktype, sampltype, suitobject, startNum, endNum, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | [HttpPost] |
| | | public HttpResponseMessage QualityInspectionAddEditSave([FromBody] JObject obj) |
| | | { |
| | | string wkshopcode= obj["wkshopcode"].ToString(); //车间编码 |
| | | string qualityinsptcode = obj["qualityinsptcode"].ToString(); //质检方案编码 |
| | | string qualityinsptname = obj["qualityinsptname"].ToString(); //质检方案名称 |
| | | string status = obj["status"].ToString(); //有效状态 |
| | |
| | | string checkitem = obj["checkitem"].ToString(); //质检列表 |
| | | string type = obj["type"].ToString(); //操作类型 |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //操作人员 |
| | | mes = QualityManagementBLL.QualityInspectionAddEditSave(qualityinsptcode, qualityinsptname, status,checktype,sampmethod,sampscare,suitobject,suitpart,descr, stepcode, checkitem,type,username); |
| | | mes = QualityManagementBLL.QualityInspectionAddEditSave(wkshopcode,qualityinsptcode, qualityinsptname, status,checktype,sampmethod,sampscare,suitobject,suitpart,descr, stepcode, checkitem,type,username); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |