fix bug
This commit is contained in:
		@ -1,8 +1,9 @@
 | 
			
		||||
import { Component, OnInit, ViewChild } from '@angular/core';
 | 
			
		||||
import { STColumn, STComponent } from '@delon/abc/st';
 | 
			
		||||
import { SFComponent, SFDateWidgetSchema, SFSchema, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
 | 
			
		||||
import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
 | 
			
		||||
import { ModalHelper, _HttpClient } from '@delon/theme';
 | 
			
		||||
import { NzModalService } from 'ng-zorro-antd/modal';
 | 
			
		||||
import { of } from 'rxjs';
 | 
			
		||||
import { map } from 'rxjs/operators';
 | 
			
		||||
import { SupplyManagementService } from '../../services/order-management.service';
 | 
			
		||||
 | 
			
		||||
@ -133,14 +134,29 @@ export class OrderManagementVehicleComponent implements OnInit {
 | 
			
		||||
            },
 | 
			
		||||
          }
 | 
			
		||||
        },
 | 
			
		||||
        no7: {
 | 
			
		||||
          type: 'string',
 | 
			
		||||
        brandId: {
 | 
			
		||||
          title: '承运司机',
 | 
			
		||||
          type: 'string',
 | 
			
		||||
          ui: {
 | 
			
		||||
            visibleIf: {
 | 
			
		||||
              _$expand: (value: boolean) => value,
 | 
			
		||||
            widget: 'select',
 | 
			
		||||
            serverSearch: true,
 | 
			
		||||
            searchDebounceTime: 300,
 | 
			
		||||
            searchLoadingText: '搜索中...',
 | 
			
		||||
            onSearch: (q: any) => {
 | 
			
		||||
              if (!!q) {
 | 
			
		||||
                return this.service
 | 
			
		||||
                  .request(this.service.$api_get_getDriverInfo, { keyword: q,
 | 
			
		||||
                  model: 1, type: 1 })
 | 
			
		||||
                  .pipe(map((res) => (res as any[]).map((i) => ({ label: i.name, value: i.id } as SFSchemaEnum))))
 | 
			
		||||
                  .toPromise();
 | 
			
		||||
              } else {
 | 
			
		||||
                return of([]);
 | 
			
		||||
              }
 | 
			
		||||
            },
 | 
			
		||||
          }
 | 
			
		||||
            visibleIf: {
 | 
			
		||||
              expand: (value: boolean) => value,
 | 
			
		||||
            },
 | 
			
		||||
          } as SFSelectWidgetSchema,
 | 
			
		||||
        },
 | 
			
		||||
        no9: {
 | 
			
		||||
          type: 'string',
 | 
			
		||||
@ -151,15 +167,30 @@ export class OrderManagementVehicleComponent implements OnInit {
 | 
			
		||||
            },
 | 
			
		||||
          }
 | 
			
		||||
        },
 | 
			
		||||
        no10: {
 | 
			
		||||
          type: 'string',
 | 
			
		||||
        brandId2: {
 | 
			
		||||
          title: '车队长',
 | 
			
		||||
          type: 'string',
 | 
			
		||||
          ui: {
 | 
			
		||||
            visibleIf: {
 | 
			
		||||
              _$expand: (value: boolean) => value,
 | 
			
		||||
            widget: 'select',
 | 
			
		||||
            serverSearch: true,
 | 
			
		||||
            searchDebounceTime: 300,
 | 
			
		||||
            searchLoadingText: '搜索中...',
 | 
			
		||||
            onSearch: (q: any) => {
 | 
			
		||||
              if (!!q) {
 | 
			
		||||
                return this.service
 | 
			
		||||
                  .request(this.service.$api_get_getDriverInfo, { keyword: q,
 | 
			
		||||
                  model: 1, type: 2 })
 | 
			
		||||
                  .pipe(map((res) => (res as any[]).map((i) => ({ label: i.name, value: i.id } as SFSchemaEnum))))
 | 
			
		||||
                  .toPromise();
 | 
			
		||||
              } else {
 | 
			
		||||
                return of([]);
 | 
			
		||||
              }
 | 
			
		||||
            },
 | 
			
		||||
          }
 | 
			
		||||
        },
 | 
			
		||||
            visibleIf: {
 | 
			
		||||
              expand: (value: boolean) => value,
 | 
			
		||||
            },
 | 
			
		||||
          } as SFSelectWidgetSchema,
 | 
			
		||||
        }, 
 | 
			
		||||
        sex: {
 | 
			
		||||
          title: '支付状态',
 | 
			
		||||
          type: 'string',
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user