多应用+插件架构,代码干净,二开方便,首家独创一键云编译技术,文档视频完善,免费商用码云13.8K 广告
~~~[api] get:shop/product/edit *int:id#商品ID <<< success { "data": { "id": 1, "bazaar_money": "2.00", "content": "789", "describe": "121323", "image_id": 2, "images": "3", "money": "1.00", "name": "21321", "postage": "4.00", "product_type_id": 6, "sort": 1, "specs_status": 1, "attrbute_list": "[{"id":9,"name":"测试属性2","sub":[{"id":42,"name":"测试属性值1"},{"id":43,"name":"测试属性值2"}]},{"id":8,"name":"测试属性1","sub":[{"id":37,"name":"测试属性值1"},{"id":38,"name":"测试属性值2"}]}]", "image_url": "http://www.serveradmin.com/upload/images/20200319/5uQqoFttaNuBoRankI7mvZgecOHC6dUExn9tVx8J.png", "images_arr": [             { "id": 3, "name": "http://www.serveradmin.com/upload/images/20200319/qiAqwZ9m9juod72xRTOWmEkhO0vqzGI7IdnSlGmV.png", "url": "http://www.serveradmin.com/upload/images/20200319/qiAqwZ9m9juod72xRTOWmEkhO0vqzGI7IdnSlGmV.png"             }         ], "product_type_id_arr": [ 5, 6         ], "attrbute_key_list": [             { "id": 9, "name": "测试属性2", "sub": [                     { "id": 42, "name": "测试属性值1"                     },                     { "id": 43, "name": "测试属性值2"                     }                 ]             },             { "id": 8, "name": "测试属性1", "sub": [                     { "id": 37, "name": "测试属性值1"                     },                     { "id": 38, "name": "测试属性值2"                     }                 ]             }         ], "product_spec_to": [             { "id": 1, "product_id": 1, "specs": [                     { "id": 42, "name": "测试属性值1"                     },                     { "id": 37, "name": "测试属性值1"                     }                 ], "money": "1.00", "bazaar_money": "2.00", "cost_money": "3.00", "postage": "4.00", "stock": 5, "sales": 6, "sku": "42|37"             },             { "id": 2, "product_id": 1, "specs": [                     { "id": 42, "name": "测试属性值1"                     },                     { "id": 38, "name": "测试属性值2"                     }                 ], "money": "20.00", "bazaar_money": "19.00", "cost_money": "18.00", "postage": "13.00", "stock": 12, "sales": 7, "sku": "42|38"             },             { "id": 3, "product_id": 1, "specs": [                     { "id": 43, "name": "测试属性值2"                     },                     { "id": 37, "name": "测试属性值1"                     }                 ], "money": "21.00", "bazaar_money": "24.00", "cost_money": "17.00", "postage": "14.00", "stock": 11, "sales": 8, "sku": "43|37"             },             { "id": 4, "product_id": 1, "specs": [                     { "id": 43, "name": "测试属性值2"                     },                     { "id": 38, "name": "测试属性值2"                     }                 ], "money": "22.00", "bazaar_money": "23.00", "cost_money": "16.00", "postage": "15.00", "stock": 10, "sales": 9, "sku": "43|38"             }         ]     }, "code": 8888, "msg": "成功!" } ~~~ ## **请求参数说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品ID| ## **成功发回参数说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |code|是|int|表示请求后的状态| |msg|是|string|表示请求提示信息| |data|是|object|返回数据| ## **data数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品ID| |bazaar_money|是|float|产品市场价(是规格表中的第一个价格)| |content|是|string|商品详情| |describe|是|string|商品描述| |image_id|是|int|图片id| |images|是|string|轮播图:多个用竖线隔开| |money|是|float|产品售价(是规格表中的第一个价格)| |name|是|string|商品名称| |postage|是|float|邮费(是规格表中的第一个价格)| |product_type_id|是|int|商品分类id| |sort|是|int|排序| |specs_status|是|int|是否有规格:0=否,1=是| |attrbute_list|是|array|前端展示多条sku的数据| |image_url|是|string|单图路径| |images_arr|是|array|多图数据| |product_type_id_arr|是|array|当前选中商品分类数据| |attrbute_key_list|是|array|当前选中属性数据| |product_spec_to|是|array|当前商品规格数据| ## **attrbute_list数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品属性ID| |name|是|string|商品属性名称| |sub|是|array|商品属性值数据| ## **sub数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品属性值ID| |name|是|string|商品属性值| ## **images_arr数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|图片id| |name|是|string|图片路径| |url|是|string|图片路径| ## **attrbute_key_list数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品属性id| |name|是|string|商品属性名称| ## **product_spec_to数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品规格ID| |product_id|是|int|商品id| |specs|是|array|单条sku的数据| |money|是|float|产品售价| |bazaar_money|是|float|产品市场价| |cost_money|是|float|产品成本价| |postage|是|float|邮费| |stock|是|int|库存| |sales|是|int|销量| |sku|是|int|单条sku_id多个用竖线隔开| ## **specs数据说明** |参数|是否必须|参数类型|说明| |-|-|-|-| |id|是|int|商品属性值ID| |name|是|string|商品属性名称|