From cdb22c78f1f172dc392754c9b095fc91ae325d6e Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Thu, 24 Mar 2022 09:57:50 +0800 Subject: [PATCH 1/2] edit --- .../withdrawals-detail.component.html | 41 ++++- .../withdrawals-detail.component.less | 10 +- .../withdrawals-detail.component.ts | 148 +++++++++++++++++- .../withdrawals-record.component.ts | 27 ++-- 4 files changed, 205 insertions(+), 21 deletions(-) diff --git a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.html b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.html index 8e03e6a1..cf8b7148 100644 --- a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.html +++ b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.html @@ -54,10 +54,39 @@ - -
-
- -
-
+ + +
+
+ +
+
+ + + + +
+
+ + + {{index+1}} + + +
+ +
+
+ +
+
+
+
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.less b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.less index e299b7d1..627355a5 100644 --- a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.less +++ b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.less @@ -5,13 +5,19 @@ border : 1px solid #dbdbdb; .ant-alert-message { - color: rgba(0, 0, 0, 0.85); + color : rgba(0, 0, 0, 0.85); font-weight: 600; - font-size: 16px; + font-size : 16px; } } .ant-form-item { margin-bottom: 15px; } + + nz-tabs-nav { + background-color: #f3f3f3; + border : 1px solid #dbdbdb; + padding-left : 18px; + } } \ No newline at end of file diff --git a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.ts b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.ts index c184fa93..c63852e5 100644 --- a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.ts +++ b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-detail/withdrawals-detail.component.ts @@ -1,5 +1,7 @@ -import { Component, OnInit } from '@angular/core'; +import { Component, OnInit, ViewChild } from '@angular/core'; import { ActivatedRoute } from '@angular/router'; +import { STColumn, STRequestOptions } from '@delon/abc/st'; +import { SFComponent, SFSchema } from '@delon/form'; import { FreightAccountService } from '../../../services/freight-account.service'; @Component({ @@ -8,17 +10,37 @@ import { FreightAccountService } from '../../../services/freight-account.service styleUrls: ['./withdrawals-detail.component.less'] }) export class WithdrawalsDetailComponent implements OnInit { + @ViewChild('st', { static: true }) + st!: Component; + @ViewChild('sf', { static: false }) + inputSF!: SFComponent; + columns: STColumn[] = this.initST(); + inputSearchSchema: SFSchema = this.initInputSF(); + _$expand = false; + formData: any = {}; timeLineData: any = []; + accountType = '1'; + constructor(public service: FreightAccountService, private route: ActivatedRoute) { const id = route.snapshot.params.id; + this.accountType = route.snapshot.queryParams.type; this.loadRefundDetail(id); } ngOnInit(): void {} + beforeReq = (requestOptions: STRequestOptions) => { + if (this.inputSF.value) { + Object.assign(requestOptions.body, { + ...this.inputSF.value + }); + } + return requestOptions; + }; + loadRefundDetail(id: string) { this.service.request(this.service.$api_get_refund_detail, { id }).subscribe(res => { if (res) { @@ -80,7 +102,131 @@ export class WithdrawalsDetailComponent implements OnInit { }); } + /** + * 重置表单 + */ + resetInputSF() { + this.inputSF.reset(); + } + + /** + * 伸缩查询条件 + */ + expandToggle() { + this._$expand = !this._$expand; + this.inputSF?.setValue('/expand', this._$expand); + } + goBack() { history.go(-1); } + + private initInputSF(): SFSchema { + return { + properties: { + expand: { + type: 'boolean', + ui: { + hidden: true + } + }, + billHCode: { + type: 'string', + title: '支付编号', + ui: { + placeholder: '请输入' + } + }, + billHCod1e: { + type: 'string', + title: '订单号', + ui: { + placeholder: '请输入' + } + }, + billHCo1de: { + type: 'string', + title: '货源编号', + ui: { + placeholder: '请输入' + } + }, + billHC1ode: { + type: 'string', + title: '服务类型', + ui: { + widget: 'select', + placeholder: '请选择', + visibleIf: { + expand: (value: boolean) => value + } + } + }, + billHCo11de: { + type: 'string', + title: '承运司机', + ui: { + placeholder: '请输入司机姓名/手机号', + visibleIf: { + expand: (value: boolean) => value + } + } + }, + billHCo111de: { + type: 'string', + title: '车牌号', + ui: { + placeholder: '请输入', + visibleIf: { + expand: (value: boolean) => value + } + } + }, + billHC1o11de: { + type: 'string', + title: '收款人', + ui: { + placeholder: '请输入收款人姓名/手机号', + visibleIf: { + expand: (value: boolean) => value + } + } + }, + billHC1o111de: { + type: 'string', + title: '车队长收款', + ui: { + widget: 'select', + placeholder: '请选择', + visibleIf: { + expand: (value: boolean) => value + } + } + } + } + }; + } + + private initST(): STColumn[] { + return [ + { title: '支付编号', index: 'brmHCode', className: 'text-left', width: 200 }, + { + title: '支付金额', + index: 'yskmoney', + type: 'widget', + className: 'text-right', + widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.yskmoney }) }, + width: 140 + }, + { title: '运费明细', index: 'billHId', className: 'text-center', width: 150 }, + { title: '货主', index: 'billHId', className: 'text-center', width: 150 }, + { title: '订单号', index: 'billHId', className: 'text-center', width: 150 }, + { title: '运单号', index: 'billHId', className: 'text-center', width: 150 }, + { title: '货源编号', index: 'billHId', className: 'text-center', width: 150 }, + { title: '服务类型', index: 'billHId', className: 'text-center', width: 150 }, + { title: '承运司机', index: 'billHId', className: 'text-center', width: 150 }, + { title: '收款人', index: 'billHId', className: 'text-center', width: 150 }, + { title: '银行类型', index: 'billHId', className: 'text-center', width: 150 } + ]; + } } diff --git a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.ts b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.ts index 8d994f80..5d58f9bc 100644 --- a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.ts +++ b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.ts @@ -28,9 +28,9 @@ export class WithdrawalsRecordComponent { refundStatus: any = ''; msg = ''; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) { } + constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} - ngOnInit(): void { } + ngOnInit(): void {} beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { @@ -254,7 +254,7 @@ export class WithdrawalsRecordComponent { { title: '提现单号', index: 'refundApplyCode', width: 120 }, { title: '网络货运人', index: 'ltdName', width: 140 }, { title: '银行类型', index: 'bankTypeLabel', width: 100 }, - { title: '账户类型', index: 'bankTypeLabel', width: 100 }, + { title: '账户类型', index: 'accountType', width: 100 }, { title: '账户名称', index: 'bankAccountName', width: 140 }, { title: '虚拟账户', index: 'virtualAccount', width: 100 }, { @@ -276,6 +276,18 @@ export class WithdrawalsRecordComponent { width: '110px', className: 'text-center', buttons: [ + { + text: '审核', + iif: item => item.refundStatus === '1', + click: item => this.auditAction(item) + }, + { + text: '详情
', + click: item => + this.router.navigate([`/financial-management/withdrawals-record/detail/${item.id}`], { + queryParams: { type: item.accountType } + }) + }, { text: '查看回单', iif: item => item.refundStatus === '3', @@ -287,15 +299,6 @@ export class WithdrawalsRecordComponent { bussType: '06', ltdId: item.ltdId }) - }, - { - text: '审核', - iif: item => item.refundStatus === '1', - click: item => this.auditAction(item) - }, - { - text: '详情', - click: item => this.router.navigate([`/financial-management/withdrawals-record/detail/${item.id}`]) } ] } From fcce660beaf4a2ce6aa730931f83de64f6b4c05b Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Thu, 24 Mar 2022 10:04:03 +0800 Subject: [PATCH 2/2] edit --- .../cancellation-invoice.component.html | 3 +++ .../cancellation-invoice.component.ts | 23 ++++++++++--------- .../invoiced-list/invoiced-list.component.ts | 13 ++++++++++- 3 files changed, 27 insertions(+), 12 deletions(-) diff --git a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html index 19420a9d..5670e063 100644 --- a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html +++ b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html @@ -65,6 +65,9 @@ + + + \ No newline at end of file diff --git a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts index 7bd939b9..b394a349 100644 --- a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts +++ b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts @@ -29,10 +29,10 @@ export class CancellationInvoiceComponent implements OnInit { selectedRows: any[] = []; totalCallNo = 0; - openInfo: any = { invoicedate: null, invoiceno: null }; - constructor(public service: TicketService, private nzModalService: NzModalService, private router: Router) { } + openInfo: any = { invoicedate: null, invoiceno: null, invoiceno2: null }; + constructor(public service: TicketService, private nzModalService: NzModalService, private router: Router) {} - ngOnInit(): void { } + ngOnInit(): void {} beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { @@ -78,7 +78,7 @@ export class CancellationInvoiceComponent implements OnInit { * @param item */ requestedAction(item: any) { - this.openInfo = { invoicedate: null, invoiceno: null }; + this.openInfo = { invoicedate: null, invoiceno: null, invoiceno2: null }; const modal = this.nzModalService.create({ nzTitle: '发票确认', nzContent: this.requestedModal, @@ -89,7 +89,8 @@ export class CancellationInvoiceComponent implements OnInit { } const params = { invoiceno: this.openInfo.invoiceno, - invoicedate: dateTimePickerUtil.format(this.openInfo.invoicedate) + invoicedate: dateTimePickerUtil.format(this.openInfo.invoicedate), + invoiceno2: this.openInfo.invoiceno2 }; this.service .request(this.service.$api_apply_fico_invoic, { @@ -154,7 +155,7 @@ export class CancellationInvoiceComponent implements OnInit { this.nzModalService.warning({ nzTitle: '确定将所选待确认开票申请撤回?', nzContent: '提交税控后发票信息不可修改,待税控开票完成后返回开票结果', - nzOnOk: () => { } + nzOnOk: () => {} }); } @@ -170,7 +171,7 @@ export class CancellationInvoiceComponent implements OnInit { this.nzModalService.warning({ nzTitle: '确定将所选待确认开票申请撤回?', nzContent: '提交税控后发票信息不可修改,待税控开票完成后返回开票结果', - nzOnOk: () => { } + nzOnOk: () => {} }); } @@ -369,22 +370,22 @@ export class CancellationInvoiceComponent implements OnInit { buttons: [ { type: 'divider' }, { - text: '查看明细', + text: '查看明细
', click: item => this.router.navigate(['ticket/cancellation-invoice/detail/' + item.id], { queryParams: { type: 1, expressno: item.expressno, ltdId: item.shipperId } }) }, { - text: '手工开票', + text: '手工开票
', iif: item => item.sts != '3', click: item => this.requestedAction(item) }, { - text: '推送开票', + text: '推送开票
', iif: item => item.sts === '1', click: item => this.pushInvoiceAction(item) - }, + } // { // text: '作废发票', // iif: item => item.sts === '3', diff --git a/src/app/routes/ticket-management/components/invoiced-list/invoiced-list.component.ts b/src/app/routes/ticket-management/components/invoiced-list/invoiced-list.component.ts index 0662aa43..ec52f839 100644 --- a/src/app/routes/ticket-management/components/invoiced-list/invoiced-list.component.ts +++ b/src/app/routes/ticket-management/components/invoiced-list/invoiced-list.component.ts @@ -137,6 +137,13 @@ export class InvoicedListComponent implements OnInit { autocomplete: 'off' } }, + invoiceno2: { + type: 'string', + title: '发票代码', + ui: { + autocomplete: 'off' + } + }, vatappHCode: { type: 'string', title: '申请编号', @@ -151,7 +158,10 @@ export class InvoicedListComponent implements OnInit { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', placeholder: '请选择', - nzShowTime: true + nzShowTime: true, + visibleIf: { + expand: (value: boolean) => value + } } as SFDateWidgetSchema }, artoname: { @@ -196,6 +206,7 @@ export class InvoicedListComponent implements OnInit { return [ { title: '', index: 'key', type: 'checkbox' }, { title: '发票号码', index: 'invoiceno', width: 150 }, + { title: '发票代码', index: 'invoiceno2', width: 150 }, { title: '申请编号', index: 'vatappHCode',