转换首巡检项目配置模块
This commit is contained in:
@@ -1,10 +1,12 @@
|
||||
import { request } from '@/api/_service'
|
||||
|
||||
const BASE = 'quality_control/first_inspection/first_inspection/'
|
||||
const PROCESS_STEP_BASE = 'production_configuration/technology_model/technology_flow_workingsubclass/'
|
||||
|
||||
function apiParams (data = {}, method = 'get.setting.list', platform = 'api') {
|
||||
return { method, platform, ...data }
|
||||
}
|
||||
|
||||
export function fetchFirstArticleInspectionConfigurationList (data = {}) {
|
||||
return request({
|
||||
url: BASE + 'list',
|
||||
@@ -37,3 +39,54 @@ export function deleteFirstArticleInspectionConfiguration (data = {}) {
|
||||
})
|
||||
}
|
||||
|
||||
export function getQualityCategoryAll (data = {}) {
|
||||
return request({
|
||||
url: BASE + 'category/all',
|
||||
method: 'post',
|
||||
data: apiParams(data, 'get.quality.category.all', 'api')
|
||||
})
|
||||
}
|
||||
|
||||
export function getWorkingsubclassAll (data = {}) {
|
||||
return request({
|
||||
url: PROCESS_STEP_BASE + 'all',
|
||||
method: 'get',
|
||||
params: {
|
||||
method: 'production_configuration_technology_model_technology_flow_workingsubclass_all',
|
||||
platform: 'background',
|
||||
...data
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSettingItemList (data = {}) {
|
||||
return request({
|
||||
url: BASE + 'item/list',
|
||||
method: 'post',
|
||||
data: apiParams(data, 'get.setting.item.list', 'api')
|
||||
})
|
||||
}
|
||||
|
||||
export function createSettingItem (data = {}) {
|
||||
return request({
|
||||
url: BASE + 'item/add',
|
||||
method: 'post',
|
||||
data: apiParams(data, 'add.setting.item', 'admin')
|
||||
})
|
||||
}
|
||||
|
||||
export function editSettingItem (data = {}) {
|
||||
return request({
|
||||
url: BASE + 'item/update',
|
||||
method: 'post',
|
||||
data: apiParams(data, 'set.setting.item', 'admin')
|
||||
})
|
||||
}
|
||||
|
||||
export function deleteSettingItem (data = {}) {
|
||||
return request({
|
||||
url: BASE + 'item/delete',
|
||||
method: 'post',
|
||||
data: apiParams(data, 'del.setting.item', 'admin')
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user