This commit is contained in:
Taric Xin
2022-02-25 17:19:03 +08:00
parent 9955d29d76
commit db73552c90
2 changed files with 169 additions and 43 deletions

View File

@ -9,49 +9,82 @@
* Copyright (C) 2022 huzhenhong. All rights reserved.
-->
<page-header-wrapper [title]="'企业审核列表'" [content]="content">
<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>
</div>
<div nz-col [nzXl]="_$expand ? 24 : 8" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right"
[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]="service.http.loading" (click)="exportList()"
acl [acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-export']">导出</button>
<button nz-button (click)="resetSF()" [disabled]="service.http.loading">重置</button>
<button nz-button nzType="link" (click)="expandToggle(!_$expand)">
{{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
</button>
</div>
</div>
</nz-card>
<nz-card>
<!-- 数据列表 -->
<st #st multiSort [data]="service.$api_get_freight_list" [columns]="tabType===1?enterColumns:adminColumns"
[req]="{ process: beforeReq }" [page]=" {}" [loading]="service.http.loading" [scroll]="{ x: '1200px' }">
<ng-template st-row="approvalStatus" let-item let-index="index">
<ng-container [ngSwitch]="item.approvalStatus">
<nz-badge *ngSwitchCase="10" nzColor="#108ee9" nzText="待审核"></nz-badge>
<nz-badge *ngSwitchCase="15" nzColor="gold" nzText="已撤销"></nz-badge>
<nz-badge *ngSwitchCase="20" nzColor="#87d068" nzText="已成功"></nz-badge>
<ng-container *ngSwitchCase="30">
<nz-badge nzColor="volcano" nzText="已驳回"></nz-badge><br>
<label style="color: #ff4d4f;">(驳回原因:{{item.approvalOpinion}}</label>
</ng-container>
<p *ngSwitchDefault></p>
</ng-container>
</ng-template>
</st>
</nz-card>
<ng-template #content>
<nz-tabset class="tabs-wrap">
<nz-tab *ngFor="let tab of tabs" [nzTitle]="tab.name" (nzSelect)="changeTab(tab)"> </nz-tab>
</nz-tabset>
</ng-template>
</page-header-wrapper>
</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>
</div>
<div nz-col [nzXl]="_$expand ? 24 : 8" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right"
[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]="service.http.loading" (click)="exportList()"
acl [acl-ability]="['USERCENTER-FREIGHT-ENTERPRISE-export']">导出</button>
<button nz-button (click)="resetSF()" [disabled]="service.http.loading">重置</button>
<button nz-button nzType="link" (click)="expandToggle(!_$expand)">
{{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
</button>
</div>
</div>
</nz-card>
<nz-card>
<!-- 数据列表 -->
<st #st multiSort [data]="service.$api_get_freight_list" [columns]="tabType===1?enterColumns:adminColumns"
[req]="{ process: beforeReq }" [page]=" {}" [loading]="service.http.loading" [scroll]="{ x: '1200px' }">
<ng-template st-row="approvalStatus" let-item let-index="index">
<ng-container [ngSwitch]="item.approvalStatus">
<nz-badge *ngSwitchCase="10" nzColor="#108ee9" nzText="待审核"></nz-badge>
<nz-badge *ngSwitchCase="15" nzColor="gold" nzText="已撤销"></nz-badge>
<nz-badge *ngSwitchCase="20" nzColor="#87d068" nzText="已成功"></nz-badge>
<ng-container *ngSwitchCase="30">
<nz-badge nzColor="volcano" nzText="已驳回"></nz-badge><br>
<label style="color: #ff4d4f;">(驳回原因:{{item.approvalOpinion}}</label>
</ng-container>
<p *ngSwitchDefault></p>
</ng-container>
</ng-template>
</st>
</nz-card>
<ng-template #approvedModal>
<div nz-row nzGutter="8">
<div nz-col nzSpan="24" se-container [labelWidth]="120">
<se [col]="1" label="公司名称">
{{ detailData?.enterpriseName }}
</se>
<se [col]="1" label="网络货运人" required>
<nz-select nzPlaceHolder="请选择" [(ngModel)]="networkTransporter">
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of ltdId"></nz-option>
</nz-select>
</se>
<se [col]="1" label="企业角色" required>
<nz-select nzPlaceHolder="请选择" [(ngModel)]="roleId">
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of roles"></nz-option>
</nz-select>
</se>
</div>
</div>
</ng-template>
<ng-template #redectModal>
<div nz-row nzGutter="8">
<div nz-col nzSpan="24" se-container [labelWidth]="120">
<se [col]="1" label="公司名称">
{{ detailData?.enterpriseName }}
</se>
<se [col]="1" label="备注" required>
<textarea nz-input rows="3" style="width: 325px;margin-left: 14px;" [(ngModel)]="approvalOpinion"></textarea>
</se>
</div>
</div>
</ng-template>