This commit is contained in:
Taric Xin
2022-05-05 17:14:41 +08:00
parent d9d6546226
commit 283e6e4a26
12 changed files with 205 additions and 440 deletions

View File

@ -16,8 +16,8 @@
<nz-badge nzStatus="warning" nzText="冻结" *ngIf="userDetail?.stateLocked" class="ml-xs"></nz-badge>
</p>
<div style="margin-right: 24px;">
<button *ngIf="userDetail?.stateLocked" [disabled]="false" nz-button nzType="primary"
nzGhost (click)="userAction(1)" acl [acl-ability]="['USERCENTER-DRIVER-LIST-DETAIL-lock']">
<button *ngIf="userDetail?.stateLocked" [disabled]="false" nz-button nzType="primary" nzGhost
(click)="userAction(1)" acl [acl-ability]="['USERCENTER-DRIVER-LIST-DETAIL-lock']">
启用
</button>
<button *ngIf="!userDetail?.stateLocked" [disabled]="false" nz-button nzDanger nzGhost
@ -193,8 +193,13 @@
[nzSuffixIcon]="isEditDriver?'calendar':''"></nz-date-picker>
</sv> -->
<sv label="驾驶证签发机关" col="2">
<input nz-input type="text" [(ngModel)]="driverDetail.signingOrganization" [readonly]="!isEditDriver"
[nzBorderless]="!isEditDriver" [placeholder]="isEditDriver?'':'-'">
<ng-container *ngIf="isEditDriver; else signingOrganizationTemplate">
<input nz-input type="text" [(ngModel)]="driverDetail.signingOrganization" [readonly]="!isEditDriver"
[nzBorderless]="!isEditDriver" [placeholder]="isEditDriver?'':'-'">
</ng-container>
<ng-template #signingOrganizationTemplate>
{{driverDetail.signingOrganization}}
</ng-template>
</sv>
<sv label="驾驶证照片" col="1">
<ng-container
@ -217,7 +222,7 @@
<input nz-input type="text" [(ngModel)]="licenseDetail.licenseNo" [readonly]="!isEditDriver"
[nzBorderless]="!isEditDriver" [placeholder]="isEditDriver?'':'-'">
</sv>
<sv label="公司所在地" >
<sv label="公司所在地">
<ng-container *ngIf="isEditDriver; else cascaderelseTemplate">
<nz-select [(ngModel)]="licenseDetail.regionCode">
<ng-container *ngFor="let item of adressCodeList">
@ -334,7 +339,8 @@
{{ userIdentityDetail?.name }}
</se>
<se [col]="1" label="备注" required>
<textarea nz-input rows="3" style="width: 325px;margin-left: 14px;" maxlength="120" [(ngModel)]="approvalOpinion" placeholder="请输入驳回原因"></textarea>
<textarea nz-input rows="3" style="width: 325px;margin-left: 14px;" maxlength="120"
[(ngModel)]="approvalOpinion" placeholder="请输入驳回原因"></textarea>
</se>
</div>
</div>
@ -350,7 +356,8 @@
{{ licenseDetail?.licenseNo }}
</se>
<se [col]="1" label="备注" required>
<textarea nz-input rows="3" style="width: 325px;margin-left: 14px;" maxlength="120" [(ngModel)]="approvalOpinion"></textarea>
<textarea nz-input rows="3" style="width: 325px;margin-left: 14px;" maxlength="120"
[(ngModel)]="approvalOpinion"></textarea>
</se>
</div>
</div>

View File

@ -1,14 +1,4 @@
<!--
* @Description :
* @Version : 1.0
* @Author : Shiming
* @Date : 2022-01-12 10:52:50
* @LastEditors : Shiming
* @LastEditTime : 2022-02-15 13:35:46
* @FilePath : \\tms-obc-web\\src\\app\\routes\\usercenter\\components\\freight\\enterprise-audit\\enterprise-audit.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved.
-->
<page-header-wrapper [title]="'企业审核列表'" [content]="content">
<!-- <page-header-wrapper [title]="'企业审核列表'" [content]="content">
<ng-template #content>
<nz-tabset class="tabs-wrap">
<nz-tab *ngFor="let tab of tabs" [nzTitle]="tab.name" (nzSelect)="changeTab(tab)"> </nz-tab>
@ -16,7 +6,6 @@
</ng-template>
</page-header-wrapper>
<nz-card class="mb-md">
<!-- 搜索表单 -->
<div nz-row nzGutter="8">
<div nz-col [nzXl]="_$expand ? 24 : 16" [nzLg]="24" [nzSm]="24" [nzXs]="24">
<sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf>
@ -25,8 +14,8 @@
[class.expend-options]="_$expand">
<button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)" acl
[acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-list']">查询</button>
<button *ngIf="tabType == 1" nz-button nzType="primary" [disabled]="false" (click)="exportList()"
acl [acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-export']">导出</button>
<button *ngIf="tabType == 1" nz-button nzType="primary" [disabled]="false" (click)="exportList()" acl
[acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-export']">导出</button>
<button nz-button (click)="resetSF()" [disabled]="false">重置</button>
<button nz-button nzType="link" (click)="expandToggle(!_$expand)">
{{ !_$expand ? '展开' : '收起' }}
@ -34,12 +23,27 @@
</button>
</div>
</div>
</nz-card>
</nz-card> -->
<nz-card>
<nz-card class="table-box">
<div class="tab_header">
<label class="page_title"><label class="driver">|</label>货主员工列表</label>
<nz-tabset [nzTabBarExtraContent]="extraTemplate">
<nz-tab *ngFor="let tab of tabs" [nzTitle]="tab.name" (nzSelect)="changeTab(tab)"> </nz-tab>
</nz-tabset>
</div>
<ng-template #extraTemplate>
<div class="mr-sm">
<button nz-button nzDanger [nzLoading]="service.http.loading" acl
[acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-list']" (click)="openDrawer()">筛选</button>
<button *ngIf="tabType == 1" nz-button nzDanger (click)="exportList()" acl
[acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-export']"> 导出</button>
</div>
</ng-template>
<!-- 数据列表 -->
<st #st multiSort [data]="service.$api_get_freight_list" [columns]="tabType===1?enterColumns:adminColumns"
[req]="{ process: beforeReq }" [page]=" {}" [loading]="false" [scroll]="{ x: '1200px' }">
[req]="{ process: beforeReq }" [page]=" {}" [loading]="false" [scroll]="{ x: '1200px',y:scrollY }">
<ng-template st-row="approvalStatus" let-item let-index="index">
<ng-container [ngSwitch]="item.approvalStatus">
<nz-badge *ngSwitchCase="10" nzColor="#108ee9" nzText="待审核"></nz-badge>

View File

@ -1,32 +0,0 @@
:host {
::ng-deep {
.tabs-wrap>.ant-tabs-nav {
margin-bottom: 0;
}
.myForm .ant-upload.ant-upload-select-picture-card>.ant-upload {
flex-direction: column !important;
}
span {
word-break: break-all
}
}
}
.expend-options {
margin-top: 0px;
}
@media (min-width: 990px) {
.expend-options {
margin-top: -40px;
max-width : 400px;
position : absolute;
right : 0;
bottom : 30px;
}
}

View File

@ -2,23 +2,22 @@ import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { STChange, STColumn, STComponent, STData, STRequestOptions } from '@delon/abc/st';
import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form';
import { SearchDrawerService } from '@shared';
import { NzModalService } from 'ng-zorro-antd/modal';
import { BasicTableComponent } from 'src/app/routes/commom';
import { UsermanageService } from '../../../services/usercenter.service';
import { AuditAdminComponent } from './audit-admin/audit-admin.component';
@Component({
selector: 'app-Freight-components-enterprise-audit',
templateUrl: './enterprise-audit.component.html',
styleUrls: ['./enterprise-audit.component.less']
styleUrls: ['../../../../commom/less/commom-table.less']
})
export class FreightComponentsEnterpriseAuditComponent implements OnInit {
_$expand = false;
ui: SFUISchema = { '*': { spanLabelFixed: 90, grid: { lg: 8, md: 12, sm: 12, xs: 24 } } };
schema: SFSchema = this.initSF();
export class FreightComponentsEnterpriseAuditComponent extends BasicTableComponent implements OnInit {
enterColumns: STColumn[] = this.initEnterST();
adminColumns: STColumn[] = this.initAdminST();
schema = this.initSF();
@ViewChild('st', { static: false }) st!: STComponent;
@ViewChild('sf', { static: false }) sf!: SFComponent;
tabType = 1;
tabs = [
{
@ -45,7 +44,18 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
networkTransporter = null;
roleId = null;
customerServiceId = null;
constructor(public service: UsermanageService, private router: Router, private modal: NzModalService) {}
constructor(
public service: UsermanageService,
private router: Router,
private modal: NzModalService,
public searchDrawerService: SearchDrawerService
) {
super(searchDrawerService);
}
search() {
this.st?.load(1);
}
beforeReq = (requestOptions: STRequestOptions) => {
if (this.sf) {
@ -65,21 +75,6 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
return requestOptions;
};
/**
* 伸缩查询条件
*/
expandToggle(status: boolean) {
this._$expand = status;
this.sf?.setValue('/expand', this._$expand);
}
/**
* 重置表单
*/
resetSF() {
this.sf.reset();
this._$expand = false;
}
/**
* 程序初始化入口
*/
@ -221,7 +216,6 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
// 切换Tab
changeTab(item: any) {
this.tabType = item.type;
this.expandToggle(false);
this.sf?.reset();
this.st.data = this.tabType === 1 ? this.service.$api_get_freight_list : this.service.$api_get_enterprise_admin_list;
setTimeout(() => {
@ -240,7 +234,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
}
exportList() {
const params = { ...this.sf?.value, flag: this.tabType, listSource: 2, pageSize: -1 };
const params = { ...this.sf?.value, flag: this.tabType, listSource: 2, pageSize: -1 };
this.service.downloadFile(this.service.$api_export_enterprise, params);
}
@ -403,10 +397,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
],
default: '',
ui: {
widget: 'select',
visibleIf: {
expand: (value: boolean) => this.tabType === 1
}
widget: 'select'
}
},
enterpriseAddressCode: {
@ -415,10 +406,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
enum: [{ label: '全部', value: '' }],
default: '',
ui: {
widget: 'select',
visibleIf: {
expand: (value: boolean) => this.tabType === 1 && value
}
widget: 'select'
}
},
oftenUsedServices: {
@ -431,10 +419,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
],
default: '',
ui: {
widget: 'select',
visibleIf: {
expand: (value: boolean) => this.tabType === 1 && value
}
widget: 'select'
}
},
// approval11St11atus: {
@ -454,10 +439,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
type: 'string',
ui: {
placeholder: '请输入',
showRequired: false,
visibleIf: {
expand: (value: boolean) => this.tabType === 1 && value
}
showRequired: false
}
},
mobile: {
@ -465,10 +447,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
type: 'string',
maxLength: 11,
ui: {
placeholder: '请输入',
visibleIf: {
expand: (value: boolean) => this.tabType === 2
}
placeholder: '请输入'
}
},
approvalUserName: {
@ -476,10 +455,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
type: 'string',
maxLength: 11,
ui: {
placeholder: '请输入',
visibleIf: {
expand: (value: boolean) => this.tabType === 1 && value
}
placeholder: '请输入'
}
},
createTime: {
@ -488,10 +464,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
ui: {
widget: 'sl-from-to-search',
format: 'yyyy-MM-dd HH:mm:ss',
nzShowTime: true,
visibleIf: {
expand: (value: boolean) => value
}
nzShowTime: true
} as SFDateWidgetSchema
},
approvalTime: {
@ -500,10 +473,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
ui: {
widget: 'sl-from-to-search',
format: 'yyyy-MM-dd HH:mm:ss',
nzShowTime: true,
visibleIf: {
expand: (value: boolean) => this.tabType === 1 && value
}
nzShowTime: true
} as SFDateWidgetSchema
},
approvalStatus: {
@ -518,10 +488,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
],
default: '',
ui: {
widget: 'select',
visibleIf: {
expand: (value: boolean) => value
}
widget: 'select'
}
},
source: {
@ -534,10 +501,7 @@ export class FreightComponentsEnterpriseAuditComponent implements OnInit {
],
default: '',
ui: {
widget: 'select',
visibleIf: {
expand: (value: boolean) => this.tabType === 1 && value
}
widget: 'select'
}
}
}

View File

@ -340,8 +340,13 @@
<sv-container col="3" class="mt16">
<sv-title>企业开票信息</sv-title>
<sv label="开户银行">
<input nz-input type="text" [(ngModel)]="detailData.createBank" [readonly]="!isEdit" [nzBorderless]="!isEdit"
[placeholder]="isEdit?'':'-'">
<ng-container *ngIf="isEdit; else createBankTemplate">
<input nz-input type="text" [(ngModel)]="detailData.createBank" [readonly]="!isEdit" [nzBorderless]="!isEdit"
[placeholder]="isEdit?'':'-'">
</ng-container>
<ng-template #createBankTemplate>
{{detailData.createBank}}
</ng-template>
</sv>
<sv label="银行账户">
<input nz-input type="text" [(ngModel)]="detailData.bankAccount" [readonly]="!isEdit" [nzBorderless]="!isEdit"
@ -352,8 +357,13 @@
[placeholder]="isEdit?'':'-'">
</sv>
<sv label="注册地址">
<input nz-input type="text" [(ngModel)]="detailData.registerAddress" [readonly]="!isEdit" [nzBorderless]="!isEdit"
[placeholder]="isEdit?'':'-'">
<ng-container *ngIf="isEdit; else registerAddressTemplate">
<input nz-input type="text" [(ngModel)]="detailData.registerAddress" [readonly]="!isEdit"
[nzBorderless]="!isEdit" [placeholder]="isEdit?'':'-'">
</ng-container>
<ng-template #registerAddressTemplate>
{{detailData.registerAddress}}
</ng-template>
</sv>
</sv-container>
<nz-divider></nz-divider>

View File

@ -1,19 +0,0 @@
:host{
::ng-deep{
.btnBox {
st-td{
// display: flex;
// align-items: center;
st-td>span{
display: inline-block;
width: 95px;
text-align: center;
margin: 0 10px;
}
}
.st__btn-text span{
white-space: nowrap;
}
}
}
}

View File

@ -1,16 +1,5 @@
<!--
* @Author: your name
* @Date: 2021-12-13 10:47:28
* @LastEditTime : 2022-02-15 13:59:52
* @LastEditors : Shiming
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath : \\tms-obc-web\\src\\app\\routes\\usercenter\\components\\freight\\user\\user.component.html
-->
<!-- 页头 -->
<page-header-wrapper [title]="'员工列表'"></page-header-wrapper>
<!-- <page-header-wrapper [title]="'员工列表'"></page-header-wrapper>
<nz-card>
<!-- 搜索区 -->
<!-- 搜索表单 -->
<div nz-row nzGutter="8">
<div nz-col [nzXl]="_$expand ? 24 : 18" [nzLg]="24" [nzSm]="24" [nzXs]="24">
<sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf>
@ -26,20 +15,30 @@
</button>
</div>
</div>
</nz-card>
</nz-card> -->
<nz-card class="content-box">
<nz-tabset [nzSelectedIndex]="1">
<nz-tab nzTitle="全部" (nzClick)="selectChange(null)"></nz-tab>
<nz-tab nzTitle="待审核" (nzClick)="selectChange(0)"></nz-tab>
<nz-tab nzTitle="已成功" (nzClick)="selectChange(1)"></nz-tab>
<nz-tab nzTitle="已驳回" (nzClick)="selectChange(2)"></nz-tab>
</nz-tabset>
<nz-card class="table-box">
<div class="tab_header">
<label class="page_title"><label class="driver">|</label>企业审核列表</label>
<nz-tabset [nzSelectedIndex]="1" [nzTabBarExtraContent]="extraTemplate">
<nz-tab nzTitle="全部" (nzClick)="selectChange(null)"></nz-tab>
<nz-tab nzTitle="待审核" (nzClick)="selectChange(0)"></nz-tab>
<nz-tab nzTitle="已成功" (nzClick)="selectChange(1)"></nz-tab>
<nz-tab nzTitle="已驳回" (nzClick)="selectChange(2)"></nz-tab>
</nz-tabset>
</div>
<ng-template #extraTemplate>
<div class="mr-sm">
<button nz-button nzDanger [nzLoading]="service.http.loading" acl [acl-ability]="['USERCENTER-FREIGHT-USER-list']"
(click)="openDrawer()">筛选</button>
<button nz-button nzDanger (click)="st?.load(1)" acl [acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-export']">
导出</button>
</div>
</ng-template>
<!-- 数据列表 -->
<!-- [data]="service.$api_get_supplier_page" -->
<st #st [columns]="columns" [data]='service.$api_get_user_list' [req]="{ process: beforeReq }"
[scroll]="{ x:'1200px',y: '400px' }" [page]="{ }" [loading]="service.http.loading">
[scroll]="{ x:'1200px',y:scrollY }" [page]="{ }" [loading]="service.http.loading">
<ng-template st-row="enterpriseName" let-item let-index="index">
<div nz-tooltip [nzTooltipTitle]="item.enterpriseName">
<div

View File

@ -2,20 +2,19 @@ import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { STColumn, STColumnBadge, STComponent, STData, STRequestOptions } from '@delon/abc/st';
import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form';
import { SearchDrawerService } from '@shared';
import { NzModalService } from 'ng-zorro-antd/modal';
import { BasicTableComponent } from 'src/app/routes/commom';
import { UsermanageService } from '../../../services/usercenter.service';
@Component({
selector: 'app-Freight-components-user',
styleUrls: ['./user.component.less'],
styleUrls: ['../../../../commom/less/commom-table.less'],
templateUrl: './user.component.html'
})
export class FreightComponentsUserComponent implements OnInit {
_$expand = false;
ui: SFUISchema = { '*': { spanLabelFixed: 120, grid: { lg: 8, md: 12, sm: 12, xs: 24 }, enter: () => this.st.load() } };
export class FreightComponentsUserComponent extends BasicTableComponent implements OnInit {
schema: SFSchema = this.initSF();
columns: STColumn[] = this.initST();
@ViewChild('st', { static: false }) st!: STComponent;
@ViewChild('sf', { static: false }) sf!: SFComponent;
@ViewChild('promoterModal', { static: false })
promoterModal!: any;
@ -23,7 +22,16 @@ export class FreightComponentsUserComponent implements OnInit {
resourceStatus: any = 0;
constructor(public service: UsermanageService, private modal: NzModalService, private router: Router, private ar: ActivatedRoute) {}
constructor(public service: UsermanageService, private modal: NzModalService, private router: Router, private ar: ActivatedRoute,
public searchDrawerService: SearchDrawerService
) {
super(searchDrawerService);
}
search() {
this.st?.load(1);
}
ngOnInit() {
this.ar.url.subscribe(params => {
@ -106,19 +114,6 @@ export class FreightComponentsUserComponent implements OnInit {
});
}
expandToggle() {
this._$expand = !this._$expand;
this.sf?.setValue('/expand', this._$expand);
}
/**
* 重置表单
*/
resetSF() {
this.sf.reset();
this._$expand = false;
}
private initSF(): SFSchema {
return {
properties: {
@ -163,9 +158,6 @@ export class FreightComponentsUserComponent implements OnInit {
default: '',
ui: {
widget: 'select',
visibleIf: {
expand: (value: boolean) => value
}
}
},
promotersTelephone: {
@ -174,9 +166,6 @@ export class FreightComponentsUserComponent implements OnInit {
maxLength: 11,
ui: {
placeholder: '请输入手机号',
visibleIf: {
expand: (value: boolean) => value
}
}
},
effectiveDate: {
@ -186,9 +175,6 @@ export class FreightComponentsUserComponent implements OnInit {
widget: 'date',
mode: 'range',
format: 'yyyy-MM-dd',
visibleIf: {
expand: (value: boolean) => value
}
} as SFDateWidgetSchema
}
}