65 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			C#
		
	
	
	
		
		
			
		
	
	
			65 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			C#
		
	
	
	
|  |  | |||
|  | /// <summary> | |||
|  | ///INTERFACE CLASS FOR TABLE t_workplan | |||
|  | ///By wm with codesmith.  | |||
|  | ///on 04/18/2017 | |||
|  | /// </summary> | |||
|  | 
 | |||
|  | using System; | |||
|  | using System.Collections.Generic; | |||
|  | using System.Linq; | |||
|  | using System.Text; | |||
|  | using System.Data; | |||
|  | 
 | |||
|  | namespace DeiNiu.wms.Data.Model | |||
|  | { | |||
|  |     [Serializable] | |||
|  |     public class Workplan : Workplan_base | |||
|  |     { | |||
|  |         public Workplan() | |||
|  |         { | |||
|  | 
 | |||
|  |         } | |||
|  | 
 | |||
|  |         public Workplan(int id): base(id) | |||
|  |         { | |||
|  | 
 | |||
|  |         } | |||
|  |         protected override void getImp() | |||
|  |         { | |||
|  |             model_imp = new Workplan_Imp(); | |||
|  | 
 | |||
|  |         } | |||
|  |         | |||
|  |         //begin cust db operation, query, excute sql etc. | |||
|  |         public DataTable getWorkplanDetails(int empId, string date) | |||
|  |         { | |||
|  |             cmdParameters[0] = empId; | |||
|  |             cmdParameters[1] = date; | |||
|  |             return CustQuery(100).Tables[0]; | |||
|  |         } | |||
|  | 
 | |||
|  |         public DataTable getWorkplanByDate(int empId, string date) | |||
|  |         { | |||
|  |             cmdParameters[0] = empId; | |||
|  |             cmdParameters[1] = date; | |||
|  |             DataTable dt = CustQuery(200).Tables[0]; | |||
|  |             if (dt.Rows.Count > 0) | |||
|  |             { | |||
|  |                 this._id = Convert.ToInt32(dt.Rows[0]["ID"].ToString()); | |||
|  |                 getModel(); | |||
|  |             } | |||
|  |             return dt; | |||
|  |         } | |||
|  | 
 | |||
|  |         public int getNextNumber(int workplanId) | |||
|  |         { | |||
|  |             cmdParameters[0] = workplanId; | |||
|  |             return Convert.ToInt32(CustQuery(300).Tables[0].Rows[0][0].ToString()) + 1; | |||
|  | 
 | |||
|  |         } | |||
|  | 
 | |||
|  | 
 | |||
|  |     } | |||
|  | } |