jiangping
2023-10-16 d7fe8ae3888c8e2b1eea3c1e3769be0d42a21cc9
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
import request from '../../utils/request'
 
// 查询
export function fetchList (data) {
  return request.post('/ext/plansExt/page', data, {
    trim: true
  })
}
 
// 导出Excel
export function exportExcel (data) {
  return request.post('/ext/plansExt/exportExcel', data, {
    trim: true,
    download: true
  })
}
 
// 创建
export function create (data) {
  return request.post('/ext/plansExt/create', data)
}
 
// 修改
export function updateById (data) {
  return request.post('/ext/plansExt/updateById', data)
}
 
// 删除
export function deleteById (id) {
  return request.get(`/ext/plansExt/delete/${id}`)
}
/**
 * 
 * @param id 计划id 
 * @returns 
 */
export function planDetailById (id) {
  return request.get(`/ext/plansExt/h5/${id}`)
}
// 批量发布
export function publish (query) {
  return request.get(`/ext/plansExt/publish/batch${query}`)
}
// 根据ID取消计划
export function cancelById (data) {
  return request.post('/ext/plansExt/cancelById', data)
}
// 根据ID分配
export function distributeById (data) {
  return request.post('/ext/plansExt/distributeById', data)
}
// 批量分配
export function distribute (data) {
  return request.post('/ext/plansExt/distribute/batch', data)
}
// 根据ID暂停
export function pauseById (data) {
  return request.post('/ext/plansExt/pauseById', data)
}
// 根据ID恢复
export function regainById (data) {
  return request.post('/ext/plansExt/regainById', data)
}
// 根据ID关闭
export function closeById (data) {
  return request.post('/ext/plansExt/closeById', data)
}
// 批量删除
export function deleteByIdInBatch (ids) {
  return request.get('/ext/plansExt/delete/batch', {
    params: {
      ids
    }
  })
}