You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

23 lines
461 B

import request from '@/utils/request'
// 获取字典
function getDictList(type) {
return request({
url: '/eam/device-maintenance-job-main/getDictList?type=' + type,
'method': 'GET',
})
}
export async function getDict(type) {
let data =[]
await getDictList(type).then((res) => {
if (res.code == 0) {
data = res.data.map(item=>{
return {
label:item.label,
value:item.code,
}
})
} else {}
}).catch((err) => {})
return data
}