79 lines
1.6 KiB
JavaScript
79 lines
1.6 KiB
JavaScript
/*3mS3VmANLuMaTtASFDOxHvWNecZeEeby5t7o9BNao9s=*/
|
|
import { requestPromise, /* setStatePromise ,*/ } from 'ssccommon/utils/asyncFunctions.js';
|
|
|
|
import {
|
|
toast,
|
|
} from 'nc-lightapp-front';
|
|
|
|
/**
|
|
* @desc 查询
|
|
* @method asyncQry
|
|
*/
|
|
async function asyncQry() {
|
|
try {
|
|
const result = await requestPromise({
|
|
url: `/nccloud/ssctp/dooroad/DRVoucherOpenQueryAction.do`,
|
|
data: {},
|
|
});
|
|
return result
|
|
} catch (e) {
|
|
toast({ title: e.message, duration: 5, color: 'danger', })
|
|
}
|
|
}
|
|
|
|
/**
|
|
* @desc 删除
|
|
* @method asyncDel
|
|
*/
|
|
async function asyncDel(data) {
|
|
try {
|
|
const result = await requestPromise({
|
|
url: `/nccloud/ssctp/dooroad/DRVoucherOpenDelAction.do`,
|
|
data,
|
|
});
|
|
return result
|
|
} catch (e) {
|
|
toast({ title: e.message, duration: 5, color: 'danger', })
|
|
}
|
|
}
|
|
|
|
/**
|
|
* @desc 保存
|
|
* @method asyncSave
|
|
*/
|
|
async function asyncSave(data) {
|
|
try {
|
|
const result = await requestPromise({
|
|
url: `/nccloud/ssctp/dooroad/DRVoucherOpenSaveAction.do`,
|
|
data,
|
|
hasErrCallBack: true,
|
|
});
|
|
return result
|
|
} catch (e) {
|
|
toast({ title: e.message, duration: 5, color: 'danger', })
|
|
}
|
|
}
|
|
|
|
/**
|
|
* @desc 编辑后事件查询
|
|
* @method asyncOtherSelect
|
|
*/
|
|
async function asyncOtherSelect(data) {
|
|
try {
|
|
const result = await requestPromise({
|
|
url: `/nccloud/ssctp/dooroad/DROtherSelectOtsAction.do`,
|
|
data,
|
|
});
|
|
return result
|
|
} catch (e) {
|
|
toast({ title: e.message, duration: 5, color: 'danger', })
|
|
}
|
|
}
|
|
|
|
export {
|
|
asyncQry,
|
|
asyncDel,
|
|
asyncSave,
|
|
asyncOtherSelect,
|
|
}
|
|
/*3mS3VmANLuMaTtASFDOxHvWNecZeEeby5t7o9BNao9s=*/ |