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 3bbf706d..df897825 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 @@ -6,10 +6,10 @@ import { SFComponent, SFSchema, SFDateWidgetSchema, SFAutoCompleteWidgetSchema, import { NzModalService } from 'ng-zorro-antd/modal'; import { of } from 'rxjs'; import { AddCollectionInvoiceModalComponent } from 'src/app/routes/ticket-management/components/input-invoice/add-collection-invoice-modal/add-collection-invoice-modal.component'; +import { map, filter } from 'rxjs/operators'; import { PartnerListService } from '../../services/partner-list.service'; import { PartnerAuditModalComponent } from '../partner-audit-modal/partner-audit-modal.component'; -import { map } from 'rxjs/operators'; @Component({ selector: 'app-partner-list', @@ -24,7 +24,7 @@ export class PartnerListComponent { columns: STColumn[] = this.initST(); searchSchema: SFSchema = this.initSF(); _$expand = false; - isLoading: boolean = false + isLoading: boolean = false; @ViewChild('editTemplate', { static: true }) editTemplate: any; templateId: any; @@ -55,10 +55,10 @@ export class PartnerListComponent { }; loadSelectOptions() { - this.service.getRebateConfig({stateLocked: 1}).subscribe(res => { + this.service.getRebateConfig({ stateLocked: 1 }).subscribe(res => { if (res) { console.log(res); - + this.customers = res; } }); @@ -319,7 +319,7 @@ export class PartnerListComponent { { value: '', label: '全部' }, { value: '0', label: '未同步' }, { value: 10, label: '同步失败' }, - { value: 20, label: '同步成功' }, + { value: 20, label: '同步成功' } ], ui: { widget: 'select', @@ -353,21 +353,21 @@ export class PartnerListComponent { widget: 'select', placeholder: '请选择', asyncData: () => - this.service.request(this.service.$api_get_rebate_config, {}, 'POST').pipe( - map(data => { - if(data) { - return data.map((m: any) => { - return { label: m.configName, value: m.id }; - }); - } else { - return []; - - } - }) - ), + this.service.request(this.service.$api_get_rebate_config, {}, 'POST').pipe( + map(data => { + if (data) { + return data.map((m: any) => { + return { label: m.configName, value: m.id }; + }); + } else { + return []; + } + }) + ), visibleIf: { expand: (value: boolean) => value - } } as SFDateWidgetSchema + } + } as SFDateWidgetSchema }, lockedStatus: { type: 'string', @@ -406,7 +406,7 @@ export class PartnerListComponent { { title: '合伙人名称', render: 'enterpriseName', - width: 180, + width: 180 }, { title: '付款编码', index: 'payCode', width: 160 }, { title: '邀请码', index: 'invitationCode', className: 'text-center', width: 130 }, @@ -512,7 +512,27 @@ export class PartnerListComponent { onSearch(value: string): void { this.isLoading = true; console.log(value); - - // this.searchChange$.next(value); + let str = value.replace(/^\s+|\s+$/g, ''); + let params: any = {}; + if (str) { + console.log(+str); + if (+str) { + console.log('数字'); + params.phoneNumber = str; + } else { + console.log('中文'); + params.name = str; + } + this.service.request(this.service.$api_get_channel, params).subscribe(res => { + console.log(res); + let NewList: { label: string; value: any; }[] = []; + let List = res.filter((i: any) => { + NewList.push({ label: `${i.name}/${i.telephone}`, value: i.channelId }) ; + }); + console.log(NewList); + }); + // .pipe(map((res: any) => (res as any[]).map(i => ({ label: `${i.name}/${i.telephone}`, value: i.channelId }))) + // this.searchChange$.next(value); + } } } diff --git a/src/app/routes/ticket-management/components/etc-invoiced-logs/etc-invoiced-logs.component.html b/src/app/routes/ticket-management/components/etc-invoiced-logs/etc-invoiced-logs.component.html index 82898869..28581ae2 100644 --- a/src/app/routes/ticket-management/components/etc-invoiced-logs/etc-invoiced-logs.component.html +++ b/src/app/routes/ticket-management/components/etc-invoiced-logs/etc-invoiced-logs.component.html @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2022-05-06 15:31:19 * @LastEditors : Shiming - * @LastEditTime : 2022-05-10 09:47:38 + * @LastEditTime : 2022-05-10 11:13:28 * @FilePath : \\tms-obc-web\\src\\app\\routes\\ticket-management\\components\\etc-invoiced-logs\\etc-invoiced-logs.component.html * Copyright (C) 2022 huzhenhong. All rights reserved. --> @@ -36,7 +36,7 @@
- +
{ this.batchInvoice(item) } @@ -226,7 +226,7 @@ export class ETCInvoicedLogsComponent extends BasicTableComponent { this.service.request(this.service.$api_createFicoInpinv, params).subscribe(res => { if (res) { - this.service.msgSrv.success('开票成功!') + this.service.msgSrv.success('收票成功!') this.st.load(1); } }); diff --git a/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.ts b/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.ts index 6deff18a..eb9923a0 100644 --- a/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.ts +++ b/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.ts @@ -1,7 +1,7 @@ /* * @Author: your name * @Date: 2021-12-23 16:50:17 - * @LastEditTime : 2022-04-28 13:54:14 + * @LastEditTime : 2022-05-10 10:58:56 * @LastEditors : Shiming * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @FilePath : \\tms-obc-web\\src\\app\\routes\\ticket-management\\components\\invoice-requested\\requested-invoice-modal\\requested-invoice-modal.component.ts