| | |
| | | string stocktypecode = obj["stocktypecode"].ToString(); //åè´§ç±»åç¼ç |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //æä½äººå |
| | | string OperType = obj["OperType"].ToString(); //æä½ç±»å |
| | | mes = ProductModelBLL.AddUpdateMaterialType(materialtypeid,materialtypecode, materialtypename, stocktypecode, username, OperType); |
| | | mes = ProductModelBLL.AddUpdateMaterialType(materialtypeid, materialtypecode, materialtypename, stocktypecode, username, OperType); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | public HttpResponseMessage UomAdd(List<Uom> json) |
| | | { |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //æä½äººå |
| | | mes = ProductModelBLL.UomAdd(username,json); |
| | | mes = ProductModelBLL.UomAdd(username, json); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "InventoryFileSelect")] |
| | | [HttpGet] |
| | | public HttpResponseMessage InventoryFileSelect(string partcode = null, string partname = null,string partspec=null,string stocktypecode = null,string materialtypecode=null,string storehousecode=null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public HttpResponseMessage InventoryFileSelect(string partcode = null, string partname = null, string partspec = null, string stocktypecode = null, string materialtypecode = null, string storehousecode = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | int startNum = rows * (page - 1) + 1; //èµ·å§è®°å½rowNum |
| | | int endNum = rows * page; //ç»æè®°å½ rowNum |
| | |
| | | string maxstockqty = obj["maxstockqty"].ToString(); //æå¤§åºå |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //æä½äººå |
| | | string OperType = obj["OperType"].ToString(); //æä½ç±»å |
| | | mes = ProductModelBLL.AddUpdateInventoryFile(materialid, materialcode, materialname, materialspec, uomcode, warehousecode, stocktypecode, materialtypecode, minstockqty, maxstockqty,username, OperType); |
| | | mes = ProductModelBLL.AddUpdateInventoryFile(materialid, materialcode, materialname, materialspec, uomcode, warehousecode, stocktypecode, materialtypecode, minstockqty, maxstockqty, username, OperType); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | public HttpResponseMessage SaveInventoryFile(string partcode, List<ObjectData> json) |
| | | { |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //æä½äººå |
| | | mes = ProductModelBLL.SaveInventoryFile(partcode, username,json); |
| | | mes = ProductModelBLL.SaveInventoryFile(partcode, username, json); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "AddUpdateRoute")] |
| | | [HttpPost] |
| | | public HttpResponseMessage AddUpdateRoute(string id,string opertype, RoutEdit json) |
| | | public HttpResponseMessage AddUpdateRoute(string id, string opertype, RoutEdit json) |
| | | { |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //æä½äººå |
| | | mes = ProductModelBLL.AddUpdateRoute(id, opertype, username, json); |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "StepSearch")] |
| | | [HttpGet] |
| | | public HttpResponseMessage StepSearch(string stepcode = null, string stepname = null, string enable = null,string steptypecode=null, string createuser = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public HttpResponseMessage StepSearch(string stepcode = null, string stepname = null, string enable = null, string steptypecode = null, string createuser = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | int startNum = rows * (page - 1) + 1; //èµ·å§è®°å½rowNum |
| | | int endNum = rows * page; //ç»æè®°å½ rowNum |
| | | mes = ProductModelBLL.StepSearch(stepcode, stepname, enable, steptypecode,createuser, startNum, endNum, prop, order); |
| | | mes = ProductModelBLL.StepSearch(stepcode, stepname, enable, steptypecode, createuser, startNum, endNum, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[å·¥åºå
³èç¼ºé·æ¥è¯¢] |
| | | /// <summary> |
| | | /// å·¥åºå
³èç¼ºé·æ¥è¯¢ |
| | | /// </summary> |
| | | /// <param name="stepcode">å·¥åºç¼ç </param> |
| | | /// <returns></returns> |
| | | [Route(template: "StepAssociationDefect")] |
| | | [HttpGet] |
| | | public HttpResponseMessage StepAssociationDefect(string stepcode) |
| | | { |
| | | mes = ProductModelBLL.StepAssociationDefect(stepcode); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[å·¥åºå
³èç¼ºé·æäº¤] |
| | | [Route(template: "SaveStepAssociationDefect")] |
| | | [HttpPost] |
| | | public HttpResponseMessage SaveStepAssociationDefect(string stepcode, List<ObjectData> json) |
| | | { |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //æä½äººå |
| | | mes = ProductModelBLL.SaveStepAssociationDefect(stepcode, username, json); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | |
| | | #region[产åä¿¡æ¯ä¸ææ¡æ¥è¯¢] |
| | | /// <summary> |
| | | /// 产åä¿¡æ¯ä¸ææ¡æ¥è¯¢ |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [Route(template: "PartSelect")] |
| | | [HttpGet] |
| | | public HttpResponseMessage PartSelect() |
| | | { |
| | | try |
| | | { |
| | | mes = ProductModelBLL.PartSelect(); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.Message = e.Message; |
| | | } |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[产åç¼ç æ¥æ¾å·¥èºè·¯çº¿ä¸ææ¡] |
| | | /// <summary> |
| | | /// 产åç¼ç æ¥æ¾å·¥èºè·¯çº¿ä¸ææ¡ |
| | | /// </summary> |
| | | /// <param name="partcode">产åç¼ç </param> |
| | | /// <returns></returns> |
| | | [Route(template: "PartSelectRpute")] |
| | | [HttpGet] |
| | | public HttpResponseMessage PartSelectRpute(string partcode) |
| | | { |
| | | try |
| | | { |
| | | mes = ProductModelBLL.PartSelectRpute(partcode); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.Message = e.Message; |
| | | } |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[æ ¹æ®å·¥èºè·¯çº¿ç¼ç æ¥æ¾å
³èå·¥åºéå] |
| | | /// <summary> |
| | | /// æ ¹æ®å·¥èºè·¯çº¿ç¼ç æ¥æ¾å
³èå·¥åºéå |
| | | /// </summary> |
| | | /// <param name="routecode">å·¥èºè·¯çº¿ç¼ç </param> |
| | | /// <returns></returns> |
| | | [Route(template: "RouteSelectStep")] |
| | | [HttpGet] |
| | | public HttpResponseMessage RouteSelectStep(string routecode) |
| | | { |
| | | try |
| | | { |
| | | mes = ProductModelBLL.RouteSelectStep(routecode); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.Message = e.Message; |
| | | } |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[æ ¹æ®å·¥åºçº¿ç¼ç æ¥æ¾å
³è设å¤éå] |
| | | /// <summary> |
| | | /// æ ¹æ®å·¥åºçº¿ç¼ç æ¥æ¾å
³è设å¤éå |
| | | /// </summary> |
| | | /// <param name="partcode">产åç¼ç </param> |
| | | /// <param name="routecode">å·¥èºè·¯çº¿ç¼ç </param> |
| | | /// <param name="stepcode">å·¥åºç¼ç </param> |
| | | /// <param name="page">页ç </param> |
| | | /// <param name="rows">æ¯é¡µæ¾ç¤ºæ¡æ°</param> |
| | | /// <param name="prop">æåºå段</param> |
| | | /// <param name="order">æåºè§å</param> |
| | | /// <returns></returns> |
| | | [Route(template: "StepSelectEqp")] |
| | | [HttpGet] |
| | | public HttpResponseMessage StepSelectEqp(string partcode, string routecode, string stepcode, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | |
| | | int startNum = rows * (page - 1) + 1; //èµ·å§è®°å½rowNum |
| | | int endNum = rows * page; //ç»æè®°å½ rowNum |
| | | mes = ProductModelBLL.StepSelectEqp(partcode, routecode, stepcode, startNum, endNum, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[èæå·¥ä»·æ¥è¯¢] |
| | | /// <summary> |
| | | /// èæå·¥ä»·æ¥è¯¢ |
| | | /// </summary> |
| | | /// <param name="partcode">产åç¼ç </param> |
| | | /// <param name="partname">产ååç§°</param> |
| | | /// <param name="partspec">产åè§æ ¼</param> |
| | | /// <param name="routecode">å·¥èºè·¯çº¿ç¼ç </param> |
| | | /// <param name="stepcode">å·¥åºç¼ç </param> |
| | | /// <param name="eqpcode">设å¤ç¼ç </param> |
| | | /// <param name="eqpname">设å¤åç§°</param> |
| | | /// <param name="page">页ç </param> |
| | | /// <param name="rows">æ¯é¡µæ¾ç¤ºæ¡æ°</param> |
| | | /// <param name="prop">æåºå段</param> |
| | | /// <param name="order">æåºè§å</param> |
| | | /// <returns></returns> |
| | | [Route(template: "BeatRateSearch")] |
| | | [HttpGet] |
| | | public HttpResponseMessage BeatRateSearch(string partcode = null, string partname = null, string partspec = null, string routecode = null, string stepcode = null, string eqpcode = null, string eqpname = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | int startNum = rows * (page - 1) + 1; //èµ·å§è®°å½rowNum |
| | | int endNum = rows * page; //ç»æè®°å½ rowNum |
| | | mes = ProductModelBLL.BeatRateSearch(partcode, partname, partspec, routecode, stepcode, eqpcode, eqpname, startNum, endNum, prop, order); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | } |
| | | } |
| | |
| | | return ProductModelDAL.SaveStepAssociationEqp(stepcode,username,json); |
| | | } |
| | | #endregion |
| | | |
| | | #region[å·¥åºå
³èç¼ºé·æ¥è¯¢] |
| | | public static ToMessage StepAssociationDefect(string stepcode) |
| | | { |
| | | return ProductModelDAL.StepAssociationDefect(stepcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[å·¥åºå
³èç¼ºé·æäº¤] |
| | | public static ToMessage SaveStepAssociationDefect(string stepcode, string username, List<ObjectData> json) |
| | | { |
| | | return ProductModelDAL.SaveStepAssociationDefect(stepcode,username,json); |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | #region[产åä¿¡æ¯ä¸ææ¡æ¥è¯¢] |
| | | public static ToMessage PartSelect() |
| | | { |
| | | return ProductModelDAL.PartSelect(); |
| | | } |
| | | #endregion |
| | | |
| | | #region[产åç¼ç æ¥æ¾å·¥èºè·¯çº¿ä¸ææ¡] |
| | | public static ToMessage PartSelectRpute(string partcode) |
| | | { |
| | | return ProductModelDAL.PartSelectRpute(partcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[æ ¹æ®å·¥èºè·¯çº¿ç¼ç æ¥æ¾å
³èå·¥åºéå] |
| | | public static ToMessage RouteSelectStep(string routecode) |
| | | { |
| | | return ProductModelDAL.RouteSelectStep(routecode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[æ ¹æ®å·¥åºçº¿ç¼ç æ¥æ¾å
³è设å¤éå] |
| | | public static ToMessage StepSelectEqp(string partcode, string routecode, string stepcode, int startNum, int endNum, string prop, string order) |
| | | { |
| | | return ProductModelDAL.StepSelectEqp(partcode, routecode, stepcode, startNum, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | | #region[èæå·¥ä»·æ¥è¯¢] |
| | | public static ToMessage BeatRateSearch(string partcode, string partname, string partspec, string routecode, string stepcode, string eqpcode, string eqpname, int startNum, int endNum, string prop, string order) |
| | | { |
| | | return ProductModelDAL.BeatRateSearch(partcode, partname, partspec, routecode, stepcode, eqpcode, eqpname, startNum, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | } |
| | | } |
| | |
| | | //search = search.Substring(3);//æªåç´¢å¼2åé¢çå符 |
| | | // --------------æ¥è¯¢æå®æ°æ®-------------- |
| | | var total = 0; //æ»æ¡æ° |
| | | var sql = @"select A.code,A.name,A.eqptype_code,B.name as eqptype_name,A.eqpgroup_code,G.name as eqpgroup_name,A.enable, |
| | | var sql = @"select A.id,A.code,A.name,A.eqptype_code,B.name as eqptype_name,A.eqpgroup_code,G.name as eqpgroup_name,A.enable, |
| | | A.input_date,A.wksp_code,T.org_name as wksp_name,A.Line_code,L.org_name as Line_name,A.opc_uom,A.operation_ration,A.lm_user,A.lm_date |
| | | from TEqpInfo A |
| | | left join TEqpType B on A.eqptype_code=B.code |
| | |
| | | if (operType == "Update") |
| | | { |
| | | var sql = @"update TEqpInfo set name=@devicename,eqptype_code=@devicetype,eqpgroup_code=@devicegroup,input_date=@importdate, |
| | | wksp_code=@workshop,line_code=@linecode,enable=@status,operation_ration=@ratio,lm_user=@usercode,lm_date=@CreateDate, |
| | | wksp_code=@workshop,line_code=@linecode,enable=@status,operation_ration=@ratio,lm_user=@usercode,lm_date=@CreateDate |
| | | where id=@deviceid"; |
| | | dynamicParams.Add("@deviceid", deviceid); |
| | | dynamicParams.Add("@devicename", devicename); |
| | |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[å·¥åºå
³èç¼ºé·æ¥è¯¢] |
| | | public static ToMessage StepAssociationDefect(string stepcode) |
| | | { |
| | | string sql = ""; |
| | | var dynamicParams = new DynamicParameters(); |
| | | List<StepDefect> list = new List<StepDefect>(); |
| | | try |
| | | { |
| | | //è·åå·¥åºå
³èç¼ºé·æ°æ®(å
å«å
³èæ è¯) |
| | | sql = @"select A.code,A.name,(case when B.defect_code is null then 'N' else 'Y' end) flag from TDefect A |
| | | left join( |
| | | select distinct defect_code from TDefect_Step where step_code='' and is_delete<>'1' |
| | | ) B on A.code=B.defect_code"; |
| | | dynamicParams.Add("@stepcode", stepcode); |
| | | var data = DapperHelper.selectdata(sql, dynamicParams); |
| | | for (int i = 0; i < data.Rows.Count; i++) |
| | | { |
| | | StepDefect dft = new StepDefect(); |
| | | dft.code = data.Rows[i]["CODE"].ToString(); |
| | | dft.name = data.Rows[i]["NAME"].ToString(); |
| | | dft.flag = data.Rows[i]["FLAG"].ToString(); |
| | | list.Add(dft); |
| | | } |
| | | mes.code = "200"; |
| | | mes.Message = "æ¥è¯¢æå!"; |
| | | mes.data = list; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[å·¥åºå
³èç¼ºé·æäº¤] |
| | | public static ToMessage SaveStepAssociationDefect(string stepcode, string username, List<ObjectData> json) |
| | | { |
| | | var sql = ""; |
| | | List<object> list = new List<object>(); |
| | | try |
| | | { |
| | | list.Clear(); |
| | | if (json == null || json.Count <= 0) |
| | | { |
| | | //æ¸
é¤å·¥åºå
³è缺é·è¡¨æ°æ® |
| | | sql = @"delete TDefect_Step where step_code=@stepcode"; |
| | | list.Add(new { str = sql, parm = new { stepcode = stepcode } }); |
| | | //æ è®°å·¥åºè¡¨å
³èå·¥ä½ç«æ è¯ |
| | | sql = @"update TStep is_defect='N' where stepcode=@stepcode"; |
| | | list.Add(new { str = sql, parm = new { stepcode = stepcode } }); |
| | | } |
| | | else |
| | | { |
| | | //æ¸
é¤å·¥åºå
³è缺é·è¡¨æ°æ® |
| | | sql = @"delete TDefect_Step where step_code=@stepcode"; |
| | | list.Add(new { str = sql, parm = new { stepcode = stepcode } }); |
| | | //循ç¯åå
¥ç¨æ·å
³èè§è²è¡¨ |
| | | for (int i = 0; i < json.Count; i++) |
| | | { |
| | | sql = @"insert into TDefect_Step(defect_code,step_code,lm_user,lm_date) values(@defect_code,@stepcode,@lm_user,@lm_date)"; |
| | | list.Add(new |
| | | { |
| | | str = sql, |
| | | parm = new |
| | | { |
| | | defect_code = json[i].code, |
| | | stepcode = stepcode, |
| | | lm_user = username, |
| | | lm_date = DateTime.Now.ToString() |
| | | } |
| | | }); |
| | | } |
| | | //æ è®°ç©æè¡¨å
³èå·¥èºè·¯çº¿æ è¯ |
| | | sql = @"update TStep set is_defect='Y' where stepcode=@stepcode"; |
| | | list.Add(new { str = sql, parm = new { stepcode = stepcode } }); |
| | | } |
| | | bool aa = DapperHelper.DoTransaction(list); |
| | | if (aa) |
| | | { |
| | | mes.code = "200"; |
| | | mes.count = 0; |
| | | mes.Message = "æä½æå!"; |
| | | mes.data = null; |
| | | } |
| | | else |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = "æä½å¤±è´¥!"; |
| | | mes.data = null; |
| | | } |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | |
| | | |
| | | #region[产åä¿¡æ¯ä¸ææ¡æ¥è¯¢] |
| | | public static ToMessage PartSelect() |
| | | { |
| | | string sql = ""; |
| | | try |
| | | { |
| | | //è·å设å¤ç±»åæ°æ® |
| | | sql = @"select partcode,partname,partspec from TMateriel_Info where is_delete<>'1' "; |
| | | var data = DapperHelper.selecttable(sql); |
| | | mes.code = "200"; |
| | | mes.Message = "æ¥è¯¢æå!"; |
| | | mes.data = data; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[产åç¼ç æ¥æ¾å·¥èºè·¯çº¿ä¸ææ¡] |
| | | public static ToMessage PartSelectRpute(string partcode) |
| | | { |
| | | string sql = ""; |
| | | var dynamicParams = new DynamicParameters(); |
| | | try |
| | | { |
| | | //éè¿äº§åç¼ç æ¥æ¾å
³èçå·¥èºè·¯çº¿ä¿¡æ¯ |
| | | sql = @"select A.route_code,B.name as route_name |
| | | from TMateriel_Route A |
| | | inner join TFlw_Rout B on A.route_code=B.code |
| | | where A.materiel_code=@partcode and B.is_delete<>'1' and A.is_delete<>'1'"; |
| | | dynamicParams.Add("@partcode", partcode); |
| | | var data = DapperHelper.selectdata(sql, dynamicParams); |
| | | mes.code = "200"; |
| | | mes.Message = "æ¥è¯¢æå!"; |
| | | mes.data = data; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[æ ¹æ®å·¥èºè·¯çº¿ç¼ç æ¥æ¾å
³èå·¥åºéå] |
| | | public static ToMessage RouteSelectStep(string routecode) |
| | | { |
| | | string sql = ""; |
| | | var dynamicParams = new DynamicParameters(); |
| | | try |
| | | { |
| | | //éè¿äº§åç¼ç æ¥æ¾å
³èçå·¥èºè·¯çº¿ä¿¡æ¯ |
| | | sql = @"select B.stepcode as code,B.stepname as name |
| | | from TFlw_Rtdt A |
| | | inner join TStep B on A.step_code=B.stepcode |
| | | where A.rout_code=@routecode and B.is_delete<>'1' and A.is_delete<>'1';"; |
| | | dynamicParams.Add("@routecode", routecode); |
| | | var data = DapperHelper.select<ObjectData>(sql, dynamicParams); |
| | | mes.code = "200"; |
| | | mes.Message = "æ¥è¯¢æå!"; |
| | | mes.data = data; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[æ ¹æ®å·¥åºçº¿ç¼ç æ¥æ¾å
³è设å¤éå] |
| | | public static ToMessage StepSelectEqp(string partcode, string routecode, string stepcode, int startNum, int endNum, string prop, string order) |
| | | { |
| | | var dynamicParams = new DynamicParameters(); |
| | | string search = ""; |
| | | try |
| | | { |
| | | // --------------æ¥è¯¢æå®æ°æ®-------------- |
| | | var total = 0; //æ»æ¡æ° |
| | | var sql = @"select C.partcode,C.partname,B.wksp_code,T.org_name as wksp_name,A.eqp_value,A.stand_value,A.cavity_qty,A.unprice |
| | | from ( |
| | | select materiel_code, eqp_code,eqp_value,stand_value,cavity_qty,unprice from TPrteEqp_Stad |
| | | where materiel_code=@partcode and route_code=@routecode and step_code=@stepcode |
| | | union all |
| | | select @partcode as materiel_code,eqp_code,'0' as eqp_value,'0' as stand_value,'0' as cavity_qty,'0' as unprice |
| | | from TFlw_Rteqp where step_code=@stepcode and style='E' and @partcode+eqp_code+step_code not in(select materiel_code+eqp_code+step_code from TPrteEqp_Stad) |
| | | ) A |
| | | left join TEqpInfo B on A.eqp_code=B.code |
| | | left join TOrganization T on B.wksp_code=T.org_code |
| | | left join TMateriel_Info C on A.materiel_code=C.partcode |
| | | where B.is_delete<>'1' and T.is_delete<>'1' and C.is_delete<>'1' "; |
| | | dynamicParams.Add("@partcode", partcode); |
| | | dynamicParams.Add("@routecode", routecode); |
| | | dynamicParams.Add("@stepcode", stepcode); |
| | | var data = DapperHelper.GetPageList<object>(sql, dynamicParams, prop, order, startNum, endNum, out total); |
| | | mes.code = "200"; |
| | | mes.Message = "æ¥è¯¢æå!"; |
| | | mes.count = total; |
| | | mes.data = data.ToList(); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[èæå·¥ä»·æ¥è¯¢] |
| | | public static ToMessage BeatRateSearch(string partcode, string partname, string partspec, string routecode, string stepcode, string eqpcode, string eqpname, int startNum, int endNum, string prop, string order) |
| | | { |
| | | var dynamicParams = new DynamicParameters(); |
| | | string search = ""; |
| | | try |
| | | { |
| | | if (partcode != "" && partcode != null) |
| | | { |
| | | search += "and partcode like '%'+@partcode+'%' "; |
| | | dynamicParams.Add("@stepcode", partcode); |
| | | } |
| | | if (partname != "" && partname != null) |
| | | { |
| | | search += "and stepname like '%'+@partname+'%' "; |
| | | dynamicParams.Add("@partname", partname); |
| | | } |
| | | if (partspec != "" && partspec != null) |
| | | { |
| | | search += "and stepname like '%'+@partspec+'%' "; |
| | | dynamicParams.Add("@partspec", partspec); |
| | | } |
| | | if (routecode != "" && routecode != null) |
| | | { |
| | | search += "and enable=@routecode "; |
| | | dynamicParams.Add("@routecode", routecode); |
| | | } |
| | | if (stepcode != "" && stepcode != null) |
| | | { |
| | | search += "and flwtype=@stepcode "; |
| | | dynamicParams.Add("@stepcode", stepcode); |
| | | } |
| | | if (eqpcode != "" && eqpcode != null) |
| | | { |
| | | search += "and stepname like '%'+@eqpcode+'%' "; |
| | | dynamicParams.Add("@eqpcode", eqpcode); |
| | | } |
| | | if (eqpname != "" && eqpname != null) |
| | | { |
| | | search += "and stepname like '%'+@eqpname+'%' "; |
| | | dynamicParams.Add("@eqpname", eqpname); |
| | | } |
| | | if (search == "") |
| | | { |
| | | search = "and 1=1 "; |
| | | } |
| | | // --------------æ¥è¯¢æå®æ°æ®-------------- |
| | | var total = 0; //æ»æ¡æ° |
| | | var sql = @"select stepcode,stepname,flwtype,enable,descr,lm_user,lm_date,is_eqp,is_defect |
| | | from TStep |
| | | where is_delete<>'1' " + search; |
| | | var data = DapperHelper.GetPageList<object>(sql, dynamicParams, prop, order, startNum, endNum, out total); |
| | | mes.code = "200"; |
| | | mes.Message = "æ¥è¯¢æå!"; |
| | | mes.count = total; |
| | | mes.data = data.ToList(); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | mes.code = "300"; |
| | | mes.count = 0; |
| | | mes.Message = e.Message; |
| | | mes.data = null; |
| | | } |
| | | return mes; |
| | | } |
| | | #endregion |
| | | |
| | | #region[èæå·¥ä»·æ°å¢ç¼è¾] |
| | | |
| | | #endregion |
| | | } |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | | using System.Web; |
| | | |
| | | namespace VueWebApi.Models |
| | | { |
| | | public class StepDefect |
| | | { |
| | | public string code { get; set; } |
| | | public string name { get; set; } |
| | | public string flag { get; set; } |
| | | } |
| | | } |
| | |
| | | <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
| | | <PropertyGroup> |
| | | <_PublishTargetUrl>D:\ç½ç«åå¸\XKDMesApi</_PublishTargetUrl> |
| | | <History>True|2022-06-17T05:23:15.1455451Z;True|2022-06-17T13:22:18.5517557+08:00;True|2022-06-17T13:19:27.7323818+08:00;True|2022-06-17T13:12:24.1252779+08:00;True|2022-06-17T13:09:20.4234258+08:00;True|2022-06-17T13:06:49.9869509+08:00;True|2022-06-17T12:58:54.6964621+08:00;False|2022-06-17T12:58:10.6767711+08:00;False|2022-06-17T12:57:08.9747950+08:00;False|2022-06-17T12:56:18.4650121+08:00;False|2022-06-17T12:55:57.9981927+08:00;True|2022-06-13T14:21:36.5610928+08:00;True|2022-06-13T11:41:39.4210151+08:00;True|2022-06-11T02:35:03.4727934+08:00;True|2022-06-11T02:31:13.7362660+08:00;True|2022-06-11T02:30:58.3616790+08:00;True|2022-06-11T01:57:04.4951468+08:00;True|2022-06-10T13:27:13.2097124+08:00;</History> |
| | | <History>True|2022-06-24T08:39:01.1080301Z;True|2022-06-17T13:23:15.1455451+08:00;True|2022-06-17T13:22:18.5517557+08:00;True|2022-06-17T13:19:27.7323818+08:00;True|2022-06-17T13:12:24.1252779+08:00;True|2022-06-17T13:09:20.4234258+08:00;True|2022-06-17T13:06:49.9869509+08:00;True|2022-06-17T12:58:54.6964621+08:00;False|2022-06-17T12:58:10.6767711+08:00;False|2022-06-17T12:57:08.9747950+08:00;False|2022-06-17T12:56:18.4650121+08:00;False|2022-06-17T12:55:57.9981927+08:00;True|2022-06-13T14:21:36.5610928+08:00;True|2022-06-13T11:41:39.4210151+08:00;True|2022-06-11T02:35:03.4727934+08:00;True|2022-06-11T02:31:13.7362660+08:00;True|2022-06-11T02:30:58.3616790+08:00;True|2022-06-11T01:57:04.4951468+08:00;True|2022-06-10T13:27:13.2097124+08:00;</History> |
| | | </PropertyGroup> |
| | | <ItemGroup> |
| | | <File Include="Areas/HelpPage/HelpPage.css"> |
| | |
| | | <publishTime>11/28/2018 13:04:24</publishTime> |
| | | </File> |
| | | <File Include="bin/VueWebApi.dll"> |
| | | <publishTime>06/23/2022 17:26:46</publishTime> |
| | | <publishTime>06/24/2022 16:42:15</publishTime> |
| | | </File> |
| | | <File Include="bin/VueWebApi.dll.config"> |
| | | <publishTime>06/15/2022 15:31:43</publishTime> |
| | | </File> |
| | | <File Include="bin/VueWebApi.pdb"> |
| | | <publishTime>06/23/2022 17:26:46</publishTime> |
| | | <publishTime>06/24/2022 16:42:15</publishTime> |
| | | </File> |
| | | <File Include="bin/VueWebApi.xml"> |
| | | <publishTime>06/16/2022 14:26:01</publishTime> |
| | |
| | | <Compile Include="Models\ObjectDataCont.cs" /> |
| | | <Compile Include="Models\RoleUserSubmit.cs" /> |
| | | <Compile Include="Models\RoutEdit.cs" /> |
| | | <Compile Include="Models\StepDefect.cs" /> |
| | | <Compile Include="Models\StepEqp.cs" /> |
| | | <Compile Include="Models\TreeDG.cs" /> |
| | | <Compile Include="Models\TreeDM.cs" /> |
| | |
| | | <!--æ¬å°ç¯å¢--> |
| | | <!--<add key="DBServer" value="Data Source=.;Initial Catalog=vmes;Integrated Security=True" />--> |
| | | <!--æå¡å¨ç¯å¢--> |
| | | <add key="DBServer" value="Data Source=121.196.36.24;Initial Catalog=vmes;User ID=sa;Password=xkd@20220602;pooling=false" /> |
| | | <add key="DBServer" value="Data Source=121.196.36.24,1533;Initial Catalog=vmes;User ID=sa;Password=xkd@20220602;pooling=false" /> |
| | | <!--redisæ°æ®åºé¾æ¥é
ç½®ip--> |
| | | <add key="RedisConnIp" value="127.0.0.1" /> |
| | | <!--redisæ°æ®åºé¾æ¥é
置端å£å·--> |
| | |
| | | <!--æ¬å°ç¯å¢--> |
| | | <!--<add key="DBServer" value="Data Source=.;Initial Catalog=vmes;Integrated Security=True" />--> |
| | | <!--æå¡å¨ç¯å¢--> |
| | | <add key="DBServer" value="Data Source=121.196.36.24;Initial Catalog=vmes;User ID=sa;Password=xkd@20220602;pooling=false" /> |
| | | <add key="DBServer" value="Data Source=121.196.36.24,1533;Initial Catalog=vmes;User ID=sa;Password=xkd@20220602;pooling=false" /> |
| | | <!--redisæ°æ®åºé¾æ¥é
ç½®ip--> |
| | | <add key="RedisConnIp" value="127.0.0.1" /> |
| | | <!--redisæ°æ®åºé¾æ¥é
置端å£å·--> |
| | |
| | | å·¥åºå®ä¹å
³èå·¥ä½ç«æäº¤ |
| | | </summary> |
| | | <param name="stepcode">å·¥åºç¼ç </param> |
| | | <param name="json"></param> |
| | | <param name="json">æäº¤æ°æ®</param> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.ProductModelController.StepAssociationDefect(System.String)"> |
| | | <summary> |
| | | å·¥åºå
³èç¼ºé·æ¥è¯¢ |
| | | </summary> |
| | | <param name="stepcode">å·¥åºç¼ç </param> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.ProductModelController.PartSelect"> |
| | | <summary> |
| | | 产åä¿¡æ¯ä¸ææ¡æ¥è¯¢ |
| | | </summary> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.ProductModelController.PartSelectRpute(System.String)"> |
| | | <summary> |
| | | 产åç¼ç æ¥æ¾å·¥èºè·¯çº¿ä¸ææ¡ |
| | | </summary> |
| | | <param name="partcode">产åç¼ç </param> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.ProductModelController.RouteSelectStep(System.String)"> |
| | | <summary> |
| | | æ ¹æ®å·¥èºè·¯çº¿ç¼ç æ¥æ¾å
³èå·¥åºéå |
| | | </summary> |
| | | <param name="routecode">å·¥èºè·¯çº¿ç¼ç </param> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.ProductModelController.StepSelectEqp(System.String,System.String,System.String,System.Int32,System.Int32,System.String,System.String)"> |
| | | <summary> |
| | | æ ¹æ®å·¥åºçº¿ç¼ç æ¥æ¾å
³è设å¤éå |
| | | </summary> |
| | | <param name="partcode">产åç¼ç </param> |
| | | <param name="routecode">å·¥èºè·¯çº¿ç¼ç </param> |
| | | <param name="stepcode">å·¥åºç¼ç </param> |
| | | <param name="page">页ç </param> |
| | | <param name="rows">æ¯é¡µæ¾ç¤ºæ¡æ°</param> |
| | | <param name="prop">æåºå段</param> |
| | | <param name="order">æåºè§å</param> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.ProductModelController.BeatRateSearch(System.String,System.String,System.String,System.String,System.String,System.String,System.String,System.Int32,System.Int32,System.String,System.String)"> |
| | | <summary> |
| | | èæå·¥ä»·æ¥è¯¢ |
| | | </summary> |
| | | <param name="partcode">产åç¼ç </param> |
| | | <param name="partname">产ååç§°</param> |
| | | <param name="partspec">产åè§æ ¼</param> |
| | | <param name="routecode">å·¥èºè·¯çº¿ç¼ç </param> |
| | | <param name="stepcode">å·¥åºç¼ç </param> |
| | | <param name="eqpcode">设å¤ç¼ç </param> |
| | | <param name="eqpname">设å¤åç§°</param> |
| | | <param name="page">页ç </param> |
| | | <param name="rows">æ¯é¡µæ¾ç¤ºæ¡æ°</param> |
| | | <param name="prop">æåºå段</param> |
| | | <param name="order">æåºè§å</param> |
| | | <returns></returns> |
| | | </member> |
| | | <member name="M:VueWebApi.Controllers.SystemSettingController.EncodingRules(System.String,System.String,System.Int32,System.Int32,System.String,System.String)"> |
| | |
| | | 4c18228ccc6ec1b0f1e055955b46344b14f533de |
| | | ead7cf2282d587d6d640ba9024111a7417c9f938 |
| | |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\bin\zh-Hans\System.Web.WebPages.resources.dll |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\bin\zh-Hans\System.Web.WebPages.Deployment.resources.dll |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\bin\zh-Hans\System.Web.WebPages.Razor.resources.dll |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\obj\Debug\VueWebApi.csproj.AssemblyReference.cache |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\obj\Debug\VueWebApi.csproj.CoreCompileInputs.cache |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\obj\Debug\VueWebApi.csproj.CopyComplete |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\obj\Debug\VueWebApi.dll |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\obj\Debug\VueWebApi.pdb |
| | | D:\æ°å¯è¿ªMES\VueWebApi\VueWebApi\obj\Debug\VueWebApi.csproj.AssemblyReference.cache |
| | |
| | | 8846817bef2faf361bb1dae0ba7c58c4d14cfba8 |
| | | b66fb695daf003212f22fc5e10c6694251fb7628 |