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.
|
|
|
import request from '@/utils/request'
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 创建企业
|
|
|
|
* @param {Object} data
|
|
|
|
*/
|
|
|
|
export function createEnterPrise(data) {
|
|
|
|
return request({
|
|
|
|
url: `/system/enterprise/create`,
|
|
|
|
method: 'POST',
|
|
|
|
data
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 获取企业列表
|
|
|
|
* @param {Object} params
|
|
|
|
*/
|
|
|
|
export function getEnterPriseList(params) {
|
|
|
|
return request({
|
|
|
|
url: `/system/enterprise/getEnterpriseByUserId`,
|
|
|
|
method: 'GET',
|
|
|
|
params
|
|
|
|
})
|
|
|
|
}
|
|
|
|
/**
|
|
|
|
* 校验企业名
|
|
|
|
*/
|
|
|
|
export function vertifyName(params) {
|
|
|
|
return request({
|
|
|
|
url: `/system/enterprise/page`,
|
|
|
|
method: 'GET',
|
|
|
|
params
|
|
|
|
})
|
|
|
|
}
|
|
|
|
/**
|
|
|
|
* 获取企业详情
|
|
|
|
* @param {Object} id
|
|
|
|
*/
|
|
|
|
export function getEnterPrise(id) {
|
|
|
|
return request({
|
|
|
|
url: `/system/enterprise/get?id=${id}`,
|
|
|
|
method: 'GET',
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 审核企业
|
|
|
|
* @param {Object} id
|
|
|
|
*/
|
|
|
|
export function checkEnterprise(id) {
|
|
|
|
return request({
|
|
|
|
url: `/system/enterprise/audit?id=${id}`,
|
|
|
|
method: 'PUT',
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 获取企业执法记录
|
|
|
|
*/
|
|
|
|
export function getTaskList(params) {
|
|
|
|
return request({
|
|
|
|
url: `/system/task-info/appPageByEnterpriseId`,
|
|
|
|
method: 'GET',
|
|
|
|
params
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 获取企业执法日志
|
|
|
|
*/
|
|
|
|
export function getTaskLog(id) {
|
|
|
|
return request({
|
|
|
|
url: `/system/inspections-log/appList?inspectionsId=${id}`,
|
|
|
|
method: 'GET',
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 更新企业
|
|
|
|
*/
|
|
|
|
export function updateEnterprise(data) {
|
|
|
|
return request({
|
|
|
|
url: `/system/enterprise/update`,
|
|
|
|
method: 'PUT',
|
|
|
|
data
|
|
|
|
})
|
|
|
|
}
|