This commit is contained in:
Taric Xin
2022-01-12 10:53:52 +08:00
parent 35b68ef287
commit 03dbc7fce6
2 changed files with 51 additions and 52 deletions

View File

@ -9,62 +9,61 @@
<page-header-wrapper title="结算客户管理"> <page-header-wrapper title="结算客户管理">
</page-header-wrapper> </page-header-wrapper>
<nz-card > <nz-card>
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<!-- 查询字段小于或等于3个时不显示伸缩按钮 --> <!-- 查询字段小于或等于3个时不显示伸缩按钮 -->
<div nz-col nzSpan="24" *ngIf="queryFieldCount <= 4"> <div nz-col nzSpan="24" *ngIf="queryFieldCount <= 4">
<sf #sf [schema]="schema" [ui]="ui" [mode]="'search'" [disabled]="!sf?.valid" [loading]="service.http.loading" <sf #sf [schema]="schema" [ui]="ui" [mode]="'search'" [loading]="service.http.loading" (formSubmit)="st?.load(1)"
(formSubmit)="st?.load(1)" (formReset)="resetSF()"></sf> (formReset)="resetSF()"></sf>
</div> </div>
<!-- 查询字段大于3个时根据展开状态调整布局 --> <!-- 查询字段大于3个时根据展开状态调整布局 -->
<ng-container *ngIf="queryFieldCount > 4"> <ng-container *ngIf="queryFieldCount > 4">
<div nz-col [nzSpan]="_$expand ? 24 : 18"> <div nz-col [nzSpan]="_$expand ? 24 : 18">
<sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf> <sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf>
</div>
<div nz-col [nzSpan]="_$expand ? 24 : 6" [class.text-right]="_$expand">
<button nz-button nzType="primary" [disabled]="!sf.valid" [nzLoading]="service.http.loading"
(click)="st?.load(1)">查询</button>
<button nz-button nzType="primary"
>导出</button>
<button nz-button (click)="resetSF()">重置</button>
<button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
</button>
</div>
</ng-container>
</div> </div>
<div nz-col [nzSpan]="_$expand ? 24 : 6" [class.expend-options]="_$expand" class="text-right">
<button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)">查询</button>
<button nz-button [disabled]="service.http.loading" nzType="primary">导出</button>
<button nz-button [disabled]="service.http.loading" (click)="resetSF()">重置</button>
<button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
</button>
</div>
</ng-container>
</div>
</nz-card> </nz-card>
<nz-card class="content-box"> <nz-card class="content-box">
<div class="d-flex justify-content-end mb-sm"> <div class="d-flex justify-content-end mb-sm mt-sm">
<div> <div>
<button nz-button nzType="primary" (click)="roleAction('',1)" >新增结算客户</button> <button nz-button nzType="primary" (click)="roleAction('',1)">新增结算客户</button>
</div>
</div> </div>
<st #st [data]="service.$api_settlementCustomer_page" [columns]="columns" </div>
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" <st #st [data]="service.$api_settlementCustomer_page" [columns]="columns"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }" [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }" [res]="{ reName: { list: 'data.records', total: 'data.total' } }"
[loading]="service.http.loading" [scroll]="{ y: '370px' }" (change)="stChange($event)"> [page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
<ng-template st-row="customerType" let-item let-index="index"> [loading]="service.http.loading" [scroll]="{ y: '370px' }" (change)="stChange($event)">
<div> <ng-template st-row="customerType" let-item let-index="index">
<span *ngIf="item?.customerType == 1">客户</span> <div>
<span *ngIf="item?.customerType == 2">供应商</span> <span *ngIf="item?.customerType == 1">客户</span>
</div> <span *ngIf="item?.customerType == 2">供应商</span>
</ng-template> </div>
</st> </ng-template>
</st>
</nz-card> </nz-card>
<nz-modal [(nzVisible)]="isVisible" [nzFooter]="nzModalFooter" [nzTitle]="editText" (nzOnOk)="handleOK()" (nzOnCancel)="handleCancel()"> <nz-modal [(nzVisible)]="isVisible" [nzFooter]="nzModalFooter" [nzTitle]="editText" (nzOnOk)="handleOK()"
<ng-container *nzModalContent> (nzOnCancel)="handleCancel()">
<sf #sfFre [schema]="addSchema" [ui]="ui2" [formData]="formData" [compact]="false" [button]="'none'"> <ng-container *nzModalContent>
</sf> <sf #sfFre [schema]="addSchema" [ui]="ui2" [formData]="formData" [compact]="false" [button]="'none'">
</ng-container> </sf>
<ng-template #nzModalFooter> </ng-container>
<button nz-button nzType="primary" (click)="handleCancel()" [disabled]="">取消</button> <ng-template #nzModalFooter>
<button nz-button nzType="default" (click)="handleOK()">确 定</button> <button nz-button nzType="primary" (click)="handleCancel()" [disabled]="">取消</button>
</ng-template> <button nz-button nzType="default" (click)="handleOK()">确 定</button>
</nz-modal> </ng-template>
</nz-modal>

View File

@ -10,7 +10,7 @@ import { SystemService } from '../../services/system.service';
@Component({ @Component({
selector: 'app-close-account', selector: 'app-close-account',
templateUrl: './close-account.component.html', templateUrl: './close-account.component.html',
styleUrls: ['./close-account.component.less'] styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less']
}) })
export class CloseAccountComponent implements OnInit { export class CloseAccountComponent implements OnInit {
@ViewChild('st', { static: true }) @ViewChild('st', { static: true })