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.
157 lines
3.3 KiB
157 lines
3.3 KiB
import { |
|
requestGet, |
|
requestOptions, |
|
requestPost, |
|
requestTableList, |
|
} from '@component/utils'; |
|
import LRU from 'lru-cache'; |
|
|
|
export const cacheData = new LRU({}); |
|
|
|
//获取服务活动列表 |
|
export function getList(params) { |
|
return requestTableList( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceType/getPageList', |
|
params, |
|
); |
|
} |
|
|
|
//获取不带分页服务活动接口 |
|
export function getServiceTypeList(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceType/getServiceType', |
|
params, |
|
['serviceTypeId', 'serviceTypeName'], |
|
); |
|
} |
|
|
|
//获取aq标准服务活动、服务方式 |
|
export function getAqServiceStandard(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceType/getAqServiceStandard', |
|
params, |
|
['id', 'aqServiceName'], |
|
); |
|
} |
|
|
|
//获取服务方式列表 |
|
export function getServiceClassify(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceType/getServiceClassify', |
|
params, |
|
['serviceClassifyId', 'serviceClassifyName'], |
|
); |
|
} |
|
|
|
//新增服务活动 |
|
export function onCreate(params) { |
|
return requestPost( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceType/addServiceType', |
|
params, |
|
); |
|
} |
|
|
|
//服务活动删除 |
|
export function onDelete(params) { |
|
return requestPost( |
|
process.env.REACT_APP_SERVICE_URL, |
|
`/serviceType/deleteServiceType/${params.serviceTypeId}`, |
|
params, |
|
); |
|
} |
|
|
|
//获取服务价格列表 |
|
export function getPricePageList(params) { |
|
return requestTableList( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceScheme/getPageList', |
|
params, |
|
); |
|
} |
|
|
|
//获取服务价格列表 |
|
export function getPriceList(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceScheme/getList', |
|
params, |
|
['id', 'name'], |
|
); |
|
} |
|
//服务价格获取服务活动 |
|
export function getSchemeServiceType(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceScheme/getServiceType', |
|
params, |
|
['serviceTypeId', 'serviceTypeName'], |
|
); |
|
} |
|
|
|
//获取服务活动列表 |
|
|
|
export function getServiceType(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceScheme/getServiceType', |
|
params, |
|
['serviceTypeId', 'serviceTypeName'], |
|
); |
|
} |
|
|
|
//获取服务活动列表 |
|
export function getServieTypeByUser(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceType/getServieTypeByUser', |
|
params, |
|
['serviceTypeId', 'serviceTypeName'], |
|
); |
|
} |
|
|
|
//服务价格创建 |
|
export function onPriceCreate(params) { |
|
return requestPost( |
|
process.env.REACT_APP_SERVICE_URL, |
|
'/serviceScheme/addServiceScheme', |
|
params, |
|
); |
|
} |
|
|
|
//服务价格删除 |
|
export function onPriceDelete(params) { |
|
return requestPost( |
|
process.env.REACT_APP_SERVICE_URL, |
|
`/serviceScheme/deleteServiceScheme/${params.serviceSchemeId}`, |
|
params, |
|
); |
|
} |
|
|
|
//创建服务选择保单接口详细描述 |
|
export function getPolicyList(params) { |
|
return requestGet( |
|
process.env.REACT_APP_BUSINESS_URL, |
|
`/policy/choicePolicy`, |
|
params, |
|
); |
|
} |
|
|
|
//获取保单地址 |
|
export function getPolicyAddress(params) { |
|
return requestOptions( |
|
process.env.REACT_APP_BUSINESS_URL, |
|
`/policyAddressDtl/list`, |
|
params, |
|
['dtl_id', 'address'], |
|
); |
|
} |
|
|
|
//服务创建 |
|
export function onServiceAdd(params) { |
|
return requestPost(process.env.REACT_APP_SERVICE_URL, '/service/add', params); |
|
}
|
|
|