This commit is contained in:
Taric Xin
2022-04-06 14:48:24 +08:00
parent 6fa1c0364d
commit d74845021f
3 changed files with 11 additions and 254 deletions

View File

@ -1,252 +0,0 @@
"use strict";
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
}
return t;
};
return __assign.apply(this, arguments);
};
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
exports.__esModule = true;
exports.RechargeRecordComponent = void 0;
var core_1 = require("@angular/core");
var RechargeRecordComponent = /** @class */ (function () {
function RechargeRecordComponent(service, modal) {
var _this = this;
this.service = service;
this.modal = modal;
this.columns = this.initST();
this.searchSchema = this.initSF();
this.rechargeRemark = '';
this._$expand = false;
this.beforeReq = function (requestOptions) {
if (_this.sf) {
Object.assign(requestOptions.body, __assign({}, _this.sf.value));
}
return requestOptions;
};
}
RechargeRecordComponent.prototype.ngOnInit = function () { };
RechargeRecordComponent.prototype.addRemark = function (item) {
var _this = this;
this.rechargeRemark = item.rechargeRemark;
var modal = this.modal.create({
nzTitle: this.rechargeRemark ? '修改备注' : '添加备注',
nzContent: this.remarkodal,
nzFooter: [
{
type: 'primary',
label: '确认',
loading: function () { return _this.service.http.loading; },
onClick: function () {
modal.destroy();
}
}
]
});
};
RechargeRecordComponent.prototype.goBack = function () {
history.go(-1);
};
/**
* 重置表单
*/
RechargeRecordComponent.prototype.resetSF = function () {
this.sf.reset();
this._$expand = false;
};
/**
* 伸缩查询条件
*/
RechargeRecordComponent.prototype.expandToggle = function () {
var _a;
this._$expand = !this._$expand;
(_a = this.sf) === null || _a === void 0 ? void 0 : _a.setValue('/expand', this._$expand);
};
RechargeRecordComponent.prototype.exportList = function () {
this.service.downloadFile(this.service.$mock_url, __assign(__assign({}, this.sf.value), { pageSize: -1 }));
};
RechargeRecordComponent.prototype.initSF = function () {
var _this = this;
return {
properties: {
expand: {
type: 'boolean',
ui: {
hidden: true
}
},
rechargeNo: {
type: 'string',
title: '充值单号',
ui: {
placeholder: '请输入'
}
},
rechargeStatus: {
type: 'string',
title: '充值状态',
"enum": [
{ label: '全部', value: '' },
{ label: '充值中', value: '1' },
{ label: '充值失败', value: '2' },
{ label: '充值成功', value: '3' }
],
ui: {
widget: 'select',
placeholder: '请选择'
},
"default": ''
},
createTime: {
title: '充值时间',
type: 'string',
ui: {
widget: 'date',
mode: 'range',
format: 'yyyy-MM-dd'
}
},
roleName: {
type: 'string',
title: '账户名称',
ui: {
placeholder: '请输入',
autocomplete: 'off',
visibleIf: {
expand: function (value) { return value; }
}
}
},
accountType: {
type: 'string',
title: '账户类型',
"enum": [
{ label: '全部', value: '' },
{ label: '货主账户', value: '1' },
{ label: '司机账户', value: '2' },
{ label: '营商商账户', value: '3' }
],
ui: {
widget: 'select',
placeholder: '请选择',
visibleIf: {
expand: function (value) { return value; }
}
},
"default": ''
},
ltdId: {
type: 'string',
title: '网络货运人',
ui: {
widget: 'select',
placeholder: '请选择',
visibleIf: {
expand: function (value) { return value; }
},
allowClear: true,
asyncData: function () { return _this.service.getNetworkFreightForwarder(); }
}
},
bankType: {
type: 'string',
title: '银行类型',
"enum": [
{ label: '全部', value: '' },
{ label: '平安银行', value: '1' },
{ label: '浦发银行', value: '2' }
],
ui: {
widget: 'select',
placeholder: '请选择',
visibleIf: {
expand: function (value) { return value; }
}
},
"default": ''
}
}
};
};
RechargeRecordComponent.prototype.initST = function () {
var _this = this;
return [
{ title: '充值时间', index: 'createTime', type: 'date', width: 180 },
{ title: '充值单号', index: 'rechargeNo', width: 140 },
{ title: '网络货运人', index: 'ltdName', width: 160 },
{ title: '银行类型', index: 'bankTypeLabel', width: 100 },
{ title: '账户类型', index: 'accountTypeLabel', width: 100 },
{ title: '账户名称', index: 'roleName', width: 160 },
{ title: '虚拟账户', index: 'virtualAccount', width: 100 },
{
title: '充值金额',
index: 'rechargeAmount',
width: 160,
type: 'widget',
className: 'text-right',
widget: { type: 'currency-chy', params: function (_a) {
var record = _a.record;
return ({ value: record.rechargeAmount });
} }
},
{ title: '充值银行账户', render: 'transferBankAccount', width: 200 },
{ title: '充值方式', index: 'payChannelLabel', width: 100 },
{ title: '充值状态', index: 'rechargeStatusLabel', width: 100 },
{ title: '银行流水号', index: 'paySerialNumber', width: 120 },
{
title: '操作',
width: 120,
fixed: 'right',
className: 'text-center',
buttons: [
{ type: 'divider' },
{
text: '查看回单<br>',
click: function (item) {
return _this.service.getReceiptUrl(item.receiptUrl, {
bankType: item.bankType,
rmYll: item.roleId,
snglFlgCd: item.paySerialNumber2,
bussType: '06',
ltdId: item.ltdId,
accountType: item.accountType
});
}
},
{
text: '添加备注',
click: function (item) { return _this.addRemark(item); }
}
]
}
];
};
__decorate([
core_1.ViewChild('st', { static: true })
], RechargeRecordComponent.prototype, "st");
__decorate([
core_1.ViewChild('sf', { static: false })
], RechargeRecordComponent.prototype, "sf");
__decorate([
core_1.ViewChild('remarkodal', { static: true })
], RechargeRecordComponent.prototype, "remarkodal");
RechargeRecordComponent = __decorate([
core_1.Component({
selector: 'app-recharge-record',
templateUrl: './recharge-record.component.html',
styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less']
})
], RechargeRecordComponent);
return RechargeRecordComponent;
}());
exports.RechargeRecordComponent = RechargeRecordComponent;

View File

@ -34,7 +34,7 @@ export class RechargeRecordComponent implements OnInit {
};
addRemark(item: any) {
this.rechargeRemark = item.rechargeRemark;
this.rechargeRemark = item.remark;
const modal = this.modal.create({
nzTitle: this.rechargeRemark ? '修改备注' : '添加备注',
nzContent: this.remarkodal,
@ -44,7 +44,14 @@ export class RechargeRecordComponent implements OnInit {
label: '确认',
loading: () => this.service.http.loading,
onClick: () => {
modal.destroy();
this.service.request(this.service.$api_edit_remark, { id: item.id, remark: this.rechargeRemark }).subscribe(res => {
if (res) {
this.service.msgSrv.success('修改成功');
this.st.load(1);
modal.destroy();
}
});
return false;
}
}
]

View File

@ -76,6 +76,8 @@ export class FreightAccountService extends ShipperBaseService {
$api_get_abnormal_gold_page = '/api/fcc/rechargeInfo/list/page';
// 运营端获取账户余额交易明细
$api_get_account_blance = '/api/fcc/accountBalanceDetail/getAccountBalanceByPage';
// 添加备注
$api_edit_remark = '/api/fcc/rechargeInfo/addRemark';
// 查询费用单抬头
$api_get_cost_page = '/api/fcc/ficoFeeH/list/page';