车辆对接
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: your name
|
||||
* @Date: 2021-12-27 14:08:49
|
||||
* @LastEditTime: 2021-12-30 14:15:22
|
||||
* @LastEditTime: 2021-12-30 15:44:54
|
||||
* @LastEditors: Please set LastEditors
|
||||
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
* @FilePath: \tms-obc-web\src\app\routes\ticket-management\components\cancellation-invoice\cancellation-invoice.component.html
|
||||
@ -30,10 +30,11 @@
|
||||
</nz-card>
|
||||
|
||||
<nz-card class="content-box" nzBordered>
|
||||
<nz-tabset [nzTabBarExtraContent]="extraTemplate">
|
||||
<nz-tabset [nzTabBarExtraContent]="extraTemplate" (nzSelectedIndexChange)="selectChange($event)">
|
||||
<nz-tab nzTitle="全部"></nz-tab>
|
||||
<nz-tab nzTitle="待处理"></nz-tab>
|
||||
<nz-tab nzTitle="待确认"></nz-tab>
|
||||
<nz-tab nzTitle="全部"></nz-tab>
|
||||
<nz-tab nzTitle="已确认"></nz-tab>
|
||||
</nz-tabset>
|
||||
<ng-template #extraTemplate>
|
||||
<div class="d-flex align-items-center">
|
||||
@ -50,11 +51,20 @@
|
||||
</ng-template>
|
||||
|
||||
|
||||
<st #st [data]="service.$api_ficoVatinvHList" [columns]="columns"
|
||||
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, process: beforeReq }"
|
||||
[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: '370px' }" (change)="stChange($event)">
|
||||
<st
|
||||
#st
|
||||
size="small"
|
||||
[bordered]="true"
|
||||
[scroll]="{ x: '2000px' }"
|
||||
[data]="service.$api_ficoVatinvHList"
|
||||
[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] }"
|
||||
[loadingDelay]="500"
|
||||
[loading]="service.http.loading"
|
||||
>
|
||||
|
||||
<ng-template st-row="vatinvcode" let-item let-index="index" let-column="column">
|
||||
{{ item.vatinvcode }} <br>
|
||||
<label class="text-primary" *ngIf="item.sts == '1'">待处理</label>
|
||||
|
||||
@ -21,7 +21,7 @@ export class CancellationInvoiceComponent implements OnInit {
|
||||
requestedModal!: any;
|
||||
columns: STColumn[] = this.initST();
|
||||
searchSchema: SFSchema = this.initSF();
|
||||
|
||||
resourceStatus = ''
|
||||
_$expand = false;
|
||||
|
||||
selectedRows: any[] = [];
|
||||
@ -30,22 +30,34 @@ export class CancellationInvoiceComponent implements OnInit {
|
||||
|
||||
ngOnInit(): void {}
|
||||
|
||||
beforeReq = (requestOptions: STRequestOptions) => {
|
||||
if (this.sf) {
|
||||
Object.assign(requestOptions.body, { ...this.sf.value });
|
||||
get reqParams() {
|
||||
// if (this.sf) {
|
||||
// Object.assign(requestOptions.body, {
|
||||
// ...this.sf.value,
|
||||
// sts: this?.resourceStatus,
|
||||
// createTime: {
|
||||
// start: this.sf.value.createTime?.[0] || null,
|
||||
// end: this.sf.value.createTime?.[1] || null
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
const a:any = {};
|
||||
if(this.resourceStatus) {
|
||||
a.sts = this.resourceStatus
|
||||
}
|
||||
return requestOptions;
|
||||
return {
|
||||
...a,
|
||||
...this.sf?.value,
|
||||
};
|
||||
};
|
||||
|
||||
stChange(e: STChange): void {
|
||||
switch (e.type) {
|
||||
case 'checkbox':
|
||||
this.selectedRows = e.checkbox!;
|
||||
this.totalCallNo = this.selectedRows.reduce((total, cv) => total + cv.callNo, 0);
|
||||
break;
|
||||
}
|
||||
selectChange(e: any) {
|
||||
console.log(e)
|
||||
this.resourceStatus = e;
|
||||
this.initST();
|
||||
setTimeout(() => {
|
||||
this.st.load();
|
||||
}, 500);
|
||||
}
|
||||
|
||||
approval(): void {}
|
||||
|
||||
add(): void {}
|
||||
@ -241,7 +253,7 @@ export class CancellationInvoiceComponent implements OnInit {
|
||||
buttons: [
|
||||
{
|
||||
text: '查看明细',
|
||||
click: item => this.router.navigate(['ticket/cancellation-invoice/detail/1'], { queryParams: { type: 1 } })
|
||||
click: item => this.router.navigate(['ticket/cancellation-invoice/detail/' + item.id], { queryParams: { type: 1 } })
|
||||
},
|
||||
{
|
||||
text: '手工开票',
|
||||
|
||||
Reference in New Issue
Block a user