diff --git a/proxy.conf.js b/proxy.conf.js index 29173019..d12c4111 100644 --- a/proxy.conf.js +++ b/proxy.conf.js @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-01-18 09:51:21 * @LastEditors : Shiming - * @LastEditTime : 2022-04-27 17:26:44 + * @LastEditTime : 2022-04-28 13:43:18 * @FilePath : \\tms-obc-web\\proxy.conf.js * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -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/sys-setting/components/config/config.component.ts b/src/app/routes/sys-setting/components/config/config.component.ts index 5ddaa8ee..90340eca 100644 --- a/src/app/routes/sys-setting/components/config/config.component.ts +++ b/src/app/routes/sys-setting/components/config/config.component.ts @@ -111,11 +111,29 @@ export class PartnerSystemConfigComponent implements OnInit, OnChanges { // }; constructor(private service: SystemService) {} - ngOnChanges(changes: SimpleChanges): void { + ngOnChanges(changes: any): void { if (changes.configList) { - console.log(changes.configList); - console.log(changes.configList.currentValue); - + console.log(changes.configList.currentValue[0]?.remark); + this.personServe = changes.configList.currentValue[0]?.remark.personServe, // 个人提现手续费 + this.enterpriseServe= changes.configList.currentValue[0]?.remark.enterpriseServe, // 企业提现手续费 + this.auditValue= changes.configList.currentValue[0]?.remark.auditValue, // 提现审核 + this.auditTime= changes.configList.currentValue[0]?.remark.auditTime, // 审核时间 + this.silenceClient= changes.configList.currentValue[0]?.remark.silenceClient, // 沉默客户 + this.loseClient= changes.configList.currentValue[0]?.remark.loseClient // 流失客户 + this.everyDayData= changes.configList.currentValue[0]?.remark.everyDayData // 流失客户 + this.MonthDayData= changes.configList.currentValue[0]?.remark.MonthDayData // 流失客户 + if (this.auditTime == '2') { + this.auditTimeStatus = true; + // 每天 + if(this.everyDayData){ + this.everyDayData = this.everyDayData + } else if(this.MonthDay) { + // 每周 + this.MonthDayData = this.MonthDayData + } + } else { + this.auditTimeStatus = false; + } } } @@ -173,14 +191,12 @@ export class PartnerSystemConfigComponent implements OnInit, OnChanges { console.log(this.MonthDayData); } everyDayChange(type: any): void { - console.log(type); if (type) { this.MonthDay = false; this.TimeStatus = true; } } MonthDayChange(type: any): void { - console.log(type); if (type) { this.everyDay = false; this.TimeStatus = false; @@ -323,7 +339,6 @@ export class PartnerSystemConfigComponent implements OnInit, OnChanges { }); }; changeAuto(value: any) { - console.log(value); if (value == '2') { this.auditTimeStatus = true; } else { @@ -331,7 +346,6 @@ export class PartnerSystemConfigComponent implements OnInit, OnChanges { } } save() { - console.log(); let params : any = { personServe: this.personServe, // 个人提现手续费 enterpriseServe: this.enterpriseServe, // 企业提现手续费 @@ -343,21 +357,15 @@ export class PartnerSystemConfigComponent implements OnInit, OnChanges { if(this.auditTime == '2') { // 每天 if(this.everyDay){ - console.log(this.everyDayData); params.everyDayData = this.everyDayData } else if(this.MonthDay) { // 每周 params.MonthDayData = this.MonthDayData - console.log(this.MonthDayData); } } - console.log( JSON.stringify(params)); - console.log( this.configList); const pra = Object.assign({}, ...this.configList) pra.remark = JSON.stringify(params) - console.log(pra); - - this.service.request(this.service.$api_update_config_batch, pra).subscribe(res => { + this.service.request(this.service.$api_update_config_batch, [pra]).subscribe(res => { if (res) { this.service.msgSrv.success('修改配置成功'); setTimeout(() => {