diff --git a/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.html b/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.html
index 4df4ab9b..bd95c61e 100644
--- a/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.html
+++ b/src/app/routes/partner/partner-list/components/add-etp-partner/add-etp-partner.component.html
@@ -1,4 +1,10 @@
-
+
+
+
+
+
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 8ad008d2..14efa97f 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
@@ -11,7 +11,7 @@ import {
} from '@delon/form';
import { NzTreeNode } from 'ng-zorro-antd/tree';
import { NzUploadFile } from 'ng-zorro-antd/upload';
-import { of } from 'rxjs';
+import { of, Subscription } from 'rxjs';
import { map } from 'rxjs/operators';
import { PartnerListService } from '../../services/partner-list.service';
@@ -64,6 +64,9 @@ export class AddEtpPartnerComponent {
}
};
+ getIdentityInfoSub = new Subscription();
+ loadingIdentityInfoSub = false;
+
constructor(public service: PartnerListService) {}
submitForm() {
@@ -426,7 +429,28 @@ export class AddEtpPartnerComponent {
ui: {
grid: { xxl: 13, xl: 18, lg: 24, md: 24 },
placeholder: '请输入企业管理员手机号',
- errors: { required: '请输入企业管理员手机号', format: '手机号格式错误' }
+ errors: { required: '请输入企业管理员手机号', format: '手机号格式错误' },
+ change: (mobile: any) => {
+ // 根据手机号获取实名信息
+ if (mobile?.length === 11) {
+ if (this.loadingIdentityInfoSub) {
+ this.getIdentityInfoSub.unsubscribe();
+ }
+ this.loadingIdentityInfoSub = true;
+ this.getIdentityInfoSub = this.service.request(this.service.$api_get_identityInfo_by_mobile, { mobile }).subscribe(
+ res => {
+ if (res) {
+ this.setInfo(res);
+ this.sf.setValue('/adminUserInfo/id', res.id);
+ this.sf.setValue('/adminUserInfo/userId', res.userId);
+ }
+ this.loadingIdentityInfoSub = false;
+ },
+ _ => {},
+ () => (this.loadingIdentityInfoSub = false)
+ );
+ }
+ }
}
},
// 企业管理员信息
@@ -441,6 +465,8 @@ export class AddEtpPartnerComponent {
},
default: true
},
+ id: { title: '', type: 'string', ui: { hidden: true } },
+ userId: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoFront: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoBack: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoFrontWatermark: {
@@ -589,4 +615,52 @@ 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,
+ name: '文件',
+ status: 'done',
+ url: info.certificatePhotoFrontWatermark,
+ response: info.certificatePhotoFrontWatermark
+ }
+ ]);
+ }
+ if (info.certificatePhotoBack) {
+ this.sf.setValue('/adminUserInfo/certificatePhotoBack', info.certificatePhotoBack);
+ }
+ if (info.certificatePhotoBackWatermark) {
+ this.sf.setValue('/adminUserInfo/certificatePhotoBackWatermark', [
+ {
+ uid: -1,
+ name: '文件',
+ status: 'done',
+ 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);
+ }
+ }
}
diff --git a/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.html b/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.html
index cb94b51b..7a071adc 100644
--- a/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.html
+++ b/src/app/routes/partner/partner-list/components/add-personal-partner/add-personal-partner.component.html
@@ -1,4 +1,10 @@
-
+
+
+
+
+
@@ -36,7 +42,8 @@
-
+
-
+
\ No newline at end of file
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 eca02366..d21416e3 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
@@ -12,7 +12,7 @@ import {
} from '@delon/form';
import { NzTreeNode } from 'ng-zorro-antd/tree';
import { NzUploadFile } from 'ng-zorro-antd/upload';
-import { of } from 'rxjs';
+import { of, Subscription } from 'rxjs';
import { map } from 'rxjs/operators';
import { PartnerListService } from '../../services/partner-list.service';
@@ -65,6 +65,9 @@ export class AddPersonalPartnerComponent {
}
};
+ getIdentityInfoSub = new Subscription();
+ loadingIdentityInfoSub = false;
+
constructor(private router: Router, public service: PartnerListService) {}
submitForm() {
@@ -156,7 +159,28 @@ export class AddPersonalPartnerComponent {
ui: {
grid: { xxl: 13, xl: 18, lg: 24, md: 24 },
placeholder: '请输入手机号',
- errors: { required: '请输入手机号', format: '手机号格式错误' }
+ errors: { required: '请输入手机号', format: '手机号格式错误' },
+ change: (mobile: any) => {
+ // 根据手机号获取实名信息
+ if (mobile?.length === 11) {
+ if (this.loadingIdentityInfoSub) {
+ this.getIdentityInfoSub.unsubscribe();
+ }
+ this.loadingIdentityInfoSub = true;
+ this.getIdentityInfoSub = this.service.request(this.service.$api_get_identityInfo_by_mobile, { mobile }).subscribe(
+ res => {
+ if (res) {
+ this.setInfo(res);
+ this.sf.setValue('/adminUserInfo/id', res.id);
+ this.sf.setValue('/adminUserInfo/userId', res.userId);
+ }
+ this.loadingIdentityInfoSub = false;
+ },
+ _ => {},
+ () => (this.loadingIdentityInfoSub = false)
+ );
+ }
+ }
}
},
// 合伙人信息
@@ -172,6 +196,8 @@ export class AddPersonalPartnerComponent {
default: true
},
certificatePhotoFront: { title: '', type: 'string', ui: { hidden: true } },
+ id: { title: '', type: 'string', ui: { hidden: true } },
+ userId: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoBack: { title: '', type: 'string', ui: { hidden: true } },
certificateType: { title: '', type: 'string', ui: { hidden: true }, default: 0 },
certificatePhotoFrontWatermark: {
@@ -311,4 +337,52 @@ export class AddPersonalPartnerComponent {
required: ['cityCodesList', 'invitationCode']
};
}
+
+ 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,
+ name: '文件',
+ status: 'done',
+ url: info.certificatePhotoFrontWatermark,
+ response: info.certificatePhotoFrontWatermark
+ }
+ ]);
+ }
+ if (info.certificatePhotoBack) {
+ this.sf.setValue('/adminUserInfo/certificatePhotoBack', info.certificatePhotoBack);
+ }
+ if (info.certificatePhotoBackWatermark) {
+ this.sf.setValue('/adminUserInfo/certificatePhotoBackWatermark', [
+ {
+ uid: -1,
+ name: '文件',
+ status: 'done',
+ 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);
+ }
+ }
}
diff --git a/src/app/routes/partner/partner-list/components/index/partner-list.component.ts b/src/app/routes/partner/partner-list/components/index/partner-list.component.ts
index 68703251..2e47723a 100644
--- a/src/app/routes/partner/partner-list/components/index/partner-list.component.ts
+++ b/src/app/routes/partner/partner-list/components/index/partner-list.component.ts
@@ -367,12 +367,12 @@ export class PartnerListComponent {
},
{ title: '付款编码', index: 'payCode', width: 160 },
{ title: '邀请码', index: 'invitationCode', className: 'text-center', width: 130 },
- { title: '企业管理员', index: 'contactName', width: 150 },
+ { 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: '注册渠道', index: 'source', type: 'enum', enum: { 1: '合伙人注册', 2: '平台添加' }, width: 130 },
{ title: '注册时间', index: 'createTime', className: 'text-center', width: 170 },
- { title: '渠道销售', index: 'channelId', width: 170 },
+ { title: '渠道销售', index: 'channelIdLabel', width: 170 },
{ title: '返佣模板', index: 'templateName', width: 150 },
{
title: '认证审核状态',
@@ -380,7 +380,7 @@ export class PartnerListComponent {
width: 150,
type: 'badge',
badge: {
- 0: { text: '草稿', color: 'default' },
+ '-1': { text: '未提交', color: 'default' },
10: { text: '待审核', color: 'processing' },
20: { text: '审核通过', color: 'success' },
30: { text: '驳回', color: 'error' }
@@ -428,7 +428,12 @@ export class PartnerListComponent {
buttons: [
{ type: 'divider' },
{
- text: '详情',
+ text: '审核',
+ iif: item => item.id && item.approvalStatus === 10,
+ click: item => this.auditPartner(item)
+ },
+ {
+ text: '详情
',
iif: item => item.id,
click: item => {
if (item.partnerType === 1) {
@@ -438,11 +443,6 @@ export class PartnerListComponent {
}
}
},
- {
- text: '审核
',
- iif: item => item.id,
- click: item => this.auditPartner(item)
- },
{
text: '修改返佣模板',
iif: item => item.id,
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 98adf913..c4abbd48 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
@@ -40,7 +40,7 @@
-
+
@@ -87,8 +87,9 @@
[nzBorderless]="!isEdit" [placeholder]="isEdit ? '' : '-'" />
-
+
+ {{detailData.adminUserInfo.mobile}}
保存
-
+
diff --git a/src/app/routes/partner/partner-list/services/partner-list.service.ts b/src/app/routes/partner/partner-list/services/partner-list.service.ts
index 1abc97f9..5a00d758 100644
--- a/src/app/routes/partner/partner-list/services/partner-list.service.ts
+++ b/src/app/routes/partner/partner-list/services/partner-list.service.ts
@@ -33,6 +33,8 @@ export class PartnerListService extends ShipperBaseService {
$api_get_enterprice_rel_list = '/api/mdc/EnterpriseRelLog/list';
// 校验合伙人是否可修改渠道销售 true:可以修改 false:不可以修改
$api_check_partenr_change_channel = '/api/mdc/partner/updateChannelCheck';
+ // 根据手机号查询实名信息
+ $api_get_identityInfo_by_mobile= '/api/mdc/cuc/identityInfo/getByMobile';
// 渠道销售修改详情
$api_get_partner_change_list = '/api/mdc/partnerChannelRelLog/partnerChannelUpdateDetaiList';
// 冻结/启用企业业