This commit is contained in:
Taric Xin
2021-12-24 13:18:34 +08:00
parent dc28444d16
commit 336dfd81f5
19 changed files with 886 additions and 217 deletions

View File

@ -1,61 +0,0 @@
<page-header-wrapper [title]="'开票订单明细'" [logo]="logo">
<ng-template #logo>
<button nz-button nz-tooltip nzTooltipTitle="返回上一页" (click)="goBack()">
<i nz-icon nzType="left" nzTheme="outline"></i>
</button>
</ng-template>
</page-header-wrapper>
<nz-card>
<nz-row [nzGutter]="16">
<nz-col [nzXl]="4" [nzLg]="8" [nzSm]="12">
<nz-statistic nzValue="05101010" [nzTitle]="'发票号码'" [nzValueStyle]="{'font-size':'21px'}">
</nz-statistic>
</nz-col>
<nz-col [nzXl]="4" [nzLg]="8" [nzSm]="12">
<nz-statistic nzValue="100000.00" [nzTitle]="'开票金额'" [nzValueStyle]="{'font-size':'21px'}">
</nz-statistic>
</nz-col>
<nz-col [nzXl]="3" [nzLg]="8" [nzSm]="12">
<nz-statistic nzValue="20" [nzTitle]="'订单数'" [nzValueStyle]="{'font-size':'21px'}"></nz-statistic>
</nz-col>
<nz-col [nzXl]="3" [nzLg]="8" [nzSm]="12">
<nz-statistic nzValue="2021-10-11" [nzTitle]="'开票日期'" [nzValueStyle]="{'font-size':'21px'}"></nz-statistic>
</nz-col>
<nz-col [nzXl]="5" [nzLg]="8" [nzSm]="12">
<nz-statistic nzValue="茅台集团股份有限公司" [nzTitle]="'托运人'" [nzValueStyle]="{'font-size':'21px'}"></nz-statistic>
</nz-col>
<nz-col [nzXl]="5" [nzLg]="8" [nzSm]="18">
<nz-statistic nzValue="天津怡亚通物流科技有限公司" [nzTitle]="'开票方'" [nzValueStyle]="{'font-size':'21px'}">
</nz-statistic>
</nz-col>
</nz-row>
</nz-card>
<nz-card class="search-box" nzBordered>
<div nz-row nzGutter="8">
<div nz-col [nzXl]="_$expand ? 24 : 18" [nzLg]="24" [nzSm]="24" [nzXs]="24">
<sf #sf [schema]="searchSchema"
[ui]="{ '*': { spanLabelFixed: 90,grid: { lg: 8, md: 12, sm: 12, xs: 24 } }}" [compact]="true"
[button]="'none'"></sf>
</div>
<div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24" [class.expend-options]="_$expand"
class="text-right">
<button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)">查询</button>
<button nz-button (click)="resetSF()">重置</button>
<button nz-button> 导出</button>
<button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
</button>
</div>
</div>
</nz-card>
<nz-card class="content-box" nzBordered>
<st #st [data]="url" [columns]="columns"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
[loading]="service.http.loading" [scroll]="{ x:'1200px',y: '330px' }" (change)="stChange($event)"></st>
</nz-card>

View File

@ -1,24 +0,0 @@
:host::ng-deep {
.search-box {
.ant-card-body {
padding-bottom: 18px;
}
}
.content-box {
.ant-card-body {
padding-top: 16px;
}
}
}
.expend-options {
margin-top: 0px;
}
@media (min-width: 990px) {
.expend-options {
margin-top: -40px;
}
}

View File

@ -1,121 +0,0 @@
import { Component, OnInit, ViewChild } from '@angular/core';
import { Router } from '@angular/router';
import { STComponent, STColumn, STChange } from '@delon/abc/st';
import { SFComponent, SFSchema } from '@delon/form';
import { NzModalService } from 'ng-zorro-antd/modal';
import { TicketService } from '../../../services/ticket.service';
@Component({
selector: 'app-invoiced-list-detail',
templateUrl: './invoiced-list-detail.component.html',
styleUrls: ['./invoiced-list-detail.component.less']
})
export class InvoicedListDetailComponent implements OnInit {
url = `/rule?_allow_anonymous=true`;
@ViewChild('st', { static: true })
st!: STComponent;
@ViewChild('sf', { static: false })
sf!: SFComponent;
columns: STColumn[] = [
{ title: '订单号', index: 'no' },
{ title: '外部订单号', index: 'callNo' },
{ title: '装货地', index: 'callNo' },
{ title: '卸货地', index: 'callNo' },
{ title: '货物名称', index: 'callNo' },
{ title: '重量/体积', index: 'callNo' },
{ title: '开票金额', index: 'callNo' },
{ title: '总费用', index: 'callNo' },
{ title: '基础运费', index: 'callNo' },
{ title: '附加费', index: 'callNo' },
];
searchSchema: SFSchema = {
properties: {
expand: {
type: 'boolean',
ui: {
hidden: true
}
},
orderSn: {
type: 'string',
title: '订单号',
ui: {
autocomplete: 'off'
}
},
orderSn2: {
type: 'string',
title: '外部订单号',
ui: {
autocomplete: 'off'
}
},
orderSn3: {
type: 'string',
title: '发票号码',
ui: {
autocomplete: 'off'
}
},
receiveName: {
type: 'string',
title: '开票状态',
enum: [
{ label: '全部', value: '' },
{ label: '待受理', value: '待受理' },
{ label: '待开票', value: '待开票' },
{ label: '开票中', value: '开票中' },
{ label: '已开票', value: '已开票' },
{ label: '已撤销', value: '已撤销' },
{ label: '已拒绝', value: '已拒绝' }
],
ui: {
widget: 'select',
placeholder: '请选择',
change: (i: any) => {
this.sf.value.receiveName = i;
this.sf?.setValue('/receiveName', i);
},
visibleIf: {
expand: (value: boolean) => value
}
},
default: ''
}
}
};
reqParams = {};
_$expand = false;
constructor(public service: TicketService, private nzModalService: NzModalService, private router: Router) {}
ngOnInit(): void {}
stChange(e: STChange): void {
switch (e.type) {
case 'filter':
this.st.load();
break;
}
}
goBack() {
history.go(-1);
}
/**
* 重置表单
*/
resetSF() {
this.sf.reset();
this._$expand = false;
}
/**
* 伸缩查询条件
*/
expandToggle() {
this._$expand = !this._$expand;
this.sf?.setValue('/expand', this._$expand);
}
}