Browse Source

档案物资信息管理

xiaoqiang 5 years ago
parent
commit
53808f9a34
31 changed files with 1250 additions and 0 deletions
  1. BIN
      codegit/CallCenterApi/CallCenterAPI.WechatSDK/obj/Debug/CallCenterAPI.WechatSDK.csprojResolveAssemblyReference.cache
  2. BIN
      codegit/CallCenterApi/CallCenterAPI.WechatSDK/obj/Debug/CallCenterAPI.WechatSDK.dll
  3. 1 0
      codegit/CallCenterApi/CallCenterApi.BLL/CallCenterApi.BLL.csproj
  4. BIN
      codegit/CallCenterApi/CallCenterApi.BLL/obj/Debug/CallCenterApi.BLL.csprojResolveAssemblyReference.cache
  5. BIN
      codegit/CallCenterApi/CallCenterApi.BLL/obj/Debug/CallCenterApi.BLL.dll
  6. BIN
      codegit/CallCenterApi/CallCenterApi.BLL/obj/Debug/CallCenterApi.BLL.pdb
  7. BIN
      codegit/CallCenterApi/CallCenterApi.Cache/obj/Debug/CallCenterApi.Cache.dll
  8. BIN
      codegit/CallCenterApi/CallCenterApi.Cache/obj/Debug/CallCenterApi.Cache.pdb
  9. BIN
      codegit/CallCenterApi/CallCenterApi.Common/obj/Debug/CallCenterApi.Common.csprojResolveAssemblyReference.cache
  10. 744 0
      codegit/CallCenterApi/CallCenterApi.DAL/archives.cs
  11. BIN
      codegit/CallCenterApi/CallCenterApi.DAL/obj/Debug/CallCenterApi.DAL.csprojResolveAssemblyReference.cache
  12. BIN
      codegit/CallCenterApi/CallCenterApi.DAL/obj/Debug/CallCenterApi.DAL.dll
  13. BIN
      codegit/CallCenterApi/CallCenterApi.DAL/obj/Debug/CallCenterApi.DAL.pdb
  14. BIN
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/ExcelMod/archivesList.xls
  15. 33 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/OperationlogInput.cs
  16. 50 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/archivesInput.cs
  17. 24 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/archivestateInput.cs
  18. 37 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/customerBorrowInput.cs
  19. 38 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/insideOperationInput.cs
  20. BIN
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/obj/Debug/CallCenterApi.Interface.csprojResolveAssemblyReference.cache
  21. BIN
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/obj/Debug/CallCenterApi.Interface.dll
  22. BIN
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/obj/Debug/CallCenterApi.Interface.pdb
  23. 5 0
      codegit/CallCenterApi/CallCenterApi.Model/CallCenterApi.Model.csproj
  24. 42 0
      codegit/CallCenterApi/CallCenterApi.Model/Operationlog.cs
  25. 100 0
      codegit/CallCenterApi/CallCenterApi.Model/archives.cs
  26. 29 0
      codegit/CallCenterApi/CallCenterApi.Model/archivestate.cs
  27. 42 0
      codegit/CallCenterApi/CallCenterApi.Model/customerBorrow.cs
  28. 43 0
      codegit/CallCenterApi/CallCenterApi.Model/insideOperation.cs
  29. BIN
      codegit/CallCenterApi/CallCenterApi.Model/obj/Debug/CallCenterApi.Model.dll
  30. BIN
      codegit/CallCenterApi/CallCenterApi.Model/obj/Debug/CallCenterApi.Model.pdb
  31. 62 0
      档案物资管理sql文档/档案物资管理建表.sql

BIN
codegit/CallCenterApi/CallCenterAPI.WechatSDK/obj/Debug/CallCenterAPI.WechatSDK.csprojResolveAssemblyReference.cache


BIN
codegit/CallCenterApi/CallCenterAPI.WechatSDK/obj/Debug/CallCenterAPI.WechatSDK.dll


+ 1 - 0
codegit/CallCenterApi/CallCenterApi.BLL/CallCenterApi.BLL.csproj

@@ -40,6 +40,7 @@
40 40
     <Reference Include="System.Xml" />
41 41
   </ItemGroup>
42 42
   <ItemGroup>
43
+    <Compile Include="archives.cs" />
43 44
     <Compile Include="article.cs" />
44 45
     <Compile Include="article_category.cs" />
45 46
     <Compile Include="CallResult.cs" />

BIN
codegit/CallCenterApi/CallCenterApi.BLL/obj/Debug/CallCenterApi.BLL.csprojResolveAssemblyReference.cache


BIN
codegit/CallCenterApi/CallCenterApi.BLL/obj/Debug/CallCenterApi.BLL.dll


BIN
codegit/CallCenterApi/CallCenterApi.BLL/obj/Debug/CallCenterApi.BLL.pdb


BIN
codegit/CallCenterApi/CallCenterApi.Cache/obj/Debug/CallCenterApi.Cache.dll


BIN
codegit/CallCenterApi/CallCenterApi.Cache/obj/Debug/CallCenterApi.Cache.pdb


BIN
codegit/CallCenterApi/CallCenterApi.Common/obj/Debug/CallCenterApi.Common.csprojResolveAssemblyReference.cache


+ 744 - 0
codegit/CallCenterApi/CallCenterApi.DAL/archives.cs

@@ -0,0 +1,744 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Text;
5
+using System.Threading.Tasks;
6
+using System.Data.SqlClient;
7
+using System.Data;
8
+using CallCenterApi.DB;
9
+using System.Reflection;
10
+
11
+namespace CallCenterApi.DAL
12
+{
13
+    public class archives
14
+    {
15
+        /// <summary>
16
+        /// 查询物资档案表信息
17
+        /// </summary>
18
+        /// <returns></returns>
19
+        public DataSet GetList()
20
+        {
21
+            StringBuilder strSql = new StringBuilder();
22
+            strSql.Append("select ");
23
+            strSql.Append(" * ");
24
+            strSql.Append(" FROM archives ");
25
+
26
+            var ds = DbHelperSQL.Query(strSql.ToString());
27
+
28
+            return ds;
29
+        }
30
+        /// <summary>
31
+        /// 是否存在该记录
32
+        /// </summary>
33
+        public bool IfHave(int id)
34
+        {
35
+            StringBuilder strSql = new StringBuilder();
36
+            strSql.Append("select count(1) from archivestate");
37
+            strSql.Append(" where id=@id");
38
+            SqlParameter[] parameters = {
39
+                    new SqlParameter("@id", SqlDbType.Int,4)
40
+            };
41
+            parameters[0].Value = id;
42
+
43
+            return DbHelperSQL.Exists(strSql.ToString(), parameters);
44
+        }
45
+        /// <summary>
46
+        /// 增加一条档案物资数据
47
+        /// </summary>
48
+        /// <param name="model"></param>
49
+        /// <returns></returns>
50
+        public int Add(CallCenterApi.Model.archives model)
51
+        {
52
+            StringBuilder strSql = new StringBuilder();
53
+            strSql.Append("insert into archives(");
54
+            strSql.Append("A_archiveCode,A_archiveName,A_archiveState,A_archivePeople,fileid)");
55
+            strSql.Append(" values (");
56
+            strSql.Append("@A_archiveCode,@A_archiveName,@A_archiveState,@A_archivePeople,@fileid)");
57
+            strSql.Append(";select @@IDENTITY");
58
+            SqlParameter[] parameters = {
59
+                    new SqlParameter("@A_archiveCode", SqlDbType.NVarChar,100),
60
+                    new SqlParameter("@A_archiveName", SqlDbType.NVarChar,100),
61
+                    new SqlParameter("@A_archiveState", SqlDbType.Int,4),
62
+                    new SqlParameter("@A_archivePeople", SqlDbType.NVarChar,50),
63
+                    new SqlParameter("@fileid", SqlDbType.Int,4)};
64
+            parameters[0].Value = model.A_archiveCode;
65
+            parameters[1].Value = model.A_archiveName;
66
+            parameters[2].Value = model.A_archiveState;
67
+            //parameters[3].Value = model.A_archiveRecord;
68
+            parameters[3].Value = model.A_archivePeople;
69
+            parameters[4].Value = model.fileid;
70
+            object obj = DbHelperSQL.GetSingle(strSql.ToString(), parameters);
71
+            if (obj == null)
72
+            {
73
+                return 0;
74
+            }
75
+            else
76
+            {
77
+                return Convert.ToInt32(obj);
78
+            }
79
+        }
80
+        /// <summary>
81
+        /// 得到一个档案物资对象实体
82
+        /// </summary>
83
+        public CallCenterApi.Model.archives GetModel(int id)
84
+        {
85
+            StringBuilder strSql = new StringBuilder();
86
+            strSql.Append("select  top 1 a.*,s.stateName as stateName,o.OperationContent,o.OperationDate from archives as a left join archivestate as s on a.A_archiveState = s.id left join Operationlog as o on a.id = o.archivesid  ");
87
+            strSql.Append(" where a.id=@id");
88
+            SqlParameter[] parameters = {
89
+                    new SqlParameter("@id", SqlDbType.BigInt)
90
+            };
91
+            parameters[0].Value = id;
92
+
93
+            CallCenterApi.Model.T_Wo_WorkOrder model = new CallCenterApi.Model.T_Wo_WorkOrder();
94
+            DataSet ds = DbHelperSQL.Query(strSql.ToString(), parameters);
95
+            if (ds.Tables[0].Rows.Count > 0)
96
+            {
97
+                return DataRowToModelarchives(ds.Tables[0].Rows[0]);
98
+            }
99
+            else
100
+            {
101
+                return null;
102
+            }
103
+        }
104
+        /// <summary>
105
+        /// 得到一个档案物资对象实体
106
+        /// </summary>
107
+        public CallCenterApi.Model.archives DataRowToModelarchives(DataRow row)
108
+        {
109
+            #region 之前的 
110
+            //CallCenterApi.Model.archives model = new CallCenterApi.Model.archives();
111
+            //if (row != null)
112
+            //{
113
+            //    if (row["id"] != null && row["id"].ToString() != "")
114
+            //    {
115
+            //        model.id = int.Parse(row["id"].ToString());
116
+            //    }
117
+            //    if (row["A_archiveCode"] != null)
118
+            //    {
119
+            //        model.A_archiveCode = row["A_archiveCode"].ToString();
120
+            //    }
121
+            //    if (row["A_archiveName"] != null && row["A_archiveName"].ToString() != "")
122
+            //    {
123
+            //        model.A_archiveName = row["A_archiveName"].ToString();
124
+            //    }
125
+
126
+            //    if (row["A_archiveState"] != null)
127
+            //    {
128
+            //        model.A_archiveState = int.Parse(row["A_archiveState"].ToString());
129
+            //    }
130
+            //    if (row["A_archivePeople"] != null)
131
+            //    {
132
+            //        model.A_archivePeople = row["A_archivePeople"].ToString();
133
+            //    }
134
+            //    if (row["stateName"] != null && row["stateName"].ToString() != "")
135
+            //    {
136
+            //        model.stateName = row["stateName"].ToString(); 
137
+            //    }
138
+
139
+            //}
140
+            //return model; 
141
+            #endregion
142
+            Model.archives model = new Model.archives();//主表字段
143
+            if (row != null)
144
+            {
145
+                #region 主表信息======================
146
+                //利用反射获得属性的所有公共属性
147
+                Type modelType = model.GetType();
148
+                for (int i = 0; i < row.Table.Columns.Count; i++)
149
+                {
150
+                    PropertyInfo proInfo = modelType.GetProperty(row.Table.Columns[i].ColumnName);
151
+                    if (proInfo != null && row[i] != DBNull.Value)
152
+                    {
153
+                        //用索引值设置属性值
154
+                        proInfo.SetValue(model, row[i], null);
155
+                    }
156
+                }
157
+                #endregion
158
+            }
159
+            return model;
160
+        }
161
+
162
+        /// <summary>
163
+        /// 更新一条档案物资数据
164
+        /// </summary>
165
+        public bool Update(CallCenterApi.Model.archives model)
166
+        {
167
+            StringBuilder strSql = new StringBuilder();
168
+            strSql.Append("update archives set ");
169
+            strSql.Append("A_archiveCode=@A_archiveCode,");
170
+            strSql.Append("A_archiveName=@A_archiveName,");
171
+            strSql.Append("A_archiveState=@A_archiveState,");
172
+            strSql.Append("A_archivePeople=@A_archivePeople");
173
+            strSql.Append(" where id=@id");
174
+            SqlParameter[] parameters = {
175
+                    new SqlParameter("@A_archiveCode", SqlDbType.NVarChar,100),
176
+                    new SqlParameter("@A_archiveName", SqlDbType.NVarChar,100),
177
+                    new SqlParameter("@A_archiveState", SqlDbType.Int,4),
178
+                    new SqlParameter("@A_archivePeople", SqlDbType.NVarChar,50),
179
+                    new SqlParameter("@id", SqlDbType.Int,4)};
180
+            parameters[0].Value = model.A_archiveCode;
181
+            parameters[1].Value = model.A_archiveName;
182
+            parameters[2].Value = model.A_archiveState;
183
+           // parameters[3].Value = model.A_archiveRecord;
184
+            parameters[3].Value = model.A_archivePeople;
185
+            parameters[4].Value = model.id;
186
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
187
+            if (rows > 0)
188
+            {
189
+                return true;
190
+            }
191
+            else
192
+            {
193
+                return false;
194
+            }
195
+        }
196
+        /// <summary>
197
+        /// 根据id 修改档案物资的状态
198
+        /// </summary>
199
+        /// <returns></returns>
200
+        public bool updateState(int id,int stateid)
201
+        {
202
+            StringBuilder strSql = new StringBuilder();
203
+            strSql.Append("update archives set ");
204
+            strSql.Append("A_archiveState=@A_archiveState,");
205
+            strSql.Append(" where id=@id");
206
+            SqlParameter[] parameters = {
207
+                    new SqlParameter("@A_archiveState", SqlDbType.Int,4) };
208
+            parameters[0].Value = stateid;
209
+            parameters[1].Value = id;
210
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
211
+            if (rows > 0)
212
+            {
213
+                return true;
214
+            }
215
+            else
216
+            {
217
+                return false;
218
+            }
219
+        }
220
+        /// <summary>
221
+        /// 删除一条档案物资数据
222
+        /// </summary>
223
+        public bool Delete(int id)
224
+        {
225
+
226
+            StringBuilder strSql = new StringBuilder();
227
+            strSql.Append("delete from archives ");
228
+            strSql.Append(" where id=@id");
229
+            SqlParameter[] parameters = {
230
+                    new SqlParameter("@id", SqlDbType.Int,4)
231
+            };
232
+            parameters[0].Value = id;
233
+
234
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
235
+            if (rows > 0)
236
+            {
237
+                return true;
238
+            }
239
+            else
240
+            {
241
+                return false;
242
+            }
243
+        }
244
+
245
+        /// <summary>
246
+        /// 获取物资状态信息 用作可选的下拉框选项
247
+        /// </summary>
248
+        /// <returns></returns>
249
+        public DataSet GetArchivestate()
250
+        {
251
+            StringBuilder strSql = new StringBuilder();
252
+            strSql.Append("select ");
253
+            strSql.Append(" * ");
254
+            strSql.Append(" FROM archivestate ");
255
+
256
+            var ds = DbHelperSQL.Query(strSql.ToString());
257
+
258
+            return ds;
259
+        }
260
+        /// <summary>
261
+        /// 得到一个物资状态对象实体
262
+        /// </summary>
263
+        public CallCenterApi.Model.archivestate DataRowToModelarchives1(DataRow row)
264
+        {
265
+            CallCenterApi.Model.archivestate model = new CallCenterApi.Model.archivestate();
266
+            if (row != null)
267
+            {
268
+                if (row["id"] != null && row["id"].ToString() != "")
269
+                {
270
+                    model.id = int.Parse(row["id"].ToString());
271
+                }
272
+                if (row["stateName"] != null)
273
+                {
274
+                    model.stateName = row["stateName"].ToString();
275
+                }
276
+               
277
+            }
278
+            return model;
279
+        }
280
+        /// <summary>
281
+        /// 增加物资状态数据
282
+        /// </summary>
283
+        /// <param name="model"></param>
284
+        /// <returns></returns>
285
+        public int Addarchivestate(CallCenterApi.Model.archivestate model)
286
+        {
287
+            StringBuilder strSql = new StringBuilder();
288
+            strSql.Append("insert into archivestate(");
289
+            strSql.Append("stateName)");
290
+            strSql.Append(" values (");
291
+            strSql.Append("@stateName)");
292
+            strSql.Append(";select @@IDENTITY");
293
+            SqlParameter[] parameters = {
294
+                    new SqlParameter("@stateName", SqlDbType.NVarChar,20)};
295
+            parameters[0].Value = model.stateName;
296
+
297
+            object obj = DbHelperSQL.GetSingle(strSql.ToString(), parameters);
298
+            if (obj == null)
299
+            {
300
+                return 0;
301
+            }
302
+            else
303
+            {
304
+                return Convert.ToInt32(obj);
305
+            }
306
+        }
307
+        /// <summary>
308
+        /// 删除一条物资状态信息
309
+        /// </summary>
310
+        /// <param name="id"></param>
311
+        /// <returns></returns>
312
+        public bool delarchivestate(int id)
313
+        {
314
+            StringBuilder strSql = new StringBuilder();
315
+            strSql.Append("delete from archivestate ");
316
+            strSql.Append(" where id=@id");
317
+            SqlParameter[] parameters = {
318
+                    new SqlParameter("@id", SqlDbType.Int,4)
319
+            };
320
+            parameters[0].Value = id;
321
+
322
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
323
+            if (rows > 0)
324
+            {
325
+                return true;
326
+            }
327
+            else
328
+            {
329
+                return false;
330
+            }
331
+        }
332
+        /// <summary>
333
+        /// 根据档案名称获取档案状态id
334
+        /// </summary>
335
+        /// <param name="statename"></param>
336
+        /// <returns></returns>
337
+        public int GetStateid(string statename)
338
+        {
339
+            StringBuilder strSql = new StringBuilder();
340
+            strSql.Append("select * from archivestate");
341
+            strSql.Append(" where stateName=@stateName");
342
+            SqlParameter[] parameters = {
343
+                    new SqlParameter("@stateName", SqlDbType.NVarChar ,20)
344
+            };
345
+            parameters[0].Value = statename;
346
+            var stateid = 0;
347
+
348
+            var ds = DbHelperSQL.Query(strSql.ToString());
349
+            foreach (Model.archivestate ar in ds.Tables[0].Columns)
350
+            {
351
+                stateid=ar.id;
352
+            }
353
+
354
+            return stateid;
355
+        }
356
+        /// <summary>
357
+        /// 获取外部客户操作表信息
358
+        /// </summary>
359
+        /// <returns></returns>
360
+        public DataSet GetCustomerBorrow()
361
+        {
362
+            StringBuilder strSql = new StringBuilder();
363
+            strSql.Append("select ");
364
+            strSql.Append(" * ");
365
+            strSql.Append(" FROM customerBorrow ");
366
+
367
+            var ds = DbHelperSQL.Query(strSql.ToString());
368
+
369
+            return ds;
370
+        }
371
+        /// <summary>
372
+        /// 外部客户操作信息添加
373
+        /// </summary>
374
+        /// <returns></returns>
375
+        public int  AddCustomerBorrow(CallCenterApi.Model.customerBorrow model)
376
+        {
377
+            StringBuilder strSql = new StringBuilder();
378
+            strSql.Append("insert into customerBorrow(");
379
+            strSql.Append("archivesid,BorrowOreturn,BorrowDate,BorrowPeople)");
380
+            strSql.Append(" values (");
381
+            strSql.Append("@archivesid,@BorrowOreturn,@BorrowDate,@BorrowPeople)");
382
+            strSql.Append(";select @@IDENTITY");
383
+            SqlParameter[] parameters = {
384
+                    new SqlParameter("@archivesid", SqlDbType.Int ,4),
385
+                    new SqlParameter("@BorrowOreturn", SqlDbType.NVarChar,20),
386
+                    new SqlParameter("@BorrowDate", SqlDbType.DateTime),
387
+                    new SqlParameter("@BorrowPeople", SqlDbType.NVarChar,50) };
388
+            parameters[0].Value = model.archivesid;
389
+            parameters[1].Value = model.BorrowOreturn;
390
+            parameters[2].Value = model.BorrowDate;
391
+            parameters[3].Value = model.BorrowPeople;
392
+
393
+            object obj = DbHelperSQL.GetSingle(strSql.ToString(), parameters);
394
+            if (obj == null)
395
+            {
396
+                return 0;
397
+            }
398
+            else
399
+            {
400
+                return Convert.ToInt32(obj);
401
+            }
402
+        }
403
+        /// <summary>
404
+        /// 修改客户操作信息
405
+        /// </summary>
406
+        /// <returns></returns>
407
+        public bool UpCustomerBorrow(CallCenterApi.Model.customerBorrow model)
408
+        {
409
+            StringBuilder strSql = new StringBuilder();
410
+            strSql.Append("update customerBorrow set ");
411
+            strSql.Append("archivesid=@archivesid,");
412
+            strSql.Append("BorrowOreturn=@BorrowOreturn,");
413
+            strSql.Append("BorrowDate=@BorrowDate,");
414
+            strSql.Append("BorrowPeople=@BorrowPeople");
415
+            strSql.Append(" where id=@id");
416
+            SqlParameter[] parameters = {
417
+                    new SqlParameter("@archivesid", SqlDbType.Int ,4),
418
+                    new SqlParameter("@BorrowOreturn", SqlDbType.NVarChar,20),
419
+                    new SqlParameter("@BorrowDate", SqlDbType.DateTime),
420
+                    new SqlParameter("@BorrowPeople", SqlDbType.NVarChar,50),
421
+                    new SqlParameter("@id", SqlDbType.Int,4)};
422
+            parameters[0].Value = model.archivesid;
423
+            parameters[1].Value = model.BorrowOreturn;
424
+            parameters[2].Value = model.BorrowDate;
425
+            parameters[3].Value = model.BorrowPeople;
426
+            parameters[4].Value = model.id;
427
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
428
+            if (rows > 0)
429
+            {
430
+                return true;
431
+            }
432
+            else
433
+            {
434
+                return false;
435
+            }
436
+        }
437
+        /// <summary>
438
+        /// 获取客户操作表实体
439
+        /// </summary>
440
+        /// <param name="id"></param>
441
+        /// <returns></returns>
442
+        public CallCenterApi.Model.customerBorrow GetCustomerModel(int id)
443
+        {
444
+            StringBuilder strSql = new StringBuilder();
445
+            strSql.Append("select  top 1 id,archivesid,BorrowOreturn,BorrowDate,BorrowPeople from customerBorrow ");
446
+            strSql.Append(" where id=@id");
447
+            SqlParameter[] parameters = {
448
+                    new SqlParameter("@id", SqlDbType.Int,4)};
449
+            parameters[0].Value = id;
450
+
451
+            DataSet ds = DbHelperSQL.Query(strSql.ToString(), parameters);
452
+            if (ds.Tables[0].Rows.Count > 0)
453
+            {
454
+                return DataRowToModelcustomerBorrow(ds.Tables[0].Rows[0]);
455
+            }
456
+            else
457
+            {
458
+                return null;
459
+            }
460
+        }
461
+        /// <summary>
462
+        /// 获取客户操作表实体
463
+        /// </summary>
464
+        /// <param name="id"></param>
465
+        /// <returns></returns>
466
+        public  Model.customerBorrow DataRowToModelcustomerBorrow(DataRow row)
467
+        {
468
+            Model.customerBorrow model = new Model.customerBorrow();//主表字段
469
+            if (row != null)
470
+            {
471
+                #region 主表信息======================
472
+                //利用反射获得属性的所有公共属性
473
+                Type modelType = model.GetType();
474
+                for (int i = 0; i < row.Table.Columns.Count; i++)
475
+                {
476
+                    PropertyInfo proInfo = modelType.GetProperty(row.Table.Columns[i].ColumnName);
477
+                    if (proInfo != null && row[i] != DBNull.Value)
478
+                    {
479
+                        //用索引值设置属性值
480
+                        proInfo.SetValue(model, row[i], null);
481
+                    }
482
+                }
483
+                #endregion
484
+            }
485
+            return model;
486
+        }
487
+        /// <summary>
488
+        /// 删除一条客户操作信息
489
+        /// </summary>
490
+        /// <param name="id"></param>
491
+        /// <returns></returns>
492
+        public bool delCustomerBorrow(int id)
493
+        {
494
+            StringBuilder strSql = new StringBuilder();
495
+            strSql.Append("delete from customerBorrow ");
496
+            strSql.Append(" where id=@id");
497
+            SqlParameter[] parameters = {
498
+                    new SqlParameter("@id", SqlDbType.Int,4)
499
+            };
500
+            parameters[0].Value = id;
501
+
502
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
503
+            if (rows > 0)
504
+            {
505
+                return true;
506
+            }
507
+            else
508
+            {
509
+                return false;
510
+            }
511
+        }
512
+
513
+        /// <summary>
514
+        /// 获取内部操作表信息
515
+        /// </summary>
516
+        /// <returns></returns>
517
+        public DataSet GetinsideOperation()
518
+        {
519
+            StringBuilder strSql = new StringBuilder();
520
+            strSql.Append("select ");
521
+            strSql.Append(" * ");
522
+            strSql.Append(" FROM insideOperation ");
523
+
524
+            var ds = DbHelperSQL.Query(strSql.ToString());
525
+
526
+            return ds;
527
+        }
528
+        /// <summary>
529
+        /// 内部员工操作信息添加
530
+        /// </summary>
531
+        /// <returns></returns>
532
+        public int AddinsideOperation(CallCenterApi.Model.insideOperation model)
533
+        {
534
+            StringBuilder strSql = new StringBuilder();
535
+            strSql.Append("insert into insideOperation(");
536
+            strSql.Append("archivesid,Warehousing,WarehousingDate,Operator)");
537
+            strSql.Append(" values (");
538
+            strSql.Append("@archivesid,@Warehousing,@WarehousingDate,@Operator)");
539
+            strSql.Append(";select @@IDENTITY");
540
+            SqlParameter[] parameters = {
541
+                    new SqlParameter("@archivesid", SqlDbType.Int ,4),
542
+                    new SqlParameter("@Warehousing", SqlDbType.NVarChar,20),
543
+                    new SqlParameter("@WarehousingDate", SqlDbType.DateTime),
544
+                    new SqlParameter("@Operator", SqlDbType.NVarChar,50) };
545
+            parameters[0].Value = model.archivesid;
546
+            parameters[1].Value = model.Warehousing;
547
+            parameters[2].Value = model.WarehousingDate;
548
+            parameters[3].Value = model.Operator;
549
+
550
+            object obj = DbHelperSQL.GetSingle(strSql.ToString(), parameters);
551
+            if (obj == null)
552
+            {
553
+                return 0;
554
+            }
555
+            else
556
+            {
557
+                return Convert.ToInt32(obj);
558
+            }
559
+        }
560
+        /// <summary>
561
+        /// 修改内部员工操作信息
562
+        /// </summary>
563
+        /// <returns></returns>
564
+        public bool UpinsideOperation(CallCenterApi.Model.insideOperation model)
565
+        {
566
+            StringBuilder strSql = new StringBuilder();
567
+            strSql.Append("update insideOperation set ");
568
+            strSql.Append("archivesid=@archivesid,");
569
+            strSql.Append("Warehousing=@Warehousing,");
570
+            strSql.Append("WarehousingDate=@WarehousingDate,");
571
+            strSql.Append("Operator=@Operator,");
572
+            strSql.Append(" where id=@id");
573
+            SqlParameter[] parameters = {
574
+                    new SqlParameter("@archivesid", SqlDbType.Int ,4),
575
+                    new SqlParameter("@Warehousing", SqlDbType.NVarChar,20),
576
+                    new SqlParameter("@WarehousingDate", SqlDbType.DateTime),
577
+                    new SqlParameter("@Operator", SqlDbType.NVarChar,50),
578
+                    new SqlParameter("@id", SqlDbType.Int,4)};
579
+            parameters[0].Value = model.archivesid;
580
+            parameters[1].Value = model.Warehousing;
581
+            parameters[2].Value = model.WarehousingDate;
582
+            parameters[3].Value = model.Operator;
583
+            parameters[4].Value = model.id;
584
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
585
+            if (rows > 0)
586
+            {
587
+                return true;
588
+            }
589
+            else
590
+            {
591
+                return false;
592
+            }
593
+        }
594
+        /// <summary>
595
+        /// 获取内部员工操作表实体
596
+        /// </summary>
597
+        /// <param name="id"></param>
598
+        /// <returns></returns>
599
+        public CallCenterApi.Model.insideOperation GetinsideOperationModel(int id)
600
+        {
601
+            StringBuilder strSql = new StringBuilder();
602
+            strSql.Append("select  top 1 id,archivesid,Warehousing,WarehousingDate,Operator from insideOperation ");
603
+            strSql.Append(" where id=@id");
604
+            SqlParameter[] parameters = {
605
+                    new SqlParameter("@id", SqlDbType.Int,4)};
606
+            parameters[0].Value = id;
607
+
608
+            DataSet ds = DbHelperSQL.Query(strSql.ToString(), parameters);
609
+            if (ds.Tables[0].Rows.Count > 0)
610
+            {
611
+                return DataRowToModelinsideOperation(ds.Tables[0].Rows[0]);
612
+            }
613
+            else
614
+            {
615
+                return null;
616
+            }
617
+        }
618
+        /// <summary>
619
+        /// 获取内部员工操作表实体
620
+        /// </summary>
621
+        /// <param name="id"></param>
622
+        /// <returns></returns>
623
+        public Model.insideOperation DataRowToModelinsideOperation(DataRow row)
624
+        {
625
+            Model.insideOperation model = new Model.insideOperation();//主表字段
626
+            if (row != null)
627
+            {
628
+                #region 主表信息======================
629
+                //利用反射获得属性的所有公共属性
630
+                Type modelType = model.GetType();
631
+                for (int i = 0; i < row.Table.Columns.Count; i++)
632
+                {
633
+                    PropertyInfo proInfo = modelType.GetProperty(row.Table.Columns[i].ColumnName);
634
+                    if (proInfo != null && row[i] != DBNull.Value)
635
+                    {
636
+                        //用索引值设置属性值
637
+                        proInfo.SetValue(model, row[i], null);
638
+                    }
639
+                }
640
+                #endregion
641
+            }
642
+            return model;
643
+        }
644
+        /// <summary>
645
+        /// 删除一条内部员工操作信息
646
+        /// </summary>
647
+        /// <param name="id"></param>
648
+        /// <returns></returns>
649
+        public bool delinsideOperation(int id)
650
+        {
651
+            StringBuilder strSql = new StringBuilder();
652
+            strSql.Append("delete from insideOperation ");
653
+            strSql.Append(" where id=@id");
654
+            SqlParameter[] parameters = {
655
+                    new SqlParameter("@id", SqlDbType.Int,4)
656
+            };
657
+            parameters[0].Value = id;
658
+
659
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
660
+            if (rows > 0)
661
+            {
662
+                return true;
663
+            }
664
+            else
665
+            {
666
+                return false;
667
+            }
668
+        }
669
+
670
+        /// <summary>
671
+        /// 获取操作日志表信息
672
+        /// </summary>
673
+        /// <returns></returns>
674
+        public DataSet GetOperationlog()
675
+        {
676
+            StringBuilder strSql = new StringBuilder();
677
+            strSql.Append("select ");
678
+            strSql.Append(" * ");
679
+            strSql.Append(" FROM Operationlog ");
680
+
681
+            var ds = DbHelperSQL.Query(strSql.ToString());
682
+
683
+            return ds;
684
+        }
685
+        /// <summary>
686
+        /// 操作日志信息添加
687
+        /// </summary>
688
+        /// <returns></returns>
689
+        public int AddOperationlog(CallCenterApi.Model.Operationlog model)
690
+        {
691
+            StringBuilder strSql = new StringBuilder();
692
+            strSql.Append("insert into Operationlog(");
693
+            strSql.Append("archivesid,Operator,OperationContent,OperationDate)");
694
+            strSql.Append(" values (");
695
+            strSql.Append("@archivesid,@Operator,@OperationContent,@OperationDate)");
696
+            strSql.Append(";select @@IDENTITY");
697
+            SqlParameter[] parameters = {
698
+                    new SqlParameter("@archivesid", SqlDbType.Int,50),
699
+                    new SqlParameter("@Operator", SqlDbType.NVarChar,50),
700
+                    new SqlParameter("@OperationContent", SqlDbType.NVarChar,100),
701
+                    new SqlParameter("@OperationDate", SqlDbType.DateTime)};
702
+            parameters[0].Value = model.archivesid;
703
+            parameters[1].Value = model.Operator;//操作人
704
+            parameters[2].Value = model.OperationContent;//操作内容
705
+            parameters[3].Value = model.OperationDate;//操作时间
706
+
707
+            object obj = DbHelperSQL.GetSingle(strSql.ToString(), parameters);
708
+            if (obj == null)
709
+            {
710
+                return 0;
711
+            }
712
+            else
713
+            {
714
+                return Convert.ToInt32(obj);
715
+            }
716
+        }
717
+        /// <summary>
718
+        /// 获取操作日志信息的实体
719
+        /// </summary>
720
+        /// <param name="row"></param>
721
+        /// <returns></returns>
722
+        public Model.Operationlog DataRowToModelOperationlog(DataRow row)
723
+        {
724
+            Model.Operationlog model = new Model.Operationlog();//主表字段
725
+            if (row != null)
726
+            {
727
+                #region 主表信息======================
728
+                //利用反射获得属性的所有公共属性
729
+                Type modelType = model.GetType();
730
+                for (int i = 0; i < row.Table.Columns.Count; i++)
731
+                {
732
+                    PropertyInfo proInfo = modelType.GetProperty(row.Table.Columns[i].ColumnName);
733
+                    if (proInfo != null && row[i] != DBNull.Value)
734
+                    {
735
+                        //用索引值设置属性值
736
+                        proInfo.SetValue(model, row[i], null);
737
+                    }
738
+                }
739
+                #endregion
740
+            }
741
+            return model;
742
+        }
743
+    }
744
+}

BIN
codegit/CallCenterApi/CallCenterApi.DAL/obj/Debug/CallCenterApi.DAL.csprojResolveAssemblyReference.cache


BIN
codegit/CallCenterApi/CallCenterApi.DAL/obj/Debug/CallCenterApi.DAL.dll


BIN
codegit/CallCenterApi/CallCenterApi.DAL/obj/Debug/CallCenterApi.DAL.pdb


BIN
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/ExcelMod/archivesList.xls


+ 33 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/OperationlogInput.cs

@@ -0,0 +1,33 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Web;
5
+
6
+namespace CallCenterApi.Interface.Models.Input
7
+{
8
+    public class OperationlogInput
9
+    {
10
+        /// <summary>
11
+        /// 操作记录表自增id
12
+        /// </summary>
13
+        public int id { get; set; }
14
+        /// <summary>
15
+        /// 操作人
16
+        /// </summary>
17
+        /// <returns></returns>
18
+        public string Operator { get; set; }
19
+        /// <summary>
20
+        /// 操作内容
21
+        /// </summary>
22
+        /// <returns></returns>
23
+        public string OperationContent { get; set; }
24
+        /// <summary>
25
+        /// 操作时间
26
+        /// </summary>
27
+        public DateTime? OperationDate { get; set; }
28
+        /// <summary>
29
+        /// 物资id
30
+        /// </summary>
31
+        public int? archivesid { get; set; }
32
+    }
33
+}

+ 50 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/archivesInput.cs

@@ -0,0 +1,50 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Web;
5
+
6
+namespace CallCenterApi.Interface.Models.Input
7
+{
8
+    public class archivesInput
9
+    {
10
+        /// <summary>
11
+        /// 自增ID
12
+        /// </summary>
13
+      
14
+        public int id { get; set; }
15
+        /// <summary>
16
+        /// 关联客户表中的客户编号
17
+        /// </summary>
18
+
19
+        public string A_archiveCode { get; set; }
20
+        /// <summary>
21
+        /// 物资名称
22
+        /// </summary>
23
+       
24
+        public string A_archiveName { get; set; }
25
+        /// <summary>
26
+        /// 物资状态 关联状态表中的id
27
+        /// </summary>
28
+       
29
+        public int? A_archiveState { get; set; }
30
+        ///// <summary>
31
+        ///// 最近一次变更记录 关联操作记录表中的id
32
+        ///// </summary>
33
+        
34
+        //public int? A_archiveRecord { get; set; }
35
+        /// <summary>
36
+        /// 操作人
37
+        /// </summary>
38
+       
39
+        public string A_archivePeople { get; set; }
40
+        /// <summary>
41
+        /// 上传附件的id
42
+        /// </summary>
43
+        public int fileid { get; set; }
44
+
45
+        /// <summary>
46
+        /// 判断是添加还是修改==0为添加大于0为修改
47
+        /// </summary>
48
+        public int isadd { get; set; }
49
+    }
50
+}

+ 24 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/archivestateInput.cs

@@ -0,0 +1,24 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Web;
5
+
6
+namespace CallCenterApi.Interface.Models.Input
7
+{
8
+    public class archivestateInput
9
+    {
10
+        #region Model
11
+        //private int id;
12
+        //private string stateName;
13
+        /// <summary>
14
+        /// 档案物资状态自增id
15
+        /// </summary>
16
+        public int id { get; set; }
17
+        /// <summary>
18
+        /// 档案物资状态
19
+        /// </summary>
20
+        public string stateName { get; set; }
21
+
22
+        #endregion
23
+    }
24
+}

+ 37 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/customerBorrowInput.cs

@@ -0,0 +1,37 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Web;
5
+
6
+namespace CallCenterApi.Interface.Models.Input
7
+{
8
+    public class customerBorrowInput
9
+    {
10
+        /// <summary>
11
+        /// 外部客户操作表则增id
12
+        /// </summary>
13
+        public int id { get; set; }
14
+        /// <summary>
15
+        /// 物品编号 关联档案物资 借阅物品名称
16
+        /// </summary>
17
+        public int? archivesid { get; set; }
18
+        /// <summary>
19
+        /// 区分借阅还是归还
20
+        /// </summary>
21
+        /// <returns></returns>
22
+        public string BorrowOreturn { get; set; }
23
+        /// <summary>
24
+        /// 物品借阅时间
25
+        /// </summary>
26
+        public DateTime BorrowDate { get; set; }
27
+        /// <summary>
28
+        /// 借阅人/归还人
29
+        /// </summary>
30
+        /// <returns></returns>
31
+        public string BorrowPeople { get; set; }
32
+        /// <summary>
33
+        /// 判断是添加还是修改
34
+        /// </summary>
35
+        public int isadd { get; set; }
36
+    }
37
+}

+ 38 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/insideOperationInput.cs

@@ -0,0 +1,38 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Web;
5
+
6
+namespace CallCenterApi.Interface.Models.Input
7
+{
8
+    public class insideOperationInput
9
+    {
10
+
11
+        /// <summary>
12
+        /// 内部员工操作表自增id
13
+        /// </summary>
14
+        public int id { get; set; }
15
+        /// <summary>
16
+        /// 物品编号 关联档案物资 入库名称
17
+        /// </summary>
18
+        public int archivesid { get; set; }
19
+        /// <summary>
20
+        /// 区分出库与入库
21
+        /// </summary>
22
+        /// <returns></returns>
23
+        public string Warehousing { get; set; }
24
+        /// <summary>
25
+        /// 出入库时间
26
+        /// </summary>
27
+        public DateTime? WarehousingDate { get; set; }
28
+        /// <summary>
29
+        /// 操作人
30
+        /// </summary>
31
+        /// <returns></returns>
32
+        public string Operator { get; set; }
33
+        /// <summary>
34
+        /// 判断是添加还是修改
35
+        /// </summary>
36
+        public int isadd { get; set; }
37
+    }
38
+}

BIN
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/obj/Debug/CallCenterApi.Interface.csprojResolveAssemblyReference.cache


BIN
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/obj/Debug/CallCenterApi.Interface.dll


BIN
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/obj/Debug/CallCenterApi.Interface.pdb


+ 5 - 0
codegit/CallCenterApi/CallCenterApi.Model/CallCenterApi.Model.csproj

@@ -41,9 +41,14 @@
41 41
     <Reference Include="System.Xml" />
42 42
   </ItemGroup>
43 43
   <ItemGroup>
44
+    <Compile Include="archives.cs" />
45
+    <Compile Include="archivestate.cs" />
44 46
     <Compile Include="article.cs" />
45 47
     <Compile Include="article_category.cs" />
46 48
     <Compile Include="CallResult.cs" />
49
+    <Compile Include="customerBorrow.cs" />
50
+    <Compile Include="insideOperation.cs" />
51
+    <Compile Include="Operationlog.cs" />
47 52
     <Compile Include="orders.cs" />
48 53
     <Compile Include="order_goods.cs" />
49 54
     <Compile Include="PageData.cs" />

+ 42 - 0
codegit/CallCenterApi/CallCenterApi.Model/Operationlog.cs

@@ -0,0 +1,42 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Text;
5
+using System.Threading.Tasks;
6
+
7
+namespace CallCenterApi.Model
8
+{
9
+    /// <summary>
10
+    /// Operationlog :操作记录表实体类信息
11
+    /// </summary>
12
+    [Serializable]
13
+    public class Operationlog
14
+    {
15
+        /// <summary>
16
+        /// 操作记录表自增id
17
+        /// </summary>
18
+        public int id { get; set; }
19
+        /// <summary>
20
+        /// 操作人
21
+        /// </summary>
22
+        /// <returns></returns>
23
+        public string Operator { get; set; }
24
+        /// <summary>
25
+        /// 操作内容
26
+        /// </summary>
27
+        /// <returns></returns>
28
+        public string  OperationContent { get; set; }
29
+        /// <summary>
30
+        /// 操作时间
31
+        /// </summary>
32
+        public DateTime? OperationDate { get; set; }
33
+        /// <summary>
34
+        /// 物资id
35
+        /// </summary>
36
+        public int? archivesid { get; set; }
37
+        /// <summary>
38
+        /// 物资档案名称
39
+        /// </summary>
40
+        public string  A_archiveName { get; set; }
41
+    }
42
+}

+ 100 - 0
codegit/CallCenterApi/CallCenterApi.Model/archives.cs

@@ -0,0 +1,100 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Text;
5
+using System.Threading.Tasks;
6
+
7
+namespace CallCenterApi.Model
8
+{
9
+    /// <summary>
10
+    ///  archives:档案物资实体类(属性说明自动提取数据库字段的描述信息)
11
+    /// </summary>
12
+    [Serializable]
13
+    public partial class archives
14
+    {
15
+        #region Model
16
+        //private int id ;
17
+        //private string A_archiveCode ;
18
+        //private string A_archiveName ;
19
+        //private int?   A_archiveState  ;
20
+        //private int?   A_archiveRecord ;
21
+        //private string A_archivePeople;
22
+        /// <summary>
23
+        /// 自增ID
24
+        /// </summary>
25
+        //public int Id 
26
+        //{
27
+        //    set { id  = value; }
28
+        //    get { return id; }
29
+        //}
30
+        public int id { get; set; }
31
+        /// <summary>
32
+        /// 关联客户表中的客户编号
33
+        /// </summary>
34
+        //public string A_ArchiveCode
35
+        //{
36
+        //    set { A_archiveCode = value; }
37
+        //    get { return A_archiveCode; }
38
+        //}
39
+        public string A_archiveCode { get; set; }
40
+        /// <summary>
41
+        /// 物资名称
42
+        /// </summary>
43
+        //public string A_ArchiveName
44
+        //{
45
+        //     set { A_archiveName = value; }
46
+        //     get { return A_archiveName; }
47
+        //}
48
+        public string A_archiveName { get; set; }
49
+        /// <summary>
50
+        /// 物资状态 关联状态表中的id
51
+        /// </summary>
52
+        //public int? A_ArchiveState
53
+        //{
54
+        //    set { A_archiveState = value; }
55
+        //    get { return A_archiveState; }
56
+        //}
57
+        public int? A_archiveState { get; set; }
58
+        ///// <summary>
59
+        ///// 最近一次变更记录 关联操作记录表中的id
60
+        ///// </summary>
61
+        ////public int? A_ArchiveRecord
62
+        ////{
63
+        ////    set  { A_archiveRecord = value; } 
64
+        ////    get { return A_archiveRecord; }
65
+        ////}
66
+        //public int? A_archiveRecord { get; set; }
67
+        /// <summary>
68
+        /// 操作人
69
+        /// </summary>
70
+        //public string A_ArchivePeople
71
+        //{
72
+        //    set { A_archivePeople = value; }
73
+        //    get { return A_archivePeople; }
74
+        //}
75
+        public string A_archivePeople { get; set; }
76
+        /// <summary>
77
+        /// 外键状态名称
78
+        /// </summary>
79
+        public string stateName { get; set; }
80
+        /// <summary>
81
+        /// 操作内容
82
+        /// </summary>
83
+        /// <returns></returns>
84
+        public string OperationContent { get; set; }
85
+        /// <summary>
86
+        /// 操作时间
87
+        /// </summary>
88
+        public DateTime? OperationDate { get; set; }
89
+        /// <summary>
90
+        /// 上传附件的id
91
+        /// </summary>
92
+        public int fileid { get; set; }
93
+
94
+        /// <summary>
95
+        /// 判断是添加还是修改==0为添加大于0为修改
96
+        /// </summary>
97
+        public int isadd { get; set; }
98
+        #endregion Model
99
+    }
100
+}

+ 29 - 0
codegit/CallCenterApi/CallCenterApi.Model/archivestate.cs

@@ -0,0 +1,29 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Text;
5
+using System.Threading.Tasks;
6
+
7
+namespace CallCenterApi.Model
8
+{
9
+    /// <summary>
10
+    ///  archivestate:档案物资状态实体类(属性说明自动提取数据库字段的描述信息)
11
+    /// </summary>
12
+    [Serializable]
13
+    public  class archivestate
14
+    {
15
+        #region Model
16
+        //private int id;
17
+        //private string stateName;
18
+        /// <summary>
19
+        /// 档案物资状态自增id
20
+        /// </summary>
21
+        public int id { get; set; }
22
+        /// <summary>
23
+        /// 档案物资状态
24
+        /// </summary>
25
+        public string stateName { get; set; }
26
+
27
+        #endregion
28
+    }
29
+}

+ 42 - 0
codegit/CallCenterApi/CallCenterApi.Model/customerBorrow.cs

@@ -0,0 +1,42 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Text;
5
+using System.Threading.Tasks;
6
+
7
+namespace CallCenterApi.Model
8
+{
9
+    /// <summary>
10
+    ///  customerBorrow:外部客户操作实体类(属性说明自动提取数据库字段的描述信息)
11
+    /// </summary>
12
+    [Serializable]
13
+    public  class customerBorrow
14
+    {
15
+        /// <summary>
16
+        /// 外部客户操作表则增id
17
+        /// </summary>
18
+        public int id { get; set; }
19
+        /// <summary>
20
+        /// 物品编号 关联档案物资 借阅物品名称
21
+        /// </summary>
22
+        public int? archivesid { get; set; }
23
+        /// <summary>
24
+        /// 区分借阅还是归还
25
+        /// </summary>
26
+        /// <returns></returns>
27
+        public string BorrowOreturn { get; set; }
28
+        /// <summary>
29
+        /// 物品借阅时间
30
+        /// </summary>
31
+        public DateTime BorrowDate { get; set; }
32
+        /// <summary>
33
+        /// 借阅人/归还人
34
+        /// </summary>
35
+        /// <returns></returns>
36
+        public string BorrowPeople { get; set; }
37
+        /// <summary>
38
+        ///档案物资名称 关联档案物资表需要显示的
39
+        /// </summary>
40
+        public string A_archiveName { get; set; }
41
+    }
42
+}

+ 43 - 0
codegit/CallCenterApi/CallCenterApi.Model/insideOperation.cs

@@ -0,0 +1,43 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Text;
5
+using System.Threading.Tasks;
6
+
7
+namespace CallCenterApi.Model
8
+{
9
+    /// <summary>
10
+    ///  insideOperation:内部客户操作实体类(属性说明自动提取数据库字段的描述信息)
11
+    /// </summary>
12
+    [Serializable]
13
+    public  class insideOperation
14
+    {
15
+
16
+        /// <summary>
17
+        /// 内部员工操作表自增id
18
+        /// </summary>
19
+        public int id { get; set; }
20
+        /// <summary>
21
+        /// 物品编号 关联档案物资 入库名称
22
+        /// </summary>
23
+        public int archivesid { get; set; }
24
+        /// <summary>
25
+        /// 区分出库与入库
26
+        /// </summary>
27
+        /// <returns></returns>
28
+        public string Warehousing { get; set; }
29
+        /// <summary>
30
+        /// 出入库时间
31
+        /// </summary>
32
+        public DateTime? WarehousingDate { get; set; }
33
+        /// <summary>
34
+        /// 操作人
35
+        /// </summary>
36
+        /// <returns></returns>
37
+        public string Operator { get; set; }
38
+        /// <summary>
39
+        /// 档案物资名称
40
+        /// </summary>
41
+        public string A_archiveName { get; set; }
42
+    }
43
+}

BIN
codegit/CallCenterApi/CallCenterApi.Model/obj/Debug/CallCenterApi.Model.dll


BIN
codegit/CallCenterApi/CallCenterApi.Model/obj/Debug/CallCenterApi.Model.pdb


+ 62 - 0
档案物资管理sql文档/档案物资管理建表.sql

@@ -0,0 +1,62 @@
1
+--创建档案物资表关联客户CustomeBaseNew表中的客户编号
2
+create table archives
3
+(
4
+	id int identity primary key , --编号
5
+	A_archiveCode   nvarchar(100),--关联客户表中的F_CustomerCode客户编号 关联显示客户名称
6
+	A_archiveName   nvarchar(100),--物资名称
7
+	A_archiveState  int ,         --物资状态 关联物质状态表中的主键id
8
+	A_archivePeople nvarchar(50), --操作者谁登陆的就填谁
9
+	fileid int                    --附件编号
10
+)
11
+
12
+--创建物资状态表
13
+create table archivestate
14
+(
15
+	id int identity primary key , --状态id
16
+	stateName nvarchar(20)        --状态名称
17
+)
18
+--添加状态信息
19
+insert into archivestate(stateName) values('在库');
20
+insert into archivestate(stateName) values('借阅中');
21
+insert into archivestate(stateName) values('已出库');
22
+insert into archivestate(stateName) values('丢失');
23
+
24
+--创建外部客户操作表 
25
+create table  customerBorrow
26
+(
27
+	id int identity primary key , --id
28
+	archivesid    int ,           --物品编号 关联档案物资 借阅物品名称
29
+	BorrowOreturn nvarchar(20),   --区分借阅还是归还
30
+	BorrowDate    datetime,  --物品借阅时间
31
+	BorrowPeople  nvarchar(50)    --借阅人/归还人
32
+)
33
+
34
+
35
+--创建内部员工操作表  
36
+create table insideOperation      --内部操作
37
+(
38
+	id int identity primary key , --id
39
+	archivesid      int ,         --物品编号 关联档案物资 入库名称
40
+	Warehousing     nvarchar(20), --区分出库与入库
41
+	WarehousingDate datetime,--出入库时间
42
+	Operator        nvarchar(50)  --操作人
43
+)
44
+
45
+--创建操作记录表  
46
+create table Operationlog          --操作日志
47
+(
48
+	id int identity primary key ,  --id
49
+	archivesid int ,               --关联物资表id
50
+	Operator         nvarchar(50), --操作人
51
+	OperationContent nvarchar(100),--操作内容
52
+	OperationDate    datetime      --操作时间
53
+)
54
+
55
+
56
+select * from archives
57
+--查询物资状态信息
58
+select *  from archivestate 
59
+select * from customerBorrow
60
+select * from Operationlog
61
+
62
+