import ApiModel from '@comprehensive/serve/core/ApiModel' // 表单信息 const formList = [ { type: 'input', label: '银行流水', value: '', name: 'trxnBr', attrs: ['readonly'] }, { type: 'input', label: '鹏友收款账户账号', value: '', name: 'acctNo', attrs: ['readonly'] }, { type: 'input', label: '鹏友收款账户户名', value: '', name: 'rpyNam', attrs: ['readonly'] }, { type: 'input', label: '鹏友收款账户开户行', value: '', name: 'bankName', attrs: ['readonly'] }, { type: 'input', label: '客户/合作方结算虚拟号', value: '', name: 'psbnBr', attrs: ['readonly'] }, { type: 'input', label: '虚拟号绑定客户名称', value: '', name: 'cltNam', attrs: ['readonly'] }, { type: 'input', label: '转账付方账号', value: '', name: 'rpyAcc', attrs: ['readonly'] }, { type: 'input', label: '转账付方户名', value: '', name: 'rpyCustomerNam', attrs: ['readonly'] }, { type: 'input', label: '转账付方开户银行', value: '', name: 'rpyBnk', attrs: ['readonly'] }, { type: 'input', label: '收付金额', value: '', name: 'crtAmt', attrs: ['readonly'], isMoney: true }, { type: 'input', label: '已认领金额', value: '', name: 'usedAmount', attrs: ['readonly'], isMoney: true }, { type: 'input', label: '已退款金额', value: '', name: 'fallBackAmount', attrs: ['readonly'], isMoney: true }, { type: 'input', label: '虚拟认领金额', value: '', name: 'virtualAmount', attrs: ['readonly'], isMoney: true }, { type: 'input', label: '剩余金额', value: '', name: 'coreBalance', attrs: ['readonly'], isMoney: true }, { type: 'input', label: '冻结金额', value: '', name: 'freezingAmount', attrs: ['readonly'], isMoney: true } ] const otherForm = [ { type: 'textarea', label: '转账备注', value: '', name: 'trxTxt', attrs: ['readonly'] }, { type: 'input', label: '收款日期', value: '', name: 'etyDat', attrs: ['readonly'] }, { type: 'input', label: '收款时间', value: '', name: 'inputTime', attrs: ['readonly'] }, { type: 'input', label: '认领状态', value: '', name: 'statusDesc', attrs: ['readonly'] }, { type: 'input', label: '转账付方开户银行号', value: '', name: 'rpyBbk', attrs: ['readonly'] }, { type: 'input', label: '转账付方开户地址', value: '', name: 'rpybBkAdr', attrs: ['readonly'] }, { type: 'input', label: '上传用户', value: '', name: 'uploadUserId', attrs: ['readonly'] }, { type: 'input', label: '上传时间', value: '', name: 'uploadTime', attrs: ['readonly'] }, { type: 'input', label: '最近操作用户', value: '', name: 'userName', attrs: ['readonly'] }, { type: 'input', label: '最近操作时间', value: '', name: 'endTime', attrs: ['readonly'] } ] const remarkForm = [ { type: 'input', label: '收款日期', value: '', name: 'etyDat', attrs: ['readonly'] }, { type: 'input', label: '收款时间', value: '', name: 'inputTime', attrs: ['readonly'] }, { type: 'input', label: '原转账备注', value: '', name: 'trxTxt', attrs: ['readonly'] }, { type: 'input', label: '追加备注', value: '', name: 'newRemark', rules: [{ required: true }] }, { type: 'input', label: '新转账备注', value: '', name: 'remark', attrs: ['readonly'] } ] export default options => { // 接口地址,required const api = 'server/claimRefundInfo' return new ApiModel({ api, formList: options === 'remark' ? [...formList, ...remarkForm] : [...formList, ...otherForm], request(params) { return this.post(params) } }) }