@things-factory/operato-hub 4.3.744 → 4.3.745

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.
Files changed (25) hide show
  1. package/dist-server/routers/api/restful-apis/v1/company/add-contact-points.js +71 -2
  2. package/dist-server/routers/api/restful-apis/v1/company/add-contact-points.js.map +1 -1
  3. package/dist-server/routers/api/restful-apis/v1/company/index.js +1 -0
  4. package/dist-server/routers/api/restful-apis/v1/company/index.js.map +1 -1
  5. package/dist-server/routers/api/restful-apis/v1/company/update-contact-points.js +243 -0
  6. package/dist-server/routers/api/restful-apis/v1/company/update-contact-points.js.map +1 -0
  7. package/dist-server/routers/api/restful-apis/v1/utils/params.js +109 -28
  8. package/dist-server/routers/api/restful-apis/v1/utils/params.js.map +1 -1
  9. package/dist-server/routers/api/restful-apis/v1/warehouse/index.js +1 -0
  10. package/dist-server/routers/api/restful-apis/v1/warehouse/index.js.map +1 -1
  11. package/dist-server/routers/api/restful-apis/v1/warehouse/update-arrival-notice.js +365 -0
  12. package/dist-server/routers/api/restful-apis/v1/warehouse/update-arrival-notice.js.map +1 -0
  13. package/dist-server/routers/api/restful-apis/v1/warehouse/update-release-order-details.js +946 -19
  14. package/dist-server/routers/api/restful-apis/v1/warehouse/update-release-order-details.js.map +1 -1
  15. package/openapi/v1/contact-point.yaml +266 -0
  16. package/openapi/v1/inbound.yaml +349 -0
  17. package/openapi/v1/outbound.yaml +256 -150
  18. package/package.json +18 -18
  19. package/server/routers/api/restful-apis/v1/company/add-contact-points.ts +91 -2
  20. package/server/routers/api/restful-apis/v1/company/index.ts +1 -0
  21. package/server/routers/api/restful-apis/v1/company/update-contact-points.ts +267 -0
  22. package/server/routers/api/restful-apis/v1/utils/params.ts +109 -28
  23. package/server/routers/api/restful-apis/v1/warehouse/index.ts +1 -0
  24. package/server/routers/api/restful-apis/v1/warehouse/update-arrival-notice.ts +429 -0
  25. package/server/routers/api/restful-apis/v1/warehouse/update-release-order-details.ts +1122 -29
@@ -7,6 +7,71 @@ import { Bizplace } from '@things-factory/biz-base'
7
7
  import { ApiError, ApiErrorHandler, throwInternalServerError } from '../utils/error-util'
8
8
  import { businessMiddleware, loggingMiddleware, validationMiddleware } from '../middlewares'
9
9
 
10
+ const VALID_DAYS = ['MONDAY', 'TUESDAY', 'WEDNESDAY', 'THURSDAY', 'FRIDAY', 'SATURDAY', 'SUNDAY']
11
+ const VALID_TYPES = ['CUSTOMER', 'SUPPLIER', 'WAREHOUSE']
12
+
13
+ function validateBusinessRestDay(businessRestDay: any, index?: number): void {
14
+ if (businessRestDay === null || businessRestDay === undefined || businessRestDay === '') {
15
+ return // Allow null/empty values
16
+ }
17
+
18
+ if (typeof businessRestDay !== 'string') {
19
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
20
+ throw new ApiError('E01', `${prefix}businessRestDay must be a string. Valid options: ${VALID_DAYS.join(', ')}`)
21
+ }
22
+
23
+ const days = businessRestDay.split(',').map(day => day.trim().toUpperCase())
24
+ const invalidDays = days.filter(day => !VALID_DAYS.includes(day))
25
+
26
+ if (invalidDays.length > 0) {
27
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
28
+ throw new ApiError(
29
+ 'E01',
30
+ `${prefix}Invalid businessRestDay value(s): ${invalidDays.join(', ')}. Valid options: ${VALID_DAYS.join(', ')}`
31
+ )
32
+ }
33
+ }
34
+
35
+ function validateType(type: any, index?: number): void {
36
+ if (!type) {
37
+ return // Type is required but validation will be handled by reqParams
38
+ }
39
+
40
+ if (typeof type !== 'string') {
41
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
42
+ throw new ApiError('E01', `${prefix}type must be a string. Valid options: ${VALID_TYPES.join(', ')}`)
43
+ }
44
+
45
+ const upperType = type.toUpperCase()
46
+ if (!VALID_TYPES.includes(upperType)) {
47
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
48
+ throw new ApiError('E01', `${prefix}Invalid type value: ${type}. Valid options: ${VALID_TYPES.join(', ')}`)
49
+ }
50
+ }
51
+
52
+ function validateReleaseShelfLife(releaseShelfLife: any, index?: number): void {
53
+ if (releaseShelfLife === null || releaseShelfLife === undefined || releaseShelfLife === '') {
54
+ return // Allow null/empty values
55
+ }
56
+
57
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
58
+
59
+ // Check if it's a number
60
+ if (typeof releaseShelfLife !== 'number') {
61
+ throw new ApiError('E01', `${prefix}releaseShelfLife must be a number (integer >= 0)`)
62
+ }
63
+
64
+ // Check if it's an integer
65
+ if (!Number.isInteger(releaseShelfLife)) {
66
+ throw new ApiError('E01', `${prefix}releaseShelfLife must be an integer (no decimals allowed)`)
67
+ }
68
+
69
+ // Check if it's non-negative
70
+ if (releaseShelfLife < 0) {
71
+ throw new ApiError('E01', `${prefix}releaseShelfLife must be 0 or above (no negative values allowed)`)
72
+ }
73
+ }
74
+
10
75
  router.post(
11
76
  '/v1/company/add-contact-points',
12
77
  businessMiddleware,
@@ -28,7 +93,24 @@ router.post(
28
93
  const emails = []
29
94
  const ids = []
30
95
  let values = []
31
- for (const datapoint of context.request.body.data) {
96
+ for (let i = 0; i < context.request.body.data.length; i++) {
97
+ const datapoint = context.request.body.data[i]
98
+
99
+ // Validate businessRestDay
100
+ if (datapoint.hasOwnProperty('businessRestDay')) {
101
+ validateBusinessRestDay(datapoint.businessRestDay, i)
102
+ }
103
+
104
+ // Validate type
105
+ if (datapoint.hasOwnProperty('type')) {
106
+ validateType(datapoint.type, i)
107
+ }
108
+
109
+ // Validate releaseShelfLife
110
+ if (datapoint.hasOwnProperty('releaseShelfLife')) {
111
+ validateReleaseShelfLife(datapoint.releaseShelfLife, i)
112
+ }
113
+
32
114
  phones.push(datapoint.phone)
33
115
  emails.push(datapoint.email)
34
116
  if (datapoint.id) {
@@ -50,7 +132,13 @@ router.post(
50
132
  country: datapoint.country,
51
133
  releaseShelfLife: datapoint.releaseShelfLife,
52
134
  postCode: datapoint.postCode,
53
- type: datapoint.type,
135
+ type: datapoint.type ? datapoint.type.toUpperCase() : datapoint.type,
136
+ businessRestDay: datapoint.businessRestDay
137
+ ? datapoint.businessRestDay
138
+ .split(',')
139
+ .map(day => day.trim().toUpperCase())
140
+ .join(',')
141
+ : datapoint.businessRestDay,
54
142
  domain: context.state.domain,
55
143
  bizplace: bizplace,
56
144
  creator: context.state.user,
@@ -122,6 +210,7 @@ router.post(
122
210
  releaseShelfLife: contactPoint.releaseShelfLife,
123
211
  postCode: contactPoint.postCode,
124
212
  type: contactPoint.type,
213
+ businessRestDay: contactPoint.businessRestDay,
125
214
  createdAt: contactPoint.createdAt
126
215
  }
127
216
  data.push(datapoint)
@@ -1,4 +1,5 @@
1
1
  import './add-contact-points'
2
+ import './update-contact-points'
2
3
  import './add-products'
3
4
  import './get-bizplace-list'
4
5
  import './get-contact-point-list'
@@ -0,0 +1,267 @@
1
+ import { getConnection, EntityManager, In, Brackets } from 'typeorm'
2
+
3
+ import { restfulApiRouter as router } from '@things-factory/api'
4
+ import { ContactPoint } from '@things-factory/biz-base'
5
+ import { Bizplace } from '@things-factory/biz-base'
6
+
7
+ import { ApiError, ApiErrorHandler, throwInternalServerError } from '../utils/error-util'
8
+ import { businessMiddleware, loggingMiddleware, validationMiddleware } from '../middlewares'
9
+
10
+ const VALID_DAYS = ['MONDAY', 'TUESDAY', 'WEDNESDAY', 'THURSDAY', 'FRIDAY', 'SATURDAY', 'SUNDAY']
11
+ const VALID_TYPES = ['CUSTOMER', 'SUPPLIER', 'WAREHOUSE']
12
+
13
+ function validateBusinessRestDay(businessRestDay: any, index?: number): void {
14
+ if (businessRestDay === null || businessRestDay === undefined || businessRestDay === '') {
15
+ return // Allow null/empty values
16
+ }
17
+
18
+ if (typeof businessRestDay !== 'string') {
19
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
20
+ throw new ApiError('E01', `${prefix}businessRestDay must be a string. Valid options: ${VALID_DAYS.join(', ')}`)
21
+ }
22
+
23
+ const days = businessRestDay.split(',').map(day => day.trim().toUpperCase())
24
+ const invalidDays = days.filter(day => !VALID_DAYS.includes(day))
25
+
26
+ if (invalidDays.length > 0) {
27
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
28
+ throw new ApiError(
29
+ 'E01',
30
+ `${prefix}Invalid businessRestDay value(s): ${invalidDays.join(', ')}. Valid options: ${VALID_DAYS.join(', ')}`
31
+ )
32
+ }
33
+ }
34
+
35
+ function validateType(type: any, index?: number): void {
36
+ if (!type) {
37
+ return // Type is optional for updates
38
+ }
39
+
40
+ if (typeof type !== 'string') {
41
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
42
+ throw new ApiError('E01', `${prefix}type must be a string. Valid options: ${VALID_TYPES.join(', ')}`)
43
+ }
44
+
45
+ const upperType = type.toUpperCase()
46
+ if (!VALID_TYPES.includes(upperType)) {
47
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
48
+ throw new ApiError('E01', `${prefix}Invalid type value: ${type}. Valid options: ${VALID_TYPES.join(', ')}`)
49
+ }
50
+ }
51
+
52
+ function validateReleaseShelfLife(releaseShelfLife: any, index?: number): void {
53
+ if (releaseShelfLife === null || releaseShelfLife === undefined || releaseShelfLife === '') {
54
+ return // Allow null/empty values
55
+ }
56
+
57
+ const prefix = index !== undefined ? `Contact point at index ${index}: ` : ''
58
+
59
+ // Check if it's a number
60
+ if (typeof releaseShelfLife !== 'number') {
61
+ throw new ApiError('E01', `${prefix}releaseShelfLife must be a number (integer >= 0)`)
62
+ }
63
+
64
+ // Check if it's an integer
65
+ if (!Number.isInteger(releaseShelfLife)) {
66
+ throw new ApiError('E01', `${prefix}releaseShelfLife must be an integer (no decimals allowed)`)
67
+ }
68
+
69
+ // Check if it's non-negative
70
+ if (releaseShelfLife < 0) {
71
+ throw new ApiError('E01', `${prefix}releaseShelfLife must be 0 or above (no negative values allowed)`)
72
+ }
73
+ }
74
+
75
+ router.post(
76
+ '/v1/company/update-contact-points',
77
+ businessMiddleware,
78
+ validationMiddleware,
79
+ loggingMiddleware,
80
+ async (context, next) => {
81
+ try {
82
+ if (!Array.isArray(context.request.body.data)) throw new ApiError('E01', 'data field is not an array')
83
+ if (!context.request.body.hasOwnProperty('bizplaceId')) throw new ApiError('E03', 'bizplaceId')
84
+ if (!context.request.body.bizplaceId) throw new ApiError('E01', 'bizplaceId')
85
+ await getConnection().transaction(async (tx: EntityManager) => {
86
+ // Validate that all contact points have IDs
87
+ const ids = []
88
+ for (const datapoint of context.request.body.data) {
89
+ if (!datapoint.id) {
90
+ throw new ApiError('E01', 'All contact points must have an id field for update')
91
+ }
92
+ ids.push(datapoint.id)
93
+ }
94
+
95
+ // Verify that all contact points exist
96
+ const existingContactPoints: ContactPoint[] = await tx
97
+ .getRepository(ContactPoint)
98
+ .createQueryBuilder('cp')
99
+ .where('cp.id IN (:...ids)', { ids })
100
+ .andWhere('cp.bizplace_id = :bizplaceId', { bizplaceId: context.request.body.bizplaceId })
101
+ .getMany()
102
+
103
+ if (existingContactPoints.length !== ids.length) {
104
+ const foundIds = existingContactPoints.map(cp => cp.id)
105
+ const missingIds = ids.filter(id => !foundIds.includes(id))
106
+ throw new ApiError('E04', `Contact point(s) not found: ${missingIds.join(', ')}`)
107
+ }
108
+
109
+ // Get bizplace
110
+ const bizplace: Bizplace = await tx.getRepository(Bizplace).findOne({
111
+ where: { id: context.request.body.bizplaceId }
112
+ })
113
+
114
+ if (!bizplace) {
115
+ throw new ApiError('E04', 'Bizplace not found')
116
+ }
117
+
118
+ // Check for duplicate email or phone within the batch
119
+ const phones = []
120
+ const emails = []
121
+ const phoneToIdMap = new Map()
122
+ const emailToIdMap = new Map()
123
+
124
+ for (let i = 0; i < context.request.body.data.length; i++) {
125
+ const datapoint = context.request.body.data[i]
126
+
127
+ // Validate businessRestDay
128
+ if (datapoint.hasOwnProperty('businessRestDay')) {
129
+ validateBusinessRestDay(datapoint.businessRestDay, i)
130
+ }
131
+
132
+ // Validate type
133
+ if (datapoint.hasOwnProperty('type')) {
134
+ validateType(datapoint.type, i)
135
+ }
136
+
137
+ // Validate releaseShelfLife
138
+ if (datapoint.hasOwnProperty('releaseShelfLife')) {
139
+ validateReleaseShelfLife(datapoint.releaseShelfLife, i)
140
+ }
141
+
142
+ if (datapoint.phone) {
143
+ phones.push(datapoint.phone)
144
+ if (phoneToIdMap.has(datapoint.phone)) {
145
+ throw new ApiError('E05', `Duplicate phone number in update batch: ${datapoint.phone}`)
146
+ }
147
+ phoneToIdMap.set(datapoint.phone, datapoint.id)
148
+ }
149
+ if (datapoint.email) {
150
+ emails.push(datapoint.email)
151
+ if (emailToIdMap.has(datapoint.email)) {
152
+ throw new ApiError('E05', `Duplicate email in update batch: ${datapoint.email}`)
153
+ }
154
+ emailToIdMap.set(datapoint.email, datapoint.id)
155
+ }
156
+ }
157
+
158
+ // Check for duplicate email or phone in existing records (excluding the records being updated)
159
+ if (phones.length > 0 || emails.length > 0) {
160
+ const checkDuplicateEmailPhone: ContactPoint[] = await tx
161
+ .getRepository(ContactPoint)
162
+ .createQueryBuilder('cp')
163
+ .where('cp.bizplace_id = :bizplaceId', { bizplaceId: context.request.body.bizplaceId })
164
+ .andWhere('cp.id NOT IN (:...ids)', { ids })
165
+ .andWhere(
166
+ new Brackets(qb => {
167
+ if (emails.length > 0) {
168
+ qb.where('cp.email IN (:...emails)', { emails })
169
+ }
170
+ if (phones.length > 0) {
171
+ if (emails.length > 0) {
172
+ qb.orWhere('cp.phone IN (:...phones)', { phones })
173
+ } else {
174
+ qb.where('cp.phone IN (:...phones)', { phones })
175
+ }
176
+ }
177
+ })
178
+ )
179
+ .getMany()
180
+
181
+ if (checkDuplicateEmailPhone.length > 0) {
182
+ const duplicates = checkDuplicateEmailPhone.map(cp => ({
183
+ id: cp.id,
184
+ email: cp.email,
185
+ phone: cp.phone
186
+ }))
187
+ throw new ApiError('E05', `Duplicate email or phone number found: ${JSON.stringify(duplicates)}`)
188
+ }
189
+ }
190
+
191
+ // Update contact points
192
+ const updatedContactPoints: ContactPoint[] = []
193
+ for (const datapoint of context.request.body.data) {
194
+ const existingContactPoint = existingContactPoints.find(cp => cp.id === datapoint.id)
195
+
196
+ // Only update fields that are explicitly provided
197
+ const updateData: any = {
198
+ updater: context.state.user
199
+ }
200
+
201
+ if (datapoint.hasOwnProperty('name')) updateData.name = datapoint.name
202
+ if (datapoint.hasOwnProperty('description')) updateData.description = datapoint.description
203
+ if (datapoint.hasOwnProperty('companyName')) updateData.companyName = datapoint.companyName
204
+ if (datapoint.hasOwnProperty('email')) updateData.email = datapoint.email
205
+ if (datapoint.hasOwnProperty('fax')) updateData.fax = datapoint.fax
206
+ if (datapoint.hasOwnProperty('phone')) updateData.phone = datapoint.phone
207
+ if (datapoint.hasOwnProperty('billingAddress')) updateData.billingAddress = datapoint.billingAddress
208
+ if (datapoint.hasOwnProperty('accountNo')) updateData.accountNo = datapoint.accountNo
209
+ if (datapoint.hasOwnProperty('address')) updateData.address = datapoint.address
210
+ if (datapoint.hasOwnProperty('address2')) updateData.address2 = datapoint.address2
211
+ if (datapoint.hasOwnProperty('city')) updateData.city = datapoint.city
212
+ if (datapoint.hasOwnProperty('state')) updateData.state = datapoint.state
213
+ if (datapoint.hasOwnProperty('country')) updateData.country = datapoint.country
214
+ if (datapoint.hasOwnProperty('releaseShelfLife')) updateData.releaseShelfLife = datapoint.releaseShelfLife
215
+ if (datapoint.hasOwnProperty('postCode')) updateData.postCode = datapoint.postCode
216
+ if (datapoint.hasOwnProperty('type'))
217
+ updateData.type = datapoint.type ? datapoint.type.toUpperCase() : datapoint.type
218
+ if (datapoint.hasOwnProperty('businessRestDay'))
219
+ updateData.businessRestDay = datapoint.businessRestDay
220
+ ? datapoint.businessRestDay
221
+ .split(',')
222
+ .map(day => day.trim().toUpperCase())
223
+ .join(',')
224
+ : datapoint.businessRestDay
225
+
226
+ const updated = await tx.getRepository(ContactPoint).save({
227
+ ...existingContactPoint,
228
+ ...updateData
229
+ })
230
+
231
+ updatedContactPoints.push(updated)
232
+ }
233
+
234
+ // Format response
235
+ const data = updatedContactPoints.map(contactPoint => ({
236
+ id: contactPoint.id,
237
+ name: contactPoint.name,
238
+ description: contactPoint.description,
239
+ companyName: contactPoint.companyName,
240
+ email: contactPoint.email,
241
+ fax: contactPoint.fax,
242
+ phone: contactPoint.phone,
243
+ billingAddress: contactPoint.billingAddress,
244
+ accountNo: contactPoint.accountNo,
245
+ address: contactPoint.address,
246
+ address2: contactPoint.address2,
247
+ city: contactPoint.city,
248
+ state: contactPoint.state,
249
+ country: contactPoint.country,
250
+ releaseShelfLife: contactPoint.releaseShelfLife,
251
+ postCode: contactPoint.postCode,
252
+ type: contactPoint.type,
253
+ businessRestDay: contactPoint.businessRestDay,
254
+ createdAt: contactPoint.createdAt,
255
+ updatedAt: contactPoint.updatedAt
256
+ }))
257
+
258
+ context.body = {
259
+ data
260
+ }
261
+ })
262
+ } catch (e) {
263
+ if (e instanceof ApiError) ApiErrorHandler(context, e)
264
+ else throwInternalServerError(context, e)
265
+ }
266
+ }
267
+ )
@@ -99,7 +99,29 @@ export const params = {
99
99
  'country',
100
100
  'releaseShelfLife',
101
101
  'postCode',
102
- 'type'
102
+ 'type',
103
+ 'businessRestDay'
104
+ ],
105
+ 'update-contact-points': [
106
+ 'bizplaceId',
107
+ 'id',
108
+ 'name',
109
+ 'companyName',
110
+ 'description',
111
+ 'email',
112
+ 'fax',
113
+ 'phone',
114
+ 'billingAddress',
115
+ 'accountNo',
116
+ 'address',
117
+ 'address2',
118
+ 'city',
119
+ 'state',
120
+ 'country',
121
+ 'releaseShelfLife',
122
+ 'postCode',
123
+ 'type',
124
+ 'businessRestDay'
103
125
  ],
104
126
  'add-marketplace-order': [
105
127
  'storeId',
@@ -452,33 +474,78 @@ export const params = {
452
474
  'bizplaceId',
453
475
  'releaseGood',
454
476
  'releaseGood.roId',
455
- 'releaseGood.collectionOrderNo',
477
+ 'releaseGood.refOrderId',
456
478
  'releaseGood.refNo',
457
479
  'releaseGood.refNo2',
458
480
  'releaseGood.refNo3',
459
- 'releaseGood.refOrderId',
460
- 'releaseGood.marketplaceOrderStatus',
461
- 'releaseGood.billingAddress',
462
- 'releaseGood.deliveryAddress1',
463
- 'releaseGood.attentionTo',
464
- 'releaseGood.city',
465
- 'releaseGood.ward',
466
- 'releaseGood.district',
467
- 'releaseGood.country',
468
- 'releaseGood.postalCode',
469
- 'releaseGood.phone1',
470
- 'releaseGood.transporter',
471
- 'releaseGood.trackingNo',
472
- 'releaseGood.airwayBill',
473
- 'releaseGood.invoice',
481
+ 'releaseGood.description',
482
+ 'releaseGood.truckNo',
483
+ 'releaseGood.collectionOrderNo',
484
+ 'releaseGood.releaseDate',
485
+ 'releaseGood.ownTransport',
486
+ 'releaseGood.exportOption',
487
+ 'releaseGood.packingOption',
488
+ 'releaseGood.courierOption',
489
+ 'releaseGood.remark',
474
490
  'shippingOrder',
475
- 'shippingOrder.shipName',
476
491
  'shippingOrder.containerNo',
477
- 'shippingOrder.loadType',
478
- 'shippingOrder.from',
479
- 'shippingOrder.to',
480
492
  'shippingOrder.containerArrivalDate',
481
- 'shippingOrder.containerLeavingDate'
493
+ 'shippingOrder.containerLeavingDate',
494
+ 'shippingOrder.containerClosureDate',
495
+ 'shippingOrder.containerSize',
496
+ 'shippingOrder.remark',
497
+ 'shippingOrder.exportRemark',
498
+ 'orderProducts',
499
+ 'orderProducts.id',
500
+ 'orderProducts.product',
501
+ 'orderProducts.product.sku',
502
+ 'orderProducts.product.refCode',
503
+ 'orderProducts.sku',
504
+ 'orderProducts.refCode',
505
+ 'orderProducts.batchId',
506
+ 'orderProducts.packingType',
507
+ 'orderProducts.packingSize',
508
+ 'orderProducts.releaseQty',
509
+ 'orderProducts.qty',
510
+ 'orderProducts.refItemId',
511
+ 'orderProducts.unitPrice',
512
+ 'orderProducts.remark',
513
+ 'orderProducts._action'
514
+ ],
515
+ 'update-arrival-notice': [
516
+ 'arrivalNoticeId',
517
+ 'ganNo',
518
+ 'refNo',
519
+ 'refNo2',
520
+ 'refNo3',
521
+ 'etaDate',
522
+ 'ownTransport',
523
+ 'importCargo',
524
+ 'container',
525
+ 'containerNo',
526
+ 'containerSize',
527
+ 'truckNo',
528
+ 'deliveryOrderNo',
529
+ 'remark',
530
+ 'description',
531
+ 'supplierId',
532
+ 'orderProducts',
533
+ 'orderProducts.id',
534
+ 'orderProducts.product',
535
+ 'orderProducts.product.sku',
536
+ 'orderProducts.product.refCode',
537
+ 'orderProducts.sku',
538
+ 'orderProducts.refCode',
539
+ 'orderProducts.batchId',
540
+ 'orderProducts.packingType',
541
+ 'orderProducts.packingSize',
542
+ 'orderProducts.qty',
543
+ 'orderProducts.packQty',
544
+ 'orderProducts.refItemId',
545
+ 'orderProducts.unitPrice',
546
+ 'orderProducts.manufactureDate',
547
+ 'orderProducts.remark',
548
+ 'orderProducts._action'
482
549
  ],
483
550
  'update-marketplace-shipping-order': ['storeId', 'orderNo', 'transporter', 'airwayBill', 'trackingNo'],
484
551
  'get-grn-document': ['fileType', 'bizplaceId', 'grnNo', 'timezoneOffSet'],
@@ -932,6 +999,13 @@ export const reqParams = {
932
999
  type: 'field'
933
1000
  }
934
1001
  ],
1002
+ 'update-contact-points': [
1003
+ {
1004
+ name: 'id',
1005
+ required: true,
1006
+ type: 'field'
1007
+ }
1008
+ ],
935
1009
  'add-marketplace-order': [
936
1010
  {
937
1011
  name: 'storeId',
@@ -1216,12 +1290,19 @@ export const reqParams = {
1216
1290
  name: 'shippingOrder',
1217
1291
  required: false,
1218
1292
  type: 'object',
1219
- data: [
1220
- { name: 'shipName', required: true, type: 'field' },
1221
- { name: 'containerNo', required: true, type: 'field' },
1222
- { name: 'containerArrivalDate', required: true, type: 'field' },
1223
- { name: 'containerLeavingDate', required: true, type: 'field' }
1224
- ]
1293
+ data: []
1294
+ }
1295
+ ],
1296
+ 'update-arrival-notice': [
1297
+ {
1298
+ name: 'arrivalNoticeId',
1299
+ required: false,
1300
+ type: 'field'
1301
+ },
1302
+ {
1303
+ name: 'ganNo',
1304
+ required: false,
1305
+ type: 'field'
1225
1306
  }
1226
1307
  ],
1227
1308
  'update-order-package-details': [
@@ -28,4 +28,5 @@ import './add-inventory-adjustment'
28
28
  import './update-gan-to-arrived'
29
29
  import './update-order-package-details'
30
30
  import './update-release-order-details'
31
+ import './update-arrival-notice'
31
32
  import './upload-attachments'