fix bug
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: your name
|
||||
* @Date: 2021-12-03 11:10:14
|
||||
* @LastEditTime: 2021-12-13 14:17:23
|
||||
* @LastEditTime: 2021-12-13 14:52:49
|
||||
* @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\supply-management\components\vehicle\vehicle.component.html
|
||||
@ -36,10 +36,17 @@
|
||||
</nz-card>
|
||||
|
||||
<nz-card>
|
||||
<nz-tabset (nzSelectedIndexChange)="selectChange($event)" [nzTabBarExtraContent]="extraTemplate">
|
||||
<!-- <nz-tabset (nzSelectedIndexChange)="selectChange($event)" [nzTabBarExtraContent]="extraTemplate">
|
||||
<nz-tab *ngFor="let tab of tabs; let i = index" [nzTitle]="tab.name + ' (' + tab.count + ') '" (nzClick)="tabChange(i)">
|
||||
</nz-tab>
|
||||
</nz-tabset>
|
||||
</nz-tabset> -->
|
||||
<nz-tabset (nzSelectedIndexChange)="selectChange($event)"
|
||||
[nzTabBarExtraContent]="extraTemplate">
|
||||
<nz-tab [nzTitle]="'全部('+tabs?.totalQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'待接单('+tabs?.stayQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已接单('+tabs?.receivedQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已取消('+tabs?.cancelQuantity+')'"></nz-tab>
|
||||
</nz-tabset>
|
||||
<div style="margin-top: 15px;">
|
||||
<!-- 选中提示框 -->
|
||||
<div style="position: relative">
|
||||
|
||||
@ -27,27 +27,12 @@ export class SupplyManagementVehicleComponent implements OnInit {
|
||||
@ViewChild('sf', { static: false }) sf!: SFComponent;
|
||||
@ViewChild('sfFre', { static: false }) sfFre!: SFComponent;
|
||||
columns: STColumn[] = [];
|
||||
tabs = [ {
|
||||
name: '全部',
|
||||
type: 0,
|
||||
count: 0,
|
||||
},
|
||||
{
|
||||
name: '待接单',
|
||||
type: 1,
|
||||
count: 0,
|
||||
},
|
||||
{
|
||||
name: '已接单',
|
||||
type: 2,
|
||||
count: 0,
|
||||
},
|
||||
{
|
||||
name: '已取消',
|
||||
type: 3,
|
||||
count: 0,
|
||||
},
|
||||
];
|
||||
tabs = {
|
||||
totalQuantity: 0,
|
||||
cancelQuantity: 0,
|
||||
receivedQuantity: 0,
|
||||
stayQuantity: 0
|
||||
};
|
||||
resourceStatus: any;
|
||||
constructor(public service: SupplyManagementService, private modal: NzModalService, private router: Router,private ar: ActivatedRoute) { }
|
||||
|
||||
@ -71,6 +56,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
|
||||
this.initSF();
|
||||
this.initST();
|
||||
this.initSFFre();
|
||||
this.getGoodsSourceStatistical();
|
||||
}
|
||||
|
||||
|
||||
@ -452,4 +438,13 @@ export class SupplyManagementVehicleComponent implements OnInit {
|
||||
},
|
||||
})
|
||||
}
|
||||
// 获取货源状态统计
|
||||
getGoodsSourceStatistical() {
|
||||
this.service.request(this.service.$api_get_goods_resource_statistical, { resourceType: 1 }).subscribe(res => {
|
||||
if (res) {
|
||||
console.log(res)
|
||||
this.tabs = res;
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user