2017-12-19 11:29:35 +00:00
|
|
|
{
|
|
|
|
"name": "Item",
|
2020-02-17 06:22:55 +00:00
|
|
|
"base": "Loggable",
|
|
|
|
"log": {
|
|
|
|
"model": "ItemLog",
|
2019-04-04 10:38:54 +00:00
|
|
|
"showField": "id"
|
2020-02-17 06:22:55 +00:00
|
|
|
},
|
2017-12-19 11:29:35 +00:00
|
|
|
"options": {
|
|
|
|
"mysql": {
|
2020-02-17 06:22:55 +00:00
|
|
|
"table": "item"
|
2017-12-19 11:29:35 +00:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"properties": {
|
2018-07-24 05:34:14 +00:00
|
|
|
"id": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2018-07-24 05:34:14 +00:00
|
|
|
"id": true,
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Id"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"name": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Name"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"size": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Size"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"category": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Category"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
2019-01-16 07:46:40 +00:00
|
|
|
"typeFk": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Type",
|
2019-01-16 07:46:40 +00:00
|
|
|
"required": true
|
|
|
|
},
|
2018-07-24 05:34:14 +00:00
|
|
|
"stems": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Stems"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"description": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Description"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"isOnOffer": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "boolean",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Offer"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"isBargain": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "boolean",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Bargain"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
2018-10-16 11:18:24 +00:00
|
|
|
"isActive": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "boolean",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Active"
|
2018-10-16 11:18:24 +00:00
|
|
|
},
|
2018-07-24 05:34:14 +00:00
|
|
|
"comment": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Comment"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"relevancy": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Relevancy"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
2018-12-17 13:15:39 +00:00
|
|
|
"density": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Density"
|
2018-12-17 13:15:39 +00:00
|
|
|
},
|
2021-01-18 10:43:48 +00:00
|
|
|
"stemMultiplier": {
|
2021-01-18 16:17:02 +00:00
|
|
|
"type": "number",
|
2021-01-18 10:43:48 +00:00
|
|
|
"description": "Multiplier"
|
2021-02-03 11:43:30 +00:00
|
|
|
},
|
|
|
|
"image": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Image"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"longName": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Long name"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"subName": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Subname"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"tag5": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"value5": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"tag6": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"value6": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"tag7": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"value7": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"tag8": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-07-24 05:34:14 +00:00
|
|
|
},
|
|
|
|
"value8": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-11-06 09:49:38 +00:00
|
|
|
},
|
|
|
|
"tag9": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-11-06 09:49:38 +00:00
|
|
|
},
|
|
|
|
"value9": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-11-06 09:49:38 +00:00
|
|
|
},
|
|
|
|
"tag10": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2018-11-06 09:49:38 +00:00
|
|
|
},
|
|
|
|
"value10": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "string"
|
2019-09-12 10:27:19 +00:00
|
|
|
},
|
2020-09-17 07:58:00 +00:00
|
|
|
"compression": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number"
|
2020-09-17 07:58:00 +00:00
|
|
|
},
|
2019-09-12 10:27:19 +00:00
|
|
|
"hasKgPrice": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "boolean",
|
2019-10-28 16:31:33 +00:00
|
|
|
"description": "Price per Kg"
|
2019-12-13 10:59:25 +00:00
|
|
|
},
|
2021-05-19 12:15:28 +00:00
|
|
|
"family": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The item family"
|
|
|
|
},
|
2019-12-13 10:59:25 +00:00
|
|
|
"expenseFk": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "number",
|
2019-12-13 10:59:25 +00:00
|
|
|
"mysql": {
|
|
|
|
"columnName": "expenceFk"
|
|
|
|
}
|
2020-08-27 15:54:43 +00:00
|
|
|
},
|
|
|
|
"minPrice": {
|
|
|
|
"type": "number"
|
2020-09-17 07:58:00 +00:00
|
|
|
},
|
2021-01-18 13:17:01 +00:00
|
|
|
"hasMinPrice": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
2020-09-17 07:58:00 +00:00
|
|
|
"isFragile": {
|
2021-01-18 13:17:01 +00:00
|
|
|
"type": "boolean"
|
2018-07-24 05:34:14 +00:00
|
|
|
}
|
2017-12-19 13:58:14 +00:00
|
|
|
},
|
|
|
|
"relations": {
|
2020-02-17 06:22:55 +00:00
|
|
|
"itemType": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "ItemType",
|
|
|
|
"foreignKey": "typeFk"
|
|
|
|
},
|
|
|
|
"ink": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Ink",
|
|
|
|
"foreignKey": "inkFk"
|
|
|
|
},
|
|
|
|
"origin": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Origin",
|
|
|
|
"foreignKey": "originFk"
|
|
|
|
},
|
|
|
|
"producer": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Producer",
|
|
|
|
"foreignKey": "producerFk"
|
|
|
|
},
|
|
|
|
"intrastat": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Intrastat",
|
|
|
|
"foreignKey": "intrastatFk"
|
|
|
|
},
|
|
|
|
"expense": {
|
|
|
|
"type": "belongsTo",
|
|
|
|
"model": "Expense",
|
|
|
|
"foreignKey": "expenseFk"
|
|
|
|
},
|
|
|
|
"tags": {
|
|
|
|
"type": "hasMany",
|
|
|
|
"model": "ItemTag",
|
|
|
|
"foreignKey": "itemFk"
|
|
|
|
},
|
|
|
|
"itemBarcode": {
|
|
|
|
"type": "hasMany",
|
|
|
|
"model": "ItemBarcode",
|
|
|
|
"foreignKey": "itemFk"
|
|
|
|
},
|
|
|
|
"taxes": {
|
|
|
|
"type": "hasMany",
|
|
|
|
"model": "ItemTaxCountry",
|
|
|
|
"foreignKey": "itemFk"
|
|
|
|
},
|
|
|
|
"itemNiche": {
|
|
|
|
"type": "hasMany",
|
|
|
|
"model": "ItemNiche",
|
|
|
|
"foreignKey": "itemFk"
|
2021-05-19 12:15:28 +00:00
|
|
|
},
|
|
|
|
"packaging": {
|
|
|
|
"type": "hasOne",
|
|
|
|
"model": "Packaging",
|
|
|
|
"foreignKey": "itemFk"
|
2020-02-17 06:22:55 +00:00
|
|
|
}
|
2020-03-11 14:56:02 +00:00
|
|
|
},
|
|
|
|
"scope": {
|
|
|
|
"where": {
|
|
|
|
"name": {
|
|
|
|
"neq": ""
|
|
|
|
}
|
|
|
|
}
|
2017-12-19 11:29:35 +00:00
|
|
|
}
|
2020-02-17 06:22:55 +00:00
|
|
|
}
|