From 28a20973d3da53acf594f5beb4d5ebfb35f86d86 Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Thu, 10 Mar 2022 20:36:10 +0800 Subject: [PATCH] edit --- .../partner-audit-modal.component.ts | 42 +++++++--- .../partner-detail.component.html | 80 ++++++++---------- .../partner-detail.component.ts | 82 ++++++++++++------- .../freight/list/detail/detail.component.html | 1 - 4 files changed, 113 insertions(+), 92 deletions(-) diff --git a/src/app/routes/partner/partner-list/components/partner-audit-modal/partner-audit-modal.component.ts b/src/app/routes/partner/partner-list/components/partner-audit-modal/partner-audit-modal.component.ts index eed7b8ac..ab86de05 100644 --- a/src/app/routes/partner/partner-list/components/partner-audit-modal/partner-audit-modal.component.ts +++ b/src/app/routes/partner/partner-list/components/partner-audit-modal/partner-audit-modal.component.ts @@ -1,5 +1,5 @@ import { Component, Input, OnInit, ViewChild } from '@angular/core'; -import { SFComponent, SFSchema } from '@delon/form'; +import { SFComponent, SFSchema, SFValue } from '@delon/form'; import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal'; import { PartnerListService } from '../../services/partner-list.service'; @@ -23,6 +23,13 @@ export class PartnerAuditModalComponent implements OnInit { initSF(user: any) { this.schema = { properties: { + isPass: { + type: 'boolean', + ui: { + hidden: true + }, + default: this.info.isPass + }, staffName: { title: '合伙人名称', type: 'string', @@ -37,7 +44,10 @@ export class PartnerAuditModalComponent implements OnInit { { value: true, label: '通过' }, { value: false, label: '驳回' } ], - ui: { widget: 'radio' }, + ui: { + widget: 'radio', + hidden: this.info.isPass !== undefined + }, default: true }, a: { @@ -49,7 +59,14 @@ export class PartnerAuditModalComponent implements OnInit { ], ui: { widget: 'select', - placeholder: '请选择' + placeholder: '请选择', + hidden: this.info.isPass === false, + visibleIf: { + status: value => value + }, + errors: { + required: ' ' + } }, default: '' }, @@ -60,19 +77,18 @@ export class PartnerAuditModalComponent implements OnInit { ui: { widget: 'textarea', placeholder: '请不要超过100个字', - autosize: { minRows: 3 } + autosize: { minRows: 3 }, + hidden: this.info.isPass === true, + visibleIf: { + status: value => !value || this.info.isPass === false + }, + errors: { + required: ' ' + } } } }, - if: { - properties: { status: { enum: [true] } } - }, - then: { - required: ['a'] - }, - else: { - required: ['b'] - } + required: ['a', 'b'] }; } diff --git a/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.html b/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.html index 6dcdbb97..f242099c 100644 --- a/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.html +++ b/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.html @@ -49,13 +49,11 @@ - - - @@ -73,8 +71,7 @@ 冻结 - @@ -113,7 +110,8 @@ [nzBorderless]="!isEdit" [placeholder]="isEdit?'':'-'"> - {{detailData.adminUserInfo?.mobile}} + - 法人信息 + 企业法人信息 @@ -232,7 +230,6 @@ (ngModelChange)="$event?detailData.legalPersonIdentityVO.validEndTime='':''" class="ml-sm">长期 -
@@ -244,15 +241,19 @@
-
- - - 所属城市 - - 深圳、上海、北京 + + + + + + + {{ detailData?.fullRegionVO?.provinceName }}{{ detailData?.fullRegionVO?.cityName }}{{ + detailData?.fullRegionVO?.areaName }} + + 渠道销售信息 @@ -271,8 +272,8 @@ 修改渠道销售记录 - + @@ -289,35 +290,6 @@ - -
-
- - {{ detailData?.enterpriseName }} - - - - - - -
-
-
- - -
-
- - {{ detailData?.enterpriseName }} - - - - -
-
-
- + + + +

转移客户数:10

+ + +

不转移客户数:10

+ + +

+ 客户转移:客户跟着上级合伙人转移一并到新渠道销售下,会同步发起CRM《客户转移》流程;不转移的,客户会与上级合伙人解绑,修改成功后,修改时间也是合伙人与客户的结算结束时间,成为原来渠道销售的直客。 +

\ No newline at end of file diff --git a/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.ts b/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.ts index f0e81cf1..fdfd31a3 100644 --- a/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.ts +++ b/src/app/routes/partner/partner-list/components/partner-detail/partner-detail.component.ts @@ -15,16 +15,13 @@ import { PartnerAuditModalComponent } from '../partner-audit-modal/partner-audit providers: [DatePipe] }) export class PartnerDetailComponent implements OnInit { - columns: STColumn[] = this.initST(); + @ViewChild('logModal') + logModal: any; - @ViewChild('approvedModal', { static: false }) - approvedModal!: any; - @ViewChild('redectModal', { static: false }) - redectModal!: any; + columns: { logsColumn: STColumn[]; changeColumn: STColumn[]; beChangeColumn: STColumn[] } = this.initST(); detailData: any = { adminUserInfo: { name: '' }, legalPersonIdentityVO: { name: '' } }; tempalateData = { ...this.detailData }; - suppliersData: any = {}; isEdit = false; @@ -33,9 +30,6 @@ export class PartnerDetailComponent implements OnInit { enterpriseAddressCode: any = []; ltdId: any = []; - approvalOpinion = ''; - networkTransporter = null; - esignCheckStatus: any = { 0: '不通过', 1: '通过', @@ -113,11 +107,21 @@ export class PartnerDetailComponent implements OnInit { // }); } - auditPartner() { + auditPartner(isPass: boolean) { const modal = this.nzModalService.create({ nzTitle: '审核', nzContent: PartnerAuditModalComponent, - nzComponentParams: { info: this.detailData }, + nzComponentParams: { info: { ...this.detailData, isPass } }, + nzFooter: null + }); + } + + showChangeDetail() { + const modal = this.nzModalService.create({ + nzTitle: '详情', + nzContent: this.logModal, + nzNoAnimation: true, + nzWidth: 700, nzFooter: null }); } @@ -313,25 +317,41 @@ export class PartnerDetailComponent implements OnInit { // }); } - private initST(): STColumn[] { - return [ - { title: '修改后渠道销售', index: 'payCode', width: 180 }, - { title: '修改前渠道销售', index: 'ltdName', width: 160 }, - { title: '转移客户数', index: 'payDate', className: 'text-center', width: 130 }, - { title: '生效节点', index: 'payDate', width: 150 }, - { title: '备注', index: 'payDate', className: 'text-center', width: 150 }, - { title: '修改时间', index: 'payDate', className: 'text-center', width: 130 }, - { title: '操作人', index: 'payDate', type: 'date', width: 130 }, - { - title: '操作', - fixed: 'right', - width: '140px', - buttons: [ - { - text: '详情' - } - ] - } - ]; + private initST(): { logsColumn: STColumn[]; changeColumn: STColumn[]; beChangeColumn: STColumn[] } { + return { + logsColumn: [ + { title: '修改后渠道销售', index: 'payCode', width: 180 }, + { title: '修改前渠道销售', index: 'ltdName', width: 160 }, + { title: '转移客户数', index: 'payDate', className: 'text-center', width: 130 }, + { title: '生效节点', index: 'payDate', width: 150 }, + { title: '备注', index: 'payDate', className: 'text-center', width: 150 }, + { title: '修改时间', index: 'payDate', className: 'text-center', width: 130 }, + { title: '操作人', index: 'payDate', type: 'date', width: 130 }, + { + title: '操作', + fixed: 'right', + width: '140px', + buttons: [ + { + text: '详情', + click: () => this.showChangeDetail() + } + ] + } + ], + changeColumn: [ + { title: '客户名称', index: 'payCode', width: 180 }, + { title: '合伙人', index: 'ltdName', width: 160 }, + { title: '渠道销售', index: 'payDate', className: 'text-center', width: 130 }, + { title: 'CRM审核状态', index: 'payDate', width: 150 }, + { title: '生效时间', index: 'payDate', className: 'text-center', width: 130 } + ], + beChangeColumn: [ + { title: '客户名称', index: 'payCode', width: 180 }, + { title: '合伙人', index: 'ltdName', width: 160 }, + { title: '渠道销售', index: 'payDate', className: 'text-center', width: 130 }, + { title: '生效时间', index: 'payDate', className: 'text-center', width: 130 } + ] + }; } } diff --git a/src/app/routes/usercenter/components/freight/list/detail/detail.component.html b/src/app/routes/usercenter/components/freight/list/detail/detail.component.html index 7a3798cf..33cb59e6 100644 --- a/src/app/routes/usercenter/components/freight/list/detail/detail.component.html +++ b/src/app/routes/usercenter/components/freight/list/detail/detail.component.html @@ -278,7 +278,6 @@ -