From 4c2ef7f4beb69879375cc76752999de8cf2d8a73 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 14:22:25 +0800 Subject: [PATCH 01/18] fix bug --- .../complaint-detail/complaint-detail.component.ts | 5 +++-- .../components/role-management/edit/edit.component.ts | 2 ++ .../components/role-management/menu/menu.component.ts | 5 +++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/app/routes/order-management/components/complaint-detail/complaint-detail.component.ts b/src/app/routes/order-management/components/complaint-detail/complaint-detail.component.ts index 0c311e0e..19ee68de 100644 --- a/src/app/routes/order-management/components/complaint-detail/complaint-detail.component.ts +++ b/src/app/routes/order-management/components/complaint-detail/complaint-detail.component.ts @@ -195,7 +195,7 @@ export class OrderManagementComplaintDetailComponent implements OnInit { } this.service.request(this.service.$api_get_dealWithComplaint, paramsa).subscribe((res: any) =>{ if(res) { - this.service.msgSrv.success('已拒绝!') + this.service.msgSrv.success('已取消!') this.isVisibleRE = false this.getDetail(this.id); this.complaintStatus = true; @@ -214,9 +214,10 @@ export class OrderManagementComplaintDetailComponent implements OnInit { return } const paramsa = { + ...this.sfView.value, id: this.channelId } - this.service.request(this.service.$api_get_canelComplaint, paramsa).subscribe((res: any) =>{ + this.service.request(this.service.$api_get_dealWithComplaint, paramsa).subscribe((res: any) =>{ if(res) { this.service.msgSrv.success('已拒绝!') this.isVisibleRE = false diff --git a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts index a390161f..70a60ca2 100644 --- a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts +++ b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts @@ -73,6 +73,8 @@ console.log(this.params.infoUrl) }); } getData(res: { authority: any[]; authorityAssistId: any[] }) { + console.log('修改了'); + this.authority = res.authority; this.authorityAssistId = res.authorityAssistId; } diff --git a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts index 34a9ba11..2a17332c 100644 --- a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts +++ b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts @@ -63,8 +63,6 @@ export class SettingMenuComponent implements OnInit, OnChanges { // 判断此菜单权限是否已经存在权限列表中 // 当前操作菜单id存在权限列表里 this.authority.forEach(menuItem => { - console.log(menuItem); - console.log(item); if (menuItem.authorityId === origin.id) { menuItem.buttonAuthorityIds = menuItem.buttonAuthorityIds || []; // 防止属性不存在,给属性指定数据类型 @@ -73,9 +71,12 @@ export class SettingMenuComponent implements OnInit, OnChanges { if (item.checked) { if (menuItem.buttonAuthorityIds.indexOf(item.functionButtonId) === -1) { // 如果该按钮在数据权限数组中不存在 + console.log('不存在'); + menuItem.buttonAuthorityIds.push(item.functionButtonId); } } else { + console.log('存在'); if (menuItem.buttonAuthorityIds && menuItem.buttonAuthorityIds.length) { menuItem.buttonAuthorityIds.forEach((btnItem: any, index: any) => { if (btnItem === item.functionButtonId) { From b6d76dad82cab4cf1b076a96a4c29f90ba78731d Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 14:24:50 +0800 Subject: [PATCH 02/18] fix bug --- .../components/complaint/complaint.component.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/app/routes/order-management/components/complaint/complaint.component.ts b/src/app/routes/order-management/components/complaint/complaint.component.ts index 3f34d0de..1851f5eb 100644 --- a/src/app/routes/order-management/components/complaint/complaint.component.ts +++ b/src/app/routes/order-management/components/complaint/complaint.component.ts @@ -48,7 +48,11 @@ export class OrderManagementComplaintComponent extends BasicTableComponent imple { name: '已撤销', type: 3 - } + }, + { + name: '已取消', + type: 4 + }, ]; constructor( public service: OrderManagementService, From 81bfaea6f5ecda1eecb0b4c64fd17cda88f3d823 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 14:48:09 +0800 Subject: [PATCH 03/18] fix bug --- .../role-management/edit/edit.component.html | 12 +++++++++++- .../role-management/edit/edit.component.ts | 12 ++++++++++++ .../role-management/menu/menu.component.ts | 2 ++ 3 files changed, 25 insertions(+), 1 deletion(-) diff --git a/src/app/routes/sys-setting/components/role-management/edit/edit.component.html b/src/app/routes/sys-setting/components/role-management/edit/edit.component.html index 8291cad4..976a3f03 100644 --- a/src/app/routes/sys-setting/components/role-management/edit/edit.component.html +++ b/src/app/routes/sys-setting/components/role-management/edit/edit.component.html @@ -1,3 +1,13 @@ + @@ -11,7 +21,7 @@ + [authorityAssistId]="roleInfoData.authorityAssistId || []" (changeIF)="changeIF($event)"> diff --git a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts index 70a60ca2..f595ee0a 100644 --- a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts +++ b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts @@ -21,6 +21,7 @@ export class SettingRoleEditComponent implements OnInit { roleInfoData: any = {}; authorityAssistId: any[] = []; params: any; + changeValue: boolean = false schema!: SFSchema; authority: any[] = []; constructor(private modal: NzModalRef, public service: SystemService) {} @@ -81,11 +82,18 @@ console.log(this.params.infoUrl) close() { this.modal.destroy(); } + changeIF(value: boolean) { + console.log(value); + console.log('54545'); + this.changeValue = true + } sure() { if (!this.sf?.valid) { this.service.msgSrv.warning('角色名称不能为空'); return; } + console.log(this.changeValue); + const auths = this.menu?.washTree(); if (auths.authorityAssistId.length === 0) { this.service.msgSrv.warning('请选择权限!'); @@ -97,6 +105,10 @@ console.log(this.params.infoUrl) authority: auths.authority, authorityAssistId: auths.authorityAssistId }; + if(this.changeValue) { + params.isUpdateAuthority = 1 + } + if (this.params.id === 0) { delete params.id; } diff --git a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts index 2a17332c..3ac047cb 100644 --- a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts +++ b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts @@ -26,6 +26,7 @@ export class SettingMenuComponent implements OnInit, OnChanges { @Input() isAuthorityIdDTOList: any[] = []; @Input() authorityAssistId: any[] = []; @Input() roleId: any; + @Output() changeIF= new EventEmitter(); @Output() changeData = new EventEmitter(); constructor(public service: SystemService, private cdr: ChangeDetectorRef, private envSrv: EAEnvironmentService) {} ngOnChanges(changes: SimpleChanges): void { @@ -67,6 +68,7 @@ export class SettingMenuComponent implements OnInit, OnChanges { if (menuItem.authorityId === origin.id) { menuItem.buttonAuthorityIds = menuItem.buttonAuthorityIds || []; // 防止属性不存在,给属性指定数据类型 if (item) { + this.changeIF.emit(true); // 单选 if (item.checked) { if (menuItem.buttonAuthorityIds.indexOf(item.functionButtonId) === -1) { From 2da8a0bcc453122aa76589801e45e0d19683d238 Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Mon, 25 Apr 2022 14:59:45 +0800 Subject: [PATCH 04/18] edit --- src/environments/eascs/environment.dev.ts | 1 + src/environments/eascs/environment.test.ts | 1 + src/environments/environment.prod.ts | 1 + src/environments/environment.ts | 1 + src/main.ts | 5 +++++ 5 files changed, 9 insertions(+) diff --git a/src/environments/eascs/environment.dev.ts b/src/environments/eascs/environment.dev.ts index 3bcdc166..4adc7f46 100644 --- a/src/environments/eascs/environment.dev.ts +++ b/src/environments/eascs/environment.dev.ts @@ -11,6 +11,7 @@ import { Environment } from '@delon/theme'; export const environment = { production: true, useHash: true, + isHiddenLog: true, api: { baseUrl: 'https://tms-api-dev.eascs.com', refreshTokenEnabled: false, diff --git a/src/environments/eascs/environment.test.ts b/src/environments/eascs/environment.test.ts index 0449f0d0..e01bc8ac 100644 --- a/src/environments/eascs/environment.test.ts +++ b/src/environments/eascs/environment.test.ts @@ -3,6 +3,7 @@ import { Environment } from '@delon/theme'; export const environment = { production: true, useHash: true, + isHiddenLog: true, api: { baseUrl: 'https://tms-api-test.eascs.com', refreshTokenEnabled: false, diff --git a/src/environments/environment.prod.ts b/src/environments/environment.prod.ts index 11537197..20e1e69d 100644 --- a/src/environments/environment.prod.ts +++ b/src/environments/environment.prod.ts @@ -3,6 +3,7 @@ import { Environment } from '@delon/theme'; export const environment = { production: true, useHash: true, + isHiddenLog: true, api: { baseUrl: 'https://tms-api.yunduoxing.com', refreshTokenEnabled: true, diff --git a/src/environments/environment.ts b/src/environments/environment.ts index 494c5943..281d90d2 100644 --- a/src/environments/environment.ts +++ b/src/environments/environment.ts @@ -10,6 +10,7 @@ import * as MOCKDATA from '../../_mock'; export const environment = { production: false, useHash: true, + isHiddenLog: false, api: { baseUrl: './', refreshTokenEnabled: true, diff --git a/src/main.ts b/src/main.ts index 2cea227c..27648e67 100644 --- a/src/main.ts +++ b/src/main.ts @@ -12,6 +12,11 @@ if (environment.production) { enableProdMode(); } +if (environment.isHiddenLog) { + // 取消系统信息输出 + window.console.log = () => {}; +} + platformBrowserDynamic() .bootstrapModule(AppModule, { defaultEncapsulation: ViewEncapsulation.Emulated, From 0f4a05e2bfdf3c1444d42aa09e43480ada305807 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 15:40:16 +0800 Subject: [PATCH 05/18] fix bug --- .../components/role-management/edit/edit.component.ts | 3 --- .../components/role-management/menu/menu.component.ts | 10 +++++++++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts index f595ee0a..50b3e8db 100644 --- a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts +++ b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts @@ -105,9 +105,6 @@ console.log(this.params.infoUrl) authority: auths.authority, authorityAssistId: auths.authorityAssistId }; - if(this.changeValue) { - params.isUpdateAuthority = 1 - } if (this.params.id === 0) { delete params.id; diff --git a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts index 3ac047cb..e5d0309a 100644 --- a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts +++ b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts @@ -329,9 +329,15 @@ export class SettingMenuComponent implements OnInit, OnChanges { } // 再次请求,需要判断暂存权限数组是否已有此权限 againGetBtn(id: any, origin: any) { - if (this.authority && this.authority.length === 0) { + if (this.authority && this.authority.length !== 0) { + console.log('1111'); + const buttonAuthorityIds: any = []; + console.log(origin); + console.log(origin.checked); + if (origin.checked) { + origin.buttonInfoList.forEach((btnItem: { functionButtonId: any; checked: boolean }) => { btnItem.checked = true; buttonAuthorityIds.push(btnItem.functionButtonId); @@ -339,6 +345,8 @@ export class SettingMenuComponent implements OnInit, OnChanges { this.authority.push({ authorityId: origin.key, buttonAuthorityIds, isUpdateAuthority: 1 }); } } else { + console.log('22222'); + if (origin.checked) { //菜单勾选情况下 if (this.authority.some(item => item.authorityId === id)) { From ac0832aa50aeec03b9317c2d1c2a4c7f2b4fd866 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 15:58:23 +0800 Subject: [PATCH 06/18] fix bug --- .../components/rebate-setting/add/add.component.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts index 15e68e18..54c686a7 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-03-21 09:26:45 * @LastEditors : Shiming - * @LastEditTime : 2022-04-22 15:01:43 + * @LastEditTime : 2022-04-25 15:52:41 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -131,13 +131,16 @@ export class ParterRebateManageMentAddComponent implements OnInit { }); } save() { + console.log(this.partnerId); + console.log(this.partnerId.join(',')); + const params = { accountingRate: this.accountingRate, configName: this.configName, configType: this.configType, rebateConfigLineDTO: this.table.data, priority: this.priority, // 优先级 - partnerId: this.partnerId.join(','), + partnerIds: this.partnerId, ruleDescription: this.sf.value.ruleDescription, remarke: this.remarke, partnerType: this.partnerType @@ -153,8 +156,10 @@ export class ParterRebateManageMentAddComponent implements OnInit { } changePartner(value: any) { console.log(value); - if (value) { + if (value == '3') { this.addStatus = true; + } else { + this.addStatus = false; } } } From ff6fd0b8011b83d081cc99ef4d54dd7e985237b0 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 16:11:28 +0800 Subject: [PATCH 07/18] fix bug --- .../withdrawals-record/withdrawals-record.component.ts | 8 ++++++-- .../withdrawals-record/withdrawals-record.component.ts | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) 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 75a921ef..5d92af1f 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 @@ -206,9 +206,13 @@ export class WithdrawalsRecordComponent { accountType: { type: 'string', title: '账户类型', + enum: [ + {label: '全部', value: ''}, + {label: '个人合伙人', value: '4'}, + {label: '企业合伙人', value: '5'} + ], ui: { - widget: 'dict-select', - params: { dictKey: 'bank:type' }, + widget: 'select', placeholder: '请选择', visibleIf: { expand: (value: boolean) => value diff --git a/src/app/routes/partner/account-management/components/withdrawals-record/withdrawals-record.component.ts b/src/app/routes/partner/account-management/components/withdrawals-record/withdrawals-record.component.ts index ad7c8ead..b26884f4 100644 --- a/src/app/routes/partner/account-management/components/withdrawals-record/withdrawals-record.component.ts +++ b/src/app/routes/partner/account-management/components/withdrawals-record/withdrawals-record.component.ts @@ -236,9 +236,13 @@ export class PartnerAccountManagementWithdrawalsRecordComponent implements OnIni accountType: { type: 'string', title: '账户类型', + enum: [ + {label: '全部', value: ''}, + {label: '个人合伙人', value: '4'}, + {label: '企业合伙人', value: '5'} + ], ui: { - widget: 'dict-select', - params: { dictKey: 'bank:type' }, + widget: 'select', placeholder: '请选择', visibleIf: { expand: (value: boolean) => value From f4743c180be320742c3b0f3838c5fbd7b87d43e1 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 17:21:34 +0800 Subject: [PATCH 08/18] fix bug --- .../withdrawals-record.component.ts | 9 ------- .../rebate-setting/add/add.component.ts | 4 ++- .../rebate-setting.component.ts | 8 +++--- .../role-management/edit/edit.component.ts | 1 + .../role-management/menu/menu.component.ts | 27 +++++++++++++++++-- 5 files changed, 33 insertions(+), 16 deletions(-) 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 5d92af1f..6f683bd3 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 @@ -177,15 +177,6 @@ export class WithdrawalsRecordComponent { placeholder: '请输入' } }, - // refundStatus: { - // type: 'string', - // title: '提现状态', - // ui: { - // widget: 'dict-select', - // params: { dictKey: 'refund:apply:status' }, - // placeholder: '请选择' - // } - // }, createTime: { title: '提现时间', type: 'string', diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts index 54c686a7..d97495d1 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-03-21 09:26:45 * @LastEditors : Shiming - * @LastEditTime : 2022-04-25 15:52:41 + * @LastEditTime : 2022-04-25 16:19:24 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -88,6 +88,8 @@ export class ParterRebateManageMentAddComponent implements OnInit { }; } ngOnInit() { + console.log(this.ar.snapshot); + this.addStatus = false; this.initSF(); } diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts index ee9b5b9d..5e7828bc 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts @@ -125,7 +125,7 @@ export class ParterRebateManageMentSettingComponent implements OnInit { buttons: [ { text: '查看', - click: _record => this.viewEvaluate(_record), + click: _record => this.configAction(_record), }, { text: '禁用', @@ -187,9 +187,9 @@ export class ParterRebateManageMentSettingComponent implements OnInit { } }); } - configAction() { - this.router.navigate(['/partner/rebate/setting/add/', 1]) - } + configAction(value?: any) { + this.router.navigate(['/partner/rebate/setting/add/', '0'], {queryParams: value}) + } /** * 重置表单 */ diff --git a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts index 50b3e8db..b91344a8 100644 --- a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts +++ b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts @@ -62,6 +62,7 @@ export class SettingRoleEditComponent implements OnInit { } getRoleInfo() { + this.roleInfoData = [] const params = { id: this.params.id }; diff --git a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts index e5d0309a..8b031d24 100644 --- a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts +++ b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts @@ -19,6 +19,7 @@ export class SettingMenuComponent implements OnInit, OnChanges { defaultCheckedKeys: any[] = []; functionList: any[] = []; allChecked = false; + changeIFT = false; indeterminate = true; @Input() type = 'edit'; @Input() source = ''; @@ -58,7 +59,7 @@ export class SettingMenuComponent implements OnInit, OnChanges { }); } addAuthority(origin: { id: any; all: any }, node: { buttonInfoList: any[] }, item?: { checked: any; functionButtonId: any }) { - console.log(origin,node); + console.log(origin); if (this.authority?.length && this.authority.filter(authItem => authItem.authorityId === origin.id).length) { // 判断此菜单权限是否已经存在权限列表中 @@ -69,6 +70,23 @@ export class SettingMenuComponent implements OnInit, OnChanges { menuItem.buttonAuthorityIds = menuItem.buttonAuthorityIds || []; // 防止属性不存在,给属性指定数据类型 if (item) { this.changeIF.emit(true); + this.changeIFT = true + // 判断此菜单下是否已有此按钮权限 + // this.againGetBtn(id, origin); + const params = { + id: origin.id + }; + this.service.request(this.service.$api_getFunctionButtonInfo, params).subscribe(res => { + if (res) { + let origins: any = {}; + origins.buttonInfoList = res; + origins.all = false; + console.log(origins); + + // 判断此菜单下是否已有此按钮权限 + this.againGetBtn(origin.id, origins); + } + }); // 单选 if (item.checked) { if (menuItem.buttonAuthorityIds.indexOf(item.functionButtonId) === -1) { @@ -329,7 +347,12 @@ export class SettingMenuComponent implements OnInit, OnChanges { } // 再次请求,需要判断暂存权限数组是否已有此权限 againGetBtn(id: any, origin: any) { - if (this.authority && this.authority.length !== 0) { + console.log(id,origin); + + console.log(this.authority); + console.log(this.authority.length); + + if ((this.authority && this.authority.length !== 0)) { console.log('1111'); const buttonAuthorityIds: any = []; From c5ca59239f81bae3ff565cf73fae9fc431e46d75 Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Mon, 25 Apr 2022 19:09:33 +0800 Subject: [PATCH 09/18] edit --- proxy.conf.js | 2 +- src/app/routes/commom/less/commom-table.less | 4 + .../abnormal-gold.component.html | 49 ++++---- .../abnormal-gold/abnormal-gold.component.ts | 61 ++++------ .../cost-management.component.html | 28 +++-- .../cost-management.component.ts | 77 +++--------- .../driver-account.component.html | 29 +++-- .../driver-account.component.ts | 67 ++++------- .../freight-account.component.html | 17 ++- .../freight-account.component.ts | 62 +++------- .../payment-order.component.html | 33 ++++-- .../payment-order/payment-order.component.ts | 95 +++++---------- .../payment-record.component.html | 41 ++++--- .../payment-record.component.less | 41 ------- .../payment-record.component.ts | 100 +++++----------- .../receipt-order.component.html | 43 +++---- .../receipt-order/receipt-order.component.ts | 78 ++++-------- .../recharge-record.component.html | 19 ++- .../recharge-record.component.ts | 53 ++------- .../transaction-flow.component.html | 18 +-- .../transaction-flow.component.ts | 74 ++---------- .../voucher-management.component.html | 29 +++-- .../voucher-management.component.ts | 112 ++++-------------- .../voucher-summary.component.html | 30 +++-- .../voucher-summary.component.ts | 109 +++++------------ .../withdrawals-record.component.html | 35 +++--- .../withdrawals-record.component.ts | 68 ++++------- .../financial-management.module.ts | 2 +- .../search-drawer.component.html | 2 +- 29 files changed, 481 insertions(+), 897 deletions(-) delete mode 100644 src/app/routes/financial-management/components/payment-record/payment-record.component.less diff --git a/proxy.conf.js b/proxy.conf.js index ff162fda..d9d60dfc 100644 --- a/proxy.conf.js +++ b/proxy.conf.js @@ -30,7 +30,7 @@ module.exports = { // }, '//api': { target: { - host: 'tms-api-dev.eascs.com', + host: 'tms-api-test.eascs.com', protocol: 'https:', port: 443 }, diff --git a/src/app/routes/commom/less/commom-table.less b/src/app/routes/commom/less/commom-table.less index 1fcbf112..c1256d36 100644 --- a/src/app/routes/commom/less/commom-table.less +++ b/src/app/routes/commom/less/commom-table.less @@ -112,6 +112,10 @@ .ant-select-single .ant-select-selector .ant-select-selection-placeholder { line-height: 21px; } + + .text-truncate { + white-space: normal; + } } } diff --git a/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.html b/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.html index 593c1e97..650f11fa 100644 --- a/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.html +++ b/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.html @@ -1,14 +1,4 @@ - - + - - - - - - + +
+ + + + + + +
- -
+ +
+ + +
+
+ + +
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.ts b/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.ts index 55817107..77f25e8c 100644 --- a/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.ts +++ b/src/app/routes/financial-management/components/abnormal-gold/abnormal-gold.component.ts @@ -2,30 +2,39 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; import { ClearingModalComponent } from './clearing-modal/clearing-modal.component'; @Component({ selector: 'app-abnormal-gold', templateUrl: './abnormal-gold.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class AbnormalGoldComponent implements OnInit { +export class AbnormalGoldComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); rechargeStatus = '1'; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + private router: Router, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { Object.assign(requestOptions.body, { rechargeStatus: this.rechargeStatus }); if (this.sf) { @@ -56,22 +65,6 @@ export class AbnormalGoldComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { @@ -116,30 +109,21 @@ export class AbnormalGoldComponent implements OnInit { type: 'string', title: '付款账户', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, transferBankCardNumber: { type: 'string', title: '付款账号', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, transferBankOpenName: { type: 'string', title: '付款银行', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, transferDate: { @@ -149,10 +133,7 @@ export class AbnormalGoldComponent implements OnInit { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', placeholder: '请选择', - nzShowTime: true, - visibleIf: { - expand: (value: boolean) => value - } + nzShowTime: true } as SFDateWidgetSchema } } diff --git a/src/app/routes/financial-management/components/cost-management/cost-management.component.html b/src/app/routes/financial-management/components/cost-management/cost-management.component.html index c9d36bdd..f9b6560d 100644 --- a/src/app/routes/financial-management/components/cost-management/cost-management.component.html +++ b/src/app/routes/financial-management/components/cost-management/cost-management.component.html @@ -8,7 +8,7 @@ * @FilePath : \\tms-obc-web\\src\\app\\routes\\financial-management\\components\\cost-management\\cost-management.component.html * Copyright (C) 2022 huzhenhong. All rights reserved. --> - + + + - + --> - -
+ +
+ +
+ + +
+
+ +
- + --> + [loading]="false" [scroll]="{ x: '2000px',y:scrollY }"> {{ item.armoeny | currency }} diff --git a/src/app/routes/financial-management/components/cost-management/cost-management.component.ts b/src/app/routes/financial-management/components/cost-management/cost-management.component.ts index 57203a7e..7e0458e2 100644 --- a/src/app/routes/financial-management/components/cost-management/cost-management.component.ts +++ b/src/app/routes/financial-management/components/cost-management/cost-management.component.ts @@ -2,34 +2,43 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema, SFSelectWidgetSchema, SFSchemaEnum } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; import { of } from 'rxjs'; import { map } from 'rxjs/operators'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-cost-management', templateUrl: './cost-management.component.html', - styleUrls: ['../../../commom/less/box.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class CostManagementComponent implements OnInit { +export class CostManagementComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; @ViewChild('auditModal', { static: false }) auditModal!: any; - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); columns: STColumn[] = this.initST(); selectedRows: any[] = []; - _$expand = false; - - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + private router: Router, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { Object.assign(requestOptions.body, { @@ -73,24 +82,9 @@ export class CostManagementComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } exportList() { - this.service.exportStart( { ...this.sf.value, pageSize: -1 }, this.service.$api_get_exportPlatformAccountBalanceByOperator,); + this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_get_exportPlatformAccountBalanceByOperator); } routeTo(url: string, params?: any, status?: any) { @@ -100,12 +94,6 @@ export class CostManagementComponent implements OnInit { private initSF(): SFSchema { return { properties: { - expand: { - type: 'boolean', - ui: { - hidden: true - } - }, feecode: { type: 'string', title: '费用单号', @@ -131,9 +119,6 @@ export class CostManagementComponent implements OnInit { format: 'yyyy-MM-dd', placeholder: '请选择', nzShowTime: true, - visibleIf: { - expand: (value: boolean) => value - } } as SFDateWidgetSchema }, feetype: { @@ -147,9 +132,6 @@ export class CostManagementComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -159,14 +141,11 @@ export class CostManagementComponent implements OnInit { enum: [ { label: '全部', value: '全部' }, { label: '运输费', value: '1475197820443299842' }, - { label: '附加费', value: '1476197820443299842 ' }, + { label: '附加费', value: '1476197820443299842 ' } ], ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } } }, ltdId: { @@ -177,9 +156,6 @@ export class CostManagementComponent implements OnInit { placeholder: '请选择', allowClear: true, asyncData: () => this.service.getNetworkFreightForwarder(), - visibleIf: { - expand: (value: boolean) => value - } } }, hrto: { @@ -202,9 +178,6 @@ export class CostManagementComponent implements OnInit { return of([]); } }, - visibleIf: { - expand: (value: boolean) => value - } } as SFSelectWidgetSchema }, arto: { @@ -227,9 +200,6 @@ export class CostManagementComponent implements OnInit { return of([]); } }, - visibleIf: { - expand: (value: boolean) => value - } } as SFSelectWidgetSchema }, createTime: { @@ -240,9 +210,6 @@ export class CostManagementComponent implements OnInit { format: 'yyyy-MM-dd', placeholder: '请选择', nzShowTime: true, - visibleIf: { - expand: (value: boolean) => value - } } as SFDateWidgetSchema }, ishrhx: { @@ -256,9 +223,6 @@ export class CostManagementComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -270,9 +234,6 @@ export class CostManagementComponent implements OnInit { placeholder: '请选择', allowClear: true, asyncData: () => this.service.getCloseAccount(), - visibleIf: { - expand: (value: boolean) => value - } } } } diff --git a/src/app/routes/financial-management/components/driver-account/driver-account.component.html b/src/app/routes/financial-management/components/driver-account/driver-account.component.html index 325369c1..622ac1da 100644 --- a/src/app/routes/financial-management/components/driver-account/driver-account.component.html +++ b/src/app/routes/financial-management/components/driver-account/driver-account.component.html @@ -1,4 +1,4 @@ - + - - + +
+ +
+ + +
+
+ {{ (parseFloat(item.availableBalance) + parseFloat(item.freezeBalance)).toFixed(2) | currency - }} + }} -
+
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/driver-account/driver-account.component.ts b/src/app/routes/financial-management/components/driver-account/driver-account.component.ts index 4892f27a..c1404e1f 100644 --- a/src/app/routes/financial-management/components/driver-account/driver-account.component.ts +++ b/src/app/routes/financial-management/components/driver-account/driver-account.component.ts @@ -3,30 +3,38 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; -import { ShipperBaseService } from '@shared'; +import { SearchDrawerService, ShipperBaseService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { AccountDetailComponent } from 'src/app/shared/components/account-detail/account-detail.component'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-driver-account', templateUrl: './driver-account.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class DriverAccountComponent implements OnInit { +export class DriverAccountComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; loading: boolean = true; - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); columns: STColumn[] = this.initST(); - _$expand = false; - constructor(public service: FreightAccountService, private router: Router, private modal: NzModalService) {} + constructor( + public service: FreightAccountService, + private router: Router, + private modal: NzModalService, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } beforeReq = (requestOptions: STRequestOptions) => { Object.assign(requestOptions.body, { accountType: 2 }); if (this.sf) { @@ -44,11 +52,8 @@ export class DriverAccountComponent implements OnInit { return requestOptions; }; afterRes = (data: any[], rawData?: any) => { - console.log(data) - this.loading = false - return data.map(item => ({ - ...item, - })); + this.loading = false; + return data; }; showAccountDetail(item: any) { this.modal.create({ @@ -64,25 +69,7 @@ export class DriverAccountComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - exportList() { - console.log(this.sf.value); - this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_export_driver_account_page); } @@ -118,9 +105,6 @@ export class DriverAccountComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - }, allowClear: true, asyncData: () => this.service.getNetworkFreightForwarder() } @@ -135,10 +119,7 @@ export class DriverAccountComponent implements OnInit { ], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: null }, @@ -146,10 +127,7 @@ export class DriverAccountComponent implements OnInit { type: 'string', title: '虚拟账户', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, createTime: { @@ -158,10 +136,7 @@ export class DriverAccountComponent implements OnInit { ui: { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } as SFDateWidgetSchema } } diff --git a/src/app/routes/financial-management/components/freight-account/freight-account.component.html b/src/app/routes/financial-management/components/freight-account/freight-account.component.html index 5dba1c89..f926f475 100644 --- a/src/app/routes/financial-management/components/freight-account/freight-account.component.html +++ b/src/app/routes/financial-management/components/freight-account/freight-account.component.html @@ -1,4 +1,4 @@ - + - - + +
+ +
+ + +
+
+ {{ (parseFloat(item.availableBalance) + parseFloat(item.freezeBalance)).toFixed(2) | currency}} diff --git a/src/app/routes/financial-management/components/freight-account/freight-account.component.ts b/src/app/routes/financial-management/components/freight-account/freight-account.component.ts index 5abfbe19..51d45ce9 100644 --- a/src/app/routes/financial-management/components/freight-account/freight-account.component.ts +++ b/src/app/routes/financial-management/components/freight-account/freight-account.component.ts @@ -5,9 +5,10 @@ import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; import { CurrencyService } from '@delon/util'; import { CurrencyCNYPipe } from '@delon/util/pipes/currency/cny.pipe'; -import { ShipperBaseService } from '@shared'; +import { SearchDrawerService, ShipperBaseService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; import { parse } from 'path'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { SystemService } from 'src/app/routes/sys-setting/services/system.service'; import { AccountDetailComponent } from 'src/app/shared/components/account-detail/account-detail.component'; import { FreightAccountService } from '../../services/freight-account.service'; @@ -15,24 +16,31 @@ import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-freight-account', templateUrl: './freight-account.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class FreightAccountComponent implements OnInit { +export class FreightAccountComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); columns: STColumn[] = this.initST(); selectedRows: any[] = []; - _$expand = false; - - constructor(public service: FreightAccountService, private router: Router, private modal: NzModalService) {} + constructor( + public service: FreightAccountService, + private router: Router, + private modal: NzModalService, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { Object.assign(requestOptions.body, { accountType: 1 }); if (this.sf) { @@ -63,22 +71,6 @@ export class FreightAccountComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - exportList() { this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_get_exportShipperAccountBalanceByOperator); } @@ -86,12 +78,6 @@ export class FreightAccountComponent implements OnInit { private initSF(): SFSchema { return { properties: { - expand: { - type: 'boolean', - ui: { - hidden: true - } - }, tenantName: { type: 'string', title: '企业名称', @@ -115,9 +101,6 @@ export class FreightAccountComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - }, allowClear: true, asyncData: () => this.service.getNetworkFreightForwarder() } @@ -133,9 +116,6 @@ export class FreightAccountComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: null }, @@ -144,9 +124,6 @@ export class FreightAccountComponent implements OnInit { title: '虚拟账户', ui: { placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } } }, createTime: { @@ -156,9 +133,6 @@ export class FreightAccountComponent implements OnInit { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } } as SFDateWidgetSchema } } @@ -172,7 +146,7 @@ export class FreightAccountComponent implements OnInit { { title: '联系人电话', width: 140, index: 'phone' }, { title: '网络货运人', width: 170, index: 'ltdName' }, { title: '银行类型', width: 120, index: 'bankTypeLabel' }, - { title: '虚拟账户', width: 140, index: 'virtualAccount' }, + { title: '虚拟账户', width: 160, index: 'virtualAccount' }, { title: '可用余额', index: 'availableBalance', diff --git a/src/app/routes/financial-management/components/payment-order/payment-order.component.html b/src/app/routes/financial-management/components/payment-order/payment-order.component.html index aec490c7..2443272a 100644 --- a/src/app/routes/financial-management/components/payment-order/payment-order.component.html +++ b/src/app/routes/financial-management/components/payment-order/payment-order.component.html @@ -1,4 +1,4 @@ - + + + -
+
--> - + +
+
+ + +
+
+ +
+
-
- + + [loading]="false" [scroll]="{ x:'1200px',y:scrollY }" (change)="stChange($event)"> \ No newline at end of file diff --git a/src/app/routes/financial-management/components/payment-order/payment-order.component.ts b/src/app/routes/financial-management/components/payment-order/payment-order.component.ts index 21a19041..f096e39d 100644 --- a/src/app/routes/financial-management/components/payment-order/payment-order.component.ts +++ b/src/app/routes/financial-management/components/payment-order/payment-order.component.ts @@ -2,7 +2,9 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { AddCollectionInvoiceModalComponent } from 'src/app/routes/ticket-management/components/input-invoice/add-collection-invoice-modal/add-collection-invoice-modal.component'; import { TicketService } from 'src/app/routes/ticket-management/services/ticket.service'; import { FreightAccountService } from '../../services/freight-account.service'; @@ -10,23 +12,30 @@ import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-payment-order', templateUrl: './payment-order.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class PaymentOrderComponent implements OnInit { +export class PaymentOrderComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); selectedRows: any[] = []; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + private router: Router, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { let params = { ...this.sf.value }; @@ -68,31 +77,9 @@ export class PaymentOrderComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { - expand: { - type: 'boolean', - ui: { - hidden: true - } - }, paycode: { type: 'string', title: '付款单号' @@ -135,10 +122,7 @@ export class PaymentOrderComponent implements OnInit { widget: 'dict-select', containsAllLabel: true, params: { dictKey: 'pay:mode' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, arto: { @@ -147,10 +131,7 @@ export class PaymentOrderComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - allowClear: true, - visibleIf: { - expand: (value: boolean) => value - } + allowClear: true } }, billCode: { @@ -159,10 +140,7 @@ export class PaymentOrderComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - allowClear: true, - visibleIf: { - expand: (value: boolean) => value - } + allowClear: true } }, payDate: { @@ -170,10 +148,7 @@ export class PaymentOrderComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, payDate2: { @@ -181,20 +156,12 @@ export class PaymentOrderComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, waybillCode: { type: 'string', - title: '运单号', - ui: { - visibleIf: { - expand: (value: boolean) => value - } - } + title: '运单号' }, // feeCode: { // type: 'string', @@ -210,20 +177,14 @@ export class PaymentOrderComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, payRemarks: { type: 'string', title: '付款备注', ui: { - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } } } @@ -233,9 +194,9 @@ export class PaymentOrderComponent implements OnInit { private initST(): STColumn[] { return [ { title: '', index: 'key', type: 'checkbox', fixed: 'left', className: 'text-center' }, - { title: '付款单号', index: 'payCode', type: 'link', width: 180 }, - { title: '网络货运人', index: 'ltdName', width: 180 }, - { title: '运单号', index: 'waybillCode', width: 180 }, + { title: '付款单号', index: 'payCode', className: 'text-left', type: 'link', width: 180 }, + { title: '网络货运人', index: 'ltdName', className: 'text-left', width: 180 }, + { title: '运单号', index: 'waybillCode', className: 'text-left', width: 180 }, // { title: '费用号', index: 'feeCode', width: 180 }, { title: '要求付款日期', index: 'payDate', type: 'date', className: 'text-center', width: 150 }, { diff --git a/src/app/routes/financial-management/components/payment-record/payment-record.component.html b/src/app/routes/financial-management/components/payment-record/payment-record.component.html index ecea67f6..a609c79b 100644 --- a/src/app/routes/financial-management/components/payment-record/payment-record.component.html +++ b/src/app/routes/financial-management/components/payment-record/payment-record.component.html @@ -1,14 +1,4 @@ - - + - + +
+ + + + + + + +
- - - - - - + +
+ + +
+
- + {{ item?.orderPaymentCode }}
{{ item?.paymentStatusLabel }}
diff --git a/src/app/routes/financial-management/components/payment-record/payment-record.component.less b/src/app/routes/financial-management/components/payment-record/payment-record.component.less deleted file mode 100644 index cd8c3436..00000000 --- a/src/app/routes/financial-management/components/payment-record/payment-record.component.less +++ /dev/null @@ -1,41 +0,0 @@ -:host::ng-deep { - .search-box { - .ant-card-body { - padding-bottom: 18px; - } - } - - .content-box { - .ant-card-body { - padding-top: 0; - } - } - - nz-range-picker { - width: 100%; - } - - .ant-tabs-tab-btn { - padding-left : 16px; - padding-right: 16px; - } - - .text-truncate { - white-space: normal; - } -} - -.expend-options { - margin-top: 0px; -} - - -@media (min-width: 1200px) { - .expend-options { - max-width: 400px; - position : absolute; - right : 0; - bottom : 25px; - } - -} \ No newline at end of file diff --git a/src/app/routes/financial-management/components/payment-record/payment-record.component.ts b/src/app/routes/financial-management/components/payment-record/payment-record.component.ts index 1442d8fd..8acbf17f 100644 --- a/src/app/routes/financial-management/components/payment-record/payment-record.component.ts +++ b/src/app/routes/financial-management/components/payment-record/payment-record.component.ts @@ -2,31 +2,39 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; import { ClearingModalComponent } from '../abnormal-gold/clearing-modal/clearing-modal.component'; @Component({ selector: 'app-payment-record', templateUrl: './payment-record.component.html', - styleUrls: ['./payment-record.component.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class PaymentRecordComponent implements OnInit { +export class PaymentRecordComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); paymentStatus: any = ''; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { Object.assign(requestOptions.body, { @@ -38,10 +46,10 @@ export class PaymentRecordComponent implements OnInit { handlerDate: { start: this.sf.value.handlerDate?.[0] || '', end: this.sf.value.handlerDate?.[1] || '' - }, - paymentStatus: this.paymentStatus || null + } }); } + Object.assign(requestOptions.body, { paymentStatus: this.paymentStatus || null }); return requestOptions; }; @@ -57,22 +65,6 @@ export class PaymentRecordComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { @@ -109,10 +101,7 @@ export class PaymentRecordComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'service:type' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -120,46 +109,34 @@ export class PaymentRecordComponent implements OnInit { type: 'string', title: '承运司机', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, driverLicensePlate: { type: 'string', title: '车牌号', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, captain: { type: 'string', title: '收款人', ui: { - placeholder: '请输入收款人姓名/手机号', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入收款人姓名/手机号' } }, isCaptain: { type: 'string', title: '车队长收款', enum: [ - {label: '全部', value: ''}, - {label: '是', value: '1'}, - {label: '否', value: '2'} + { label: '全部', value: '' }, + { label: '是', value: '1' }, + { label: '否', value: '2' } ], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -169,10 +146,7 @@ export class PaymentRecordComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'paybill:type' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -183,10 +157,7 @@ export class PaymentRecordComponent implements OnInit { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', placeholder: '请选择', - nzShowTime: true, - visibleIf: { - expand: (value: boolean) => value - } + nzShowTime: true } as SFDateWidgetSchema }, handlerDate: { @@ -196,10 +167,7 @@ export class PaymentRecordComponent implements OnInit { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', placeholder: '请选择', - nzShowTime: true, - visibleIf: { - expand: (value: boolean) => value - } + nzShowTime: true } as SFDateWidgetSchema }, bankType: { @@ -212,10 +180,7 @@ export class PaymentRecordComponent implements OnInit { ], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -226,10 +191,7 @@ export class PaymentRecordComponent implements OnInit { widget: 'select', placeholder: '请选择', allowClear: true, - asyncData: () => this.service.getNetworkFreightForwarder(), - visibleIf: { - expand: (value: boolean) => value - } + asyncData: () => this.service.getNetworkFreightForwarder() } } } diff --git a/src/app/routes/financial-management/components/receipt-order/receipt-order.component.html b/src/app/routes/financial-management/components/receipt-order/receipt-order.component.html index 58f7732c..47ffbda4 100644 --- a/src/app/routes/financial-management/components/receipt-order/receipt-order.component.html +++ b/src/app/routes/financial-management/components/receipt-order/receipt-order.component.html @@ -1,14 +1,4 @@ - - + + +
-
+
--> - -
- + +
+
+ + +
+
+ +
+
+ + [loading]="false" [scroll]="{ x: '1200px',y:scrollY }" (change)="stChange($event)">
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/receipt-order/receipt-order.component.ts b/src/app/routes/financial-management/components/receipt-order/receipt-order.component.ts index bf8006d6..e4c3ae26 100644 --- a/src/app/routes/financial-management/components/receipt-order/receipt-order.component.ts +++ b/src/app/routes/financial-management/components/receipt-order/receipt-order.component.ts @@ -2,30 +2,38 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; -import { AddCollectionInvoiceModalComponent } from 'src/app/routes/ticket-management/components/input-invoice/add-collection-invoice-modal/add-collection-invoice-modal.component'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-receipt-order', templateUrl: './receipt-order.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class ReceiptOrderComponent implements OnInit { +export class ReceiptOrderComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); selectedRows: any[] = []; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + private router: Router, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { Object.assign(requestOptions.body, { @@ -48,6 +56,7 @@ export class ReceiptOrderComponent implements OnInit { }); } } + this.selectedRows = []; return requestOptions; }; @@ -72,22 +81,6 @@ export class ReceiptOrderComponent implements OnInit { // }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { @@ -128,10 +121,7 @@ export class ReceiptOrderComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'driverrecord:receive:type' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, brmmode: { @@ -140,10 +130,7 @@ export class ReceiptOrderComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'receive:mode' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, arto: { @@ -155,10 +142,7 @@ export class ReceiptOrderComponent implements OnInit { searchDebounceTime: 300, searchLoadingText: '搜索中...', allowClear: true, - onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q }), - visibleIf: { - expand: (value: boolean) => value - } + onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q }) } }, sts: { @@ -167,10 +151,7 @@ export class ReceiptOrderComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'write:off:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, brmdate: { @@ -178,10 +159,7 @@ export class ReceiptOrderComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, createTime: { @@ -189,10 +167,7 @@ export class ReceiptOrderComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, // billHCode: { @@ -219,10 +194,7 @@ export class ReceiptOrderComponent implements OnInit { type: 'string', title: '收款备注', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } } } diff --git a/src/app/routes/financial-management/components/recharge-record/recharge-record.component.html b/src/app/routes/financial-management/components/recharge-record/recharge-record.component.html index 8c7c5d10..d0ed4c80 100644 --- a/src/app/routes/financial-management/components/recharge-record/recharge-record.component.html +++ b/src/app/routes/financial-management/components/recharge-record/recharge-record.component.html @@ -1,5 +1,5 @@ - - + - + - + +
+ +
+ + +
+
+ [loading]="false" [scroll]="{ x:'1200px',y:scrollY }"> {{ item.transferBankOpenName }}
{{ item.transferBankCardNumber }}
diff --git a/src/app/routes/financial-management/components/recharge-record/recharge-record.component.ts b/src/app/routes/financial-management/components/recharge-record/recharge-record.component.ts index f06bc8cb..3ab37b61 100644 --- a/src/app/routes/financial-management/components/recharge-record/recharge-record.component.ts +++ b/src/app/routes/financial-management/components/recharge-record/recharge-record.component.ts @@ -1,31 +1,36 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-recharge-record', templateUrl: './recharge-record.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class RechargeRecordComponent implements OnInit { +export class RechargeRecordComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); @ViewChild('remarkodal', { static: true }) remarkodal!: any; rechargeRemark = ''; - _$expand = false; - constructor(public service: FreightAccountService, private modal: NzModalService) {} + constructor(public service: FreightAccountService, private modal: NzModalService, public searchDrawerService: SearchDrawerService) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { Object.assign(requestOptions.body, { ...this.sf.value }); @@ -70,22 +75,6 @@ export class RechargeRecordComponent implements OnInit { history.go(-1); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - exportList() { this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_get_exportPageByOperator); } @@ -93,12 +82,6 @@ export class RechargeRecordComponent implements OnInit { private initSF(): SFSchema { return { properties: { - expand: { - type: 'boolean', - ui: { - hidden: true - } - }, rechargeNo: { type: 'string', title: '充值单号', @@ -137,9 +120,6 @@ export class RechargeRecordComponent implements OnInit { ui: { placeholder: '请输入', autocomplete: 'off', - visibleIf: { - expand: (value: boolean) => value - } } }, accountType: { @@ -154,9 +134,6 @@ export class RechargeRecordComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -166,9 +143,6 @@ export class RechargeRecordComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - }, allowClear: true, asyncData: () => this.service.getNetworkFreightForwarder() } @@ -184,9 +158,6 @@ export class RechargeRecordComponent implements OnInit { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' } diff --git a/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.html b/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.html index bd7fb2aa..84e9be34 100644 --- a/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.html +++ b/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.html @@ -1,4 +1,4 @@ - + - + +
+ +
+ + +
+
- - - + [loading]="false" [scroll]="{ x: '1200px',y:scrollY }">
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.ts b/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.ts index 0e7987e9..ca397864 100644 --- a/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.ts +++ b/src/app/routes/financial-management/components/transaction-flow/transaction-flow.component.ts @@ -3,32 +3,29 @@ import { Component, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-transaction-flow', templateUrl: './transaction-flow.component.html', - styleUrls: ['./transaction-flow.component.less'], - providers: [CurrencyPipe] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class TransactionFlowComponent { +export class TransactionFlowComponent extends BasicTableComponent { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); - _$expand = false; - - constructor( - public service: FreightAccountService, - private nzModalService: NzModalService, - private router: Router, - private currencyPipe: CurrencyPipe - ) {} + constructor(public service: FreightAccountService, public searchDrawerService: SearchDrawerService) { + super(searchDrawerService); + } + search() { + this.st?.load(1); + } beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { @@ -43,31 +40,10 @@ export class TransactionFlowComponent { return requestOptions; }; - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } private initSF(): SFSchema { return { properties: { - expand: { - type: 'boolean', - ui: { - hidden: true - } - }, createTime: { title: '交易时间', type: 'string', @@ -96,9 +72,6 @@ export class TransactionFlowComponent { title: '订单号', ui: { placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } } }, tradeType: { @@ -120,9 +93,6 @@ export class TransactionFlowComponent { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -137,9 +107,6 @@ export class TransactionFlowComponent { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -155,9 +122,6 @@ export class TransactionFlowComponent { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -166,9 +130,6 @@ export class TransactionFlowComponent { title: '账户名称', ui: { placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } } }, projectId: { @@ -178,9 +139,6 @@ export class TransactionFlowComponent { widget: 'select', placeholder: '请选择', allowClear: true, - visibleIf: { - expand: (value: boolean) => value - }, asyncData: () => this.service.getEnterpriseProject() }, default: '' @@ -196,9 +154,6 @@ export class TransactionFlowComponent { ui: { widget: 'select', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } }, default: '' }, @@ -209,9 +164,6 @@ export class TransactionFlowComponent { widget: 'select', placeholder: '请选择', allowClear: true, - visibleIf: { - expand: (value: boolean) => value - }, asyncData: () => this.service.getNetworkFreightForwarder() }, default: '' @@ -225,8 +177,8 @@ export class TransactionFlowComponent { { title: '交易时间', index: 'createTime', width: 180 }, { title: '流水号', index: 'transactionNumber', width: 180 }, { title: '交易类型', index: 'tradeTypeLabel', width: 120 }, - { title: '关联单号', index: 'businessNumber', width: 150 }, - { title: '订单号', index: 'orderSn', width: 150 }, + { title: '关联单号', index: 'businessNumber', width: 170 }, + { title: '订单号', index: 'orderSn', width: 170 }, { title: '账户类型', index: 'accountTypeLabel', width: 130 }, { title: '账户名称', index: 'roleName', width: 180 }, { title: '所属项目', index: 'projectName', width: 140 }, diff --git a/src/app/routes/financial-management/components/voucher-management/voucher-management.component.html b/src/app/routes/financial-management/components/voucher-management/voucher-management.component.html index 30ea85a7..88a9cc2c 100644 --- a/src/app/routes/financial-management/components/voucher-management/voucher-management.component.html +++ b/src/app/routes/financial-management/components/voucher-management/voucher-management.component.html @@ -1,4 +1,4 @@ - + + +
-
+
--> - + +
+ +
+ +
+
-
- -
+ + --> + [loading]="false" [scroll]="{ x:'1200px',y:scrollY }" (change)="stChange($event)">
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/voucher-management/voucher-management.component.ts b/src/app/routes/financial-management/components/voucher-management/voucher-management.component.ts index 014bde06..76f4bb47 100644 --- a/src/app/routes/financial-management/components/voucher-management/voucher-management.component.ts +++ b/src/app/routes/financial-management/components/voucher-management/voucher-management.component.ts @@ -1,43 +1,36 @@ -/* - * @Description : - * @Version : 1.0 - * @Author : Shiming - * @Date : 2022-01-18 15:57:44 - * @LastEditors : Shiming - * @LastEditTime : 2022-04-09 16:36:42 - * @FilePath : \\tms-obc-web\\src\\app\\routes\\financial-management\\components\\voucher-management\\voucher-management.component.ts - * Copyright (C) 2022 huzhenhong. All rights reserved. - */ -import { CurrencyPipe } from '@angular/common'; import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-voucher-management', templateUrl: './voucher-management.component.html', - styleUrls: ['../../../commom/less/box.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class VoucherManagementComponent implements OnInit { +export class VoucherManagementComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; @ViewChild('auditModal', { static: false }) auditModal!: any; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); selectedRows: any[] = []; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor(public service: FreightAccountService, private router: Router, public searchDrawerService: SearchDrawerService) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { Object.assign(requestOptions.body, { @@ -71,22 +64,6 @@ export class VoucherManagementComponent implements OnInit { } } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { @@ -128,10 +105,7 @@ export class VoucherManagementComponent implements OnInit { title: '原始单号', ui: { autocomplete: 'off', - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, sourceType: { @@ -155,10 +129,7 @@ export class VoucherManagementComponent implements OnInit { ], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, createTime: { @@ -166,20 +137,14 @@ export class VoucherManagementComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, remarks: { type: 'string', title: '凭证摘要', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, vctype: { @@ -188,10 +153,7 @@ export class VoucherManagementComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'credential:type' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -211,20 +173,14 @@ export class VoucherManagementComponent implements OnInit { type: 'string', title: '借方金额', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, crmoney: { type: 'string', title: '贷方金额', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, vcltdid: { @@ -233,10 +189,7 @@ export class VoucherManagementComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'refund:apply:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, sts: { @@ -245,10 +198,7 @@ export class VoucherManagementComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'credential:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -256,20 +206,14 @@ export class VoucherManagementComponent implements OnInit { type: 'string', title: 'NC凭证', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, vc2code: { type: 'string', title: '汇总凭证号', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, importnc: { @@ -278,10 +222,7 @@ export class VoucherManagementComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'refund:apply:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, isvc2: { @@ -294,10 +235,7 @@ export class VoucherManagementComponent implements OnInit { ], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } } } diff --git a/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.html b/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.html index 5f5f53c7..7380f466 100644 --- a/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.html +++ b/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.html @@ -1,14 +1,4 @@ - - + + + -
+ --> - + +
+ +
+ + +
+
+ [loading]="false" [scroll]="{ x:'1200px',y:scrollY }" (change)="stChange($event)">
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.ts b/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.ts index ca64fd91..029d31c7 100644 --- a/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.ts +++ b/src/app/routes/financial-management/components/voucher-summary/voucher-summary.component.ts @@ -3,36 +3,41 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { DateHelperByDatePipe } from 'ng-zorro-antd/i18n'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { AddCollectionInvoiceModalComponent } from 'src/app/routes/ticket-management/components/input-invoice/add-collection-invoice-modal/add-collection-invoice-modal.component'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-voucher-summary', templateUrl: './voucher-summary.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class VoucherSummaryComponent implements OnInit { +export class VoucherSummaryComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); selectedRows: any[] = []; constructor( public service: FreightAccountService, private nzModalService: NzModalService, private router: Router, - private dateHelperByDatePipe: DateHelperByDatePipe - ) {} + private dateHelperByDatePipe: DateHelperByDatePipe, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { Object.assign(requestOptions.body, { isvc2: 1 }); if (this.sf) { @@ -72,22 +77,6 @@ export class VoucherSummaryComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - exportList() { this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_export_fico_vch_page); } @@ -133,10 +122,7 @@ export class VoucherSummaryComponent implements OnInit { title: '原始单号', ui: { autocomplete: 'off', - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, sourceType: { @@ -144,10 +130,7 @@ export class VoucherSummaryComponent implements OnInit { title: '原始单类型', ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, createTime: { @@ -155,20 +138,14 @@ export class VoucherSummaryComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema }, remarks: { type: 'string', title: '凭证摘要', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, vctype: { @@ -177,10 +154,7 @@ export class VoucherSummaryComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'credential:type' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: '' }, @@ -190,30 +164,21 @@ export class VoucherSummaryComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'refund:apply:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, drmoney: { type: 'string', title: '借方金额', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, crmoney: { type: 'string', title: '贷方金额', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, vcltdid: { @@ -222,10 +187,7 @@ export class VoucherSummaryComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'refund:apply:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, sts: { @@ -234,30 +196,21 @@ export class VoucherSummaryComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'credential:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, feecode: { type: 'string', title: 'NC凭证', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, vccode: { type: 'string', title: '凭证号', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, s22t2ss: { @@ -266,10 +219,7 @@ export class VoucherSummaryComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'refund:apply:status' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, createt1im2e: { @@ -277,10 +227,7 @@ export class VoucherSummaryComponent implements OnInit { type: 'string', ui: { widget: 'sl-from-to-search', - format: 'yyyy-MM-dd', - visibleIf: { - expand: (value: boolean) => value - } + format: 'yyyy-MM-dd' } as SFDateWidgetSchema } } diff --git a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.html b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.html index a4db6171..8272131b 100644 --- a/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.html +++ b/src/app/routes/financial-management/components/withdrawals-record/withdrawals-record.component.html @@ -1,5 +1,5 @@ - - + - + - - - - - - - - - + +
+ + + + + + + + + +
@@ -60,12 +65,14 @@ totalCallNo }} 清空
+ +
+ [loading]="false" [scroll]="{ x:'1200px',y:scrollY }" (change)="stChange($event)"> {{ item.bankName }}
{{ item.bankCardNumber }}
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 75a921ef..0c5b4c86 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 @@ -2,36 +2,45 @@ import { Component, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-withdrawals-record', templateUrl: './withdrawals-record.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class WithdrawalsRecordComponent { +export class WithdrawalsRecordComponent extends BasicTableComponent { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; @ViewChild('auditModal', { static: false }) auditModal!: any; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); - - _$expand = false; + schema: SFSchema = this.initSF(); selectedRows: any[] = []; totalCallNo = 0; refundStatus: any = ''; msg = ''; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + private router: Router, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } + beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { Object.assign(requestOptions.body, { @@ -40,10 +49,12 @@ export class WithdrawalsRecordComponent { start: this.sf.value.createTime?.[0] || '', end: this.sf.value.createTime?.[1] || '' }, - refundStatus: this.refundStatus || null }); } delete requestOptions?.body?.expand; + this.selectedRows = []; + this.totalCallNo = 0; + Object.assign(requestOptions.body, { refundStatus: this.refundStatus || null }); return requestOptions; }; @@ -145,31 +156,9 @@ export class WithdrawalsRecordComponent { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { - expand: { - type: 'boolean', - ui: { - hidden: true - } - }, refundApplyCode: { type: 'string', title: '提现单号', @@ -209,10 +198,7 @@ export class WithdrawalsRecordComponent { ui: { widget: 'dict-select', params: { dictKey: 'bank:type' }, - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' } }, ltdId: { @@ -222,10 +208,7 @@ export class WithdrawalsRecordComponent { widget: 'select', placeholder: '请选择', allowClear: true, - asyncData: () => this.service.getNetworkFreightForwarder(), - visibleIf: { - expand: (value: boolean) => value - } + asyncData: () => this.service.getNetworkFreightForwarder() } }, bankType: { @@ -234,10 +217,7 @@ export class WithdrawalsRecordComponent { ui: { widget: 'dict-select', params: { dictKey: 'bankname:type' }, - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } } } @@ -246,7 +226,7 @@ export class WithdrawalsRecordComponent { private initST(): STColumn[] { return [ - { title: '', index: 'key', type: 'checkbox' }, + { title: '', index: 'key', type: 'checkbox', className: 'text-center' }, { title: '提现时间', index: 'createTime', width: 180 }, { title: '提现单号', index: 'refundApplyCode', width: 120 }, { title: '网络货运人', index: 'ltdName', width: 140 }, diff --git a/src/app/routes/financial-management/financial-management.module.ts b/src/app/routes/financial-management/financial-management.module.ts index 76cafed5..e99c95d6 100644 --- a/src/app/routes/financial-management/financial-management.module.ts +++ b/src/app/routes/financial-management/financial-management.module.ts @@ -2,7 +2,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { FreightAccountComponent } from './components/freight-account/freight-account.component'; import { DriverAccountComponent } from './components/driver-account/driver-account.component'; -import { RechargeRecordComponent } from './components/recharge-record/recharge-record.component'; import { WithdrawalsRecordComponent } from './components/withdrawals-record/withdrawals-record.component'; import { SharedModule } from '@shared'; import { FinancialManagementRoutingModule } from './financial-managemen-routing.module'; @@ -40,6 +39,7 @@ import { CwcBankCardManagementIndexComponent } from './components/bank-card-mana import { CwcBankCardManagementBindComponent } from './components/bank-card-management/bind/bind.component'; import { CwcBankCardManagementAddComponent } from './components/bank-card-management/add/add.component'; import { CwcAccountManagementWithdrawDepositComponent } from './components/platform-account/withdraw-deposit/withdraw-deposit.component'; +import { RechargeRecordComponent } from './components/recharge-record/recharge-record.component'; const ROUTESCOMPONENTS = [ FreightAccountComponent, diff --git a/src/app/shared/components/search-drawer/search-drawer.component.html b/src/app/shared/components/search-drawer/search-drawer.component.html index 070bb956..da6a8c17 100644 --- a/src/app/shared/components/search-drawer/search-drawer.component.html +++ b/src/app/shared/components/search-drawer/search-drawer.component.html @@ -8,7 +8,7 @@
- +
\ No newline at end of file From 3ffae048e2569d6eae538561fdcd973117f30dce Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Mon, 25 Apr 2022 19:33:20 +0800 Subject: [PATCH 10/18] edit --- .../advance-collection.component.html | 17 +++-- .../advance-collection.component.ts | 53 +++++++--------- .../refund-record.component.html | 36 +++++++---- .../refund-record/refund-record.component.ts | 62 ++++++------------- 4 files changed, 75 insertions(+), 93 deletions(-) diff --git a/src/app/routes/financial-management/components/advance-collection/advance-collection.component.html b/src/app/routes/financial-management/components/advance-collection/advance-collection.component.html index 065f29b2..74618239 100644 --- a/src/app/routes/financial-management/components/advance-collection/advance-collection.component.html +++ b/src/app/routes/financial-management/components/advance-collection/advance-collection.component.html @@ -1,4 +1,4 @@ - + - - + +
+ +
+ + +
+
+
\ No newline at end of file diff --git a/src/app/routes/financial-management/components/advance-collection/advance-collection.component.ts b/src/app/routes/financial-management/components/advance-collection/advance-collection.component.ts index 1462a5cd..334c030e 100644 --- a/src/app/routes/financial-management/components/advance-collection/advance-collection.component.ts +++ b/src/app/routes/financial-management/components/advance-collection/advance-collection.component.ts @@ -2,26 +2,37 @@ import { Component, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-advance-collection', templateUrl: './advance-collection.component.html', - styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class AdvanceCollectionComponent { +export class AdvanceCollectionComponent extends BasicTableComponent { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); columns: STColumn[] = this.initST(); - _$expand = false; - constructor(public service: FreightAccountService, private router: Router, private modal: NzModalService) {} + constructor( + public service: FreightAccountService, + private router: Router, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } + + ngOnInit(): void {} + + search() { + this.st?.load(1); + } beforeReq = (requestOptions: STRequestOptions) => { if (this.sf) { @@ -30,24 +41,8 @@ export class AdvanceCollectionComponent { return requestOptions; }; - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - exportList() { - this.service.exportStart( { ...this.sf.value, pageSize: -1 }, this.service.$api_get_reportYskBla,); + this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_get_reportYskBla); } private initSF(): SFSchema { @@ -97,10 +92,7 @@ export class AdvanceCollectionComponent { enum: [{ label: '全部', value: null }], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: null }, @@ -114,10 +106,7 @@ export class AdvanceCollectionComponent { ], ui: { widget: 'select', - placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请选择' }, default: null } diff --git a/src/app/routes/financial-management/components/refund-record/refund-record.component.html b/src/app/routes/financial-management/components/refund-record/refund-record.component.html index 251eff68..463ab740 100644 --- a/src/app/routes/financial-management/components/refund-record/refund-record.component.html +++ b/src/app/routes/financial-management/components/refund-record/refund-record.component.html @@ -1,4 +1,4 @@ - + - - - - - - - - + +
+ + + + + + + + +
+ [loading]="false" [scroll]="{ x:'1200px',y:scrollY }"> {{ item.orderRefundCode }}
{{ item.refundStatusLabel }}
@@ -42,7 +47,7 @@ - {{ bill.paymentApplicationCode }}
+ {{ bill.paymentApplicationCode }}
@@ -54,6 +59,13 @@
+ +
+ + +
+
+
diff --git a/src/app/routes/financial-management/components/refund-record/refund-record.component.ts b/src/app/routes/financial-management/components/refund-record/refund-record.component.ts index 6074f36b..70569f0b 100644 --- a/src/app/routes/financial-management/components/refund-record/refund-record.component.ts +++ b/src/app/routes/financial-management/components/refund-record/refund-record.component.ts @@ -2,32 +2,40 @@ import { Component, OnInit, ViewChild } from '@angular/core'; import { Router } from '@angular/router'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form'; +import { SearchDrawerService } from '@shared'; import { NzModalService } from 'ng-zorro-antd/modal'; +import { BasicTableComponent } from 'src/app/routes/commom'; import { FreightAccountService } from '../../services/freight-account.service'; @Component({ selector: 'app-refund-record', templateUrl: './refund-record.component.html', - styleUrls: ['../../../commom/less/box.less'] + styleUrls: ['../../../commom/less/commom-table.less'] }) -export class RefundRecordComponent implements OnInit { +export class RefundRecordComponent extends BasicTableComponent implements OnInit { @ViewChild('st', { static: true }) st!: STComponent; - @ViewChild('sf', { static: false }) - sf!: SFComponent; @ViewChild('auditModal', { static: false }) auditModal!: any; columns: STColumn[] = this.initST(); - searchSchema: SFSchema = this.initSF(); + schema: SFSchema = this.initSF(); - _$expand = false; refundStatus: any = ''; msg = ''; - constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {} + constructor( + public service: FreightAccountService, + private nzModalService: NzModalService, + public searchDrawerService: SearchDrawerService + ) { + super(searchDrawerService); + } ngOnInit(): void {} + search() { + this.st?.load(1); + } beforeReq = (requestOptions: STRequestOptions) => { Object.assign(requestOptions.body, { refundStatus: this.refundStatus || null }); @@ -120,22 +128,6 @@ export class RefundRecordComponent implements OnInit { }); } - /** - * 重置表单 - */ - resetSF() { - this.sf.reset(); - this._$expand = false; - } - - /** - * 伸缩查询条件 - */ - expandToggle() { - this._$expand = !this._$expand; - this.sf?.setValue('/expand', this._$expand); - } - private initSF(): SFSchema { return { properties: { @@ -177,9 +169,6 @@ export class RefundRecordComponent implements OnInit { type: 'string', title: '订单号', ui: { - visibleIf: { - expand: (value: boolean) => value - }, placeholder: '请输入' } }, @@ -187,19 +176,13 @@ export class RefundRecordComponent implements OnInit { type: 'string', title: '所属项目', ui: { - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } }, resourceCode: { type: 'string', title: '货源号', ui: { - visibleIf: { - expand: (value: boolean) => value - }, placeholder: '请输入' } }, @@ -210,9 +193,6 @@ export class RefundRecordComponent implements OnInit { widget: 'sl-from-to-search', format: 'yyyy-MM-dd', placeholder: '请选择', - visibleIf: { - expand: (value: boolean) => value - }, nzShowTime: true } as SFDateWidgetSchema }, @@ -223,10 +203,7 @@ export class RefundRecordComponent implements OnInit { widget: 'select', placeholder: '请选择', allowClear: true, - asyncData: () => this.service.getNetworkFreightForwarder(), - visibleIf: { - expand: (value: boolean) => value - } + asyncData: () => this.service.getNetworkFreightForwarder() } }, bankType: { @@ -235,10 +212,7 @@ export class RefundRecordComponent implements OnInit { ui: { widget: 'dict-select', params: { dictKey: 'bankname:type' }, - placeholder: '请输入', - visibleIf: { - expand: (value: boolean) => value - } + placeholder: '请输入' } } } From 636a725c08ecd0225a8a5d0ad87e37cc6389fa03 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Mon, 25 Apr 2022 19:58:39 +0800 Subject: [PATCH 11/18] fix bug --- .../rebate-setting/add/add.component.html | 12 ++++---- .../rebate-setting/add/add.component.ts | 30 +++++++++++++++++-- .../services/rebate-management.service.ts | 4 ++- 3 files changed, 36 insertions(+), 10 deletions(-) diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html index 08f89e5b..8aa67c55 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html @@ -4,11 +4,11 @@ * @Author : Shiming * @Date : 2022-02-24 20:09:49 * @LastEditors : Shiming - * @LastEditTime : 2022-04-24 13:42:10 + * @LastEditTime : 2022-04-25 19:58:03 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.html * Copyright (C) 2022 huzhenhong. All rights reserved. --> - + @@ -51,7 +51,7 @@ - + 1 2 3 @@ -61,17 +61,17 @@ - - + -
+
{ + console.log(res); + if(res) { + this.configName = res?.configName; + this.accountingRate = res?.accountingRate; + this.accountingRate = res?.accountingRate; + this.configType = res?.configType + ''; + this.tabelData = res?.partnerRebateConfigLineVOList; + this.partnerType = res?.partnerType + ''; + this.partnerPeopleList = res?.partnerListVOs; + this.priority = res?.priority + ''; + this.formData = res?.ruleDescription; + } + }) + } changePartner(value: any) { console.log(value); if (value == '3') { diff --git a/src/app/routes/partner/rebate-management/services/rebate-management.service.ts b/src/app/routes/partner/rebate-management/services/rebate-management.service.ts index fd12644c..b67abe19 100644 --- a/src/app/routes/partner/rebate-management/services/rebate-management.service.ts +++ b/src/app/routes/partner/rebate-management/services/rebate-management.service.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-03-10 11:19:00 * @LastEditors : Shiming - * @LastEditTime : 2022-03-29 11:26:38 + * @LastEditTime : 2022-04-25 19:23:25 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\services\\rebate-management.service.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -27,6 +27,8 @@ export class RebateManagementService extends BaseService { // 运营端查询合伙人返佣 public $api_get_getIncomeByBillpage = '/api/bpc/partnerIncomeHead/getIncomeByBillpage'; + // 获取返佣模板信息 + public $api_get_getPartnerRebateConfigInfo = '/api/mdc/rebateConfig/getPartnerRebateConfigInfo';   // 查询合伙人信息-分页 public $api_get_partner_page = '/api/mdc/partner/list/page'; constructor(public injector: Injector) { From 5b1d5d7ea874eaceb2d509f5dce169b483391230 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 26 Apr 2022 10:21:05 +0800 Subject: [PATCH 12/18] fix bug --- .../components/edit/edit.component.ts | 4 + .../components/list/list.component.html | 11 ++ .../components/list/list.component.ts | 34 ++++-- .../components/config/config.component.html | 106 +++++++----------- .../components/config/config.component.ts | 71 +++--------- .../role-management/edit/edit.component.ts | 2 +- .../role-management/menu/menu.component.ts | 50 ++------- 7 files changed, 106 insertions(+), 172 deletions(-) diff --git a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts index bd01de45..1ae908ee 100644 --- a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts +++ b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts @@ -34,6 +34,10 @@ export class ParterChannelSalesEditComponent implements OnInit { this.service.request(this.service.$api_getChannelSalesInfo, {id:this.i?.id}).subscribe(res => { if(res){ this.record = res; + + // this.sf.getProperty('/employeeVO')!.schema.enum = res; + // this.sf.getProperty('/employeeVO')!.widget.reset(res); + // this.sf.setValue('/employeeVO', this.enterpriseProjectIds); this.initSF(); } }); diff --git a/src/app/routes/partner/channel-sales/components/list/list.component.html b/src/app/routes/partner/channel-sales/components/list/list.component.html index 589c32e9..8b7dd971 100644 --- a/src/app/routes/partner/channel-sales/components/list/list.component.html +++ b/src/app/routes/partner/channel-sales/components/list/list.component.html @@ -1,3 +1,13 @@ + -

货主端配置

-

图片配置

- - - - - -
可输入字符
- -
-
-

短信配置

+

提现手续费配置

- -

配置用户端登陆页注册帐号、修改密码、修改手机号时的短信内容

- + +
+ 按照提现金额收取 + + + %手续费 + +
+
+ +
+ 按照提现金额收取 + + + %手续费 + +
-

通知配置

+

合伙人提现配置

-
- - - +
+ + + + + + +
-

客服电话配置

+

客服电话配置

@@ -84,10 +86,6 @@

通知配置

- - - -
@@ -146,42 +144,24 @@
- +
- - - + + + - - - - - - - - - - - - - - - - - - - - - - - -
- - -
-
+
+ + + + + + + + + +
\ No newline at end of file diff --git a/src/app/routes/partner/system-config/components/config/config.component.ts b/src/app/routes/partner/system-config/components/config/config.component.ts index 27a32a88..b7489b98 100644 --- a/src/app/routes/partner/system-config/components/config/config.component.ts +++ b/src/app/routes/partner/system-config/components/config/config.component.ts @@ -4,7 +4,7 @@ import { Observable, Observer } from 'rxjs'; import { ConfigService } from '../../services/config.service'; @Component({ - selector: 'app-config', + selector: 'app-parterl-config', templateUrl: './config.component.html', styleUrls: ['./config.component.less'] }) @@ -15,12 +15,17 @@ export class PartnerSystemConfigComponent implements OnInit { isEveryDay: false, isEveryWeek: false }; + personValue!: number; + enterpriseValue!: number; + auditValue!: number; + auditTime!: any; + auditTimeStatus: boolean = false tabs = [ { - name: '货主端配置' + name: '基础配置' }, { - name: '司机端配置' + name: '分享配置' } ]; selectedTab = 0; @@ -37,7 +42,6 @@ export class PartnerSystemConfigComponent implements OnInit { i: any; schema!: SFSchema; - schema2!: SFSchema; imageConfig = { widget: 'upload', @@ -64,61 +68,8 @@ export class PartnerSystemConfigComponent implements OnInit { } initSF() { + this.schema = { - properties: { - sysMinLogo: { - type: 'string', - title: '系统LOGO(大)', - // enum: [], - ui: { - ...this.imageConfig, - descriptionI18n: '大尺寸logo,支持JPG、PNG格式,文件小于2M(建议尺寸300*170px)。', - change: args => { - if (args.type === 'success') { - const avatar = this.getImageModel(args, 'sysMinLogo'); - this.sf?.setValue('/sysMinLogo', avatar); - this.i.sysMinLogo = avatar; - } - }, - beforeUpload: this.uploadBefore - } as SFUploadWidgetSchema - }, - sysMaxLogo: { - type: 'string', - title: '用户默认头像', - ui: { - ...this.imageConfig, - descriptionI18n: '支持JPG、PNG格式,文件小于2M(建议尺寸60*60px)。', - change: args => { - if (args.type === 'success') { - const avatar = this.getImageModel(args, -1); - this.sf?.setValue('/sysMaxLogo', avatar); - this.i.sysMaxLogo = avatar; - } - }, - beforeUpload: this.uploadBefore - } as SFUploadWidgetSchema - }, - sysMaxLogo1: { - type: 'string', - title: '用户默认头像', - ui: { - ...this.imageConfig, - descriptionI18n: '支持JPG、PNG格式,文件小于5M(建议尺寸375*773px)。', - change: args => { - if (args.type === 'success') { - const avatar = this.getImageModel(args, -1); - this.sf?.setValue('/sysMaxLogo1', avatar); - this.i.sysMaxLogo1 = avatar; - } - }, - beforeUpload: this.uploadBefore - } as SFUploadWidgetSchema - }, - }, - required: ['sysMinLogo', 'sysMaxLogo', 'sysMaxLogo1'] - }; - this.schema2 = { properties: { sysMinLogo: { type: 'string', @@ -221,7 +172,11 @@ export class PartnerSystemConfigComponent implements OnInit { required: ['sysMinLogo', 'sysMaxLogo', 'sysMaxLogo1', 'sysMaxLogo2', 'sysMaxLogo3', 'sysMaxLogo4'] }; } + auditTimeChange(ss: any,value: any) { + console.log(value); + this.auditTimeStatus = true + } private uploadBefore = (file: any, fileList: any) => { return new Observable((observer: Observer) => { const isLt1M = file.size / 1024 / 1024 < 2; diff --git a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts index b91344a8..9d00f002 100644 --- a/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts +++ b/src/app/routes/sys-setting/components/role-management/edit/edit.component.ts @@ -83,7 +83,7 @@ console.log(this.params.infoUrl) close() { this.modal.destroy(); } - changeIF(value: boolean) { + changeIF(value: any) { console.log(value); console.log('54545'); this.changeValue = true diff --git a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts index 8b031d24..4f6c67a5 100644 --- a/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts +++ b/src/app/routes/sys-setting/components/role-management/menu/menu.component.ts @@ -1,5 +1,5 @@ import { ChangeDetectorRef, Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges, ViewChild } from '@angular/core'; -import { ModalHelper, _HttpClient } from '@delon/theme'; +import { _HttpClient } from '@delon/theme'; import { EAEnvironmentService } from '@shared'; import { NzTreeComponent } from 'ng-zorro-antd/tree'; import { SystemService } from '../../../services/system.service'; @@ -19,7 +19,6 @@ export class SettingMenuComponent implements OnInit, OnChanges { defaultCheckedKeys: any[] = []; functionList: any[] = []; allChecked = false; - changeIFT = false; indeterminate = true; @Input() type = 'edit'; @Input() source = ''; @@ -27,7 +26,6 @@ export class SettingMenuComponent implements OnInit, OnChanges { @Input() isAuthorityIdDTOList: any[] = []; @Input() authorityAssistId: any[] = []; @Input() roleId: any; - @Output() changeIF= new EventEmitter(); @Output() changeData = new EventEmitter(); constructor(public service: SystemService, private cdr: ChangeDetectorRef, private envSrv: EAEnvironmentService) {} ngOnChanges(changes: SimpleChanges): void { @@ -36,9 +34,9 @@ export class SettingMenuComponent implements OnInit, OnChanges { this.authority = this.isAuthorityIdDTOList || []; } } - if (changes.authorityAssistId) { - this.defaultCheckedKeys = [...this.authorityAssistId]; - } + // if (changes.authorityAssistId) { + // this.defaultCheckedKeys = [...this.authorityAssistId]; + // } } ngOnInit() { @@ -59,44 +57,25 @@ export class SettingMenuComponent implements OnInit, OnChanges { }); } addAuthority(origin: { id: any; all: any }, node: { buttonInfoList: any[] }, item?: { checked: any; functionButtonId: any }) { - console.log(origin); + console.log(origin,node); if (this.authority?.length && this.authority.filter(authItem => authItem.authorityId === origin.id).length) { // 判断此菜单权限是否已经存在权限列表中 // 当前操作菜单id存在权限列表里 this.authority.forEach(menuItem => { + console.log(menuItem); + console.log(item); if (menuItem.authorityId === origin.id) { menuItem.buttonAuthorityIds = menuItem.buttonAuthorityIds || []; // 防止属性不存在,给属性指定数据类型 if (item) { - this.changeIF.emit(true); - this.changeIFT = true - // 判断此菜单下是否已有此按钮权限 - // this.againGetBtn(id, origin); - const params = { - id: origin.id - }; - this.service.request(this.service.$api_getFunctionButtonInfo, params).subscribe(res => { - if (res) { - let origins: any = {}; - origins.buttonInfoList = res; - origins.all = false; - console.log(origins); - - // 判断此菜单下是否已有此按钮权限 - this.againGetBtn(origin.id, origins); - } - }); // 单选 if (item.checked) { if (menuItem.buttonAuthorityIds.indexOf(item.functionButtonId) === -1) { // 如果该按钮在数据权限数组中不存在 - console.log('不存在'); - menuItem.buttonAuthorityIds.push(item.functionButtonId); } } else { - console.log('存在'); if (menuItem.buttonAuthorityIds && menuItem.buttonAuthorityIds.length) { menuItem.buttonAuthorityIds.forEach((btnItem: any, index: any) => { if (btnItem === item.functionButtonId) { @@ -347,20 +326,9 @@ export class SettingMenuComponent implements OnInit, OnChanges { } // 再次请求,需要判断暂存权限数组是否已有此权限 againGetBtn(id: any, origin: any) { - console.log(id,origin); - - console.log(this.authority); - console.log(this.authority.length); - - if ((this.authority && this.authority.length !== 0)) { - console.log('1111'); - + if (this.authority && this.authority.length === 0) { const buttonAuthorityIds: any = []; - console.log(origin); - console.log(origin.checked); - if (origin.checked) { - origin.buttonInfoList.forEach((btnItem: { functionButtonId: any; checked: boolean }) => { btnItem.checked = true; buttonAuthorityIds.push(btnItem.functionButtonId); @@ -368,8 +336,6 @@ export class SettingMenuComponent implements OnInit, OnChanges { this.authority.push({ authorityId: origin.key, buttonAuthorityIds, isUpdateAuthority: 1 }); } } else { - console.log('22222'); - if (origin.checked) { //菜单勾选情况下 if (this.authority.some(item => item.authorityId === id)) { From a8a1d9ed65cc4d66d084d0a34703b310fbe92f70 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 26 Apr 2022 10:59:33 +0800 Subject: [PATCH 13/18] fix bug --- .../components/edit/edit.component.ts | 23 +++++++++++++------ .../components/list/list.component.ts | 1 + .../rebate-setting/add/add.component.html | 18 +++++++-------- .../rebate-setting/add/add.component.ts | 8 +++++-- 4 files changed, 32 insertions(+), 18 deletions(-) diff --git a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts index 1ae908ee..bd12ea3a 100644 --- a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts +++ b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts @@ -33,16 +33,25 @@ export class ParterChannelSalesEditComponent implements OnInit { if(!this.sts) { this.service.request(this.service.$api_getChannelSalesInfo, {id:this.i?.id}).subscribe(res => { if(res){ - this.record = res; - - // this.sf.getProperty('/employeeVO')!.schema.enum = res; - // this.sf.getProperty('/employeeVO')!.widget.reset(res); - // this.sf.setValue('/employeeVO', this.enterpriseProjectIds); - this.initSF(); + let value1 = Object.assign({}, res) + delete value1.employeeVO; + this.record = value1; + console.log(value1); + console.log(this.record); + + let value = res.employeeVO; + let yeeVO = {label: value.empName+"/"+value.empNo, value: value.empNo} + console.log(yeeVO); + + setTimeout(()=>{ + this.sf.getProperty('/employeeVO')!.schema.enum = [yeeVO]; + this.sf.getProperty('/employeeVO')!.widget.reset([yeeVO]); + }) + + this.initSF(); } }); } - this.initSF(); } initSF() { diff --git a/src/app/routes/partner/channel-sales/components/list/list.component.ts b/src/app/routes/partner/channel-sales/components/list/list.component.ts index 2a5a8db1..88b791a4 100644 --- a/src/app/routes/partner/channel-sales/components/list/list.component.ts +++ b/src/app/routes/partner/channel-sales/components/list/list.component.ts @@ -122,6 +122,7 @@ export class ParterChannelSalesListComponent implements OnInit { title: '操作', className: 'text-center', width: '120px', + fixed: 'right', buttons: [ { text: '编辑', diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html index 8aa67c55..0482f6e6 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-02-24 20:09:49 * @LastEditors : Shiming - * @LastEditTime : 2022-04-25 19:58:03 + * @LastEditTime : 2022-04-26 10:53:50 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.html * Copyright (C) 2022 huzhenhong. All rights reserved. --> @@ -12,16 +12,16 @@ - + 固定结算费率配置 -  % +  % 业务量和管理费比例配置 - + @@ -36,7 +36,7 @@ 关联合伙人配置 - + @@ -51,7 +51,7 @@ - + 1 2 3 @@ -60,13 +60,13 @@ - - + - + diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts index d85611c3..71097915 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-03-21 09:26:45 * @LastEditors : Shiming - * @LastEditTime : 2022-04-25 19:56:41 + * @LastEditTime : 2022-04-26 10:58:58 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -67,6 +67,7 @@ export class ParterRebateManageMentAddComponent implements OnInit { { text: '移除', click: _record => this.delete(_record), + iif: ()=> this.hiden, acl: { ability: ['AbnormalAppear-reply'] } } ] @@ -78,7 +79,9 @@ export class ParterRebateManageMentAddComponent implements OnInit { ruleDescription: { type: 'string', title: '', + disabled: this.hiden, ui: { + widget: 'tinymce', loadingTip: 'loading...', config: { @@ -176,7 +179,8 @@ export class ParterRebateManageMentAddComponent implements OnInit { this.partnerType = res?.partnerType + ''; this.partnerPeopleList = res?.partnerListVOs; this.priority = res?.priority + ''; - this.formData = res?.ruleDescription; + this.formData = {ruleDescription: res?.ruleDescription}; + this.remarke = res.remark; } }) } From 019dd90757d63e3fc0818e3fe4ba3fc0fa42ba1d Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 26 Apr 2022 11:06:31 +0800 Subject: [PATCH 14/18] fix bug --- .../rebate-setting/add/add.component.ts | 56 ++++++++++--------- 1 file changed, 30 insertions(+), 26 deletions(-) diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts index 71097915..01389bd2 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-03-21 09:26:45 * @LastEditors : Shiming - * @LastEditTime : 2022-04-26 10:58:58 + * @LastEditTime : 2022-04-26 11:06:25 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -49,30 +49,7 @@ export class ParterRebateManageMentAddComponent implements OnInit { private modal: NzModalService, public shipperservice: ShipperBaseService ) {} - columns: STColumn[] = [ - { - title: '合伙人名称', - index: 'enterpriseName', - width: 180, - format: item => (item.partnerType ? `${item.enterpriseName || item.contactName}` : '') - }, - { title: '联系人', index: 'contactName', width: 150, format: item => (item.partnerType ? `${item.contactName}` : '') }, - { title: '手机号', index: 'contactMobile', className: 'text-center', width: 150 }, - { title: '类型', index: 'partnerType', className: 'text-center', width: 130, type: 'enum', enum: { 1: '企业', 2: '个人' } }, - { - title: '操作', - width: '90px', - fixed: 'right', - buttons: [ - { - text: '移除', - click: _record => this.delete(_record), - iif: ()=> this.hiden, - acl: { ability: ['AbnormalAppear-reply'] } - } - ] - } - ]; + columns: STColumn[] =[] initSF(data?: any) { this.schema1 = { properties: { @@ -92,13 +69,40 @@ export class ParterRebateManageMentAddComponent implements OnInit { } } }; + this.columns= [ + { + title: '合伙人名称', + index: 'enterpriseName', + width: 180, + format: item => (item.partnerType ? `${item.enterpriseName || item.contactName}` : '') + }, + { title: '联系人', index: 'contactName', width: 150, format: item => (item.partnerType ? `${item.contactName}` : '') }, + { title: '手机号', index: 'contactMobile', className: 'text-center', width: 150 }, + { title: '类型', index: 'partnerType', className: 'text-center', width: 130, type: 'enum', enum: { 1: '企业', 2: '个人' } }, + { + title: '操作', + width: '120px', + fixed: 'right', + buttons: [ + { + text: '移除', + click: _record => this.delete(_record), + iif: ()=> { + console.log(this.hiden); + return !this.hiden + }, + acl: { ability: ['AbnormalAppear-reply'] } + } + ] + } + ]; } ngOnInit() { console.log(this.ar.snapshot.queryParams.id); if(this.ar.snapshot?.queryParams?.id) { this.titleText= '查看' this.hiden= true - + this.initSF(); this.initData(this.ar.snapshot?.queryParams?.id); } this.addStatus = false; From 5cddd9a9566a06364d0915856664b3ecc1f6b681 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 26 Apr 2022 11:07:18 +0800 Subject: [PATCH 15/18] fix bug --- .../components/rebate-setting/add/add.component.ts | 4 ++-- .../components/rebate-setting/rebate-setting.component.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts index 01389bd2..bddf0dca 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-03-21 09:26:45 * @LastEditors : Shiming - * @LastEditTime : 2022-04-26 11:06:25 + * @LastEditTime : 2022-04-26 11:04:46 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -81,7 +81,7 @@ export class ParterRebateManageMentAddComponent implements OnInit { { title: '类型', index: 'partnerType', className: 'text-center', width: 130, type: 'enum', enum: { 1: '企业', 2: '个人' } }, { title: '操作', - width: '120px', + width: '90px', fixed: 'right', buttons: [ { diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts b/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts index 5e7828bc..49a1d8d0 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/rebate-setting.component.ts @@ -120,7 +120,7 @@ export class ParterRebateManageMentSettingComponent implements OnInit { { title: '操作', fixed: 'right', - width: '90px', + width: '120px', className: 'text-left', buttons: [ { From 3b331b81f84d28ac8e7f3afed19a8d06908ddbf2 Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Tue, 26 Apr 2022 13:27:09 +0800 Subject: [PATCH 16/18] edit --- .../platform-account-detail.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/routes/financial-management/components/platform-account/platform-account-detail/platform-account-detail.component.ts b/src/app/routes/financial-management/components/platform-account/platform-account-detail/platform-account-detail.component.ts index 43e46e5b..d2e4b20c 100644 --- a/src/app/routes/financial-management/components/platform-account/platform-account-detail/platform-account-detail.component.ts +++ b/src/app/routes/financial-management/components/platform-account/platform-account-detail/platform-account-detail.component.ts @@ -119,7 +119,7 @@ export class PlatformAccountDetailComponent implements OnInit { nzShowTime: true } as SFDateWidgetSchema }, - businessNumber: { + channelPaySn: { type: 'string', title: '流水号', ui: { From e40860dd6019eb008f9392977c45cac9edd2ba4b Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 26 Apr 2022 13:46:53 +0800 Subject: [PATCH 17/18] fix bug --- .../components/edit/edit.component.ts | 161 ++++++++++++------ .../add-etp-partner.component.ts | 24 +-- .../add-personal-partner.component.ts | 42 ++--- 3 files changed, 121 insertions(+), 106 deletions(-) diff --git a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts index bd12ea3a..b5891ac0 100644 --- a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts +++ b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts @@ -1,8 +1,19 @@ import { AfterViewInit, ChangeDetectorRef, Component, OnChanges, OnInit, ViewChild } from '@angular/core'; import { ActivatedRoute } from '@angular/router'; -import { SFAutoCompleteWidgetSchema, SFComponent, SFRadioWidgetSchema, SFSchema, SFSchemaEnumType, SFSelectWidgetSchema, SFTextareaWidgetSchema, SFUISchema } from '@delon/form'; +import { + SFAutoCompleteWidgetSchema, + SFComponent, + SFRadioWidgetSchema, + SFSchema, + SFSchemaEnum, + SFSchemaEnumType, + SFSelectWidgetSchema, + SFTextareaWidgetSchema, + SFUISchema +} from '@delon/form'; import { _HttpClient } from '@delon/theme'; import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal'; +import { of } from 'rxjs'; import { map } from 'rxjs/operators'; import { AmapPoiPickerComponent } from 'src/app/shared/components/amap'; import { ChannelSalesService } from '../../services/channel-sales.service'; @@ -18,8 +29,8 @@ export class ParterChannelSalesEditComponent implements OnInit { i: any; sts: any; type: any; - record:any; - currentOAItem:any; + record: any; + currentOAItem: any; constructor( public http: _HttpClient, private cdr: ChangeDetectorRef, @@ -30,29 +41,39 @@ export class ParterChannelSalesEditComponent implements OnInit { ) {} ngOnInit(): void { - if(!this.sts) { - this.service.request(this.service.$api_getChannelSalesInfo, {id:this.i?.id}).subscribe(res => { - if(res){ - let value1 = Object.assign({}, res) - delete value1.employeeVO; - this.record = value1; - console.log(value1); - console.log(this.record); - - let value = res.employeeVO; - let yeeVO = {label: value.empName+"/"+value.empNo, value: value.empNo} - console.log(yeeVO); - - setTimeout(()=>{ - this.sf.getProperty('/employeeVO')!.schema.enum = [yeeVO]; - this.sf.getProperty('/employeeVO')!.widget.reset([yeeVO]); - }) - - this.initSF(); + this.initSF(); + if (!this.sts) { + this.service.request(this.service.$api_getChannelSalesInfo, { id: this.i?.id }).subscribe(res => { + const List: any = []; + if (res) { + let value1 = Object.assign({}, res); + delete value1.employeeVO; + console.log(value1); + console.log(this.record); + + let value = res.employeeVO; + console.log(value); + + List.push({ label: value.empName + '/' + value.empNo, value: value.empNo }); + console.log(List); + + setTimeout(() => { + if (this.sf) { + console.log(this.sf.getProperty('/employeeVO')!.schema); + + this.sf.getProperty('/employeeVO')!.schema.enum = List; + this.sf.getProperty('/employeeVO')!.widget.reset(List); + } + if (value.empNo) { + this.sf.setValue('/employeeVO', value.empNo); + this.currentOAItem = value; + this.sf.setValue('/phoneNumber', res.telephone); + } + }); + this.record = value1; } }); } - } initSF() { this.schema = { @@ -67,34 +88,67 @@ export class ParterChannelSalesEditComponent implements OnInit { type: 'string', maxLength: 12, ui: { - placeholder:'请输入' - } + placeholder: '请输入' + } }, phoneNumber: { title: '手机号', type: 'string', maxLength: 11, ui: { - placeholder:'请输入' - } + placeholder: '请输入' + } }, + // employeeVO: { + // title: '关联OA员工', + // type: 'string', + // ui: { + // widget: 'select', + // placeholder:'请选择', + // asyncData: (input:string) => this.service.request(this.service.$api_fuzzyQuery,{name:input}).pipe( + // map((res: any) => { + // return res.map((item:any)=>{ + // return {label: item.empName+"/"+item.empNo, value: item.empNo, obj: item} + // }) + // }) + // ), + // change:(item:any, org:any)=>{ + // this.currentOAItem = org.obj; + // } + // } as SFAutoCompleteWidgetSchema, + // }, employeeVO: { title: '关联OA员工', type: 'string', + maxLength: 30, ui: { - widget: 'autocomplete', - placeholder:'请选择', - asyncData: (input:string) => this.service.request(this.service.$api_fuzzyQuery,{name:input}).pipe( - map((res: any) => { - return res.map((item:any)=>{ - return {label: item.empName+"/"+item.empNo, value: item.empNo, obj: item} - }) - }) - ), - change:(item:any, org:any)=>{ + widget: 'select', + // serverSearch: true, + allowClear: true, + searchDebounceTime: 300, + searchLoadingText: '搜索中...', + onSearch: (q: any) => { + let str = q?.replace(/^\s+|\s+$/g, ''); + if (str) { + return this.service + .request(this.service.$api_fuzzyQuery, { name: str }) + .pipe(map(res => (res as any[]).map(i => ({ label: i.empName + '/' + i.empNo, value: i.empNo, obj: i } as SFSchemaEnum)))) + .toPromise(); + } else { + return of([]); + } + }, + // asyncData: (input:string) => this.service.request(this.service.$api_fuzzyQuery,{name:input}).pipe( + // map((res: any) => { + // return res.map((item:any)=>{ + // return {label: item.empName+"/"+item.empNo, value: item.empNo, obj: item} + // }) + // }) + // ), + change: (item: any, org: any) => { this.currentOAItem = org.obj; } - } as SFAutoCompleteWidgetSchema, + } as SFSelectWidgetSchema }, isAuthorization: { type: 'string', @@ -104,9 +158,9 @@ export class ParterChannelSalesEditComponent implements OnInit { { label: '是', value: '1' } ], ui: { - widget: 'radio', + widget: 'radio' } as SFRadioWidgetSchema, - default: '0', + default: '0' }, roleIds: { title: '', @@ -128,7 +182,7 @@ export class ParterChannelSalesEditComponent implements OnInit { ); }, visibleIf: { isAuthorization: (value: string) => value === '1' } - }, + } }, remark: { type: 'string', @@ -137,9 +191,9 @@ export class ParterChannelSalesEditComponent implements OnInit { ui: { widget: 'textarea', autosize: { minRows: 3, maxRows: 6 }, - placeholder:'请输入50字符' - } as SFTextareaWidgetSchema, - }, + placeholder: '请输入50字符' + } as SFTextareaWidgetSchema + } }, required: ['name', 'phoneNumber', 'employeeVO', 'roleIds', 'remark'] }; @@ -148,24 +202,25 @@ export class ParterChannelSalesEditComponent implements OnInit { spanLabelFixed: 150, grid: { span: 24 } }, - $isAuthorization:{ grid: { span: 12 }}, - $roleIds:{ spanLabelFixed: 10, grid: { span: 12 }}, - - + $isAuthorization: { grid: { span: 12 } }, + $roleIds: { spanLabelFixed: 10, grid: { span: 12 } } }; } close() { this.modalRef.destroy(); } - save() { + save() { this.sf.validator({ emitError: true }); - if(!this.sf.valid) return; - this.service.request(this.service.$api_save, { ...this.sf.value, employeeVO: this.currentOAItem}).subscribe(res => { + if (!this.sf.valid) return; + let params = { + ...this.sf.value + } + delete params.telephone + this.service.request(this.service.$api_save, { ...params, employeeVO: this.currentOAItem }).subscribe(res => { if (res) { + this.service.msgSrv.success(res.msg); this.modalRef.destroy(true); - } else { - this.service.msgSrv.error(res.msg); } }); } diff --git a/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.ts b/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.ts index 14efa97f..2ccfeb94 100644 --- a/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.ts +++ b/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.ts @@ -617,15 +617,8 @@ export class AddEtpPartnerComponent { } private setInfo(info: any) { - if (info.name) { this.sf.setValue('/adminUserInfo/name', info.name); - } - if (info.certificatePhotoFront) { this.sf.setValue('/adminUserInfo/certificatePhotoFront', info.certificatePhotoFront); - } - if (info.certificatePhotoFrontWatermark) { - console.log(this.sf.getProperty('/adminUserInfo/certificatePhotoFrontWatermark')); - this.sf.setValue('/adminUserInfo/certificatePhotoFrontWatermark', [ { uid: -1, @@ -635,11 +628,7 @@ export class AddEtpPartnerComponent { response: info.certificatePhotoFrontWatermark } ]); - } - if (info.certificatePhotoBack) { this.sf.setValue('/adminUserInfo/certificatePhotoBack', info.certificatePhotoBack); - } - if (info.certificatePhotoBackWatermark) { this.sf.setValue('/adminUserInfo/certificatePhotoBackWatermark', [ { uid: -1, @@ -649,18 +638,9 @@ export class AddEtpPartnerComponent { response: info.certificatePhotoBackWatermark } ]); - } - if (info.certificateNumber) { this.sf.setValue('/adminUserInfo/certificateNumber', info.certificateNumber); - } - if (info.validStartTime) { this.sf.setValue('/adminUserInfo/validStartTime', info.validStartTime); - } - if (info.validEndTime) { - this.sf.setValue('/adminUserInfo/validEndTime', info.validEndTime); - this.sf.setValue('/adminUserInfo/_isLoingDate', false); - } else { - this.sf.setValue('/adminUserInfo/_isLoingDate', true); - } + this.sf.setValue('/adminUserInfo/validEndTime', info?.validEndTime ? info?.validEndTime: null); + this.sf.setValue('/adminUserInfo/_isLoingDate', info?.validEndTime ? false: true); } } diff --git a/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.ts b/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.ts index d21416e3..c18550ef 100644 --- a/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.ts +++ b/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.ts @@ -339,50 +339,30 @@ export class AddPersonalPartnerComponent { } private setInfo(info: any) { - if (info.name) { - this.sf.setValue('/adminUserInfo/name', info.name); - } - if (info.certificatePhotoFront) { - this.sf.setValue('/adminUserInfo/certificatePhotoFront', info.certificatePhotoFront); - } - if (info.certificatePhotoFrontWatermark) { - console.log(this.sf.getProperty('/adminUserInfo/certificatePhotoFrontWatermark')); - + this.sf.setValue('/adminUserInfo/name', info?.name); + this.sf.setValue('/adminUserInfo/certificatePhotoFront', info?.certificatePhotoFront); this.sf.setValue('/adminUserInfo/certificatePhotoFrontWatermark', [ { uid: -1, name: '文件', status: 'done', - url: info.certificatePhotoFrontWatermark, - response: info.certificatePhotoFrontWatermark + url: info?.certificatePhotoFrontWatermark, + response: info?.certificatePhotoFrontWatermark } ]); - } - if (info.certificatePhotoBack) { - this.sf.setValue('/adminUserInfo/certificatePhotoBack', info.certificatePhotoBack); - } - if (info.certificatePhotoBackWatermark) { + this.sf.setValue('/adminUserInfo/certificatePhotoBack', info?.certificatePhotoBack); this.sf.setValue('/adminUserInfo/certificatePhotoBackWatermark', [ { uid: -1, name: '文件', status: 'done', - url: info.certificatePhotoBackWatermark, - response: info.certificatePhotoBackWatermark + url: info?.certificatePhotoBackWatermark, + response: info?.certificatePhotoBackWatermark } ]); - } - if (info.certificateNumber) { - this.sf.setValue('/adminUserInfo/certificateNumber', info.certificateNumber); - } - if (info.validStartTime) { - this.sf.setValue('/adminUserInfo/validStartTime', info.validStartTime); - } - if (info.validEndTime) { - this.sf.setValue('/adminUserInfo/validEndTime', info.validEndTime); - this.sf.setValue('/adminUserInfo/_isLoingDate', false); - } else { - this.sf.setValue('/adminUserInfo/_isLoingDate', true); - } + this.sf.setValue('/adminUserInfo/certificateNumber', info?.certificateNumber); + this.sf.setValue('/adminUserInfo/validStartTime', info?.validStartTime); + this.sf.setValue('/adminUserInfo/validEndTime', info?.validEndTime ? info?.validEndTime: null); + this.sf.setValue('/adminUserInfo/_isLoingDate', info?.validEndTime ? false: true); } } From 47a5dfedad1d4db072db281ac1dfbae8578c704f Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 26 Apr 2022 14:05:17 +0800 Subject: [PATCH 18/18] fix bug --- .../components/edit/edit.component.ts | 36 ++++++++----------- .../rebate-setting/add/add.component.html | 4 +-- 2 files changed, 17 insertions(+), 23 deletions(-) diff --git a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts index b5891ac0..c563ff9b 100644 --- a/src/app/routes/partner/channel-sales/components/edit/edit.component.ts +++ b/src/app/routes/partner/channel-sales/components/edit/edit.component.ts @@ -48,28 +48,21 @@ export class ParterChannelSalesEditComponent implements OnInit { if (res) { let value1 = Object.assign({}, res); delete value1.employeeVO; - console.log(value1); - console.log(this.record); - let value = res.employeeVO; - console.log(value); - List.push({ label: value.empName + '/' + value.empNo, value: value.empNo }); - console.log(List); + setTimeout(() => { + if (this.sf) { + console.log(this.sf.getProperty('/employeeVO')!.schema); - setTimeout(() => { - if (this.sf) { - console.log(this.sf.getProperty('/employeeVO')!.schema); - - this.sf.getProperty('/employeeVO')!.schema.enum = List; - this.sf.getProperty('/employeeVO')!.widget.reset(List); - } - if (value.empNo) { - this.sf.setValue('/employeeVO', value.empNo); - this.currentOAItem = value; - this.sf.setValue('/phoneNumber', res.telephone); - } - }); + this.sf.getProperty('/employeeVO')!.schema.enum = List; + this.sf.getProperty('/employeeVO')!.widget.reset(List); + } + if (value.empNo) { + this.sf.setValue('/employeeVO', value.empNo); + this.currentOAItem = value; + this.sf.setValue('/phoneNumber', res.telephone); + } + }) this.record = value1; } }); @@ -212,9 +205,10 @@ export class ParterChannelSalesEditComponent implements OnInit { } save() { this.sf.validator({ emitError: true }); + if (!this.sf.valid) return; - let params = { - ...this.sf.value + let params: any= { + ...this.sf.value, } delete params.telephone this.service.request(this.service.$api_save, { ...params, employeeVO: this.currentOAItem }).subscribe(res => { diff --git a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html index 0482f6e6..f0be7aff 100644 --- a/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html +++ b/src/app/routes/partner/rebate-management/components/rebate-setting/add/add.component.html @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-02-24 20:09:49 * @LastEditors : Shiming - * @LastEditTime : 2022-04-26 10:53:50 + * @LastEditTime : 2022-04-26 14:04:41 * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.html * Copyright (C) 2022 huzhenhong. All rights reserved. --> @@ -61,7 +61,7 @@ -