This commit is contained in:
wangshiming
2022-04-18 16:56:20 +08:00
parent 4068a3ece2
commit 582ea2d3fa
7 changed files with 133 additions and 149 deletions

View File

@ -4,22 +4,18 @@
* @Author : Shiming
* @Date : 2022-03-30 17:57:46
* @LastEditors : Shiming
* @LastEditTime : 2022-04-18 16:11:00
* @LastEditTime : 2022-04-18 16:37:41
* @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\compliance\\salesman\\salesman.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved.
-->
<!-- 页头 -->
<page-header-wrapper [title]="'业务员报告'"></page-header-wrapper>
<nz-card >
<nz-tabset (nzSelectedIndexChange)="selectChange($event)" [nzTabBarExtraContent]="extraTemplate">
<nz-tab [nzTitle]="'客户'"></nz-tab>
<nz-tab [nzTitle]="'合伙人'"></nz-tab>
</nz-tabset>
<page-header-wrapper [title]="'业务员-合规报告'"></page-header-wrapper>
<nz-card [nzExtra]="extraTemplate">
<ng-template #extraTemplate>
<div class="chooseBox">
<div class="timeBox">
<sf #sf [schema]="searchSchema" button="none"
[ui]="{ '*': { spanLabelFixed: 0, grid: { xxl:5,xl:4, lg: 8, md: 12, sm: 12, xs: 24,gutter:20 } } }"
[ui]="{ '*': { spanLabelFixed: 0, grid: { xxl:4,xl:4, lg: 4, md: 4, sm: 4, xs: 4,gutter:4 } } }"
[compact]="true">
<ng-template sf-template="no4" let-me let-ui="ui" let-schema="schema">
<div class="chooseBox">
@ -40,10 +36,9 @@
</div>
</ng-template>
</sf>
</div>
</div>
</ng-template>
<st #st multiSort [columns]="columns" [ps]="20" [data]="service.$api_listShipperReportPage"
<st #st multiSort [columns]="columns" [ps]="20" [data]="service.$api_listPartComplianceReportPage"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[scroll]="{ x: '1200px' }" [res]="{ reName: { list: 'data.records', total: 'data.total' } }"
[page]="{ show: true, showSize: true, pageSizes: [20, 50, 100] }">

View File

@ -1,7 +1,4 @@
.chooseBox {
display: flex;
float : right;
}
.timeBox {
display: flex;

View File

@ -29,11 +29,11 @@ export class DatatableComplianceSalesmanComponent implements OnInit {
isLoading: boolean = false;
searchSchema: SFSchema = {
properties: {
customerName: {
department: {
type: 'string',
title: '',
ui: {
placeholder: '请输入客户名称',
placeholder: '请选择部门',
change: (value: any) => {
console.log(value);
this.st.reload({ ...this.reqParams });
@ -41,11 +41,22 @@ export class DatatableComplianceSalesmanComponent implements OnInit {
},
},
salesmanName: {
customerName: {
type: 'string',
title: '',
ui: {
placeholder: '请输入业务员',
change: (value: any) => {
console.log(value);
this.st.reload({ ...this.reqParams });
}
},
},
salesmanName: {
type: 'string',
title: '',
ui: {
placeholder: '请输入客户名称',
change: (value: any) => {
this.st.reload({ ...this.reqParams });
}
@ -57,39 +68,21 @@ export class DatatableComplianceSalesmanComponent implements OnInit {
ui: {
class: 'custom',
widget: 'custom',
grid: { xxl: 12, xl: 12, lg: 24, md: 24, sm: 24, xs: 24 }
grid: { xxl: 12, xl: 12, lg: 12, md: 12, sm: 12, xs: 12 }
}
}
}
},
};
columns: STColumn[] = [
{ title: '货主名称', index: 'enterpriseName', className: 'text-center', width: '200px' },
{ title: '注册时间', index: 'registerTime', className: 'text-center', width: '200px' },
{ title: '客户类型', index: 'customerType', className: 'text-center', width: '100px', type: 'enum', enum: {
1: '平台客户',
2: '直客',
3: '渠道客户'
}
},
{ title: '业务员', index: 'salesmanName', className: 'text-center', width: '100px' },
{ title: '合伙人', index: 'partnerName', className: 'text-center', width: '100px' },
{ title: '客户状态', index: 'customerStatus', className: 'text-center', width: '100px', type: 'enum', enum: {
1: '未激活',
2: '沉默',
3: '流失',
4: '活跃'
} },
{ title: '订单数', index: 'zsl', className: 'text-center', width: '100px' },
{ title: '订单金额', index: 'ddje', className: 'text-right', width: '100px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.ddje }) } },
{ title: '应收订单数', index: 'ysdds', className: 'text-center', width: '120px' },
{ title: '应收金额', index: 'yingsje', className: 'text-right', width: '100px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.yingsje }) } },
{ title: '待开票订单数', index: 'yifyf', className: 'text-center', width: '130px' },
{ title: '待开票金额', index: 'dkpdds', className: 'text-right', width: '120px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.dkpdds }) } },
{ title: '已收金额', index: 'yisje', className: 'text-right', width: '100px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.yisje }) } },
{ title: '应收附加费', index: 'yingsfjf', className: 'text-right', width: '120px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.yingsfjf }) } },
{ title: '已收附加费', index: 'yisfjf', className: 'text-right', width: '120px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.yisfjf }) } },
{ title: '附加费率', index: 'fjfl', className: 'text-center', width: '100px' },
{ title: '已开票金额', index: 'ykpje', className: 'text-right', width: '100px', type: 'widget', widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.ykpje }) } },
{ title: '部门', index: 'department', className: 'text-center', width: '200px' },
{ title: '业务员', index: 'salesmen', className: 'text-center', width: '100px' },
{ title: '客户', index: 'cusCount', className: 'text-right', width: '100px', },
{ title: '订单数', index: 'billCount', className: 'text-center', width: '120px' },
{ title: '订单合格率', index: 'billComPer', className: 'text-right', width: '100px',format: (item: any) => {return ((item?.billComPer)*100).toFixed(2) + '%' }},
{ title: '付款及时率', index: 'payTimePer', className: 'text-center', width: '130px',format: (item: any) => {return ((item?.payTimePer)*100).toFixed(2) + '%'  } },
{ title: '货源单占比', index: 'goodResPer', className: 'text-right', width: '120px',format: (item: any) => {return ((item?.goodResPer)*100).toFixed(2) + '%'  } },
{ title: '运费直付占比', index: 'feightPayPer', className: 'text-right', width: '100px', format: (item: any) => {return ((item?.feightPayPer)*100).toFixed(2) + '%'  } },
];
/**
* 查询参数
@ -223,11 +216,4 @@ export class DatatableComplianceSalesmanComponent implements OnInit {
this._$expand = false;
this.isLoading = true
}
selectChange(e: number) {
// this.resourceStatus = e;
// this.initST();
setTimeout(() => {
this.st.load();
}, 500);
}
}