| @@ -35,16 +35,6 @@ | |||||
| "plugin": "upload", | "plugin": "upload", | ||||
| "required": false | "required": false | ||||
| }, | }, | ||||
| "category_sparepart": { | |||||
| "type": "enumeration", | |||||
| "enum": [ | |||||
| "YGP", | |||||
| "Yamalube", | |||||
| "Helmet", | |||||
| "Apparel", | |||||
| "Accessories" | |||||
| ] | |||||
| }, | |||||
| "stock": { | "stock": { | ||||
| "type": "string" | "type": "string" | ||||
| } | } | ||||
| @@ -0,0 +1,52 @@ | |||||
| { | |||||
| "routes": [ | |||||
| { | |||||
| "method": "GET", | |||||
| "path": "/yamalubes", | |||||
| "handler": "yamalube.find", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "GET", | |||||
| "path": "/yamalubes/count", | |||||
| "handler": "yamalube.count", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "GET", | |||||
| "path": "/yamalubes/:id", | |||||
| "handler": "yamalube.findOne", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "POST", | |||||
| "path": "/yamalubes", | |||||
| "handler": "yamalube.create", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "PUT", | |||||
| "path": "/yamalubes/:id", | |||||
| "handler": "yamalube.update", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "DELETE", | |||||
| "path": "/yamalubes/:id", | |||||
| "handler": "yamalube.delete", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| } | |||||
| ] | |||||
| } | |||||
| @@ -0,0 +1,8 @@ | |||||
| 'use strict'; | |||||
| /** | |||||
| * Read the documentation (https://strapi.io/documentation/developer-docs/latest/concepts/controllers.html#core-controllers) | |||||
| * to customize this controller | |||||
| */ | |||||
| module.exports = {}; | |||||
| @@ -0,0 +1,8 @@ | |||||
| 'use strict'; | |||||
| /** | |||||
| * Read the documentation (https://strapi.io/documentation/developer-docs/latest/concepts/models.html#lifecycle-hooks) | |||||
| * to customize this model | |||||
| */ | |||||
| module.exports = {}; | |||||
| @@ -0,0 +1,40 @@ | |||||
| { | |||||
| "kind": "collectionType", | |||||
| "collectionName": "yamalubes", | |||||
| "info": { | |||||
| "name": "Yamalube" | |||||
| }, | |||||
| "options": { | |||||
| "increments": true, | |||||
| "timestamps": true, | |||||
| "draftAndPublish": true | |||||
| }, | |||||
| "attributes": { | |||||
| "name": { | |||||
| "type": "string" | |||||
| }, | |||||
| "part_code": { | |||||
| "type": "string" | |||||
| }, | |||||
| "price": { | |||||
| "type": "biginteger" | |||||
| }, | |||||
| "stock": { | |||||
| "type": "biginteger" | |||||
| }, | |||||
| "description": { | |||||
| "type": "richtext" | |||||
| }, | |||||
| "img": { | |||||
| "model": "file", | |||||
| "via": "related", | |||||
| "allowedTypes": [ | |||||
| "images", | |||||
| "files", | |||||
| "videos" | |||||
| ], | |||||
| "plugin": "upload", | |||||
| "required": false | |||||
| } | |||||
| } | |||||
| } | |||||
| @@ -0,0 +1,8 @@ | |||||
| 'use strict'; | |||||
| /** | |||||
| * Read the documentation (https://strapi.io/documentation/developer-docs/latest/concepts/services.html#core-services) | |||||
| * to customize this service | |||||
| */ | |||||
| module.exports = {}; | |||||
| @@ -0,0 +1,52 @@ | |||||
| { | |||||
| "routes": [ | |||||
| { | |||||
| "method": "GET", | |||||
| "path": "/ygps", | |||||
| "handler": "ygp.find", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "GET", | |||||
| "path": "/ygps/count", | |||||
| "handler": "ygp.count", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "GET", | |||||
| "path": "/ygps/:id", | |||||
| "handler": "ygp.findOne", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "POST", | |||||
| "path": "/ygps", | |||||
| "handler": "ygp.create", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "PUT", | |||||
| "path": "/ygps/:id", | |||||
| "handler": "ygp.update", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| }, | |||||
| { | |||||
| "method": "DELETE", | |||||
| "path": "/ygps/:id", | |||||
| "handler": "ygp.delete", | |||||
| "config": { | |||||
| "policies": [] | |||||
| } | |||||
| } | |||||
| ] | |||||
| } | |||||
| @@ -0,0 +1,8 @@ | |||||
| 'use strict'; | |||||
| /** | |||||
| * Read the documentation (https://strapi.io/documentation/developer-docs/latest/concepts/controllers.html#core-controllers) | |||||
| * to customize this controller | |||||
| */ | |||||
| module.exports = {}; | |||||
| @@ -0,0 +1,8 @@ | |||||
| 'use strict'; | |||||
| /** | |||||
| * Read the documentation (https://strapi.io/documentation/developer-docs/latest/concepts/models.html#lifecycle-hooks) | |||||
| * to customize this model | |||||
| */ | |||||
| module.exports = {}; | |||||
| @@ -0,0 +1,40 @@ | |||||
| { | |||||
| "kind": "collectionType", | |||||
| "collectionName": "ygps", | |||||
| "info": { | |||||
| "name": "YGP" | |||||
| }, | |||||
| "options": { | |||||
| "increments": true, | |||||
| "timestamps": true, | |||||
| "draftAndPublish": true | |||||
| }, | |||||
| "attributes": { | |||||
| "name": { | |||||
| "type": "string" | |||||
| }, | |||||
| "part_code": { | |||||
| "type": "string" | |||||
| }, | |||||
| "price": { | |||||
| "type": "biginteger" | |||||
| }, | |||||
| "stock": { | |||||
| "type": "biginteger" | |||||
| }, | |||||
| "description": { | |||||
| "type": "richtext" | |||||
| }, | |||||
| "img": { | |||||
| "model": "file", | |||||
| "via": "related", | |||||
| "allowedTypes": [ | |||||
| "images", | |||||
| "files", | |||||
| "videos" | |||||
| ], | |||||
| "plugin": "upload", | |||||
| "required": false | |||||
| } | |||||
| } | |||||
| } | |||||
| @@ -0,0 +1,8 @@ | |||||
| 'use strict'; | |||||
| /** | |||||
| * Read the documentation (https://strapi.io/documentation/developer-docs/latest/concepts/services.html#core-services) | |||||
| * to customize this service | |||||
| */ | |||||
| module.exports = {}; | |||||