123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990 |
- import request from '@/utils/request'
- // 查询模板列表
- export function getSpecList(query) {
- return request({
- url: '/system/template/list',
- method: 'get',
- params: query
- })
- }
- // 新增或修改模板
- export function changeSpec(data) {
- return request({
- url: `/system/template/${data.specTemplateId ? 'edit' : 'addSpec'}`,
- method: 'post',
- data
- })
- }
- // 删除规格模板
- export function delSpec(id) {
- return request({
- url: '/system/template/del/' + id,
- method: 'get',
- })
- }
- // 模板详情
- export function getSpecDetail(id) {
- return request({
- url: '/system/template/detail/' + id,
- method: 'get',
- })
- }
- // 新增规格属性关联
- export function relation(data, b) {
- return request({
- url: `/system/relation/${b ? 'edit' : ''}`,
- method: 'post',
- data
- })
- }
- // 获得商品模板列表
- export function getGoodsSpecList(id) {
- return request({
- url: '/goods/spec/list/' + id,
- method: 'get',
- })
- }
- // 修改商品默认规格模板
- export function goodsUpdateSpec(data) {
- return request({
- url: `/goods/update/spec`,
- method: 'post',
- data
- })
- }
- // 商品批量上下架
- export function goodsUpdateStatus(data) {
- return request({
- url: `/goods/batch/updateStatus`,
- method: 'post',
- data
- })
- }
- // 商品批量删除
- export function goodsDel(data) {
- return request({
- url: `/goods/batch/del`,
- method: 'post',
- data
- })
- }
- // 新增每日一练试卷时间
- export function addExamTime(data) {
- return request({
- url: `/goods/addExamTime`,
- method: 'post',
- data
- })
- }
|