Compare commits
2 Commits
8f430574ed
...
d2db62339f
Author | SHA1 | Date |
---|---|---|
|
d2db62339f | |
|
07d1cc78e2 |
|
@ -134,7 +134,15 @@ export class ItemDto extends BaseStatusDto implements ItemEntity {
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
})
|
})
|
||||||
@IsArray()
|
@IsArray({
|
||||||
|
message: (body) => {
|
||||||
|
const value = body.value;
|
||||||
|
if (!value || value?.length === 0) {
|
||||||
|
return 'Product bundling tidak boleh kosong.';
|
||||||
|
}
|
||||||
|
return 'Product bundling tidak sesuai.';
|
||||||
|
},
|
||||||
|
})
|
||||||
@ValidateIf((body) => body.item_type.toLowerCase() == ItemType.BUNDLING)
|
@ValidateIf((body) => body.item_type.toLowerCase() == ItemType.BUNDLING)
|
||||||
bundling_items: ItemEntity[];
|
bundling_items: ItemEntity[];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue