|
|
@@ -20,10 +20,11 @@ Class KitModel_Class |
|
|
|
Public Status '106 |
|
|
|
Public OutboundSTID '106 |
|
|
|
Public InboundSTID '106 |
|
|
|
Public OfficeCopiesAmount |
|
|
|
|
|
|
|
Private Sub Class_Initialize |
|
|
|
'ValidateExitsts Me, "","" |
|
|
|
Class_Get_Properties = Array("ID, JobNumber, Jcode, CreatedOn, LabelsPrinted, ExportedToSnailWorks, InkJetJob, JobType, Filename, Cass, Status, OutboundSTID, InboundSTID") |
|
|
|
Class_Get_Properties = Array("ID, JobNumber, Jcode, CreatedOn, LabelsPrinted, ExportedToSnailWorks, InkJetJob, JobType, Filename, Cass, Status, OutboundSTID, InboundSTID, OfficeCopiesAmount") |
|
|
|
End Sub |
|
|
|
|
|
|
|
End CLass |
|
|
@@ -47,10 +48,11 @@ Class IndexKitModel_Class |
|
|
|
Public Status |
|
|
|
Public OutboundSTID |
|
|
|
Public InboundSTID |
|
|
|
Public OfficeCopiesAmount |
|
|
|
|
|
|
|
Private Sub Class_Initialize |
|
|
|
'ValidateExitsts Me, "","" |
|
|
|
Class_Get_Properties = Array("ID, JobNumber,Jcode, Jurisdiction,LabelCount,CreatedOn,LabelsPrinted,ExportedToSnailWorks,InkJetJob,JobType,Filename,Cass,Status,OutboundSTID,InboundSTID") |
|
|
|
Class_Get_Properties = Array("ID, JobNumber,Jcode, Jurisdiction,LabelCount,CreatedOn,LabelsPrinted,ExportedToSnailWorks,InkJetJob,JobType,Filename,Cass,Status,OutboundSTID,InboundSTID,OfficeCopiesAmount") |
|
|
|
End Sub |
|
|
|
End Class |
|
|
|
|
|
|
@@ -65,7 +67,7 @@ Class KitRepository_Class |
|
|
|
dim sql : sql = "SELECT Kit.ID,Kit.JobNumber as [JobNumber],Kit.JCode, " &_ |
|
|
|
"Jurisdiction.Name As Jurisdiction," &_ |
|
|
|
"(SELECT COUNT(*) From InkjetRecords Where KitId = Kit.ID)" &_ |
|
|
|
" As [LabelCount],[CreatedOn],[LabelsPrinted],[ExportedToSnailWorks],[InkJetJob],[JobType],[Filename],[Cass],[Status],[OutboundSTID],[InboundSTID] FROM Kit INNER JOIN Jurisdiction ON Kit.Jcode = Jurisdiction.JCode Where Kit.JobType = 'Purple Envelopes';" |
|
|
|
" As [LabelCount],[CreatedOn],[LabelsPrinted],[ExportedToSnailWorks],[InkJetJob],[JobType],[Filename],[Cass],[Status],[OutboundSTID],[InboundSTID],[OfficeCopiesAmount] FROM Kit INNER JOIN Jurisdiction ON Kit.Jcode = Jurisdiction.JCode Where Kit.JobType = 'Purple Envelopes';" |
|
|
|
|
|
|
|
dim list : set list = new LinkedList_Class |
|
|
|
dim rs : set rs = DAL.PagedQuery(sql, empty, per_page, page_num) |
|
|
@@ -133,7 +135,7 @@ Class KitRepository_Class |
|
|
|
dim sql : sql = "SELECT Kit.ID,Kit.JobNumber as [JobNumber],Kit.JCode, " &_ |
|
|
|
"Jurisdiction.Name As Jurisdiction," &_ |
|
|
|
"(SELECT COUNT(*) From InkjetRecords Where KitID = Kit.ID)" &_ |
|
|
|
" As [LabelCount],[CreatedOn],[LabelsPrinted],[ExportedToSnailWorks],[JobType],[Status],[OutboundSTID],[InboundSTID] FROM Kit INNER JOIN Jurisdiction ON Kit.Jcode = Jurisdiction.JCode " &_ |
|
|
|
" As [LabelCount],[CreatedOn],[LabelsPrinted],[ExportedToSnailWorks],[JobType],[Status],[OutboundSTID],[InboundSTID],[OfficeCopiesAmount] FROM Kit INNER JOIN Jurisdiction ON Kit.Jcode = Jurisdiction.JCode " &_ |
|
|
|
"WHERE ID = ? " |
|
|
|
|
|
|
|
dim rs : set rs = DAL.Query(sql,ID) |
|
|
@@ -148,7 +150,7 @@ Class KitRepository_Class |
|
|
|
|
|
|
|
|
|
|
|
Public Function FindByID(ID) |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID] FROM [Kit] WHERE ID = ?" |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID], [OfficeCopiesAmount] FROM [Kit] WHERE ID = ?" |
|
|
|
dim rs : set rs = DAL.Query(sql,ID) |
|
|
|
If rs.EOF then |
|
|
|
Err.Raise 1, "KitRepository_Class", KitNotFoundException("ID", ID) |
|
|
@@ -162,7 +164,7 @@ Class KitRepository_Class |
|
|
|
End Function |
|
|
|
|
|
|
|
Public Function Find(where_kvarray, order_string_or_array) |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID] FROM [Kit]" |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID], [OfficeCopiesAmount] FROM [Kit]" |
|
|
|
|
|
|
|
If Not IsEmpty(where_kvarray) then |
|
|
|
sql = sql & " WHERE " |
|
|
@@ -195,7 +197,7 @@ Class KitRepository_Class |
|
|
|
End Function |
|
|
|
|
|
|
|
Public Function FindPaged(where_kvarray, order_string_or_array, per_page, page_num, ByRef page_count, ByRef record_count) |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID] FROM [Kit]" |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID], [OfficeCopiesAmount] FROM [Kit]" |
|
|
|
|
|
|
|
If Not IsEmpty(where_kvarray) then |
|
|
|
sql = sql & " WHERE " |
|
|
@@ -237,7 +239,7 @@ Class KitRepository_Class |
|
|
|
End Function |
|
|
|
|
|
|
|
Public Function SearchTablePaged(where_kvarray, order_string_or_array, per_page, page_num, ByRef page_count, ByRef record_count) |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID] FROM [Kit]" |
|
|
|
dim sql : sql = "Select [ID], [JobNumber], [Jcode], [CreatedOn], [LabelsPrinted], [ExportedToSnailWorks], [InkJetJob], [JobType], [Filename], [Cass], [Status], [OutboundSTID], [InboundSTID], [OfficeCopiesAmount] FROM [Kit]" |
|
|
|
|
|
|
|
If Not IsEmpty(where_kvarray) then |
|
|
|
sql = sql & " WHERE " |
|
|
@@ -332,7 +334,8 @@ Public Sub Update(model) |
|
|
|
"[Cass] = ?," &_ |
|
|
|
"[Status] = ?," &_ |
|
|
|
"[OutboundSTID] = ?," &_ |
|
|
|
"[InboundSTID] = ?" &_ |
|
|
|
"[InboundSTID] = ?," &_ |
|
|
|
"[OfficeCopiesAmount] = ?" &_ |
|
|
|
" WHERE [ID] = ?" |
|
|
|
|
|
|
|
DAL.Execute sql, Array(model.JobNumber, _ |
|
|
@@ -347,6 +350,7 @@ Public Sub Update(model) |
|
|
|
model.Status, _ |
|
|
|
model.OutboundSTID, _ |
|
|
|
model.InboundSTID, _ |
|
|
|
model.OfficeCopiesAmount, _ |
|
|
|
model.ID) |
|
|
|
End Sub |
|
|
|
|
|
|
|