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..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 @@ -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,32 @@ 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; + let value = res.employeeVO; + List.push({ label: value.empName + '/' + value.empNo, value: value.empNo }); + 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 +81,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 +151,9 @@ export class ParterChannelSalesEditComponent implements OnInit { { label: '是', value: '1' } ], ui: { - widget: 'radio', + widget: 'radio' } as SFRadioWidgetSchema, - default: '0', + default: '0' }, roleIds: { title: '', @@ -128,7 +175,7 @@ export class ParterChannelSalesEditComponent implements OnInit { ); }, visibleIf: { isAuthorization: (value: string) => value === '1' } - }, + } }, remark: { type: 'string', @@ -137,9 +184,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 +195,26 @@ 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: any= { + ...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); } } 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 @@ - diff --git a/src/app/routes/partner/system-config/components/config/config.component.html b/src/app/routes/partner/system-config/components/config/config.component.html index 27c06f58..394af73c 100644 --- a/src/app/routes/partner/system-config/components/config/config.component.html +++ b/src/app/routes/partner/system-config/components/config/config.component.html @@ -1,167 +1,205 @@ -
-
-
    -
  • - {{ item.name }} -
  • -
-
- -
- -

提现手续费配置

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

合伙人提现配置

-
-
- - - - - - - - -
-
-

客服电话配置

-
-
- - - -
-
-
- - -

司机端配置

-

图片配置

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

短信配置

-
-
- -

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

- -
-
-
-

通知配置

-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
-
-

客服电话配置

-
-
- - - -
-
-

证件提醒配置

-
-
- - 距离到期时间 - - 天开始提醒,每隔 - - 天提醒一次 - -
-
-
- -
- - -
-
+
+
+
    +
  • + {{ item.name }} +
  • +
+ +
+ +

提现手续费配置

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

合伙人提现配置

+
+
+ + + + + + + +
+ + + + +
+
+
+ +
+
+
+

客服电话配置

+
+
+ + + +
+
+
+ + +

司机端配置

+

图片配置

+ + + + +
可输入字符
+ +
+
+

短信配置

+
+
+ +

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

+ +
+
+
+

通知配置

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+
+

客服电话配置

+
+
+ + + +
+
+

证件提醒配置

+
+
+ + 距离到期时间 + + 天开始提醒,每隔 + + 天提醒一次 + +
+
+
+ +
+ + +
+
+
- -
- - - - - - -
- - - - - - - - - + + +
+
+ + + +
+ -- +
+
+ -- +
+
+ +
+ + +
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 b7489b98..3ee76370 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 @@ -20,6 +20,9 @@ export class PartnerSystemConfigComponent implements OnInit { auditValue!: number; auditTime!: any; auditTimeStatus: boolean = false + everyDay: boolean = false + time: Date | null = null; + defaultOpenValue = new Date(0, 0, 0, 0, 0, 0); tabs = [ { name: '基础配置' @@ -172,11 +175,6 @@ 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; @@ -196,7 +194,14 @@ export class PartnerSystemConfigComponent implements OnInit { observer.complete(); }); }; - + changeAuto(value: any) { + console.log(value); + if(value == '2') { + this.auditTimeStatus = true + } else { + this.auditTimeStatus = false + } + } private getImageModel(args: any, key: any) { return [ { 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 5f8491e0..42599f9b 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 @@ -422,7 +422,7 @@ {{ item.remark diff --git a/src/app/routes/usercenter/components/freight/list/detail/detail.component.ts b/src/app/routes/usercenter/components/freight/list/detail/detail.component.ts index 5a2dbc89..bd066e42 100644 --- a/src/app/routes/usercenter/components/freight/list/detail/detail.component.ts +++ b/src/app/routes/usercenter/components/freight/list/detail/detail.component.ts @@ -144,9 +144,9 @@ export class FreightComponentsListDetailComponent implements OnInit, OnDestroy { }, className: 'text-center' }, - { title: '修改时间', render: 'mybidDetailInfo', className: 'text-center' }, - { title: '生效时间', index: 'eeffectiveTime', className: 'text-center' }, - { title: '操作人', index: 'approvalUser', className: 'text-center' } + { title: '修改时间', index: 'modifyTime', className: 'text-center' }, + { title: '生效时间', index: 'effectiveTime', className: 'text-center' }, + { title: '操作人', index: 'modifyUserId', className: 'text-center' } ]; } loadPartnerInfo(){