1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Web;
using VueWebApi.DLL.DAL;
using VueWebApi.Models;
using VueWebApi.Tools;
 
namespace VueWebApi.DLL.BLL
{
    public class ProductModelBLL
    {
        #region [存货类型]
        public static ToMessage StockTypeSelect()
        {
            return ProductModelDAL.StockTypeSelect();
        }
        #endregion
 
        #region[物料类型查询]
        public static ToMessage MaterialTypeSearch(string materialtypecode, string materialtypename, string stocktypecode, int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.MaterialTypeSearch(materialtypecode, materialtypename, stocktypecode, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[物料类型新增编辑]
        public static ToMessage AddUpdateMaterialType(string materialtypeid, string materialtypecode, string materialtypename, string stocktypecode, string username, string operType)
        {
            return ProductModelDAL.AddUpdateMaterialType(materialtypeid,materialtypecode, materialtypename, stocktypecode, username, operType);
        }
        #endregion
 
        #region[物料类型删除]
        public static ToMessage DeleteMaterialType(string materialtypecode)
        {
            return ProductModelDAL.DeleteMaterialType(materialtypecode);
        }
        #endregion
 
 
 
 
        #region[单位列表查询]
        public static ToMessage UomSearch(int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.UomSearch(startNum,endNum,prop,order);
        }
        #endregion
 
        #region[单位新增]
        public static ToMessage UomAdd(string username, List<Uom> json)
        {
            return ProductModelDAL.UomAdd(username,json);
        }
        #endregion
 
        #region[单位删除]
        public static ToMessage UomDelete(string uomcode)
        {
            return ProductModelDAL.UomDelete(uomcode);
        }
        #endregion
 
        #region[存类型查找物料类型]
        public static ToMessage StockTypeSelectMaterialType(string stocktypecode)
        {
            return ProductModelDAL.StockTypeSelectMaterialType(stocktypecode);
        }
        #endregion
 
        #region[单位下拉列表查询]
        public static ToMessage UomSelect()
        {
            return ProductModelDAL.UomSelect();
        }
        #endregion
 
        #region[存货档案查询]
        public static ToMessage InventoryFileSelect(string partcode, string partname, string partspec, string stocktypecode, string materialtypecode, string storehousecode, int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.InventoryFileSelect(partcode, partname, partspec, stocktypecode, materialtypecode, storehousecode, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[存货档案新增编辑]
        public static ToMessage AddUpdateInventoryFile(string materialid, string materialcode, string materialname, string materialspec, string uomcode, string warehousecode, string stocktypecode, string materialtypecode, string minstockqty, string maxstockqty, string username, string operType)
        {
            return ProductModelDAL.AddUpdateInventoryFile(materialid, materialcode, materialname, materialspec, uomcode, warehousecode, stocktypecode, materialtypecode, minstockqty, maxstockqty, username, operType);
        }
        #endregion
 
        #region[存货档案删除]
        public static ToMessage DeleteInventoryFile(string materialcode)
        {
            return ProductModelDAL.DeleteInventoryFile(materialcode);
        }
        #endregion
 
        #region[存货档案关联工艺路线查询]
        public static ToMessage InventoryFileAssociationRoute(string partcode)
        {
            return ProductModelDAL.InventoryFileAssociationRoute(partcode);
        }
        #endregion
 
        #region[存货档案关联工艺路线提交]
        public static ToMessage SaveInventoryFile(string partcode,string defaultroute_code, string username, List<ObjectData> json)
        {
            return ProductModelDAL.SaveInventoryFile(partcode, defaultroute_code, username, json);
        }
        #endregion
 
 
 
        #region[物料清单主列表查询]
        public static ToMessage BoIventorySelect(string parentpartcode, string parentpartname,string parentpartspec,string parttype, string status, string version, string createusername, string createopendate, string createclosedate, int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.BoIventorySelect(parentpartcode, parentpartname, parentpartspec, parttype, status, version, createusername, createopendate, createclosedate, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[物料清单新增时获取最大版本号]
        public static ToMessage MaterielDetailedVsion(string parentpartcode)
        {
            return ProductModelDAL.MaterielDetailedVsion(parentpartcode);
        }
        #endregion
 
        #region[物料清单新增/编辑提交]
        public static ToMessage AddUpdateBoIventory(string bomid,string parentpartcode, string parentpartname, string parentpartspec, string status, string uomcode, string quantity, string startdate, string version, string username, string opertype, List<BomSub> objs)
        {
            return ProductModelDAL.AddUpdateBoIventory(bomid,parentpartcode, parentpartname, parentpartspec, status, uomcode, quantity, startdate, version, username, opertype, objs);
        }
        #endregion
 
        #region[物料清单编辑显示及预览]
        public static ToMessage BoIventorySelectView(string bomid)
        {
            return ProductModelDAL.BoIventorySelectView(bomid);
        }
        #endregion
 
        #region[物料清单删除]
        public static ToMessage DeleteBoIventory(string bomid)
        {
            return ProductModelDAL.DeleteBoIventory(bomid);
        }
        #endregion
 
 
 
 
        #region[工序下拉查询接口]
        public static ToMessage StepSelect()
        {
            return ProductModelDAL.StepSelect();
        }
        #endregion
 
        #region[工艺路线查询]
        public static ToMessage RouteSearch(string routecode, string routename, string description, string createuser, int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.RouteSearch(routecode, routename, description, createuser, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[工艺路线预览]
        public static ToMessage ViewRoute(string routecode)
        {
            return ProductModelDAL.ViewRoute(routecode);
        }
        #endregion
 
        #region[工艺路线新增]
        public static ToMessage AddUpdateRoute(string id,string opertype, string username, RoutEdit json)
        {
            return ProductModelDAL.AddUpdateRoute(id,opertype,username, json);
        }
        #endregion
 
        #region[工艺路线删除]
        public static ToMessage DeleteRoute(string routecode)
        {
            return ProductModelDAL.DeleteRoute(routecode);
        }
        #endregion
 
 
 
        #region[工序查询]
        public static ToMessage StepSearch(string stepcode, string stepname, string enable,string steptypecode, string createuser, int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.StepSearch(stepcode, stepname, enable, steptypecode, createuser, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[工序新增编辑]
        public static ToMessage AddUpdateStep(string stepid, string stepcode, string stepname, string steptypecode, string enable, string description, string username, string operType)
        {
            return ProductModelDAL.AddUpdateStep(stepid, stepcode, stepname, steptypecode, enable, description, username, operType);
        }
        #endregion
 
        #region[工序删除]
        public static ToMessage DeleteStep(string stepcode)
        {
            return ProductModelDAL.DeleteStep(stepcode);
        }
        #endregion
 
        #region[工序定义关联工作站查询]
        public static ToMessage StepAssociationEqp(string stepcode)
        {
            return ProductModelDAL.StepAssociationEqp(stepcode);
        }
        #endregion
 
        #region [工序定义关联工作站提交]
        public static ToMessage SaveStepAssociationEqp(string stepcode, string username, List<ObjectData> json)
        {
            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 stepcode)
        {
            return ProductModelDAL.StepSelectEqp(stepcode);
        }
        #endregion
 
        #region[根据工序线编码查找关联设备集合]
        public static ToMessage StepSelectEqpList(string partcode, string routecode, string stepcode,string steptype, int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.StepSelectEqpList(partcode, routecode, stepcode, steptype, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[节拍工价查询]
        public static ToMessage BeatRateSearch(string partcode,string routecode, string stepcode, string eqpcode,int startNum, int endNum, string prop, string order)
        {
            return ProductModelDAL.BeatRateSearch(partcode,routecode, stepcode, eqpcode, startNum, endNum, prop, order);
        }
        #endregion
 
        #region[节拍工价提交]
        public static ToMessage SaveBeatRate(string partcode, string routecode, string stepcode, string eqpcode, string wkshopcode, string eqp_value, string stand_value, string cavity_qty, string unprice, string username)
        {
            return ProductModelDAL.SaveBeatRate(partcode, routecode, stepcode, eqpcode, wkshopcode, eqp_value, stand_value, cavity_qty, unprice, username);
        }
        #endregion
 
        #region[节拍工价删除]
        public static ToMessage DeleteBeatRate(string partcode, string routecode, string stepcode, string eqpcode)
        {
            return ProductModelDAL.SaveBeatRate(partcode,routecode,stepcode,eqpcode);
        }
        #endregion
    }
}