@ricado/api-client 2.3.28 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ricado.api.client.js +1 -1
- package/lib/Controllers/Lab/Site/DehydratorController.js +198 -0
- package/lib/Controllers/Lab/Site/FruitProfileController.js +204 -0
- package/lib/Controllers/Lab/Site/LabController.js +222 -0
- package/lib/Controllers/Lab/Site/RackController.js +222 -0
- package/lib/Controllers/Lab/Site/RackPositionController.js +207 -0
- package/lib/Controllers/Lab/Site/SampleController.js +1023 -0
- package/lib/Controllers/Lab/Site/SampleFailureReasonController.js +192 -0
- package/lib/Controllers/Lab/Site/SampleResultController.js +905 -0
- package/lib/Controllers/Lab/Site/index.js +46 -0
- package/lib/Controllers/Lab/index.js +25 -0
- package/lib/Controllers/Packhouse/Site/ShiftController.js +304 -0
- package/lib/Controllers/index.js +9 -6
- package/lib/Models/Lab/Site/DehydratorModel.js +250 -0
- package/lib/Models/Lab/Site/FruitProfileModel.js +303 -0
- package/lib/Models/Lab/Site/LabModel.js +365 -0
- package/lib/Models/Lab/Site/RackModel.js +358 -0
- package/lib/Models/Lab/Site/RackPositionModel.js +525 -0
- package/lib/Models/Lab/Site/SampleFailureReasonModel.js +195 -0
- package/lib/Models/Lab/Site/SampleModel.js +545 -0
- package/lib/Models/Lab/Site/SampleResultModel.js +545 -0
- package/lib/Models/Lab/Site/index.js +46 -0
- package/lib/Models/Lab/index.js +25 -0
- package/lib/Models/index.js +7 -4
- package/lib/PackageVersion.js +1 -1
- package/lib/index.d.ts +10441 -7526
- package/package.json +1 -1
- package/src/Controllers/Lab/Site/DehydratorController.js +175 -0
- package/src/Controllers/Lab/Site/FruitProfileController.js +181 -0
- package/src/Controllers/Lab/Site/LabController.js +199 -0
- package/src/Controllers/Lab/Site/RackController.js +199 -0
- package/src/Controllers/Lab/Site/RackPositionController.js +184 -0
- package/src/Controllers/Lab/Site/SampleController.js +1160 -0
- package/src/Controllers/Lab/Site/SampleFailureReasonController.js +169 -0
- package/src/Controllers/Lab/Site/SampleResultController.js +1036 -0
- package/src/Controllers/Lab/Site/index.js +30 -0
- package/src/Controllers/Lab/index.js +16 -0
- package/src/Controllers/Packhouse/Site/ShiftController.js +367 -0
- package/src/Controllers/index.js +2 -0
- package/src/Models/Lab/Site/DehydratorModel.js +234 -0
- package/src/Models/Lab/Site/FruitProfileModel.js +290 -0
- package/src/Models/Lab/Site/LabModel.js +372 -0
- package/src/Models/Lab/Site/RackModel.js +358 -0
- package/src/Models/Lab/Site/RackPositionModel.js +600 -0
- package/src/Models/Lab/Site/SampleFailureReasonModel.js +170 -0
- package/src/Models/Lab/Site/SampleModel.js +565 -0
- package/src/Models/Lab/Site/SampleResultModel.js +565 -0
- package/src/Models/Lab/Site/index.js +30 -0
- package/src/Models/Lab/index.js +16 -0
- package/src/Models/index.js +2 -0
- package/src/PackageVersion.js +1 -1
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* File Auto-Generated by the RICADO Gen 4 PHP API Project
|
|
3
|
+
*
|
|
4
|
+
* Do Not Edit this File Manually!
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import BaseModel from '../../../Models/BaseModel';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Model Class for a Sample Failure Reason
|
|
11
|
+
*
|
|
12
|
+
* @class
|
|
13
|
+
* @hideconstructor
|
|
14
|
+
* @extends BaseModel
|
|
15
|
+
*/
|
|
16
|
+
class SampleFailureReasonModel extends BaseModel
|
|
17
|
+
{
|
|
18
|
+
/**
|
|
19
|
+
* SampleFailureReasonModel Constructor
|
|
20
|
+
*
|
|
21
|
+
* @protected
|
|
22
|
+
* @param {number} siteId The Site ID associated with this Sample Failure Reason
|
|
23
|
+
*/
|
|
24
|
+
constructor(siteId)
|
|
25
|
+
{
|
|
26
|
+
super();
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* The Sample Failure Reason ID
|
|
30
|
+
*
|
|
31
|
+
* @type {string}
|
|
32
|
+
* @public
|
|
33
|
+
*/
|
|
34
|
+
this.id = "";
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* The Sample Failure Reason Name
|
|
38
|
+
*
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @public
|
|
41
|
+
*/
|
|
42
|
+
this.name = "";
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* The Sample Failure Reason Description
|
|
46
|
+
*
|
|
47
|
+
* @type {string}
|
|
48
|
+
* @public
|
|
49
|
+
*/
|
|
50
|
+
this.description = "";
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Whether the Sample Failure Reason has been deleted
|
|
54
|
+
*
|
|
55
|
+
* @type {boolean}
|
|
56
|
+
* @public
|
|
57
|
+
*/
|
|
58
|
+
this.deleted = false;
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* When the Sample Failure Reason was last updated
|
|
62
|
+
*
|
|
63
|
+
* @type {Date}
|
|
64
|
+
* @public
|
|
65
|
+
*/
|
|
66
|
+
this.updateTimestamp = new Date();
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* The Site ID associated with this Sample Failure Reason
|
|
70
|
+
*
|
|
71
|
+
* @type {number}
|
|
72
|
+
* @public
|
|
73
|
+
*/
|
|
74
|
+
this.siteId = siteId;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* Create a new **SampleFailureReasonModel** from a JSON Object or JSON String
|
|
79
|
+
*
|
|
80
|
+
* @static
|
|
81
|
+
* @public
|
|
82
|
+
* @param {Object<string, any>|string} json A JSON Object or JSON String
|
|
83
|
+
* @param {number} siteId The Site ID associated with this Sample Failure Reason
|
|
84
|
+
* @return {SampleFailureReasonModel}
|
|
85
|
+
*/
|
|
86
|
+
static fromJSON(json, siteId)
|
|
87
|
+
{
|
|
88
|
+
let model = new SampleFailureReasonModel(siteId);
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* The JSON Object
|
|
92
|
+
*
|
|
93
|
+
* @type {Object<string, any>}
|
|
94
|
+
*/
|
|
95
|
+
let jsonObject = {};
|
|
96
|
+
|
|
97
|
+
if(typeof json === 'string')
|
|
98
|
+
{
|
|
99
|
+
jsonObject = JSON.parse(json);
|
|
100
|
+
}
|
|
101
|
+
else if(typeof json === 'object')
|
|
102
|
+
{
|
|
103
|
+
jsonObject = json;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
if('id' in jsonObject)
|
|
107
|
+
{
|
|
108
|
+
model.id = (function(){
|
|
109
|
+
if(typeof jsonObject['id'] !== 'string')
|
|
110
|
+
{
|
|
111
|
+
return String(jsonObject['id']);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
return jsonObject['id'];
|
|
115
|
+
}());
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
if('name' in jsonObject)
|
|
119
|
+
{
|
|
120
|
+
model.name = (function(){
|
|
121
|
+
if(typeof jsonObject['name'] !== 'string')
|
|
122
|
+
{
|
|
123
|
+
return String(jsonObject['name']);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
return jsonObject['name'];
|
|
127
|
+
}());
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
if('description' in jsonObject)
|
|
131
|
+
{
|
|
132
|
+
model.description = (function(){
|
|
133
|
+
if(typeof jsonObject['description'] !== 'string')
|
|
134
|
+
{
|
|
135
|
+
return String(jsonObject['description']);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
return jsonObject['description'];
|
|
139
|
+
}());
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
if('deleted' in jsonObject)
|
|
143
|
+
{
|
|
144
|
+
model.deleted = (function(){
|
|
145
|
+
if(typeof jsonObject['deleted'] !== 'boolean')
|
|
146
|
+
{
|
|
147
|
+
return Boolean(jsonObject['deleted']);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
return jsonObject['deleted'];
|
|
151
|
+
}());
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
if('updateTimestamp' in jsonObject)
|
|
155
|
+
{
|
|
156
|
+
model.updateTimestamp = (function(){
|
|
157
|
+
if(typeof jsonObject['updateTimestamp'] !== 'string')
|
|
158
|
+
{
|
|
159
|
+
return new Date(String(jsonObject['updateTimestamp']));
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
return new Date(jsonObject['updateTimestamp']);
|
|
163
|
+
}());
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
return model;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export default SampleFailureReasonModel;
|