feat:添加admin相关接口
This commit is contained in:
+52
-3
@@ -29,12 +29,12 @@ export function getCompletedTicketList(count, page) {
|
||||
return getTickerList(count,page,3)
|
||||
}
|
||||
|
||||
// 获取详情
|
||||
// 获取工单详情
|
||||
export function getTicketDetail(work_id) {
|
||||
return request.get('/api/v1/admin/work_order/detail', { work_id })
|
||||
}
|
||||
|
||||
// 回复
|
||||
// 回复工单
|
||||
export function replyTicket(work_id, content, files) {
|
||||
return request.post('/api/v1/admin/work_order/reply', { work_id, content, files })
|
||||
}
|
||||
@@ -67,4 +67,53 @@ export async function parseFilesToImages(files) {
|
||||
|
||||
const fileIds = files.split(',')
|
||||
return await Promise.all(fileIds.map(async (id) => await getFileImage(id.trim())))
|
||||
}
|
||||
}
|
||||
|
||||
/**获取工单数量 */
|
||||
export function getTicketCount() {
|
||||
return request.get('/api/v1/admin/work_order/count')
|
||||
}
|
||||
/**修改工单信息 */
|
||||
export function updateTicketInfo(data) {
|
||||
return request.post('/api/v1/admin/work_order/update', data,{
|
||||
headers:{
|
||||
'Content-Type':'multipart/form-data'
|
||||
}
|
||||
})
|
||||
}
|
||||
/**添加工单类型 */
|
||||
export function addTicketType(data) {
|
||||
return request.post('/api/v1/admin/work_order/add_type', data,{
|
||||
headers:{
|
||||
'Content-Type':'multipart/form-data'
|
||||
}
|
||||
})
|
||||
}
|
||||
/**修改工单类型 */
|
||||
export function updateTicketType(data) {
|
||||
return request.post('/api/v1/admin/work_order/update_type', data,{
|
||||
headers:{
|
||||
'Content-Type':'multipart/form-data'
|
||||
}
|
||||
})
|
||||
}
|
||||
/**删除工单类型 */
|
||||
export function deleteTicketType(data) {
|
||||
return request.delete('/api/v1/admin/work_order/delete_type', data,{
|
||||
headers:{
|
||||
'Content-Type':'multipart/form-data'
|
||||
}
|
||||
})
|
||||
}
|
||||
/**获取工单类型列表 */
|
||||
export function getTicketTypeList(data) {
|
||||
return request.get('/api/v1/admin/work_order/type_list', data)
|
||||
}
|
||||
/**修改工单回复信息 */
|
||||
export function updateTicketReplayInfo(data){
|
||||
return request.post('/api/v1/admin/work_order/update_reply',data,{
|
||||
headers:{
|
||||
'Content-Type':'multipart/form-data'
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user