Merge branch 'develop' of https://gitlab.eascs.com/tms-ui/tms-obc-web into develop

This commit is contained in:
heqinghang
2022-03-28 17:59:49 +08:00
146 changed files with 4558 additions and 2518 deletions

View File

@ -27,7 +27,7 @@ const alainConfig: AlainConfig = {
'https://gw.alipayobjects.com/os/lib/antv/g2/4.1.4/dist/g2.min.js', 'https://gw.alipayobjects.com/os/lib/antv/g2/4.1.4/dist/g2.min.js',
'https://gw.alipayobjects.com/os/lib/antv/data-set/0.11.7/dist/data-set.js' 'https://gw.alipayobjects.com/os/lib/antv/data-set/0.11.7/dist/data-set.js'
] ]
} },
}; };
const alainModules = [AlainThemeModule.forRoot(), DelonACLModule.forRoot()]; const alainModules = [AlainThemeModule.forRoot(), DelonACLModule.forRoot()];

View File

@ -0,0 +1,32 @@
<!-- 页头 -->
<page-header-wrapper [title]="'数据报表'"></page-header-wrapper>
<div nz-row [nzGutter]="16">
<div nz-col class="gutter-row" [nzSpan]="6">
<g2-card [title]="'客户预存款总额'" [bordered]="true" [total]="'¥ 126,560.00'" [footer]="footer" contentHeight="46">
<ng-template #footer>
<g2-mini-area line color="#cceafe" height="45" [data]="visitData" (clickItem)="handleClick($event)"></g2-mini-area>
</ng-template>
</g2-card>
</div>
<div nz-col class="gutter-row" [nzSpan]="6">
<g2-card [title]="'客户预存款总额'" [bordered]="true" [total]="'¥ 126,560.00'" [footer]="footer" contentHeight="46">
<ng-template #footer>
<g2-mini-area line color="#cceafe" height="45" [data]="visitData" (clickItem)="handleClick($event)"></g2-mini-area>
</ng-template>
</g2-card>
</div>
<div nz-col class="gutter-row" [nzSpan]="6">
<g2-card [title]="'客户预存款总额'" [bordered]="true" [total]="'¥ 126,560.00'" [footer]="footer" contentHeight="46">
<ng-template #footer>
<g2-mini-area line color="#cceafe" height="45" [data]="visitData" (clickItem)="handleClick($event)"></g2-mini-area>
</ng-template>
</g2-card>
</div>
<div nz-col class="gutter-row" [nzSpan]="6">
<g2-card [title]="'客户预存款总额'" [bordered]="true" [total]="'¥ 126,560.00'" [footer]="footer" contentHeight="46">
<ng-template #footer>
<g2-mini-area line color="#cceafe" height="45" [data]="visitData" (clickItem)="handleClick($event)"></g2-mini-area>
</ng-template>
</g2-card>
</div>
</div>

View File

@ -0,0 +1,24 @@
import { waitForAsync, ComponentFixture, TestBed } from '@angular/core/testing';
import { DatatableDataindexComponent } from './dataindex.component';
describe('DatatableDataindexComponent', () => {
let component: DatatableDataindexComponent;
let fixture: ComponentFixture<DatatableDataindexComponent>;
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [ DatatableDataindexComponent ]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(DatatableDataindexComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});

View File

@ -0,0 +1,37 @@
import { Component, OnInit, ViewChild } from '@angular/core';
import { ModalHelper, _HttpClient } from '@delon/theme';
import { G2MiniAreaClickItem, G2MiniAreaData } from '@delon/chart/mini-area';
import { format } from 'date-fns';
@Component({
selector: 'app-datatable-dataindex',
templateUrl: './dataindex.component.html',
styleUrls: ['./dataindex.component.less']
})
export class DatatableDataindexComponent implements OnInit {
visitData = this.genData();
constructor(private http: _HttpClient, private modal: ModalHelper) { }
ngOnInit(): void { }
private genData(): G2MiniAreaData[] {
const beginDay = new Date().getTime();
const res: G2MiniAreaData[] = [];
for (let i = 0; i < 20; i += 1) {
res.push({
x: format(new Date(beginDay + 1000 * 60 * 60 * 24 * i), 'yyyy-MM-dd'),
y: Math.floor(Math.random() * 100) + 10,
});
}
return res;
}
refresh(): void {
this.visitData = this.genData();
}
handleClick(data: G2MiniAreaClickItem): void {
//this.msg.info(`${data.item.x} - ${data.item.y}`);
}
}

View File

@ -0,0 +1,13 @@
import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { DatatableDataindexComponent } from './dataindex/dataindex.component';
const routes: Routes = [
{ path: 'dataindex', component: DatatableDataindexComponent }];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule]
})
export class DatatableRoutingModule { }

View File

@ -0,0 +1,17 @@
import { NgModule, Type } from '@angular/core';
import { SharedModule, SHARED_G2_MODULES } from '@shared';
import { DatatableRoutingModule } from './datatable-routing.module';
import { DatatableDataindexComponent } from './dataindex/dataindex.component';
const COMPONENTS: Type<void>[] = [
DatatableDataindexComponent];
@NgModule({
imports: [
SharedModule,
DatatableRoutingModule,
SHARED_G2_MODULES
],
declarations: COMPONENTS,
})
export class DatatableModule { }

View File

@ -84,9 +84,11 @@ export class AdvanceCollectionComponent {
title: '付款人', title: '付款人',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', serverSearch: true,
searchDebounceTime: 300,
searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
asyncData: () => this.service.getCRM() onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q })
} }
}, },
brmtype: { brmtype: {

View File

@ -165,7 +165,9 @@ export class DriverAccountDetailComponent implements OnInit {
{ title: '交易时间', index: 'createTime', type: 'date' }, { title: '交易时间', index: 'createTime', type: 'date' },
{ title: '流水号', index: 'channelPaySn' }, { title: '流水号', index: 'channelPaySn' },
{ title: '交易类型', index: 'tradeTypeLabel', className: 'text-center' }, { title: '交易类型', index: 'tradeTypeLabel', className: 'text-center' },
{ title: '关联单号', index: 'businessNumber' }, { title: '交易单号', index: 'businessNumber' },
{ title: '订单号', index: 'orderSn' },
{ title: '运单号', index: 'transportSn' },
{ title: '收支类型', index: 'incomeTypeLabel', className: 'text-center' }, { title: '收支类型', index: 'incomeTypeLabel', className: 'text-center' },
{ {
title: '交易金额', title: '交易金额',
@ -182,7 +184,10 @@ export class DriverAccountDetailComponent implements OnInit {
type: 'widget', type: 'widget',
className: 'text-right', className: 'text-right',
widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.accountBalance }) } widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.accountBalance }) }
} },
{ title: '付款方', index: 'payName'},
{ title: '收款方', index: 'payeeName' },
{ title: '备注', index: 'tradeContent' },
]; ];
} }
} }

View File

@ -164,7 +164,7 @@ export class DriverAccountComponent implements OnInit {
{ title: '司机姓名', width: 140, index: 'name' }, { title: '司机姓名', width: 140, index: 'name' },
{ title: '证件号码', width: 140, index: 'idNo' }, { title: '证件号码', width: 140, index: 'idNo' },
{ title: '手机号', width: 140, index: 'phone' }, { title: '手机号', width: 140, index: 'phone' },
{ title: '网络货运人', width: 140, index: 'ltdName' }, { title: '网络货运人', width: 180, index: 'ltdName' },
{ title: '银行类型', width: 120, index: 'bankTypeLabel' }, { title: '银行类型', width: 120, index: 'bankTypeLabel' },
{ title: '虚拟账户', width: 140, index: 'virtualAccount' }, { title: '虚拟账户', width: 140, index: 'virtualAccount' },
{ {
@ -186,13 +186,14 @@ export class DriverAccountComponent implements OnInit {
{ {
title: '本月累计提现金额', title: '本月累计提现金额',
index: 'withdrawBalance', index: 'withdrawBalance',
width: 150, width: 160,
type: 'widget', type: 'widget',
className: 'text-right', className: 'text-right',
widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.withdrawBalance }) } widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.withdrawBalance }) }
}, },
{ title: '账户总余额', render: 'availableBalance', className: 'text-right', width: 180 }, { title: '账户总余额', render: 'availableBalance', className: 'text-right', width: 180 },
{ title: '创建时间', index: 'createTime', type: 'date', width: 150 }, { title: '创建时间', index: 'createTime', type: 'date', width: 150 },
{ title: '状态', index: 'stateDeletedLabel', width: 120 },
{ {
title: '操作', title: '操作',
width: 120, width: 120,

View File

@ -80,7 +80,7 @@ export class FreightAccountComponent implements OnInit {
} }
exportList() { exportList() {
this.service.downloadFile(this.service.$mock_url, { ...this.sf.value, pageSize: -1 }); this.service.asyncExport({ ...this.sf.value, pageSize: -1 }, this.service.$api_export_shipper);
} }
private initSF(): SFSchema { private initSF(): SFSchema {

View File

@ -8,7 +8,7 @@
[ui]="{ '*': { spanLabelFixed: 110,grid: { lg: 8, md: 12, sm: 12, xs: 24 } }}" [compact]="true" [ui]="{ '*': { spanLabelFixed: 110,grid: { lg: 8, md: 12, sm: 12, xs: 24 } }}" [compact]="true"
[button]="'none'"></sf> [button]="'none'"></sf>
</div> </div>
<div nz-col [nzXl]="_$expand ? 24 : 7" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right"> <div nz-col [nzXl]="_$expand ? 24 : 7" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right" [class.expend-options]="_$expand">
<button nz-button nzType="primary" [nzLoading]="false" (click)="st?.load(1)">查询</button> <button nz-button nzType="primary" [nzLoading]="false" (click)="st?.load(1)">查询</button>
<button nz-button (click)="resetSF()">重置</button> <button nz-button (click)="resetSF()">重置</button>
<!-- <button nz-button nzType="primary" > 导出</button> <!-- <button nz-button nzType="primary" > 导出</button>

View File

@ -196,15 +196,15 @@ export class PaymentOrderComponent implements OnInit {
} }
} }
}, },
feeCode: { // feeCode: {
type: 'string', // type: 'string',
title: '费用号', // title: '费用号',
ui: { // ui: {
visibleIf: { // visibleIf: {
expand: (value: boolean) => value // expand: (value: boolean) => value
} // }
} // }
}, // },
createTime: { createTime: {
title: '创建时间', title: '创建时间',
type: 'string', type: 'string',
@ -235,6 +235,8 @@ export class PaymentOrderComponent implements OnInit {
{ title: '', index: 'key', type: 'checkbox', fixed: 'left', className: 'text-center' }, { title: '', index: 'key', type: 'checkbox', fixed: 'left', className: 'text-center' },
{ title: '付款单号', index: 'payCode', type: 'link', width: 180 }, { title: '付款单号', index: 'payCode', type: 'link', width: 180 },
{ title: '网络货运人', index: 'ltdName', width: 180 }, { title: '网络货运人', index: 'ltdName', width: 180 },
{ title: '运单号', index: 'waybillCode', width: 180 },
// { title: '费用号', index: 'feeCode', width: 180 },
{ title: '要求付款日期', index: 'payDate', type: 'date', className: 'text-center', width: 150 }, { title: '要求付款日期', index: 'payDate', type: 'date', className: 'text-center', width: 150 },
{ {
title: '付款金额', title: '付款金额',

View File

@ -16,7 +16,7 @@
<sf #sf [schema]="searchSchema" [ui]="{ '*': { spanLabelFixed: 110, grid: { lg: 8, md: 12, sm: 12, xs: 24 } } }" <sf #sf [schema]="searchSchema" [ui]="{ '*': { spanLabelFixed: 110, grid: { lg: 8, md: 12, sm: 12, xs: 24 } } }"
[compact]="true" [button]="'none'"></sf> [compact]="true" [button]="'none'"></sf>
</div> </div>
<div nz-col [nzXl]="_$expand ? 24 : 7" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right"> <div nz-col [nzXl]="_$expand ? 24 : 7" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right" [class.expend-options]="_$expand">
<button nz-button nzType="primary" [nzLoading]="false" (click)="st?.load(1)">查询</button> <button nz-button nzType="primary" [nzLoading]="false" (click)="st?.load(1)">查询</button>
<button nz-button (click)="resetSF()">重置</button> <button nz-button (click)="resetSF()">重置</button>
<!-- <button nz-button nzType="primary"> 导出</button> <!-- <button nz-button nzType="primary"> 导出</button>

View File

@ -9,7 +9,7 @@ import { FreightAccountService } from '../../services/freight-account.service';
@Component({ @Component({
selector: 'app-receipt-order', selector: 'app-receipt-order',
templateUrl: './receipt-order.component.html', templateUrl: './receipt-order.component.html',
styleUrls: ['../../../commom/less/box.less'] styleUrls: ['../../../commom/less/box.less', '../../../commom/less/expend-but.less']
}) })
export class ReceiptOrderComponent implements OnInit { export class ReceiptOrderComponent implements OnInit {
@ViewChild('st', { static: true }) @ViewChild('st', { static: true })
@ -151,9 +151,11 @@ export class ReceiptOrderComponent implements OnInit {
title: '付款人', title: '付款人',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', serverSearch: true,
searchDebounceTime: 300,
searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
asyncData: () => this.service.getCRM(), onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q }),
visibleIf: { visibleIf: {
expand: (value: boolean) => value expand: (value: boolean) => value
} }
@ -193,26 +195,26 @@ export class ReceiptOrderComponent implements OnInit {
} }
} as SFDateWidgetSchema } as SFDateWidgetSchema
}, },
billHCode: { // billHCode: {
type: 'string', // type: 'string',
title: '订单号', // title: '订单号',
ui: { // ui: {
placeholder: '请输入', // placeholder: '请输入',
visibleIf: { // visibleIf: {
expand: (value: boolean) => value // expand: (value: boolean) => value
} // }
} // }
}, // },
feeHCodes: { // feeHCodes: {
type: 'string', // type: 'string',
title: '费用号', // title: '费用号',
ui: { // ui: {
placeholder: '请输入', // placeholder: '请输入',
visibleIf: { // visibleIf: {
expand: (value: boolean) => value // expand: (value: boolean) => value
} // }
} // }
}, // },
remarks: { remarks: {
type: 'string', type: 'string',
title: '付款备注', title: '付款备注',
@ -231,6 +233,8 @@ export class ReceiptOrderComponent implements OnInit {
return [ return [
{ title: '', index: 'key', type: 'checkbox', width: 60, fixed: 'left', className: 'text-center' }, { title: '', index: 'key', type: 'checkbox', width: 60, fixed: 'left', className: 'text-center' },
{ title: '收款单号', index: 'brmcode', type: 'link', width: 180, className: 'text-left' }, { title: '收款单号', index: 'brmcode', type: 'link', width: 180, className: 'text-left' },
// { title: '订单号', index: 'billHCode', width: 180, className: 'text-left' },
// { title: '费用号', index: 'feeCode', width: 180, className: 'text-left' },
{ title: '网络货运人', index: 'ltdName', width: 200, className: 'text-left' }, { title: '网络货运人', index: 'ltdName', width: 200, className: 'text-left' },
{ title: '到账日期', index: 'brmdate', type: 'date', width: 200, className: 'text-left' }, { title: '到账日期', index: 'brmdate', type: 'date', width: 200, className: 'text-left' },
{ title: '收款账户', index: 'ltdaccountId', width: 200, className: 'text-left' }, { title: '收款账户', index: 'ltdaccountId', width: 200, className: 'text-left' },

View File

@ -29,9 +29,9 @@
<se label="付款人" required> <se label="付款人" required>
{{headerInfo?.artoname}} {{headerInfo?.artoname}}
</se> </se>
<se label="付款账户" required> <!-- <se label="付款账户" required>
{{headerInfo?.artocode}} {{headerInfo?.artocode}}
</se> </se> -->
<se label="应收金额"> <se label="应收金额">
{{headerInfo?.armoney | currency}} {{headerInfo?.armoney | currency}}
</se> </se>

View File

@ -119,9 +119,9 @@ export class ReceivableOrderComponent implements OnInit {
brmtype: { brmtype: {
type: 'string', type: 'string',
title: '收款类型', title: '收款类型',
enum: [{ value: '1', label: '费用款项' }],
ui: { ui: {
widget: 'select', widget: 'dict-select',
params: { dictKey: 'driverrecord:receive:type' },
placeholder: '请选择', placeholder: '请选择',
visibleIf: { visibleIf: {
expand: (value: boolean) => value expand: (value: boolean) => value
@ -131,9 +131,9 @@ export class ReceivableOrderComponent implements OnInit {
arvattype: { arvattype: {
type: 'string', type: 'string',
title: '付款类型', title: '付款类型',
enum: [{ value: '1', label: '费用款项' }],
ui: { ui: {
widget: 'select', widget: 'dict-select',
params: { dictKey: 'pay:type' },
placeholder: '请选择', placeholder: '请选择',
visibleIf: { visibleIf: {
expand: (value: boolean) => value expand: (value: boolean) => value
@ -158,9 +158,11 @@ export class ReceivableOrderComponent implements OnInit {
title: '付款人', title: '付款人',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', serverSearch: true,
searchDebounceTime: 300,
searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
asyncData: () => this.service.getCRM(), onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q }),
visibleIf: { visibleIf: {
expand: (value: boolean) => value expand: (value: boolean) => value
} }
@ -181,6 +183,23 @@ export class ReceivableOrderComponent implements OnInit {
} }
} }
}, },
banktype: {
type: 'string',
title: '银行类型',
enum: [
{ label: '全部', value: '' },
{ label: '平安银行', value: '1' },
{ label: '浦发银行', value: '2' }
],
ui: {
widget: 'select',
placeholder: '请选择',
visibleIf: {
expand: (value: boolean) => value
}
},
default: ''
},
ahxdate: { ahxdate: {
title: '核销日期', title: '核销日期',
type: 'string', type: 'string',
@ -213,16 +232,16 @@ export class ReceivableOrderComponent implements OnInit {
} }
} }
}, },
orderS3: { // orderS3: {
type: 'string', // type: 'string',
title: '费用号', // title: '费用号',
ui: { // ui: {
placeholder: '请输入', // placeholder: '请输入',
visibleIf: { // visibleIf: {
expand: (value: boolean) => value // expand: (value: boolean) => value
} // }
} // }
}, // },
remarks: { remarks: {
type: 'string', type: 'string',
title: '核销备注', title: '核销备注',
@ -242,9 +261,9 @@ export class ReceivableOrderComponent implements OnInit {
return [ return [
{ title: '', index: 'key', type: 'checkbox' }, { title: '', index: 'key', type: 'checkbox' },
{ title: '核销单号', index: 'ahxcode', type: 'link', width: 140 }, { title: '核销单号', index: 'ahxcode', type: 'link', width: 140 },
{ title: '订单号', index: 'billHCode', type: 'link', width: 140 },
{ title: '网络货运人', index: 'ltdName', width: 160 }, { title: '网络货运人', index: 'ltdName', width: 160 },
{ title: '核销日期', index: 'ahxdate', type: 'date', width: 160 }, { title: '核销日期', index: 'ahxdate', type: 'date', width: 160 },
{ title: '付款账户', index: 'shipperaccount', width: 170 },
{ title: '收款账户', index: 'ltdaccountId', width: 160 }, { title: '收款账户', index: 'ltdaccountId', width: 160 },
{ title: '核销类型', index: 'ahxType', type: 'enum', enum: { '1': '预收款' }, width: 120 }, { title: '核销类型', index: 'ahxType', type: 'enum', enum: { '1': '预收款' }, width: 120 },
{ {
@ -264,6 +283,7 @@ export class ReceivableOrderComponent implements OnInit {
{ title: '银行类型', index: 'banktype', type: 'enum', enum: { '1': '平安', '2': '浦发' }, width: 120 }, { title: '银行类型', index: 'banktype', type: 'enum', enum: { '1': '平安', '2': '浦发' }, width: 120 },
{ title: '收款类型', index: 'arvattype', type: 'enum', enum: { '1': '费用款项' }, width: 120 }, { title: '收款类型', index: 'arvattype', type: 'enum', enum: { '1': '费用款项' }, width: 120 },
{ title: '付款人', index: 'artoname', width: 200 }, { title: '付款人', index: 'artoname', width: 200 },
{ title: '付款账户', index: 'shipperaccount', width: 170 },
{ title: '结算客户', index: 'cnoName', width: 120 }, { title: '结算客户', index: 'cnoName', width: 120 },
{ title: '银行水单', index: 'bankreceipt', width: 200 }, { title: '银行水单', index: 'bankreceipt', width: 200 },
{ title: '创建时间', index: 'createTime', width: 180 }, { title: '创建时间', index: 'createTime', width: 180 },

View File

@ -190,7 +190,8 @@ export class RechargeRecordComponent implements OnInit {
rmYll: item.roleId, rmYll: item.roleId,
snglFlgCd: item.paySerialNumber2, snglFlgCd: item.paySerialNumber2,
bussType: '06', bussType: '06',
ltdId: item.ltdId ltdId: item.ltdId,
accountType: item.accountType
}) })
} }
] ]

View File

@ -35,7 +35,7 @@ export class TransactionFlowComponent {
Object.assign(requestOptions.body, { Object.assign(requestOptions.body, {
...this.sf.value, ...this.sf.value,
createTime: { createTime: {
start: this.sf.value.tcreateTimeime?.[0] || '', start: this.sf.value.createTime?.[0] || '',
end: this.sf.value.createTime?.[1] || '' end: this.sf.value.createTime?.[1] || ''
} }
}); });
@ -120,9 +120,9 @@ export class TransactionFlowComponent {
type: 'string', type: 'string',
title: '收支类型', title: '收支类型',
enum: [ enum: [
{ label: '全部', value: '' }, { label: '全部', value: '' },
{ label: '收入', value: 1 }, { label: '收入', value: 2 },
{ label: '支出', value: 2 } { label: '支出', value: 1 }
], ],
ui: { ui: {
widget: 'select', widget: 'select',
@ -253,7 +253,8 @@ export class TransactionFlowComponent {
rmYll: item.roleId, rmYll: item.roleId,
snglFlgCd: item.channelPaySn, snglFlgCd: item.channelPaySn,
bussType: item.tradeType === '7' ? '05' : item.tradeType === '8' ? '06' : '07', bussType: item.tradeType === '7' ? '05' : item.tradeType === '8' ? '06' : '07',
ltdId: item.ltdId ltdId: item.ltdId,
accountType: item.accountType
}) })
} }
] ]

View File

@ -54,10 +54,56 @@
</se> </se>
</div> </div>
<nz-alert nzType="info" nzMessage="提现进度" class="mb-md mt-md"></nz-alert> <nz-tabset class="mt-md">
<div nz-row class="mt-xl"> <nz-tab nzTitle="提现明细" *ngIf="accountType === '2'">
<div nz-col nzSpan="12" nzOffset="1"> <div nz-row nzGutter="8">
<app-logistics-time-line [data]="timeLineData"></app-logistics-time-line> <div nz-col [nzXl]="_$expand ? 24 : 18" [nzLg]="24" [nzSm]="24" [nzXs]="24">
</div> <sf #sf [schema]="inputSearchSchema"
</div> [ui]="{ '*': { spanLabelFixed: 110,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="text-right">
<button nz-button nzType="primary" [nzLoading]="false" (click)="inputST?.load(1)">查询</button>
<button nz-button (click)="resetInputSF()">重置</button>
<button nz-button> 导出</button>
<button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
</button>
</div>
</div>
<st #inputST [data]="service.$api_get_refund_detail_page" [columns]="columns" [page]="{ }"
[req]="{ process: beforeReq }" [loading]="false" [scroll]="{ x: '1200px', y: '370px' }" class="mt-md">
<ng-template st-row="amountDetails" let-item let-index="index" let-column="column">
<ng-container *ngFor="let detail of item.amountDetails">
{{detail.costName}}:{{detail.price |currency}}
</ng-container>
</ng-template>
<ng-template st-row="billId" let-item let-index="index" let-column="column">
{{item.billCode}}<br>
{{item.billStatus}}<br>
</ng-template>
<ng-template st-row="wayBillId" let-item let-index="index" let-column="column">
{{item.wayBillCode}}<br>
{{item.wayBillStatus}}<br>
</ng-template>
<ng-template st-row="driverId" let-item let-index="index" let-column="column">
{{item.driverName}}<br>
{{item.driverTelephone}}<br>
{{item.driverLicencePlate}}<br>
</ng-template>
<ng-template st-row="captainName" let-item let-index="index" let-column="column">
{{item.captainName}}<br>
{{item.captainTelephone}}<br>
</ng-template>
</st>
</nz-tab>
<nz-tab nzTitle="提现进度">
<div nz-row class="mt-xl">
<div nz-col nzSpan="12" nzOffset="1">
<app-logistics-time-line [data]="timeLineData"></app-logistics-time-line>
</div>
</div>
</nz-tab>
</nz-tabset>
</nz-card> </nz-card>

View File

@ -5,13 +5,19 @@
border : 1px solid #dbdbdb; border : 1px solid #dbdbdb;
.ant-alert-message { .ant-alert-message {
color: rgba(0, 0, 0, 0.85); color : rgba(0, 0, 0, 0.85);
font-weight: 600; font-weight: 600;
font-size: 16px; font-size : 16px;
} }
} }
.ant-form-item { .ant-form-item {
margin-bottom: 15px; margin-bottom: 15px;
} }
nz-tabs-nav {
background-color: #f3f3f3;
border : 1px solid #dbdbdb;
padding-left : 18px;
}
} }

View File

@ -1,5 +1,7 @@
import { Component, OnInit } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute } from '@angular/router'; import { ActivatedRoute } from '@angular/router';
import { STColumn, STRequestOptions } from '@delon/abc/st';
import { SFComponent, SFSchema } from '@delon/form';
import { FreightAccountService } from '../../../services/freight-account.service'; import { FreightAccountService } from '../../../services/freight-account.service';
@Component({ @Component({
@ -8,17 +10,38 @@ import { FreightAccountService } from '../../../services/freight-account.service
styleUrls: ['./withdrawals-detail.component.less'] styleUrls: ['./withdrawals-detail.component.less']
}) })
export class WithdrawalsDetailComponent implements OnInit { export class WithdrawalsDetailComponent implements OnInit {
@ViewChild('st', { static: true })
st!: Component;
@ViewChild('sf', { static: false })
inputSF!: SFComponent;
columns: STColumn[] = this.initST();
inputSearchSchema: SFSchema = this.initInputSF();
_$expand = false;
formData: any = {}; formData: any = {};
timeLineData: any = []; timeLineData: any = [];
accountType = '1';
constructor(public service: FreightAccountService, private route: ActivatedRoute) { constructor(public service: FreightAccountService, private route: ActivatedRoute) {
const id = route.snapshot.params.id; const id = route.snapshot.params.id;
this.accountType = route.snapshot.queryParams.type;
this.loadRefundDetail(id); this.loadRefundDetail(id);
} }
ngOnInit(): void {} ngOnInit(): void {}
beforeReq = (requestOptions: STRequestOptions) => {
if (this.inputSF?.value) {
Object.assign(requestOptions.body, {
...this.inputSF.value
});
}
Object.assign(requestOptions.body, { refundApplicationId: this.route.snapshot.params.id });
return requestOptions;
};
loadRefundDetail(id: string) { loadRefundDetail(id: string) {
this.service.request(this.service.$api_get_refund_detail, { id }).subscribe(res => { this.service.request(this.service.$api_get_refund_detail, { id }).subscribe(res => {
if (res) { if (res) {
@ -76,11 +99,143 @@ export class WithdrawalsDetailComponent implements OnInit {
rmYll: this.formData.userId, rmYll: this.formData.userId,
snglFlgCd: this.formData.coreSerNo, snglFlgCd: this.formData.coreSerNo,
bussType: '06', bussType: '06',
ltdId: this.formData.ltdId ltdId: this.formData.ltdId,
accountType: this.formData.accountType
}); });
} }
/**
* 重置表单
*/
resetInputSF() {
this.inputSF.reset();
}
/**
* 伸缩查询条件
*/
expandToggle() {
this._$expand = !this._$expand;
this.inputSF?.setValue('/expand', this._$expand);
}
goBack() { goBack() {
history.go(-1); history.go(-1);
} }
private initInputSF(): SFSchema {
return {
properties: {
expand: {
type: 'boolean',
ui: {
hidden: true
}
},
billHCode: {
type: 'string',
title: '支付编号',
ui: {
placeholder: '请输入'
}
},
billHCod1e: {
type: 'string',
title: '订单号',
ui: {
placeholder: '请输入'
}
},
billHCo1de: {
type: 'string',
title: '货源编号',
ui: {
placeholder: '请输入'
}
},
billHC1ode: {
type: 'string',
title: '服务类型',
ui: {
widget: 'select',
placeholder: '请选择',
visibleIf: {
expand: (value: boolean) => value
}
}
},
billHCo11de: {
type: 'string',
title: '承运司机',
ui: {
placeholder: '请输入司机姓名/手机号',
visibleIf: {
expand: (value: boolean) => value
}
}
},
billHCo111de: {
type: 'string',
title: '车牌号',
ui: {
placeholder: '请输入',
visibleIf: {
expand: (value: boolean) => value
}
}
},
billHC1o11de: {
type: 'string',
title: '收款人',
ui: {
placeholder: '请输入收款人姓名/手机号',
visibleIf: {
expand: (value: boolean) => value
}
}
},
billHC1o111de: {
type: 'string',
title: '车队长收款',
ui: {
widget: 'select',
placeholder: '请选择',
visibleIf: {
expand: (value: boolean) => value
}
}
}
}
};
}
private initST(): STColumn[] {
return [
{ title: '支付编号', index: 'orderPaymentCode', className: 'text-left', width: 200 },
{
title: '支付金额',
index: 'payAmount',
type: 'widget',
className: 'text-right',
widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.payAmount }) },
width: 140
},
{ title: '运费明细', render: 'amountDetails', className: 'text-center', width: 150 },
{ title: '货主', index: 'ltdName', className: 'text-center', width: 200 },
{ title: '订单号', render: 'billId', className: 'text-center', width: 150 },
{ title: '运单号', render: 'wayBillId', className: 'text-center', width: 150 },
{ title: '货源编号', index: 'resourceCode', className: 'text-center', width: 150 },
{
title: '服务类型',
index: 'serviceType',
className: 'text-center',
width: 150,
type: 'enum',
enum: { '1': '抢单', '2': '指派', '3': '二维码', '4': '手工单' }
},
{ title: '承运司机', render: 'driverId', className: 'text-center', width: 150 },
{ title: '收款人', render: 'captainName', className: 'text-center', width: 150 },
{ title: '银行类型', index: 'bankType', className: 'text-center', width: 150 }
];
}
} }

View File

@ -28,9 +28,9 @@ export class WithdrawalsRecordComponent {
refundStatus: any = ''; refundStatus: any = '';
msg = ''; msg = '';
constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) { } constructor(public service: FreightAccountService, private nzModalService: NzModalService, private router: Router) {}
ngOnInit(): void { } ngOnInit(): void {}
beforeReq = (requestOptions: STRequestOptions) => { beforeReq = (requestOptions: STRequestOptions) => {
if (this.sf) { if (this.sf) {
@ -254,7 +254,7 @@ export class WithdrawalsRecordComponent {
{ title: '提现单号', index: 'refundApplyCode', width: 120 }, { title: '提现单号', index: 'refundApplyCode', width: 120 },
{ title: '网络货运人', index: 'ltdName', width: 140 }, { title: '网络货运人', index: 'ltdName', width: 140 },
{ title: '银行类型', index: 'bankTypeLabel', width: 100 }, { title: '银行类型', index: 'bankTypeLabel', width: 100 },
{ title: '账户类型', index: 'bankTypeLabel', width: 100 }, { title: '账户类型', index: 'accountTypeLabel', width: 100 },
{ title: '账户名称', index: 'bankAccountName', width: 140 }, { title: '账户名称', index: 'bankAccountName', width: 140 },
{ title: '虚拟账户', index: 'virtualAccount', width: 100 }, { title: '虚拟账户', index: 'virtualAccount', width: 100 },
{ {
@ -276,6 +276,18 @@ export class WithdrawalsRecordComponent {
width: '110px', width: '110px',
className: 'text-center', className: 'text-center',
buttons: [ buttons: [
{
text: '审核',
iif: item => item.refundStatus === '1',
click: item => this.auditAction(item)
},
{
text: '详情<br>',
click: item =>
this.router.navigate([`/financial-management/withdrawals-record/detail/${item.id}`], {
queryParams: { type: item.accountType }
})
},
{ {
text: '查看回单', text: '查看回单',
iif: item => item.refundStatus === '3', iif: item => item.refundStatus === '3',
@ -285,17 +297,9 @@ export class WithdrawalsRecordComponent {
rmYll: item.userId, rmYll: item.userId,
snglFlgCd: item.coreSerNo, snglFlgCd: item.coreSerNo,
bussType: '06', bussType: '06',
ltdId: item.ltdId ltdId: item.ltdId,
accountType: item.accountType
}) })
},
{
text: '审核',
iif: item => item.refundStatus === '1',
click: item => this.auditAction(item)
},
{
text: '详情',
click: item => this.router.navigate([`/financial-management/withdrawals-record/detail/${item.id}`])
} }
] ]
} }

View File

@ -42,6 +42,8 @@ export class FreightAccountService extends ShipperBaseService {
// 货主端获取账户余额交易明细 // 货主端获取账户余额交易明细
$api_get_balance_by_shipper = '/api/fcc/accountBalanceDetail/getAccountBalanceByShipperPage'; $api_get_balance_by_shipper = '/api/fcc/accountBalanceDetail/getAccountBalanceByShipperPage';
// 运营端导出货主账户明细信息
$api_export_shipper = '/api/fcc/accountBalance/reportShipperAccountBalanceByOperator';
// 查询订单支付申请表 // 查询订单支付申请表
$api_get_order_payment_page = '/api/fcc/billPaymentApplicationOBC/list/page'; $api_get_order_payment_page = '/api/fcc/billPaymentApplicationOBC/list/page';
@ -50,6 +52,8 @@ export class FreightAccountService extends ShipperBaseService {
$api_get_refund_page = '/api/fcc/refundApplicationOBC/list/page'; $api_get_refund_page = '/api/fcc/refundApplicationOBC/list/page';
// 获取提现申请表详情 // 获取提现申请表详情
$api_get_refund_detail = '/api/fcc/refundApplicationOBC/get'; $api_get_refund_detail = '/api/fcc/refundApplicationOBC/get';
// 获取提现支付详情
$api_get_refund_detail_page = '/api/fcc/refundApplicationOBC/get/payList';
// 同意提现 // 同意提现
$api_agree_refund = '/api/fcc/refundApplicationOBC/agreeRefund'; $api_agree_refund = '/api/fcc/refundApplicationOBC/agreeRefund';
// 拒绝提现 // 拒绝提现

View File

@ -233,7 +233,7 @@ export class insuranceManagementListComponent implements OnInit {
title: '所属项目', title: '所属项目',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', placeholder: '请选择货主',
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
}, },

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-06 20:20:26 * @Date : 2021-12-06 20:20:26
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-23 14:43:34 * @LastEditTime : 2022-03-24 14:08:55
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk-detail\\bulk-detail.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk-detail\\bulk-detail.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->

View File

@ -35,7 +35,7 @@
<button nz-button nzType="primary" [nzLoading]="loading" (click)="search()" acl [acl-ability]="['ORDER-BULK-search']" <button nz-button nzType="primary" [nzLoading]="loading" (click)="search()" acl [acl-ability]="['ORDER-BULK-search']"
>查询</button >查询</button
> >
<button nz-button nzType="primary" [disabled]="loading">导出</button> <button nz-button nzType="primary" [disabled]="loading" (click)="exprot()">导出</button>
<button nz-button [disabled]="loading" (click)="resetSF()">重置</button> <button nz-button [disabled]="loading" (click)="resetSF()">重置</button>
<button nz-button nzType="link" (click)="expandToggle()"> <button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }} {{ !_$expand ? '展开' : '收起' }}

View File

@ -88,6 +88,8 @@ export class OrderManagementBulkComponent implements OnInit {
} }
const params: any = Object.assign({}, this.sf?.value || {}); const params: any = Object.assign({}, this.sf?.value || {});
delete params._$expand; delete params._$expand;
console.log(params);
if (this.sf) { if (this.sf) {
Object.assign(requestOptions.body, { Object.assign(requestOptions.body, {
...a, ...a,
@ -186,6 +188,13 @@ export class OrderManagementBulkComponent implements OnInit {
placeholder: '最多100个单号空号隔开', placeholder: '最多100个单号空号隔开',
} }
}, },
wayBillCode: {
type: 'string',
title: '运单号',
ui: {
placeholder: '最多100个单号空号隔开',
}
},
resourceCode: { resourceCode: {
type: 'string', type: 'string',
title: '货源编号' title: '货源编号'
@ -199,6 +208,9 @@ export class OrderManagementBulkComponent implements OnInit {
searchDebounceTime: 300, searchDebounceTime: 300,
searchLoadingText: '搜索中...', searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
visibleIf: {
_$expand: (value: boolean) => value
},
onSearch: (q: any) => { onSearch: (q: any) => {
let str =q.replace(/^\s+|\s+$/g,""); let str =q.replace(/^\s+|\s+$/g,"");
if (str) { if (str) {
@ -220,7 +232,7 @@ export class OrderManagementBulkComponent implements OnInit {
title: '所属项目', title: '所属项目',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', placeholder: '请选择货主',
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
}, },
@ -457,10 +469,10 @@ export class OrderManagementBulkComponent implements OnInit {
width: '180px', width: '180px',
className: 'text-left', className: 'text-left',
format: (item: any) => format: (item: any) =>
`${item.goodsName}/ `${item?.goodsName}/
${item.goodsWeight || '0'}吨/ ${item?.weight || '0'}吨/
${item.goodsVolume || '0'}方/ ${item?.volume || '0'}方/
${item.goodsNumber || '0'}` ${item?.goodsNumber || '0'}`
}, },
{ {
title: '运费单价', title: '运费单价',
@ -474,8 +486,8 @@ export class OrderManagementBulkComponent implements OnInit {
width: '170px', width: '170px',
className: 'text-left', className: 'text-left',
format: (item: any) => format: (item: any) =>
`${item.acceptWeight || '0'}吨/ `${item.loadWeight || '0'}吨/
${item.acceptVolume || '0'}` ${item.loadVolume || '0'}`
}, },
{ {
title: '结算数量', title: '结算数量',
@ -837,4 +849,12 @@ export class OrderManagementBulkComponent implements OnInit {
} }
}); });
} }
// 导出
exprot() {
this.service.request(this.service.$api_get_asyncExportBulkList, this.reqParams).subscribe((res: any) => {
if (res) {
this.service.msgSrv.success('导出成功,请去下载中心下载!');
}
});
}
} }

View File

@ -172,6 +172,10 @@ export class OrderManagementComplaintDetailComponent implements OnInit {
查看评价: 3 查看评价: 3
*/ */
handleCancel(type: string) { handleCancel(type: string) {
if(!this.sfView.valid) {
this.service.msgSrv.error('请填写处理结果!')
return
}
const paramsa = { const paramsa = {
...this.sfView.value, ...this.sfView.value,
handleStatus: 0, handleStatus: 0,
@ -193,6 +197,10 @@ export class OrderManagementComplaintDetailComponent implements OnInit {
this.isVisibleRE = false this.isVisibleRE = false
} }
handleCancel2() { handleCancel2() {
if(!this.sfView.valid) {
this.service.msgSrv.error('请填写处理结果!')
return
}
const paramsa = { const paramsa = {
id: this.channelId id: this.channelId
} }
@ -212,6 +220,10 @@ export class OrderManagementComplaintDetailComponent implements OnInit {
* 审核通过按钮 * 审核通过按钮
*/ */
handleOK() { handleOK() {
if(!this.sfView.valid) {
this.service.msgSrv.error('请填写处理结果!')
return
}
const paramsa = { const paramsa = {
...this.sfView.value, ...this.sfView.value,
handleStatus: 1, handleStatus: 1,

View File

@ -71,15 +71,13 @@ export class OrderManagementComplaintComponent implements OnInit {
if(this.selectedMainTabStatus) { if(this.selectedMainTabStatus) {
a.complaintType = this.selectedMainTabStatus a.complaintType = this.selectedMainTabStatus
} }
console.log( this.sf?.value);
const params: any = Object.assign({}, this.sf?.value || {}); const params: any = Object.assign({}, this.sf?.value || {});
delete params._$expand; delete params._$expand;
return { return {
...a, ...a,
...params, ...params,
complainantTime: {
start: this.sf?.value?.complainantTime?.[0] || '',
end: this.sf?.value?.complainantTime?.[1] || ''
}
}; };
} }
get selectedRows() { get selectedRows() {
@ -103,14 +101,19 @@ export class OrderManagementComplaintComponent implements OnInit {
type: 'string', type: 'string',
title: '投诉单号', title: '投诉单号',
}, },
complainantTime: { complaintCause: {
title: '投诉时间', title: '投诉原因',
type: 'string', type: 'string',
ui: { ui: {
widget: 'date', widget: 'dict-select',
mode: 'range', params: { dictKey: 'complaint:cause' },
format: 'yyyy-MM-dd', containsAllLabel: true,
} as SFDateWidgetSchema, } as SFSelectWidgetSchema
},
complainantTime: {
type: 'string',
title: '投诉时间',
ui: { widget: 'sl-from-to', type: 'date', format: 'yyyy-MM-dd' } as SFDateWidgetSchema,
}, },
}, },
}; };
@ -124,14 +127,14 @@ export class OrderManagementComplaintComponent implements OnInit {
this.columns = [ this.columns = [
{ {
title: '投诉单号', title: '投诉单号',
width: '170px', width: '200px',
fixed: 'left', fixed: 'left',
className: 'text-center', className: 'text-center',
render: 'complaintCode' render: 'complaintCode'
}, },
{ {
title: '运单号', title: '运单号',
width: '170px', width: '200px',
className: 'text-center', className: 'text-center',
index: 'wayBillCode' index: 'wayBillCode'
}, },
@ -161,6 +164,12 @@ export class OrderManagementComplaintComponent implements OnInit {
width: '200px', width: '200px',
index:'handlePartyLabel' index:'handlePartyLabel'
}, },
{
title: '处理时间',
className: 'text-center',
width: '200px',
index:'handleTime'
},
{ {
title: '处理结果', title: '处理结果',
className: 'text-center', className: 'text-center',
@ -237,7 +246,6 @@ export class OrderManagementComplaintComponent implements OnInit {
*/ */
resetSF(): void { resetSF(): void {
this.sf.reset(); this.sf.reset();
this._$expand = false;
} }
selectChange(e: number) { selectChange(e: number) {
this.resourceStatus = e; this.resourceStatus = e;

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-12 10:52:50 * @Date : 2022-01-12 10:52:50
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-23 13:34:31 * @LastEditTime : 2022-03-25 13:44:42
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\compliance-audit\\compliance-audit.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\compliance-audit\\compliance-audit.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -87,13 +87,15 @@
<div> {{ item?.payeeName }}/{{ item?.payeePhone }} </div> <div> {{ item?.payeeName }}/{{ item?.payeePhone }} </div>
</ng-template> </ng-template>
<ng-template st-row="billCode" let-item let-index="index"> <ng-template st-row="billCode" let-item let-index="index">
<div>{{ item.billCode }}</div> <a *ngIf="item.billType == '1'" [routerLink]="'/order-management/vehicle/vehicle-detail/' + item.id">{{ item.billCode }}</a>
<div> <a *ngIf="item.billType == '2'" [routerLink]="'/order-management/bulk/bulk-detail/' + item.id">{{ item.billCode }}</a>
<span>{{ item?.resourceTypeLabel }}{{ item?.serviceTypeLabel }}</span> <a *ngIf="item.billType == '3'" [routerLink]="'/order-management/vehicle/vehicle-detail/' + item.id">{{ item.billCode }}</a>
</div>
<div> <div>
<span>{{ item?.billStatusLabel }}</span> <span>{{ item?.billStatusLabel }}</span>
</div> </div>
<div>
<span >{{item?.billTypeLabel}}{{item?.serviceTypeLabel === item?.billTypeLabel ? '':item?.serviceTypeLabel}}</span>
</div>
</ng-template> </ng-template>
<ng-template st-row="goodsName" let-item let-index="index"> <ng-template st-row="goodsName" let-item let-index="index">
<div>{{ item?.goodsName }}</div> <div>{{ item?.goodsName }}</div>

View File

@ -10,6 +10,7 @@ import { ConfirReceiptComponent } from '../../modal/bulk/confir-receipt/confir-r
import { of } from 'rxjs'; import { of } from 'rxjs';
import { ShipperBaseService } from '@shared'; import { ShipperBaseService } from '@shared';
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { OneCarOrderAppealComponent } from '../../modal/audit/appeal/appeal.component';
@Component({ @Component({
selector: 'app-order-management-compliance-audit', selector: 'app-order-management-compliance-audit',
@ -120,7 +121,6 @@ export class OrderManagementComplianceAuditComponent implements OnInit {
this.initST(); this.initST();
setTimeout(() => { setTimeout(() => {
this.st.load(); this.st.load();
this.getGoodsSourceStatistical();
}, 500); }, 500);
} }
ngOnInit(): void { ngOnInit(): void {
@ -179,7 +179,7 @@ export class OrderManagementComplianceAuditComponent implements OnInit {
title: '所属项目', title: '所属项目',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', placeholder: '请选择货主',
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
}, },
@ -331,6 +331,7 @@ export class OrderManagementComplianceAuditComponent implements OnInit {
{ title: '所属项目', index: 'enterpriseProjectName', width: '220px', className: 'text-left' }, { title: '所属项目', index: 'enterpriseProjectName', width: '220px', className: 'text-left' },
{ title: '关联运单号', index: 'wayBillCode', width: '220px', className: 'text-left' }, { title: '关联运单号', index: 'wayBillCode', width: '220px', className: 'text-left' },
{ title: '货源编号', index: 'resourceCode', width: '180px', className: 'text-left' }, { title: '货源编号', index: 'resourceCode', width: '180px', className: 'text-left' },
{ title: '服务类型', index: 'serviceTypeLabel', width: '180px', className: 'text-left' },
{ title: '装货地', index: 'loadingAddressArr', width: '180px', className: 'text-left' }, { title: '装货地', index: 'loadingAddressArr', width: '180px', className: 'text-left' },
{ {
title: '卸货地', title: '卸货地',
@ -374,13 +375,13 @@ export class OrderManagementComplianceAuditComponent implements OnInit {
title: '审核人', title: '审核人',
width: '180px', width: '180px',
className: 'text-left', className: 'text-left',
index: 'loadingLadingBillFilePath' index: 'complianceName'
}, },
{ {
title: '审核时间', title: '审核时间',
width: '180px', width: '180px',
className: 'text-left', className: 'text-left',
index: 'loadingLadingBillFilePath' index: 'complianceTime'
}, },
{ {
title: '状态', title: '状态',
@ -396,7 +397,7 @@ export class OrderManagementComplianceAuditComponent implements OnInit {
buttons: [ buttons: [
{ {
text: '查看申诉记录', text: '查看申诉记录',
click: _record => console.log('1'), click: _record => this.appeal(_record),
// iif: item => item.billStatus == '5' // iif: item => item.billStatus == '5'
}, },
{ {
@ -488,6 +489,24 @@ export class OrderManagementComplianceAuditComponent implements OnInit {
get queryFieldCount(): number { get queryFieldCount(): number {
return Object.keys(this.schema?.properties || {}).length; return Object.keys(this.schema?.properties || {}).length;
} }
// 申诉记录
appeal(item: any) {
// const modalRef = this.modal.create({
// nzTitle: '申诉',
// nzContent: OneCarOrderAppealComponent,
// nzComponentParams: {
// i: item
// },
// nzFooter: null
// });
// modalRef.afterClose.subscribe((res) => {
// if(res){
// this.resetSF;
// this.st.load();
// }
// });
this.router.navigate(['/order-management/risk-detail', item.id]);
}
/** /**
* 浮动费用查看 * 浮动费用查看
*/ */

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-12 10:52:50 * @Date : 2022-01-12 10:52:50
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-22 17:54:50 * @LastEditTime : 2022-03-25 13:44:11
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\receipts-audit\\receipts-audit.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\receipts-audit\\receipts-audit.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -59,8 +59,8 @@
[scroll]="{ x: '2000px' }" [scroll]="{ x: '2000px' }"
[data]="service.$api_get_billExamine_page" [data]="service.$api_get_billExamine_page"
[columns]="columns" [columns]="columns"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" [req]="{ process: beforeReq }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }" [res]="{ reName: { list: 'data.records', total: 'data.total' } , process: afterRes}"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }" [page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
[loading]="false" [loading]="false"
> >
@ -98,12 +98,15 @@
<div> {{ item?.payeeName }}/{{ item?.payeePhone }} </div> <div> {{ item?.payeeName }}/{{ item?.payeePhone }} </div>
</ng-template> </ng-template>
<ng-template st-row="billCode" let-item let-index="index"> <ng-template st-row="billCode" let-item let-index="index">
<div>{{ item.billCode }}</div> <!-- <div>{{ item.billCode }}</div> -->
<a *ngIf="item.resourceType == '1'" [routerLink]="'/order-management/vehicle/vehicle-detail/' + item.id">{{ item.billCode }}</a>
<a *ngIf="item.resourceType == '2'" [routerLink]="'/order-management/bulk/bulk-detail/' + item.id">{{ item.billCode }}</a>
<a *ngIf="item.resourceType == '3'" [routerLink]="'/order-management/vehicle/vehicle-detail/' + item.id">{{ item.billCode }}</a>
<div> <div>
<span>{{item?.billStatusLabel}}</span> <span>{{item?.billStatusLabel}}</span>
</div> </div>
<div> <div>
<span >{{item?.billTypeLabel}}{{item?.serviceTypeLabel}}</span> <span >{{item?.resourceTypeLabel}}{{item?.serviceTypeLabel === item?.resourceTypeLabel ? '':item?.serviceTypeLabel}}</span>
</div> </div>
</ng-template> </ng-template>
<ng-template st-row="goodsName" let-item let-index="index"> <ng-template st-row="goodsName" let-item let-index="index">
@ -128,7 +131,7 @@
<ng-template #extraTemplate> <ng-template #extraTemplate>
<div> <div>
<button nz-button nzType="primary" (click)="sign('1')" acl [acl-ability]="['ORDER-RECEIPTS-billAuditPassBatch']"> 批量签收 </button> <button nz-button nzType="primary" (click)="sign('1')" acl [acl-ability]="['ORDER-RECEIPTS-billAuditPassBatch']"> 批量通过 </button>
<button nz-button nzType="primary" (click)="sign1('1')" acl [acl-ability]="['ORDER-RECEIPTS- electronicBilling']"> 批量生成电子单据 </button> <button nz-button nzType="primary" (click)="sign1('1')" acl [acl-ability]="['ORDER-RECEIPTS- electronicBilling']"> 批量生成电子单据 </button>
</div> </div>
</ng-template> </ng-template>

View File

@ -1,5 +1,5 @@
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { STColumn, STComponent } from '@delon/abc/st'; import { STColumn, STComponent, STRequestOptions } from '@delon/abc/st';
import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form'; import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
import { ModalHelper, _HttpClient } from '@delon/theme'; import { ModalHelper, _HttpClient } from '@delon/theme';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
@ -30,6 +30,7 @@ export class OrderManagementReceiptsAuditComponent implements OnInit {
@ViewChild('st') private readonly st!: STComponent; @ViewChild('st') private readonly st!: STComponent;
@ViewChild('sf', { static: false }) sf!: SFComponent; @ViewChild('sf', { static: false }) sf!: SFComponent;
columns: STColumn[] = []; columns: STColumn[] = [];
loading: boolean = true;
resourceStatus: any; resourceStatus: any;
tabs = { tabs = {
receivedQuantity: 0, receivedQuantity: 0,
@ -62,6 +63,34 @@ export class OrderManagementReceiptsAuditComponent implements OnInit {
} }
}; };
} }
beforeReq = (requestOptions: STRequestOptions) => {
const a: any = {};
if (this.resourceStatus) {
a.auditStatus = this.resourceStatus;
}
const params: any = Object.assign({}, this.sf?.value || {});
delete params._$expand;
if (this.sf) {
Object.assign(requestOptions.body, {
...a,
...params,
createTime: {
start: this.sf?.value?.createTime?.[0] || '',
end: this.sf?.value?.createTime?.[1] || ''
}
});
}
this.loading = true;
return requestOptions;
};
afterRes = (data: any[], rawData?: any) => {
console.log(data)
this.loading = false
return data.map(item => ({
...item,
// disabled: item.billStatus !== '4'
}));
};
get selectedRows() { get selectedRows() {
return this.st?.list.filter(item => item.checked) || []; return this.st?.list.filter(item => item.checked) || [];
} }
@ -120,6 +149,13 @@ export class OrderManagementReceiptsAuditComponent implements OnInit {
placeholder: '最多100个单号空号隔开' placeholder: '最多100个单号空号隔开'
} }
}, },
wayBillCode: {
type: 'string',
title: '运单号',
ui: {
placeholder: '最多100个运单空号隔开'
}
},
resourceCode: { resourceCode: {
type: 'string', type: 'string',
title: '货源编号' title: '货源编号'
@ -133,6 +169,9 @@ export class OrderManagementReceiptsAuditComponent implements OnInit {
searchDebounceTime: 300, searchDebounceTime: 300,
searchLoadingText: '搜索中...', searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
visibleIf: {
_$expand: (value: boolean) => value
},
onSearch: (q: any) => { onSearch: (q: any) => {
let str =q.replace(/^\s+|\s+$/g,""); let str =q.replace(/^\s+|\s+$/g,"");
if (str) { if (str) {
@ -154,7 +193,7 @@ export class OrderManagementReceiptsAuditComponent implements OnInit {
title: '所属项目', title: '所属项目',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', placeholder: '请选择货主',
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
}, },
@ -243,19 +282,38 @@ export class OrderManagementReceiptsAuditComponent implements OnInit {
} }
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
}, },
settlementBasis: { billStatus: {
title: '装卸凭证', title: '运输状态',
type: 'string', type: 'string',
default: '',
ui: { ui: {
widget: 'dict-select', widget: 'dict-select',
params: { dictKey: 'bill:status' },
containsAllLabel: true, containsAllLabel: true,
params: { dictKey: 'goodresource:settlement:type' },
containAllLable: true,
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
} }
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
} },
loadingDocuments: {
type: 'string',
title: '装卸货凭证',
enum:[
{label: '全部',value: ''},
{label: '无装卸货凭证',value: '1'},
{label: '装卸货凭证齐全',value: '2'},
{label: '只有装货凭证',value: '3'},
{label: '只有卸货凭证',value: '4'},
],
ui: {
widget: 'select',
placeholder: '请选择',
allowClear: true,
visibleIf: {
_$expand: (value: boolean) => value
},
}
},
}, },
type: 'object' type: 'object'
}; };

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-16 10:19:08 * @Date : 2021-12-16 10:19:08
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-23 19:12:19 * @LastEditTime : 2022-03-24 14:12:14
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\risk-detail\\risk-detail.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\risk-detail\\risk-detail.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -21,7 +21,7 @@
<sv label="申诉状态"> <sv label="申诉状态">
<span >{{i?.representationsStatusLabel}}</span> <span >{{i?.representationsStatusLabel}}</span>
</sv> </sv>
<sv label="承运司机">{{i?.driverName ? i?.driverName + '/': ''}} {{i?.driverPhone ?i?.driverPhone + '/': '' }} {{i?.carId}}</sv> <sv label="承运司机">{{i?.driverName ? i?.driverName + '/': ''}} {{i?.driverPhone ?i?.driverPhone + '/': '' }} {{i?.carNo}}</sv>
<sv label="车队长"> {{i?.carCaptainName ? i?.carCaptainName+ '/' : ''}}{{i?.carCaptainPhone}} </sv> <sv label="车队长"> {{i?.carCaptainName ? i?.carCaptainName+ '/' : ''}}{{i?.carCaptainPhone}} </sv>
<sv label="装货时间">{{i?.loadTime}}</sv> <sv label="装货时间">{{i?.loadTime}}</sv>
<sv label="卸货时间">{{i?.unloadTime}}</sv> <sv label="卸货时间">{{i?.unloadTime}}</sv>

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-12 10:52:50 * @Date : 2022-01-12 10:52:50
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-22 09:42:03 * @LastEditTime : 2022-03-24 19:53:19
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\risk\\risk.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\risk\\risk.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -59,13 +59,19 @@
[scroll]="{ x: '2000px' }" [scroll]="{ x: '2000px' }"
[data]="service.$api_get_listRiskPage" [data]="service.$api_get_listRiskPage"
[columns]="columns" [columns]="columns"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" [req]="{ process: beforeReq }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }" [res]="{ reName: { list: 'data.records', total: 'data.total' } , process: afterRes}"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }" [page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
[loading]="false" [loading]="false"
> >
<ng-template st-row="billCode" let-item let-index="index"> <ng-template st-row="billCode" let-item let-index="index">
<a [routerLink]="'/order-management/risk-detail/' + item.id">{{ item?.billCode }}</a> <a [routerLink]="'/order-management/risk-detail/' + item.id">{{ item.billCode }}</a>
<div>
<span>{{ item?.representationsStatusLabel }}</span>
</div>
<div>
<span >{{item?.billTypeLabel}}{{item?.billTypeLabel === item?.serviceTypeLabel ? '' : item?.serviceTypeLabel}}</span>
</div>
</ng-template> </ng-template>
<ng-template st-row="timeer" let-item let-index="index"> <ng-template st-row="timeer" let-item let-index="index">
<p>创建时间:{{ item?.createTime }}</p> <p>创建时间:{{ item?.createTime }}</p>

View File

@ -1,7 +1,7 @@
import { registerLocaleData } from '@angular/common'; import { registerLocaleData } from '@angular/common';
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { STColumn, STComponent } from '@delon/abc/st'; import { STColumn, STComponent, STRequestOptions } from '@delon/abc/st';
import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form'; import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
import { ModalHelper, _HttpClient } from '@delon/theme'; import { ModalHelper, _HttpClient } from '@delon/theme';
import { ShipperBaseService } from '@shared'; import { ShipperBaseService } from '@shared';
@ -21,6 +21,7 @@ export class OrderManagementRiskComponent implements OnInit {
schema: SFSchema = {}; schema: SFSchema = {};
schemaView: SFSchema = {}; schemaView: SFSchema = {};
auditMany = false; auditMany = false;
loading: boolean = true;
auditId: any; auditId: any;
auditIdR: any; auditIdR: any;
isVisibleRE = false; isVisibleRE = false;
@ -47,14 +48,6 @@ export class OrderManagementRiskComponent implements OnInit {
* 查询参数 * 查询参数
*/ */
get reqParams() { get reqParams() {
// const a:any = {};
// if(this.resourceStatus) {
// a.representationsStatus = this.resourceStatus
// }
// return {
// ...a,
// ...this.sf?.value,
// };
const a: any = {}; const a: any = {};
if (this.resourceStatus) { if (this.resourceStatus) {
a.representationsStatus = this.resourceStatus a.representationsStatus = this.resourceStatus
@ -70,6 +63,34 @@ export class OrderManagementRiskComponent implements OnInit {
}, },
}; };
} }
beforeReq = (requestOptions: STRequestOptions) => {
const a: any = {};
if (this.resourceStatus) {
a.representationsStatus = this.resourceStatus
}
const params: any = Object.assign({}, this.sf?.value || {});
delete params._$expand;
if (this.sf) {
Object.assign(requestOptions.body, {
...a,
...params,
createTime: {
start: this.sf?.value?.createTime?.[0] || '',
end: this.sf?.value?.createTime?.[1] || '',
},
});
}
this.loading = true;
return requestOptions;
};
afterRes = (data: any[], rawData?: any) => {
console.log(data)
this.loading = false
return data.map(item => ({
...item,
disabled: item.auditStatus !== '1'
}));
};
search() { search() {
this.st?.load(1); this.st?.load(1);
this.getGoodsSourceStatistical() this.getGoodsSourceStatistical()

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-12 10:52:50 * @Date : 2022-01-12 10:52:50
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-23 10:28:41 * @LastEditTime : 2022-03-28 11:10:20
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle\\vehicle.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle\\vehicle.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -209,7 +209,7 @@
[acl-ability]="['ORDER-VEHICLE-batchSignWholeOrder']"> [acl-ability]="['ORDER-VEHICLE-batchSignWholeOrder']">
批量签收 批量签收
</button> </button>
<button nz-button nzType="primary" [disabled]="loading">导出</button> <button nz-button nzType="primary" [disabled]="loading" (click)="exprot()">导出</button>
<button nz-button nzType="primary" (click)="visible=true;" class="mr-sm">筛选</button> <button nz-button nzType="primary" (click)="visible=true;" class="mr-sm">筛选</button>
</div> </div>
</ng-template> </ng-template>

View File

@ -29,6 +29,7 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
isVisibleEvaluate = false; isVisibleEvaluate = false;
isVisible = false; isVisible = false;
loading: boolean = true; loading: boolean = true;
paramsList: any;
changeId: any; // 主页面查看运费变更记录id - 用于运费变更记录 changeId: any; // 主页面查看运费变更记录id - 用于运费变更记录
changeViewId: any; // 查看运费变更记录id - 用于查看 changeViewId: any; // 查看运费变更记录id - 用于查看
ViewCause: any; // 变更运费查看数据 ViewCause: any; // 变更运费查看数据
@ -97,36 +98,25 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
if (this.resourceStatus) { if (this.resourceStatus) {
a.billStatus = this.resourceStatus; a.billStatus = this.resourceStatus;
} }
const params: any = Object.assign({}, this.sf?.value || {}); const params: any = Object.assign({}, this.sf?.value || this.paramsList);
delete params._$expand; delete params._$expand;
return { return {
...a, ...a,
...params, ...params,
createTime: {
start: this.sf?.value?.createTime?.[0] || '',
end: this.sf?.value?.createTime?.[1] || ''
}
}; };
} }
beforeReq = (requestOptions: STRequestOptions) => { beforeReq = (requestOptions: STRequestOptions) => {
const a: any = {}; const a: any = {};
if (this.resourceStatus) { if (this.resourceStatus) {
a.billStatus = this.resourceStatus; a.billStatus = this.resourceStatus;
Object.assign(requestOptions.body, {
...a
});
} }
const params: any = Object.assign({}, this.sf?.value || {}); const params: any = Object.assign({}, this.sf?.value || this.paramsList);
delete params._$expand; delete params._$expand;
if (this.sf) { this.paramsList = params
Object.assign(requestOptions.body, { Object.assign(requestOptions.body, {
...params, ...a,
createTime: { ...this.paramsList,
start: this.sf?.value?.createTime?.[0] || '',
end: this.sf?.value?.createTime?.[1] || ''
}
}); });
}
this.loading = true; this.loading = true;
return requestOptions; return requestOptions;
}; };
@ -203,6 +193,13 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
placeholder: '最多100个单号空号隔开' placeholder: '最多100个单号空号隔开'
} }
}, },
wayBillCode: {
type: 'string',
title: '运单号',
ui: {
placeholder: '最多100个单号空号隔开',
}
},
resourceCode: { resourceCode: {
type: 'string', type: 'string',
title: '货源编号' title: '货源编号'
@ -237,7 +234,7 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
title: '所属项目', title: '所属项目',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择' placeholder: '请选择货主',
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
}, },
loadingPlace: { loadingPlace: {
@ -275,14 +272,19 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
containsAllLable: true containsAllLable: true
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
}, },
// createTime: {
// title: '创建时间',
// type: 'string',
// ui: {
// widget: 'date',
// mode: 'range',
// format: 'yyyy-MM-dd'
// } as SFDateWidgetSchema
// },
createTime: { createTime: {
title: '创建时间',
type: 'string', type: 'string',
ui: { title: '创建时间',
widget: 'date', ui: { widget: 'sl-from-to', type: 'date', format: 'yyyy-MM-dd' } as SFDateWidgetSchema,
mode: 'range',
format: 'yyyy-MM-dd'
} as SFDateWidgetSchema
}, },
riskStatus: { riskStatus: {
type: 'string', type: 'string',
@ -443,7 +445,7 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
{ {
text: '取消订单', text: '取消订单',
click: _record => this.cancellation(_record), click: _record => this.cancellation(_record),
iif: item => item.billStatus !== '1' && item.billStatus !== '6' && item.overallPaymentStatus !== '2', iif: item => item.billStatus !== '6' && item.overallPaymentStatus !== '2',
acl: { ability: ['ORDER-VEHICLE-cancelAnOrder'] } acl: { ability: ['ORDER-VEHICLE-cancelAnOrder'] }
}, },
{ {
@ -571,7 +573,7 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
this.resourceStatus = e; this.resourceStatus = e;
this.initST(); this.initST();
setTimeout(() => { setTimeout(() => {
this.st.load(1); this.st.load();
}, 500); }, 500);
} }
/** /**
@ -855,4 +857,12 @@ export class OrderManagementVehicleComponent extends BasicTableComponent impleme
} }
}); });
} }
// 导出
exprot() {
this.service.request(this.service.$api_get_asyncExportWholeList, this.reqParams).subscribe((res: any) => {
if (res) {
this.service.msgSrv.success('导出成功,请去下载中心下载!');
}
});
}
} }

View File

@ -0,0 +1,48 @@
<!--
* @Description :
* @Version : 1.0
* @Author : Shiming
* @Date : 2022-03-25 14:10:23
* @LastEditors : Shiming
* @LastEditTime : 2022-03-25 15:59:00
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\audit\\appeal\\appeal.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved.
-->
<nz-spin *ngIf="!i" class="modal-spin"></nz-spin>
<div nz-row>
<sv-container col="1">
<sv label="申诉结果">
{{ dataList?.representationsStatusLabel }}
</sv>
<sv label="异常原因">
<div *ngFor="let item of dataList?.billComplianceVOS; let id=index;">
<div>
{{ item?.complianceName }}
</div>
</div>
</sv>
<sv label="申诉原因">
{{ dataList?.representationsCause }}
</sv>
<sv label="申诉描述">
{{ dataList?.representationsDescribe }}
</sv>
<sv label="凭证">
<div >
<app-imagelist
[imgList]="[
dataList?.representationFirstFilePath ? dataList?.representationFirstFilePath : '',
dataList?.representationSecondFilePath,
dataList?.representationThirdFilePath,
dataList?.representationFourthFilePath,
dataList?.representationFifthFilePath
]"
>
</app-imagelist>
</div>
</sv>
</sv-container>
</div>
<div class="modal-footer">
<button nz-button type="button" (click)="close()">关闭</button>
</div>

View File

@ -0,0 +1,123 @@
import { Component, OnInit, ViewChild } from '@angular/core';
import { apiConf } from '@conf/api.conf';
import {
SFComponent,
SFCustomWidgetSchema,
SFNumberWidgetSchema,
SFRadioWidgetSchema,
SFSchema,
SFSelectWidgetSchema,
SFTextareaWidgetSchema,
SFUISchema,
SFUploadWidgetSchema
} from '@delon/form';
import { _HttpClient } from '@delon/theme';
import { NzMessageService } from 'ng-zorro-antd/message';
import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal';
import { Observable, Observer } from 'rxjs';
import { OrderManagementService } from '../../../services/order-management.service';
@Component({
selector: 'app-order-management-appeal',
templateUrl: './appeal.component.html'
})
export class OneCarOrderAppealComponent implements OnInit {
i: any;
dataList: any;
constructor(
private modalRef: NzModalRef,
private modal: NzModalService,
private msgSrv: NzMessageService,
public http: _HttpClient,
public service: OrderManagementService
) {}
ngOnInit(): void {
this.initDate();
}
// initSF() {
// this.schema = {
// properties: {
// abnormalCause: {
// type: 'string',
// title: '异常原因',
// default: this.i.abnormalCause,
// readOnly: true,
// ui: {
// widget: 'textarea',
// autosize: { minRows: 4, maxRows: 6 }
// } as SFTextareaWidgetSchema
// },
// representationsCause: {
// type: 'string',
// title: '申诉原因',
// ui: {
// widget: 'dict-select',
// params: { dictKey: 'bill:representation:reason' },
// containsAllLabel: false,
// placeholder: '请选择',
// errors: { required: '请选择' }
// }
// },
// representationsDescribe: {
// type: 'string',
// title: '申诉描述',
// maxLength: 100,
// ui: {
// widget: 'textarea',
// autosize: { minRows: 4, maxRows: 6 }
// } as SFTextareaWidgetSchema
// },
// fileArr: {
// type: 'string',
// title: '上传凭证',
// ui: {
// action: apiConf.fileUpload,
// accept: 'image/png,image/jpeg,image/jpg',
// limit: 5,
// limitFileCount: 5,
// resReName: 'data.fullFilePath',
// urlReName: 'data.fullFilePath',
// widget: 'upload',
// descriptionI18n: '不超过5张单张大小不超过5M支持.jpg、.jpeg和 .png格式',
// name: 'multipartFile',
// multiple: true,
// listType: 'picture-card',
// beforeUpload: (file: any, _fileList: any) => {
// return new Observable((observer: Observer<boolean>) => {
// const isLt2M = file.size / 1024 / 1024 < 5;
// if (!isLt2M) {
// this.service.msgSrv.warning('图片大小超过5M!');
// observer.complete();
// return;
// }
// observer.next(isLt2M);
// observer.complete();
// });
// }
// } as SFUploadWidgetSchema
// }
// },
// required: ['representationsCause', 'representationsDescribe']
// };
// this.ui = {
// '*': {
// spanLabelFixed: 100,
// grid: { span: 20 }
// }
// };
// }
initDate(): void {
console.log(this.i);
this.service.request(this.service.$api_get_getOrderComplaintDetail, { id: this.i?.id }).subscribe((res: any) => {
if (res) {
console.log(res);
this.dataList = res
}
});
}
close(): void {
this.modalRef.destroy();
}
}

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-30 14:45:39 * @Date : 2021-12-30 14:45:39
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-01-18 17:23:11 * @LastEditTime : 2022-03-24 10:28:48
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\modify-captain\\modify-captain.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\modify-captain\\modify-captain.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -96,7 +96,7 @@ export class VehicleModifyCaptainComponent implements OnInit {
console.log(this.bankData); console.log(this.bankData);
const params = { const params = {
billIds: this.data?.ids, billIds: this.data?.ids,
carCaptainId: value.id, carCaptainId: value.appUserId,
bankData: this.bankData bankData: this.bankData
}; };
this.service.request(this.service.$api_get_updateCarCaptainBatch, params).subscribe((res: any) => { this.service.request(this.service.$api_get_updateCarCaptainBatch, params).subscribe((res: any) => {

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-15 13:17:42 * @Date : 2021-12-15 13:17:42
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-02-24 10:47:39 * @LastEditTime : 2022-03-24 19:17:58
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\update-freight\\update-freight.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\update-freight\\update-freight.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -20,7 +20,7 @@
</p> </p>
<p> <p>
<label nz-checkbox [(ngModel)]="aggreechecked"></label> <label nz-checkbox [(ngModel)]="aggreechecked"></label>
<span>&nbsp;确认已阅读并知晓 <a target="_blank" [routerLink]="['/agreement']" [queryParams]="{ type: 11 }">《变更协议》</a></span> <span>&nbsp;确认已阅读并知晓 <a target="_blank" [routerLink]="['/agreement']" [queryParams]="{ type: 3, data: dataJSON }">《变更协议》</a></span>
</p> </p>
</div> </div>

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-15 13:17:42 * @Date : 2021-12-15 13:17:42
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-02-23 14:25:45 * @LastEditTime : 2022-03-24 19:17:10
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\update-freight\\update-freight.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\update-freight\\update-freight.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -30,12 +30,16 @@ export class VehicleUpdateFreightComponent implements OnInit {
@Input() @Input()
data: any; data: any;
dataJSON: any;
calculateSub!: Subscription; calculateSub!: Subscription;
constructor(private modal: NzModalRef, private msgSrv: NzMessageService, public service: OrderManagementService) {} constructor(private modal: NzModalRef, private msgSrv: NzMessageService, public service: OrderManagementService) {}
ngOnInit(): void { ngOnInit(): void {
console.log(this.data) console.log(this.data)
this.dataJSON = JSON.stringify(this.data)
console.log(this.dataJSON)
this.initSF(this.data); this.initSF(this.data);
} }
initSF(data: any) { initSF(data: any) {

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-06 09:24:00 * @Date : 2022-01-06 09:24:00
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-02-22 13:55:06 * @LastEditTime : 2022-03-25 14:10:36
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\order-management.module.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\order-management.module.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -24,6 +24,7 @@ import { OrderManagementVehicleDetailChangeComponent } from './components/vehicl
import { OrderManagementVehicleDetailComponent } from './components/vehicle-detail/vehicle-detail.component'; import { OrderManagementVehicleDetailComponent } from './components/vehicle-detail/vehicle-detail.component';
import { OrderManagementVehicleComponent } from './components/vehicle/vehicle.component'; import { OrderManagementVehicleComponent } from './components/vehicle/vehicle.component';
import { OneCarOrderAppealComponent } from './modal/audit/appeal/appeal.component';
import { orderManagementVoucherViewComponent } from './modal/audit/voucher-view/voucher-view.component'; import { orderManagementVoucherViewComponent } from './modal/audit/voucher-view/voucher-view.component';
import { ConfirReceiptComponent } from './modal/bulk/confir-receipt/confir-receipt.component'; import { ConfirReceiptComponent } from './modal/bulk/confir-receipt/confir-receipt.component';
import { UpdateFreightComponent } from './modal/bulk/update-freight/update-freight.component'; import { UpdateFreightComponent } from './modal/bulk/update-freight/update-freight.component';
@ -64,7 +65,8 @@ const COMPONENTS: Type<void>[] = [
orderManagementVoucherViewComponent, orderManagementVoucherViewComponent,
OrderManagementComplianceAuditComponent, OrderManagementComplianceAuditComponent,
OneCarOrderCancelConfirmComponent, OneCarOrderCancelConfirmComponent,
OneCarOrderViewtrackComponent OneCarOrderViewtrackComponent,
OneCarOrderAppealComponent
]; ];
@NgModule({ @NgModule({

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-03 15:31:52 * @Date : 2021-12-03 15:31:52
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-22 17:29:07 * @LastEditTime : 2022-03-28 11:07:48
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\services\\order-management.service.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\services\\order-management.service.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -174,6 +174,14 @@ export class OrderManagementService extends ShipperBaseService {
$api_get_getTrajectory = `/api/sdc/billShipper/getTrajectoryByBillId`; $api_get_getTrajectory = `/api/sdc/billShipper/getTrajectoryByBillId`;
// 获取订单司机轨迹 // 获取订单司机轨迹
$api_get_getAppDriverPosition = `/api/sdc/billShipper/getAppDriverPosition`; $api_get_getAppDriverPosition = `/api/sdc/billShipper/getAppDriverPosition`;
// 查看申述记录
$api_get_getOrderComplaintDetail = `/api/sdc/billOperate/getOrderComplaintDetail`;
// 异步导出运营后台大宗订单列表
$api_get_asyncExportBulkList = `/api/sdc/billOperate/asyncExportBulkList`;
// 异步导出运营后台整车订单列表
$api_get_asyncExportWholeList = `/api/sdc/billOperate/asyncExportWholeList`;
/** /**
* 根据企业ID获取企业历史网络货运人 * 根据企业ID获取企业历史网络货运人
* @returns * @returns

View File

@ -11,13 +11,13 @@
<b class="text-md ">{{headerTotalInfo?.ltdName}}</b> <b class="text-md ">{{headerTotalInfo?.ltdName}}</b>
</sv> </sv>
<sv label="可用余额"> <sv label="可用余额">
{{headerTotalInfo?.allAmount |currency}} <span class="text-error-dark font-weight-bold">{{headerTotalInfo?.allAmount |currency}}</span>
</sv> </sv>
<sv label="收入金额"> <sv label="收入金额">
{{headerTotalInfo?.incomeAmount |currency}} <span class="text-error-dark font-weight-bold"> {{headerTotalInfo?.incomeAmount |currency}}</span>
</sv> </sv>
<sv label="支出金额"> <sv label="支出金额">
{{headerTotalInfo?.payAmount |currency}} <span class="text-error-dark font-weight-bold">{{headerTotalInfo?.payAmount |currency}}</span>
</sv> </sv>
</sv-container> </sv-container>
<ng-template #labelTpl> <ng-template #labelTpl>

View File

@ -59,7 +59,7 @@ export class PartnerAccountManagementListComponent implements OnInit {
*/ */
initST() { initST() {
this.columns = [ this.columns = [
{ title: '合伙人名称', index: 'userName', className: 'text-center', width: 250 }, { title: '合伙人名称', index: 'name', className: 'text-center', width: 250 },
{ title: '手机号', index: 'phone', className: 'text-center', width: 200 }, { title: '手机号', index: 'phone', className: 'text-center', width: 200 },
{ {
title: '账户总额(元)', index: 'allBalance', className: 'text-right', sort: true, width: 150, type: 'currency', title: '账户总额(元)', index: 'allBalance', className: 'text-right', sort: true, width: 150, type: 'currency',

View File

@ -8,23 +8,27 @@
<nz-card> <nz-card>
<sv-container layout="vertical" [noColon]="true" col="5"> <sv-container layout="vertical" [noColon]="true" col="5">
<sv [label]="labelTpl"> <sv [label]="labelTpl">
<b class="text-md ">{{summaryObj?.company}}</b> <b class="text-md ">{{summaryObj?.taxno}}</b>
</sv> </sv>
<sv label="返佣总额"> <sv label="返佣总额">
{{summaryObj?.totalRebate |currency}} <span class="text-error-dark font-weight-bold">{{(summaryObj?.totalRebate?summaryObj?.totalRebate: 0 )|currency :'
'}}</span>
</sv> </sv>
<sv label="已入账金额"> <sv label="已入账金额">
{{summaryObj?.totalRebate |currency}} <span class="text-error-dark font-weight-bold">{{(summaryObj?.recordedAmount?summaryObj?.recordedAmount:0
)|currency:' '}}</span>
</sv> </sv>
<sv label="代缴个税"> <sv label="代缴个税">
{{summaryObj?.taxPersonalSum |currency}} <span class="text-error-dark font-weight-bold">{{(summaryObj?.taxPersonalSum?summaryObj?.taxPersonalSum:0
)|currency:' '}}</span>
</sv> </sv>
<sv label="待入账金额"> <sv label="待入账金额">
{{summaryObj?.waitRecordedAmount |currency}} <span class="text-error-dark font-weight-bold">{{(summaryObj?.waitRecordedAmount?summaryObj?.waitRecordedAmount:0)
|currency:' '}}</span>
</sv> </sv>
</sv-container> </sv-container>
<ng-template #labelTpl> <ng-template #labelTpl>
<b class="text-md" style="color: black;">{{summaryObj?.name}}</b> <b class="text-md" style="color: black;">{{summaryObj?.ltdName}}</b>
</ng-template> </ng-template>
</nz-card> </nz-card>
<nz-card> <nz-card>
@ -43,11 +47,11 @@
</ng-template> </ng-template>
</st> </st>
<div class="total-footer text-md" *ngIf="st?.list?.length !== 0 "> <div class="total-footer text-md" *ngIf="st?.list?.length !== 0 ">
合计 <label class="text-red-dark">{{ summaryObj?.total }}</label> 项,收入 <label 合计 <label class="text-red-dark">{{ footerSummary?.total }}</label> 项,收入 <label
class="text-red-dark font-weight-bold">{{ class="text-red-dark font-weight-bold">{{
summaryObj?.income | currency footerSummary?.income | currency
}}</label>,支出 <label class="text-red-dark font-weight-bold">{{ }}</label>,支出 <label class="text-red-dark font-weight-bold">{{
summaryObj?.spending | currency }}</label> footerSummary?.spending | currency }}</label>
</div> </div>
</div> </div>
</nz-card> </nz-card>
@ -55,8 +59,8 @@
<nz-modal [(nzVisible)]="showBillDetail" nzTitle="账户明细" [nzFooter]="null" (nzOnCancel)="handleCancel()" nzWidth="700px"> <nz-modal [(nzVisible)]="showBillDetail" nzTitle="账户明细" [nzFooter]="null" (nzOnCancel)="handleCancel()" nzWidth="700px">
<div *nzModalContent> <div *nzModalContent>
<div class="mb-sm"> <div class="mb-sm">
<span class="mr-xxl text-md font-weight-bold"><label>网络货运人:</label>{{detailRecord?.ltdName}}</span> <span class="mr-xxl text-sm font-weight-bold"><label>网络货运人:</label>{{detailRecord?.ltdName}}</span>
<span class="text-md font-weight-bold"><label>返佣总额(元):</label>{{detailRecord?.totalRebate |currency: ' '}}</span> <span class="text-sm font-weight-bold"><label>返佣总额(元):</label>{{detailRecord?.totalRebate |currency: ' '}}</span>
</div> </div>
<st #st [data]="billDetailList " [columns]="billDetailColumns" [res]="{ reName: { list: 'data' } }" <st #st [data]="billDetailList " [columns]="billDetailColumns" [res]="{ reName: { list: 'data' } }"
[req]="{ method: 'POST', allInBody: true, params:billDetailReqParams}" [page]="{show:false}"> [req]="{ method: 'POST', allInBody: true, params:billDetailReqParams}" [page]="{show:false}">

View File

@ -19,6 +19,12 @@ export class PartnerAccountManagementRecordedDetailComponent implements OnInit {
taxno: '' taxno: ''
}; };
footerSummary = {
total: 0,
income: 0,
spending: 0
}
detailRecord: any = {}; detailRecord: any = {};
url = `/user`; url = `/user`;
@ -56,8 +62,7 @@ export class PartnerAccountManagementRecordedDetailComponent implements OnInit {
initSF() { initSF() {
this.schema = { this.schema = {
properties: { properties: {
ltdName: {
abnormalCause: {
title: '网络货运人', title: '网络货运人',
type: 'string', type: 'string',
ui: { ui: {
@ -78,7 +83,7 @@ export class PartnerAccountManagementRecordedDetailComponent implements OnInit {
{ title: '网络货运人', index: 'ltdName', className: 'text-center', width: 200 }, { title: '网络货运人', index: 'ltdName', className: 'text-center', width: 200 },
{ title: '银行类型', render: 'bankTypeLabel', className: 'text-center', width: 150 }, { title: '银行类型', render: 'bankTypeLabel', className: 'text-center', width: 150 },
{ title: '虚拟账户', render: 'fictitiousAccount', className: 'text-center', width: 200 }, { title: '虚拟账户', render: 'fictitiousAccount', className: 'text-center', width: 200 },
{ title: '返佣总额(元)', index: 'totalRebate', className: 'text-center', width: 120, type: 'currency' }, { title: '返佣总额(元)', index: 'totalRebate', className: 'text-center', width: 180, type: 'currency' },
{ title: '已入账金额(元)', index: 'recordedAmount', className: 'text-center', width: 180, type: 'currency' }, { title: '已入账金额(元)', index: 'recordedAmount', className: 'text-center', width: 180, type: 'currency' },
{ title: '代缴个税(元)', index: 'taxPersonalSum', className: 'text-center', width: 180, type: 'currency' }, { title: '代缴个税(元)', index: 'taxPersonalSum', className: 'text-center', width: 180, type: 'currency' },
{ title: '待入账金额(元)', index: 'waitRecordedAmount', className: 'text-right', width: 180, type: 'currency' }, { title: '待入账金额(元)', index: 'waitRecordedAmount', className: 'text-right', width: 180, type: 'currency' },
@ -146,7 +151,7 @@ export class PartnerAccountManagementRecordedDetailComponent implements OnInit {
* @param record 当前行 * @param record 当前行
*/ */
viewBookedRecord(record: any) { viewBookedRecord(record: any) {
window.open(location.origin + `#/partner/recorded/record?ltdId=${record?.ltdId}&userId=${record?.userId}&userIdLabel=${record?.banktypeLabel}`); window.open(location.origin + `#/partner/recorded/record?ltdId=${record?.ltdId}`);
} }
/** /**
@ -157,6 +162,7 @@ export class PartnerAccountManagementRecordedDetailComponent implements OnInit {
this.billDetailColumns = []; this.billDetailColumns = [];
this.showBillDetail = true; this.showBillDetail = true;
this.initBillDetailST(); this.initBillDetailST();
this.detailRecord = record;
this.getBillDetail(record?.ltdId); this.getBillDetail(record?.ltdId);
} }
@ -170,6 +176,7 @@ export class PartnerAccountManagementRecordedDetailComponent implements OnInit {
handleCancel() { handleCancel() {
this.showBillDetail = false; this.showBillDetail = false;
this.detailRecord = {};
} }
goBack() { goBack() {

View File

@ -2,7 +2,6 @@ import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router'; import { ActivatedRoute } from '@angular/router';
import { FreightAccountService } from 'src/app/routes/financial-management/services/freight-account.service'; import { FreightAccountService } from 'src/app/routes/financial-management/services/freight-account.service';
@Component({ @Component({
selector: 'app-partner-account-management-withdrawals-detail', selector: 'app-partner-account-management-withdrawals-detail',
templateUrl: './withdrawals-detail.component.html', templateUrl: './withdrawals-detail.component.html',
@ -18,7 +17,7 @@ export class PartnerAccountManagementWithdralDetailComponent implements OnInit {
this.loadRefundDetail(id); this.loadRefundDetail(id);
} }
ngOnInit(): void { } ngOnInit(): void {}
loadRefundDetail(id: string) { loadRefundDetail(id: string) {
this.service.request(this.service.$api_get_refund_detail, { id }).subscribe(res => { this.service.request(this.service.$api_get_refund_detail, { id }).subscribe(res => {
@ -77,7 +76,8 @@ export class PartnerAccountManagementWithdralDetailComponent implements OnInit {
rmYll: this.formData.userId, rmYll: this.formData.userId,
snglFlgCd: this.formData.coreSerNo, snglFlgCd: this.formData.coreSerNo,
bussType: '06', bussType: '06',
ltdId: this.formData.ltdId ltdId: this.formData.ltdId,
accountType: this.formData.accountType
}); });
} }

View File

@ -311,7 +311,8 @@ export class PartnerAccountManagementWithdrawalsRecordComponent implements OnIni
rmYll: item.userId, rmYll: item.userId,
snglFlgCd: item.coreSerNo, snglFlgCd: item.coreSerNo,
bussType: '06', bussType: '06',
ltdId: item.ltdId ltdId: item.ltdId,
accountType: item.accountType
}) })
}, },
{ {

View File

@ -1,4 +1,10 @@
<page-header-wrapper [title]="'新增企业合伙人'"></page-header-wrapper> <page-header-wrapper [logo]="logo" [title]="'新增企业合伙人'">
<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-card>
<sf #sf [ui]="ui" [schema]="schema" [button]="'none'"> <sf #sf [ui]="ui" [schema]="schema" [button]="'none'">
<!-- 企业基本信 --> <!-- 企业基本信 -->

View File

@ -11,7 +11,7 @@ import {
} from '@delon/form'; } from '@delon/form';
import { NzTreeNode } from 'ng-zorro-antd/tree'; import { NzTreeNode } from 'ng-zorro-antd/tree';
import { NzUploadFile } from 'ng-zorro-antd/upload'; import { NzUploadFile } from 'ng-zorro-antd/upload';
import { of } from 'rxjs'; import { of, Subscription } from 'rxjs';
import { map } from 'rxjs/operators'; import { map } from 'rxjs/operators';
import { PartnerListService } from '../../services/partner-list.service'; import { PartnerListService } from '../../services/partner-list.service';
@ -64,6 +64,9 @@ export class AddEtpPartnerComponent {
} }
}; };
getIdentityInfoSub = new Subscription();
loadingIdentityInfoSub = false;
constructor(public service: PartnerListService) {} constructor(public service: PartnerListService) {}
submitForm() { submitForm() {
@ -426,7 +429,28 @@ export class AddEtpPartnerComponent {
ui: { ui: {
grid: { xxl: 13, xl: 18, lg: 24, md: 24 }, grid: { xxl: 13, xl: 18, lg: 24, md: 24 },
placeholder: '请输入企业管理员手机号', placeholder: '请输入企业管理员手机号',
errors: { required: '请输入企业管理员手机号', format: '手机号格式错误' } errors: { required: '请输入企业管理员手机号', format: '手机号格式错误' },
change: (mobile: any) => {
// 根据手机号获取实名信息
if (mobile?.length === 11) {
if (this.loadingIdentityInfoSub) {
this.getIdentityInfoSub.unsubscribe();
}
this.loadingIdentityInfoSub = true;
this.getIdentityInfoSub = this.service.request(this.service.$api_get_identityInfo_by_mobile, { mobile }).subscribe(
res => {
if (res) {
this.setInfo(res);
this.sf.setValue('/adminUserInfo/id', res.id);
this.sf.setValue('/adminUserInfo/userId', res.userId);
}
this.loadingIdentityInfoSub = false;
},
_ => {},
() => (this.loadingIdentityInfoSub = false)
);
}
}
} }
}, },
// 企业管理员信息 // 企业管理员信息
@ -441,6 +465,8 @@ export class AddEtpPartnerComponent {
}, },
default: true default: true
}, },
id: { title: '', type: 'string', ui: { hidden: true } },
userId: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoFront: { title: '', type: 'string', ui: { hidden: true } }, certificatePhotoFront: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoBack: { title: '', type: 'string', ui: { hidden: true } }, certificatePhotoBack: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoFrontWatermark: { certificatePhotoFrontWatermark: {
@ -589,4 +615,52 @@ export class AddEtpPartnerComponent {
] ]
}; };
} }
private setInfo(info: any) {
if (info.name) {
this.sf.setValue('/adminUserInfo/name', info.name);
}
if (info.certificatePhotoFront) {
this.sf.setValue('/adminUserInfo/certificatePhotoFront', info.certificatePhotoFront);
}
if (info.certificatePhotoFrontWatermark) {
console.log(this.sf.getProperty('/adminUserInfo/certificatePhotoFrontWatermark'));
this.sf.setValue('/adminUserInfo/certificatePhotoFrontWatermark', [
{
uid: -1,
name: '文件',
status: 'done',
url: info.certificatePhotoFrontWatermark,
response: info.certificatePhotoFrontWatermark
}
]);
}
if (info.certificatePhotoBack) {
this.sf.setValue('/adminUserInfo/certificatePhotoBack', info.certificatePhotoBack);
}
if (info.certificatePhotoBackWatermark) {
this.sf.setValue('/adminUserInfo/certificatePhotoBackWatermark', [
{
uid: -1,
name: '文件',
status: 'done',
url: info.certificatePhotoBackWatermark,
response: info.certificatePhotoBackWatermark
}
]);
}
if (info.certificateNumber) {
this.sf.setValue('/adminUserInfo/certificateNumber', info.certificateNumber);
}
if (info.validStartTime) {
this.sf.setValue('/adminUserInfo/validStartTime', info.validStartTime);
}
if (info.validEndTime) {
this.sf.setValue('/adminUserInfo/validEndTime', info.validEndTime);
this.sf.setValue('/adminUserInfo/_isLoingDate', false);
} else {
this.sf.setValue('/adminUserInfo/_isLoingDate', true);
}
}
} }

View File

@ -1,4 +1,10 @@
<page-header-wrapper [title]="'新增个人合伙人'"></page-header-wrapper> <page-header-wrapper [logo]="logo" [title]="'新增个人合伙人'">
<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-card>
<sf #sf [ui]="ui" [schema]="schema" [button]="'none'"> <sf #sf [ui]="ui" [schema]="schema" [button]="'none'">
<!-- 合伙人信息 --> <!-- 合伙人信息 -->
@ -36,7 +42,8 @@
</sf> </sf>
<div style="display: flex; justify-content: center"> <div style="display: flex; justify-content: center">
<button nz-button type="button" nzType="primary" (click)="submitForm()" [nzLoading]="service.http.loading">确认新增</button> <button nz-button type="button" nzType="primary" (click)="submitForm()"
[nzLoading]="service.http.loading">确认新增</button>
<button nz-button (click)="goBack()">返回</button> <button nz-button (click)="goBack()">返回</button>
</div> </div>
</nz-card> </nz-card>

View File

@ -12,7 +12,7 @@ import {
} from '@delon/form'; } from '@delon/form';
import { NzTreeNode } from 'ng-zorro-antd/tree'; import { NzTreeNode } from 'ng-zorro-antd/tree';
import { NzUploadFile } from 'ng-zorro-antd/upload'; import { NzUploadFile } from 'ng-zorro-antd/upload';
import { of } from 'rxjs'; import { of, Subscription } from 'rxjs';
import { map } from 'rxjs/operators'; import { map } from 'rxjs/operators';
import { PartnerListService } from '../../services/partner-list.service'; import { PartnerListService } from '../../services/partner-list.service';
@ -65,6 +65,9 @@ export class AddPersonalPartnerComponent {
} }
}; };
getIdentityInfoSub = new Subscription();
loadingIdentityInfoSub = false;
constructor(private router: Router, public service: PartnerListService) {} constructor(private router: Router, public service: PartnerListService) {}
submitForm() { submitForm() {
@ -156,7 +159,28 @@ export class AddPersonalPartnerComponent {
ui: { ui: {
grid: { xxl: 13, xl: 18, lg: 24, md: 24 }, grid: { xxl: 13, xl: 18, lg: 24, md: 24 },
placeholder: '请输入手机号', placeholder: '请输入手机号',
errors: { required: '请输入手机号', format: '手机号格式错误' } errors: { required: '请输入手机号', format: '手机号格式错误' },
change: (mobile: any) => {
// 根据手机号获取实名信息
if (mobile?.length === 11) {
if (this.loadingIdentityInfoSub) {
this.getIdentityInfoSub.unsubscribe();
}
this.loadingIdentityInfoSub = true;
this.getIdentityInfoSub = this.service.request(this.service.$api_get_identityInfo_by_mobile, { mobile }).subscribe(
res => {
if (res) {
this.setInfo(res);
this.sf.setValue('/adminUserInfo/id', res.id);
this.sf.setValue('/adminUserInfo/userId', res.userId);
}
this.loadingIdentityInfoSub = false;
},
_ => {},
() => (this.loadingIdentityInfoSub = false)
);
}
}
} }
}, },
// 合伙人信息 // 合伙人信息
@ -172,6 +196,8 @@ export class AddPersonalPartnerComponent {
default: true default: true
}, },
certificatePhotoFront: { title: '', type: 'string', ui: { hidden: true } }, certificatePhotoFront: { title: '', type: 'string', ui: { hidden: true } },
id: { title: '', type: 'string', ui: { hidden: true } },
userId: { title: '', type: 'string', ui: { hidden: true } },
certificatePhotoBack: { title: '', type: 'string', ui: { hidden: true } }, certificatePhotoBack: { title: '', type: 'string', ui: { hidden: true } },
certificateType: { title: '', type: 'string', ui: { hidden: true }, default: 0 }, certificateType: { title: '', type: 'string', ui: { hidden: true }, default: 0 },
certificatePhotoFrontWatermark: { certificatePhotoFrontWatermark: {
@ -311,4 +337,52 @@ export class AddPersonalPartnerComponent {
required: ['cityCodesList', 'invitationCode'] required: ['cityCodesList', 'invitationCode']
}; };
} }
private setInfo(info: any) {
if (info.name) {
this.sf.setValue('/adminUserInfo/name', info.name);
}
if (info.certificatePhotoFront) {
this.sf.setValue('/adminUserInfo/certificatePhotoFront', info.certificatePhotoFront);
}
if (info.certificatePhotoFrontWatermark) {
console.log(this.sf.getProperty('/adminUserInfo/certificatePhotoFrontWatermark'));
this.sf.setValue('/adminUserInfo/certificatePhotoFrontWatermark', [
{
uid: -1,
name: '文件',
status: 'done',
url: info.certificatePhotoFrontWatermark,
response: info.certificatePhotoFrontWatermark
}
]);
}
if (info.certificatePhotoBack) {
this.sf.setValue('/adminUserInfo/certificatePhotoBack', info.certificatePhotoBack);
}
if (info.certificatePhotoBackWatermark) {
this.sf.setValue('/adminUserInfo/certificatePhotoBackWatermark', [
{
uid: -1,
name: '文件',
status: 'done',
url: info.certificatePhotoBackWatermark,
response: info.certificatePhotoBackWatermark
}
]);
}
if (info.certificateNumber) {
this.sf.setValue('/adminUserInfo/certificateNumber', info.certificateNumber);
}
if (info.validStartTime) {
this.sf.setValue('/adminUserInfo/validStartTime', info.validStartTime);
}
if (info.validEndTime) {
this.sf.setValue('/adminUserInfo/validEndTime', info.validEndTime);
this.sf.setValue('/adminUserInfo/_isLoingDate', false);
} else {
this.sf.setValue('/adminUserInfo/_isLoingDate', true);
}
}
} }

View File

@ -33,7 +33,7 @@
<ng-template #editTemplate> <ng-template #editTemplate>
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<div nz-col nzSpan="24" se-container [labelWidth]="120"> <div nz-col nzSpan="24" se-container [labelWidth]="120">
<se [col]="1" label="合伙人名称"> {{selectItem?.enterpriseName}} </se> <se [col]="1" label="合伙人名称"> {{selectItem?.enterpriseName || selectItem?.contactName}} </se>
<se [col]="1" label="返佣模板" required> <se [col]="1" label="返佣模板" required>
<nz-select [(ngModel)]="templateId" style="width: 100%"> <nz-select [(ngModel)]="templateId" style="width: 100%">
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of customers"></nz-option> <nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of customers"></nz-option>
@ -47,28 +47,29 @@
<ng-template #editCannel> <ng-template #editCannel>
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<div nz-col nzSpan="24" se-container [labelWidth]="140" [col]="1"> <div nz-col nzSpan="24" se-container [labelWidth]="140" [col]="1">
<se label="合伙人名称"> 深圳某某有限公司 </se> <se label="合伙人名称"> {{selectItem?.enterpriseName || selectItem?.contactName}} </se>
<se label="当前渠道销售"> 张三/13999999999 </se> <se label="当前渠道销售"> {{selectItem?.channelId}} </se>
<se label="渠道销售修改为" required> <se label="渠道销售修改为" required>
<nz-select ngModel="lucy" style="width: 100%"> <nz-select [(ngModel)]="cannelItem.channelId" style="width: 100%">
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of cannels"></nz-option> <nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of cannels"></nz-option>
</nz-select> </nz-select>
</se> </se>
<se label="备注" required> <se label="备注" required>
<textarea rows="3" nz-input></textarea> <textarea rows="3" nz-input [(ngModel)]="cannelItem.remark"></textarea>
</se> </se>
<se label="一并转移的客户"> <se label="一并转移的客户">
<p style="margin-top: 8px">已选0</p> <p style="margin-top: 8px">已选0</p>
<st #rest [data]="service.$api_get_enterprice_rel_list" [columns]="[ <st #rest [data]="service.$api_get_enterprice_rel_list" [columns]="[
{ title: '', index: 'key', type: 'checkbox' }, { title: '', index: 'key', type: 'checkbox' },
{ title: '客户名称', index: 'enterpriceName' } { title: '客户名称', index: 'enterpriceName' }
]" [req]="{ process: beforeReq }" [loading]="service.http.loading" [page]="{show:false}"> ]" [req]="{ process: beforeReq,params:{effectiveStatus:2 ,newPartnerId:selectItem.id} }"
[loading]="service.http.loading" [page]="{show:false}" (change)="stChange($event)">
</st> </st>
</se> </se>
<se label="生效节点" required> <se label="生效节点" required>
<nz-radio-group> <nz-radio-group [(ngModel)]="cannelItem.effectiveNode">
<label nz-radio nzValue="A">修改成功后立即生效</label> <label nz-radio [nzValue]="1">修改成功后立即生效</label>
<label nz-radio nzValue="B">CRM流程审核通过后生</label> <label nz-radio [nzValue]="2">CRM流程审核通过后生</label>
</nz-radio-group> </nz-radio-group>
</se> </se>
</div> </div>

View File

@ -31,6 +31,8 @@ export class PartnerListComponent {
editCannel: any; editCannel: any;
customers: any[] = []; customers: any[] = [];
cannels: any[] = []; cannels: any[] = [];
selectedRows: any[] = [];
cannelItem: any = { channelId: null, effectiveNode: 1, enterpriseIdList: [], remark: '' };
selectItem: any = {}; selectItem: any = {};
@ -49,7 +51,7 @@ export class PartnerListComponent {
return requestOptions; return requestOptions;
}; };
loadSelectOptions(){ loadSelectOptions() {
this.service.getRebateConfig().subscribe(res => { this.service.getRebateConfig().subscribe(res => {
if (res) { if (res) {
this.customers = res; this.customers = res;
@ -57,7 +59,7 @@ export class PartnerListComponent {
}); });
this.service.getChannel().subscribe(res => { this.service.getChannel().subscribe(res => {
if (res) { if (res) {
this.customers = res; this.cannels = res;
} }
}); });
} }
@ -66,13 +68,14 @@ export class PartnerListComponent {
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '审核', nzTitle: '审核',
nzContent: PartnerAuditModalComponent, nzContent: PartnerAuditModalComponent,
nzComponentParams: { info: { ...item, enterpriseName: item.enterpriseName || item.contactName } }, nzComponentParams: { info: { ...item, enterpriseName: item.enterpriseName || item.contactName }, sourcePage: '合伙人审核列表' },
nzFooter: null nzFooter: null
}); });
} }
editTemplateAction(item: any) { editTemplateAction(item: any) {
this.selectItem = item; this.selectItem = item;
this.templateId = item.templateId || null;
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '修改返佣模板', nzTitle: '修改返佣模板',
nzContent: this.editTemplate, nzContent: this.editTemplate,
@ -87,7 +90,7 @@ export class PartnerListComponent {
}); });
} }
confirmEditTemplate() { private confirmEditTemplate() {
const modal = this.nzModalService.confirm({ const modal = this.nzModalService.confirm({
nzTitle: '确定要修改返佣模板吗?', nzTitle: '确定要修改返佣模板吗?',
nzOnOk: () => { nzOnOk: () => {
@ -107,15 +110,39 @@ export class PartnerListComponent {
}); });
} }
stChange(e: STChange): void {
switch (e.type) {
case 'checkbox':
this.selectedRows = e.checkbox!;
break;
}
}
editCannelAction(item: any) { editCannelAction(item: any) {
this.selectItem = item; this.selectItem = item;
const modal = this.nzModalService.create({ this.cannelItem = { channelId: null, effectiveNode: 1, enterpriseIdList: [], remark: '' };
nzTitle: '修改渠道销售', this.selectedRows = [];
nzWidth: 650, // 校验合伙人是否可修改渠道销售 true:可以修改 false不可以修改
nzContent: this.editCannel, this.service.request(this.service.$api_check_partenr_change_channel, { id: item.id }).subscribe(res => {
nzOnOk: () => { if (res) {
this.confirmEditCannel(item); this.selectItem = item;
return false; const modal = this.nzModalService.create({
nzTitle: '修改渠道销售',
nzWidth: 650,
nzContent: this.editCannel,
nzOnOk: () => {
if (!this.cannelItem.channelId) {
this.service.msgSrv.warning('请选择渠道销售');
return false;
}
if (!this.cannelItem.remark) {
this.service.msgSrv.warning('请填写备注');
return false;
}
this.confirmEditCannel(item);
return false;
}
});
} }
}); });
} }
@ -124,7 +151,18 @@ export class PartnerListComponent {
const modal = this.nzModalService.confirm({ const modal = this.nzModalService.confirm({
nzTitle: '确定提交吗?', nzTitle: '确定提交吗?',
nzOnOk: () => { nzOnOk: () => {
this.nzModalService.closeAll(); this.cannelItem.enterpriseIdList = this.selectedRows.map(row => row.id);
this.service
.request(this.service.$api_update_partner_channel_by_id, {
...this.cannelItem,
id: item.id
})
.subscribe(res => {
if (res) {
this.service.msgSrv.success('修改成功');
this.nzModalService.closeAll();
}
});
} }
}); });
} }
@ -321,15 +359,20 @@ export class PartnerListComponent {
private initST(): STColumn[] { private initST(): STColumn[] {
return [ return [
{ title: '合伙人名称', index: 'enterpriseName', width: 180, format: item => `${item.enterpriseName || item.contactName}` }, {
title: '合伙人名称',
index: 'enterpriseName',
width: 180,
format: item => (item.partnerType ? `${item.enterpriseName || item.contactName}` : '')
},
{ title: '付款编码', index: 'payCode', width: 160 }, { title: '付款编码', index: 'payCode', width: 160 },
{ title: '邀请码', index: 'invitationCode', className: 'text-center', width: 130 }, { title: '邀请码', index: 'invitationCode', className: 'text-center', width: 130 },
{ title: '企业管理员', index: 'contactName', width: 150 }, { title: '企业管理员', index: 'contactName', width: 150, format: item => (item.partnerType ? `${item.contactName}` : '') },
{ title: '手机号', index: 'contactMobile', className: 'text-center', width: 150 }, { title: '手机号', index: 'contactMobile', className: 'text-center', width: 150 },
{ title: '类型', index: 'partnerType', className: 'text-center', width: 130, type: 'enum', enum: { 1: '企业', 2: '个人' } }, { title: '类型', index: 'partnerType', className: 'text-center', width: 130, type: 'enum', enum: { 1: '企业', 2: '个人' } },
{ title: '注册渠道', index: 'source', type: 'enum', enum: { 1: '合伙人注册', 2: '平台添加' }, width: 130 }, { title: '注册渠道', index: 'source', type: 'enum', enum: { 1: '合伙人注册', 2: '平台添加' }, width: 130 },
{ title: '注册时间', index: 'createTime', className: 'text-center', width: 170 }, { title: '注册时间', index: 'createTime', className: 'text-center', width: 170 },
{ title: '渠道销售', index: 'channelId', width: 170 }, { title: '渠道销售', index: 'channelIdLabel', width: 170 },
{ title: '返佣模板', index: 'templateName', width: 150 }, { title: '返佣模板', index: 'templateName', width: 150 },
{ {
title: '认证审核状态', title: '认证审核状态',
@ -337,7 +380,7 @@ export class PartnerListComponent {
width: 150, width: 150,
type: 'badge', type: 'badge',
badge: { badge: {
0: { text: '草稿', color: 'default' }, '-1': { text: '未提交', color: 'default' },
10: { text: '待审核', color: 'processing' }, 10: { text: '待审核', color: 'processing' },
20: { text: '审核通过', color: 'success' }, 20: { text: '审核通过', color: 'success' },
30: { text: '驳回', color: 'error' } 30: { text: '驳回', color: 'error' }
@ -385,7 +428,13 @@ export class PartnerListComponent {
buttons: [ buttons: [
{ type: 'divider' }, { type: 'divider' },
{ {
text: '详情', text: '审核',
iif: item => item.id && item.approvalStatus === 10,
click: item => this.auditPartner(item)
},
{
text: '详情<br>',
iif: item => item.id,
click: item => { click: item => {
if (item.partnerType === 1) { if (item.partnerType === 1) {
this.router.navigate([`/partner/partner-list/etp-detail/${item.id}`]); this.router.navigate([`/partner/partner-list/etp-detail/${item.id}`]);
@ -394,21 +443,20 @@ export class PartnerListComponent {
} }
} }
}, },
{
text: '审核<br>',
click: item => this.auditPartner(item)
},
{ {
text: '修改返佣模板', text: '修改返佣模板',
iif: item => item.id,
click: item => this.editTemplateAction(item) click: item => this.editTemplateAction(item)
}, },
{ {
text: '修改渠道销售', text: '修改渠道销售',
iif: item => item.id,
click: item => this.editCannelAction(item) click: item => this.editCannelAction(item)
}, },
{ {
text: '重发CRM流程', text: '重发CRM流程',
click: item => this.reSendCRM(item) click: item => item.id && this.reSendCRM(item),
iif: item => item.crmStatus === 10
} }
] ]
} }

View File

@ -14,6 +14,7 @@ export class PartnerAuditModalComponent implements OnInit {
@Input() @Input()
info: any; info: any;
schema!: SFSchema; schema!: SFSchema;
sourcePage = '';
constructor(private nzModalService: NzModalService, public service: PartnerListService) {} constructor(private nzModalService: NzModalService, public service: PartnerListService) {}
ngOnInit(): void { ngOnInit(): void {
@ -53,13 +54,11 @@ export class PartnerAuditModalComponent implements OnInit {
channelId: { channelId: {
title: '渠道销售', title: '渠道销售',
type: 'string', type: 'string',
enum: [
{ value: true, label: '通过' },
{ value: false, label: '驳回' }
],
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', placeholder: '请选择',
allowClear: true,
asyncData: () => this.service.getChannel(),
hidden: this.info.isPass === false, hidden: this.info.isPass === false,
visibleIf: { visibleIf: {
status: value => value status: value => value
@ -115,7 +114,8 @@ export class PartnerAuditModalComponent implements OnInit {
.request(this.service.$api_audit_partner, { .request(this.service.$api_audit_partner, {
auditStatusEnum: params.auditStatusEnum, auditStatusEnum: params.auditStatusEnum,
id: params.id, id: params.id,
approvalOpinion: params.approvalOpinion approvalOpinion: params.approvalOpinion,
sourcePage: this.sourcePage
}) })
.subscribe(res => { .subscribe(res => {
if (res) { if (res) {

View File

@ -40,7 +40,7 @@
<button [disabled]="service.http.loading" nz-button nzDanger (click)="save()"> 保存 </button> <button [disabled]="service.http.loading" nz-button nzDanger (click)="save()"> 保存 </button>
</ng-container> </ng-container>
<ng-template #editButton> <ng-template #editButton>
<ng-container> <ng-container *ngIf="detailData?.approvalStatus === 10">
<button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(true)"> 通过 </button> <button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(true)"> 通过 </button>
<button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(false)"> 驳回 </button> <button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(false)"> 驳回 </button>
</ng-container> </ng-container>
@ -87,8 +87,9 @@
[nzBorderless]="!isEdit" [placeholder]="isEdit ? '' : '-'" /> [nzBorderless]="!isEdit" [placeholder]="isEdit ? '' : '-'" />
</sv> </sv>
<sv label="手机号"> <sv label="手机号">
<input nz-input type="text" [(ngModel)]="detailData.adminUserInfo.mobile" [readonly]="!isEdit" <!-- <input nz-input type="text" [(ngModel)]="detailData.adminUserInfo.mobile" [readonly]="!isEdit"
[nzBorderless]="!isEdit" [placeholder]="isEdit ? '' : '-'" /> [nzBorderless]="!isEdit" [placeholder]="isEdit ? '' : '-'" /> -->
{{detailData.adminUserInfo.mobile}}
</sv> </sv>
<sv label="身份证号"> <sv label="身份证号">
<input nz-input type="text" [(ngModel)]="detailData.adminUserInfo.certificateNumber" [readonly]="!isEdit" <input nz-input type="text" [(ngModel)]="detailData.adminUserInfo.certificateNumber" [readonly]="!isEdit"
@ -125,7 +126,8 @@
[nzBorderless]="!isEdit" [nzSuffixIcon]="isEdit ? 'calendar' : ''" style="width: 100px" class="calendar"> [nzBorderless]="!isEdit" [nzSuffixIcon]="isEdit ? 'calendar' : ''" style="width: 100px" class="calendar">
</nz-date-picker> </nz-date-picker>
- -
<ng-container *ngIf="!isEdit && !detailData?.adminUserInfo.validEndTime && detailData?.adminUserInfo.validStartTime"> <ng-container
*ngIf="!isEdit && !detailData?.adminUserInfo.validEndTime && detailData?.adminUserInfo.validStartTime">
<label style="padding-left: 11px">长期</label> <label style="padding-left: 11px">长期</label>
</ng-container> </ng-container>
<nz-date-picker [(ngModel)]="detailData.adminUserInfo.validEndTime" [nzDisabled]="!isEdit" nzPlaceHolder=" " <nz-date-picker [(ngModel)]="detailData.adminUserInfo.validEndTime" [nzDisabled]="!isEdit" nzPlaceHolder=" "
@ -281,7 +283,8 @@
<sv-title>修改渠道销售记录</sv-title> <sv-title>修改渠道销售记录</sv-title>
<sv label=""> <sv label="">
<st #st [data]="service.$api_get_personal_channel_list" [columns]="columns.logsColumn" <st #st [data]="service.$api_get_personal_channel_list" [columns]="columns.logsColumn"
[loading]="service.http.loading" bordered size="small" [page]="{ show: false }" [scroll]="{ x: '1200px' }"> [req]="{params:{partnerId:route.snapshot.params.id}}" [loading]="service.http.loading" bordered size="small"
[page]="{ show: false }" [scroll]="{ x: '1200px' }">
</st> </st>
</sv> </sv>
</sv-container> </sv-container>
@ -316,13 +319,15 @@
</ng-template> </ng-template>
<ng-template #logModal> <ng-template #logModal>
<h2>转移客户数:10</h2> <h2>转移客户数:{{changeST?.total}}</h2>
<st #st [data]="service.$mock_url" [columns]="columns.changeColumn" [loading]="service.http.loading" bordered <st #changeST [data]="service.$api_get_partner_change_list" [columns]="columns.changeColumn"
size="small" [page]="{ show: false }" [scroll]="{ x: '750px' }"> [req]="{params:{partnerId:route.snapshot.params.id ,type:1}}" [loading]="service.http.loading" bordered size="small"
[page]="{ show: false }" [scroll]="{ x: '750px' }">
</st> </st>
<h2>不转移客户数:10</h2> <h2>不转移客户数:{{noChangeST?.total}}</h2>
<st #st [data]="service.$mock_url" [columns]="columns.beChangeColumn" [loading]="service.http.loading" bordered <st #noChangeST [data]="service.$api_get_partner_change_list" [columns]="columns.beChangeColumn"
size="small" [page]="{ show: false }" [scroll]="{ x: '750px' }"> [req]="{params:{partnerId:route.snapshot.params.id ,type:2}}" [res]="{reName: { list: 'data' }}"
[loading]="service.http.loading" bordered size="small" [page]="{ show: false }" [scroll]="{ x: '750px' }">
</st> </st>
<p> <p>
客户转移客户跟着上级合伙人转移一并到新渠道销售下会同步发起CRM《客户转移》流程不转移的客户会与上级合伙人解绑修改成功后修改时间也是合伙人与客户的结算结束时间成为原来渠道销售的直客。 客户转移客户跟着上级合伙人转移一并到新渠道销售下会同步发起CRM《客户转移》流程不转移的客户会与上级合伙人解绑修改成功后修改时间也是合伙人与客户的结算结束时间成为原来渠道销售的直客。

View File

@ -47,7 +47,7 @@ export class PartnerDetailComponent implements OnInit, OnDestroy {
subscribeScoll!: Subscription; subscribeScoll!: Subscription;
constructor( constructor(
public service: PartnerListService, public service: PartnerListService,
private route: ActivatedRoute, public route: ActivatedRoute,
private nzModalService: NzModalService, private nzModalService: NzModalService,
private datePipe: DatePipe private datePipe: DatePipe
) {} ) {}
@ -138,7 +138,7 @@ export class PartnerDetailComponent implements OnInit, OnDestroy {
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '审核', nzTitle: '审核',
nzContent: PartnerAuditModalComponent, nzContent: PartnerAuditModalComponent,
nzComponentParams: { info: { ...this.detailData, isPass } }, nzComponentParams: { info: { ...this.detailData, isPass },sourcePage:'合伙人审核详情' },
nzFooter: null nzFooter: null
}); });
} }
@ -366,13 +366,13 @@ export class PartnerDetailComponent implements OnInit, OnDestroy {
private initST(): { logsColumn: STColumn[]; changeColumn: STColumn[]; beChangeColumn: STColumn[] } { private initST(): { logsColumn: STColumn[]; changeColumn: STColumn[]; beChangeColumn: STColumn[] } {
return { return {
logsColumn: [ logsColumn: [
{ title: '修改后渠道销售', index: 'newChannelName', width: 180 }, { title: '修改后渠道销售', index: 'newChannelIdLabel', width: 180 },
{ title: '修改前渠道销售', index: 'originalChannelName', width: 160 }, { title: '修改前渠道销售', index: 'originalChannelIdLabel', width: 160 },
{ title: '转移客户数', index: 'quantity', className: 'text-center', width: 130 }, { title: '转移客户数', index: 'quantity', className: 'text-center', width: 130 },
{ title: '生效节点', index: 'effectiveNode', width: 150, type: 'enum', enum: { 1: '立即生效', 2: 'CRM审核后生效' } }, { title: '生效节点', index: 'effectiveNode', width: 150, type: 'enum', enum: { 1: '立即生效', 2: 'CRM审核后生效' } },
{ title: '备注', index: 'remark', className: 'text-center', width: 150 }, { title: '备注', index: 'remark', className: 'text-center', width: 150 },
{ title: '修改时间', index: 'effectiveTime', className: 'text-center', width: 130, type: 'date' }, { title: '修改时间', index: 'effectiveTime', className: 'text-center', width: 180, type: 'date' },
{ title: '操作人', index: 'modifyUserId', width: 130 }, { title: '操作人', index: 'modifyUserIdLabel', width: 180 },
{ {
title: '操作', title: '操作',
fixed: 'right', fixed: 'right',

View File

@ -40,7 +40,7 @@
<button [disabled]="service.http.loading" nz-button nzDanger (click)="save()"> 保存 </button> <button [disabled]="service.http.loading" nz-button nzDanger (click)="save()"> 保存 </button>
</ng-container> </ng-container>
<ng-template #editButton> <ng-template #editButton>
<ng-container> <ng-container *ngIf="detailData?.approvalStatus === 10">
<button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(true)"> 通过 </button> <button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(true)"> 通过 </button>
<button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(false)"> 驳回 </button> <button [disabled]="service.http.loading" nz-button nzDanger (click)="auditPartner(false)"> 驳回 </button>
</ng-container> </ng-container>

View File

@ -113,7 +113,10 @@ export class PersonalPartnerDetailComponent implements OnInit {
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '审核', nzTitle: '审核',
nzContent: PartnerAuditModalComponent, nzContent: PartnerAuditModalComponent,
nzComponentParams: { info: { ...this.detailData, isPass, enterpriseName: this.detailData.adminUserInfo?.name } }, nzComponentParams: {
info: { ...this.detailData, isPass, enterpriseName: this.detailData.adminUserInfo?.name },
sourcePage: '合伙人审核详情'
},
nzFooter: null nzFooter: null
}); });
} }

View File

@ -23,12 +23,20 @@ export class PartnerListService extends ShipperBaseService {
$api_update_partner_template = '/api/mdc/partner/updateTemplate'; $api_update_partner_template = '/api/mdc/partner/updateTemplate';
// 更新渠道销售 // 更新渠道销售
$api_update_partner_channel = '/api/mdc/partner/updateChannelSale'; $api_update_partner_channel = '/api/mdc/partner/updateChannelSale';
// 更新渠道销售
$api_update_partner_channel_by_id = '/api/mdc/partner/updateChannelSaleByID';
// 重新发起CRM // 重新发起CRM
$api_resend_crm = '/api/mdc/partner/reSendCrm'; $api_resend_crm = '/api/mdc/partner/reSendCrm';
// 查询合伙人修改渠道渠道销售记录 // 查询合伙人修改渠道渠道销售记录
$api_get_personal_channel_list = '/api/mdc/partnerChannelRelLog/list/page'; $api_get_personal_channel_list = '/api/mdc/partnerChannelRelLog/list/page';
// 查询客户关系列表-不分页 // 查询客户关系列表-不分页
$api_get_enterprice_rel_list = '/api/mdc/enterpriceRelLog/list'; $api_get_enterprice_rel_list = '/api/mdc/EnterpriseRelLog/list';
// 校验合伙人是否可修改渠道销售 true:可以修改 false不可以修改
$api_check_partenr_change_channel = '/api/mdc/partner/updateChannelCheck';
// 根据手机号查询实名信息
$api_get_identityInfo_by_mobile= '/api/mdc/cuc/identityInfo/getByMobile';
// 渠道销售修改详情
$api_get_partner_change_list = '/api/mdc/partnerChannelRelLog/partnerChannelUpdateDetaiList';
// 冻结/启用企业业 // 冻结/启用企业业
$api_lock_freight = '/api/mdc/cuc/enterpriseInfo/operate/lock'; $api_lock_freight = '/api/mdc/cuc/enterpriseInfo/operate/lock';

View File

@ -61,6 +61,7 @@ import { BannerComponentsAddComponent } from './knowledge/banner/components/add/
import { PersonalPartnerDetailComponent } from './partner-list/components/personal-partner-detail/personal-partner-detail.component'; import { PersonalPartnerDetailComponent } from './partner-list/components/personal-partner-detail/personal-partner-detail.component';
import { ParterAdviceFeedbackListComponent } from './advice-feedback/components/list/list.component'; import { ParterAdviceFeedbackListComponent } from './advice-feedback/components/list/list.component';
import { ParterAdviceFeedbackDetailComponent } from './advice-feedback/components/feedback-detail/feedback-detail.component'; import { ParterAdviceFeedbackDetailComponent } from './advice-feedback/components/feedback-detail/feedback-detail.component';
import { ParterRebateManageMentAddPartnerListComponent } from './rebate-management/components/rebate-setting/add-partnerlist/add-partnerlist.component';
const COMPONENTS: any[] = [ const COMPONENTS: any[] = [
PartnerBusinessStatisticsIndexComponent, PartnerBusinessStatisticsIndexComponent,
@ -111,7 +112,8 @@ const COMPONENTS: any[] = [
BannerComponentsAddComponent, BannerComponentsAddComponent,
PersonalPartnerDetailComponent, PersonalPartnerDetailComponent,
ParterAdviceFeedbackListComponent, ParterAdviceFeedbackListComponent,
ParterAdviceFeedbackDetailComponent ParterAdviceFeedbackDetailComponent,
ParterRebateManageMentAddPartnerListComponent
]; ];
@NgModule({ @NgModule({

View File

@ -0,0 +1,38 @@
<nz-card>
<div nz-row nzGutter="8">
<!-- 查询字段小于或等于3个时不显示伸缩按钮 -->
<div nz-col nzSpan="24" *ngIf="queryFieldCount <= 4">
<sf #sf [schema]="schema" [ui]="ui" [mode]="'search'" [disabled]="!sf?.valid" [loading]="false"
(formSubmit)="search()" (formReset)="resetSF()"></sf>
</div>
<!-- 查询字段大于3个时根据展开状态调整布局 -->
<ng-container *ngIf="queryFieldCount > 4">
<div nz-col [nzSpan]="_$expand ? 24 : 18">
<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]="false" (click)="search()" acl
[acl-ability]="['AbnormalAppear-serach']">查询</button>
<button nz-button (click)="resetSF()" acl [acl-ability]="['AbnormalAppear-reset']">重置</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 class="content-box">
<st #st [data]="service.$api_get_rebateConfig" [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]="false"
[scroll]="{ x: '2000px' }">
</st>
<ng-template #extraTemplate>
<button *ngIf="selectedIndex===0" (click)="batchReply()" nz-button nzType="primary" acl
[acl-ability]="['AbnormalAppear-batchReply']">批量回复</button>
</ng-template>
</nz-card>

View File

@ -0,0 +1,20 @@
:host::ng-deep{
.search-box{
.ant-card-body{
padding-bottom: 18px;
}
}
.content-box{
.ant-card-body{
padding-top: 14px;
}
}
.imgBox {
display: flex;
img {
width: 60px !important;
}
}
}

View File

@ -0,0 +1,220 @@
import { Component, OnInit, ViewChild, Type } from '@angular/core';
import { STComponent, STColumn, STChange } from '@delon/abc/st';
import { SFComponent, SFDateWidgetSchema, SFRadioWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
import { ShipperBaseService } from '@shared';
import { NzModalService } from 'ng-zorro-antd/modal';
import { of } from 'rxjs';
import { map } from 'rxjs/operators';
import { RebateManagementService } from '../../../services/rebate-management.service';
@Component({
selector: 'app-add-partnerlist',
templateUrl: './add-partnerlist.component.html',
styleUrls: ['./add-partnerlist.component.less']
})
export class ParterRebateManageMentAddPartnerListComponent implements OnInit {
@ViewChild('st', { static: true })
st!: STComponent;
@ViewChild('sf', { static: false }) sf!: SFComponent;
ui: SFUISchema = {};
i: any;
schema: SFSchema = {};
addSchema: SFSchema = {};
_$expand = false;
editText = '';
formData: any;
isVisible = false;
edit = false;
editId = false;
selectedIndex = 0;
columns: STColumn[] = [
{ title: '', type: 'checkbox', width: '50px', className: 'text-center' },
{ title: '异常编号', index: 'exceptionCode', width: '140px', className: 'text-left', },
{ title: '订单号', index: 'billCode', width: '160px', className: 'text-left', },
{ title: '装货地', index: 'loadingAddressArr', width: '220px', className: 'text-left', },
{ title: '卸货地', index: 'unloadingAddressArr', width: '220px', className: 'text-left', },
{ title: '承运司机', index: 'driver', width: '180px', className: 'text-left', },
{ title: '异常信息', index: 'exceptionContent', width: '100px', className: 'text-left', },
{ title: '异常图片', render: 'exceptionCertificateFirstFilePath', width: '150px', className: 'text-left', },
{ title: '上报时间', index: 'createTime', width: '140px', className: 'text-left', },
{
title: '操作', index: 'createTime', width: '90px', className: 'text-left',
buttons: [
{
text: '回复',
click: _record => this.reply(_record),
acl: { ability: ['AbnormalAppear-reply'] }
},
]
},
];
columns2: STColumn[] = [
{ title: '异常编号', index: 'exceptionCode', width: '140px', className: 'text-left' },
{ title: '订单号', index: 'billCode', width: '160px', className: 'text-left' },
{ title: '装货地', index: 'loadingAddressArr', width: '220px', className: 'text-left' },
{ title: '卸货地', index: 'unloadingAddressArr', width: '220px', className: 'text-left' },
{ title: '承运司机', index: 'driver', width: '180px', className: 'text-left' },
{ title: '异常信息', index: 'exceptionContent', width: '100px', className: 'text-left' },
{ title: '异常图片', render: 'exceptionCertificateFirstFilePath', width: '150px', className: 'text-left' },
{ title: '上报时间', index: 'createTime', width: '140px', className: 'text-left' },
{ title: '回复内容', index: 'replyContent', width: '150px', className: 'text-left' },
{ title: '回复人', index: 'replyAppUserName', width: '90px', className: 'text-left' },
{ title: '回复时间', index: 'replyTime', width: '140px', className: 'text-left' },
];
get reqParams() {
let params: any = { ...this.sf?.value };
if (params.reportingTime) {
const reportingTime = { start: this.sf?.value?.reportingTime?.[0], end: this.sf?.value?.reportingTime?.[1] }
params.reportingTime = reportingTime;
}
return params;
}
get selectedRows() {
return this.st?.list.filter(item => item.checked) || [];
}
constructor(
public service: RebateManagementService,
private nzModalService: NzModalService,
public shipperSrv: ShipperBaseService,
private modal: NzModalService,
) { }
ngOnInit(): void {
this.initSF()
}
/**
* 伸缩查询条件
*/
expandToggle(): void {
this._$expand = !this._$expand;
this.sf?.setValue('/_$expand', this._$expand);
}
/**
* 查询字段个数
*/
get queryFieldCount(): number {
return Object.keys(this.schema?.properties || {}).length;
}
initSF() {
this.schema = {
properties: {
_$expand: { type: 'boolean', ui: { hidden: true } },
exceptionCode: {
type: 'string',
title: '异常编号',
ui: { placeholder: '请输入' }
},
billCode: {
type: 'string',
title: '订单号',
ui: {
placeholder: '最多100个订单空号隔开',
}
},
exceptionType: {
title: '异常类型',
type: 'string',
ui: {
widget: 'dict-select',
containsAllLabel: true,
params: { dictKey: 'exception:report:type' },
} as SFSelectWidgetSchema
},
driverName: {
title: '承运司机',
type: 'string',
ui: {
visibleIf: {
_$expand: (value: boolean) => value
}
}
},
carNo: {
title: '车牌号',
type: 'string',
ui: {
visibleIf: {
_$expand: (value: boolean) => value
}
}
},
reportingTime: {
title: '上报时间',
type: 'string',
ui: {
widget: 'date',
mode: 'range',
format: 'yyyy-MM-dd',
visibleIf: {
_$expand: (value: boolean) => value
}
} as SFDateWidgetSchema
}
}
};
this.ui = { '*': { spanLabelFixed: 110, grid: { span: 8, gutter: 4 } } };
}
search() {
if (this.selectedIndex === 0) {
this.st?.load(1)
}
}
selectedIndexChange(event: any) {
if (this.selectedIndex === 0) {
this.st?.load(1)
}
}
/**
* 重置表单
*/
resetSF() {
this.sf.reset();
}
// 回复操作
reply(item: any) {
// const modalRef = this.modal.create({
// nzTitle: '回复',
// nzWidth: 700,
// nzContent: AbnormalReplyComponent,
// nzComponentParams: {
// i: item
// },
// nzFooter: null
// });
// modalRef.afterClose.subscribe((res) => {
// if (res) {
// this.resetSF;
// this.st.load();
// }
// });
}
// 批量回复操作
batchReply() {
// if (this.selectedRows.length === 0) {
// this.service.msgSrv.warning('请勾选数据!')
// return;
// }
// const modalRef = this.modal.create({
// nzTitle: '批量回复',
// nzContent: AbnormalreplyBatchComponent,
// nzComponentParams: {
// selectedRows: this.selectedRows
// },
// nzFooter: null
// });
// modalRef.afterClose.subscribe(() => {
// this.resetSF;
// this.st.load();
// });
}
}

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-02-24 20:09:49 * @Date : 2022-02-24 20:09:49
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-21 13:53:31 * @LastEditTime : 2022-03-28 15:39:27
* @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -33,7 +33,7 @@
<nz-option nzValue="jack" nzLabel="Jack"></nz-option> <nz-option nzValue="jack" nzLabel="Jack"></nz-option>
<nz-option nzValue="lucy" nzLabel="Lucy"></nz-option> <nz-option nzValue="lucy" nzLabel="Lucy"></nz-option>
</nz-select> </nz-select>
&nbsp;&nbsp;<span >添加</span> &nbsp;&nbsp;<span (click)="add()">添加</span>
</sv> </sv>
&nbsp;&nbsp;<sv label="优先级" col="1"> &nbsp;&nbsp;<sv label="优先级" col="1">
<nz-select ngModel="lucy" style="max-width: 400px; min-width: 200px;"> <nz-select ngModel="lucy" style="max-width: 400px; min-width: 200px;">
@ -49,6 +49,17 @@
<textarea style="max-width: 400px; min-width: 200px;" rows="4" nz-input [(ngModel)]="inputValue"></textarea> <textarea style="max-width: 400px; min-width: 200px;" rows="4" nz-input [(ngModel)]="inputValue"></textarea>
</sv> </sv>
</sv-container> </sv-container>
<div>
<button>返回</button>
<button>提交</button>
</div>
</div> </div>
</nz-card> </nz-card>
<nz-card>
<div class="align-center">
<button nz-button nzType="primary" (click)="goBack()">取消</button>
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submit()"
acl [acl-ability]="['SUPPLY-VEHICLE-AMEND-submitChange']">提交</button
>
</div>
</nz-card>

View File

@ -1,10 +1,10 @@
/* /*
* @Description : * @Description :
* @Version : 1.0 * @Version : 1.0
* @Author : Shiming * @Author : Shiming
* @Date : 2022-03-21 09:26:45 * @Date : 2022-03-21 09:26:45
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-21 13:44:34 * @LastEditTime : 2022-03-28 14:45:41
* @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\add\\add.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -16,6 +16,7 @@ import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/fo
import { processSingleSort, ShipperBaseService } from '@shared'; import { processSingleSort, ShipperBaseService } from '@shared';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
import { RebateManagementService } from '../../../services/rebate-management.service'; import { RebateManagementService } from '../../../services/rebate-management.service';
import { ParterRebateManageMentAddPartnerListComponent } from '../add-partnerlist/add-partnerlist.component';
@Component({ @Component({
selector: 'app-parter-channel-rebate-management-add', selector: 'app-parter-channel-rebate-management-add',
styleUrls: ['./add.component.less'], styleUrls: ['./add.component.less'],
@ -26,7 +27,7 @@ export class ParterRebateManageMentAddComponent implements OnInit {
toFixedValue: Number = 2; toFixedValue: Number = 2;
radioValue = 'A'; radioValue = 'A';
precision = 2; precision = 2;
inputValue= ''; inputValue = '';
@ViewChild('sf', { static: false }) sf!: SFComponent; @ViewChild('sf', { static: false }) sf!: SFComponent;
schema1!: SFSchema; schema1!: SFSchema;
constructor( constructor(
@ -34,7 +35,7 @@ export class ParterRebateManageMentAddComponent implements OnInit {
public ar: ActivatedRoute, public ar: ActivatedRoute,
public service: RebateManagementService, public service: RebateManagementService,
private modal: NzModalService, private modal: NzModalService,
public shipperservice: ShipperBaseService, public shipperservice: ShipperBaseService
) {} ) {}
initSF(data?: any) { initSF(data?: any) {
this.schema1 = { this.schema1 = {
@ -55,6 +56,28 @@ export class ParterRebateManageMentAddComponent implements OnInit {
}; };
} }
ngOnInit() { ngOnInit() {
this.initSF() this.initSF();
}
submit() {}
goBack() {
window.history.go(-1);
}
/**
*申请退款
*/
add(item?: any) {
const modalRef = this.modal.create({
nzTitle: '申请退款',
nzContent: ParterRebateManageMentAddPartnerListComponent,
nzComponentParams: {
i: item,
},
nzFooter: null
});
modalRef.afterClose.subscribe((res: boolean) => {
if (res) {
}
});
} }
} }

View File

@ -8,7 +8,7 @@
</div> </div>
<div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24" [class.expend-options]="_$expand" <div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24" [class.expend-options]="_$expand"
class="text-right"> class="text-right">
<button nz-button nzType="primary" (click)="st?.load(1)">查询</button> <button nz-button nzType="primary" (click)="search()">查询</button>
<button nz-button (click)="resetSF()">重置</button> <button nz-button (click)="resetSF()">重置</button>
<button nz-button> 导出</button> <button nz-button> 导出</button>
<button nz-button nzType="link" (click)="expandToggle()"> <button nz-button nzType="link" (click)="expandToggle()">
@ -51,12 +51,15 @@
</ng-template> </ng-template>
</st> </st>
<div class=" text-md" *ngIf="st?.list?.length !== 0 "> <div class=" text-md" *ngIf="st?.list?.length !== 0 ">
<span class="mr-md">合伙人数:<label class="text-red-dark font-weight-bold">{{totalInfo?.partnerNum}}</label></span> <span class="mr-md">合伙人数:<label
class="text-red-dark font-weight-bold">{{totalInfo?.invoiceAmountSum}}</label></span>
<span class="mr-md">入账笔数:<label class="text-red-dark font-weight-bold">{{totalInfo?.count}}</label></span> <span class="mr-md">入账笔数:<label class="text-red-dark font-weight-bold">{{totalInfo?.count}}</label></span>
<span class="mr-md">开票金额:<label class="text-red-dark font-weight-bold">{{totalInfo?.invoiceAmount}}</label></span> <span class="mr-md">开票金额:<label
<span class="mr-md">代缴个税:<label class="text-red-dark font-weight-bold">{{totalInfo?.tax}}</label></span> class="text-red-dark font-weight-bold">{{totalInfo?.invoiceEntryNum}}</label></span>
<span class="mr-md">代缴个税:<label
class="text-red-dark font-weight-bold">{{totalInfo?.taxPersonalSum}}</label></span>
<span class="mr-md">入账金额:<label <span class="mr-md">入账金额:<label
class="text-red-dark font-weight-bold">{{totalInfo?.recorededAmount}}</label></span> class="text-red-dark font-weight-bold">{{totalInfo?.recordedAmountSum}}</label></span>
</div> </div>
</div> </div>
</nz-card> </nz-card>

View File

@ -22,11 +22,11 @@ export class PartnerRecordedRecordComponent implements OnInit {
columns!: STColumn[]; columns!: STColumn[];
searchSchema!: SFSchema; searchSchema!: SFSchema;
totalInfo: any = { totalInfo: any = {
partnerNum: 34, invoiceAmountSum: 0,
count: 98, invoiceEntryNum: 0,
invoiceAmount: 978239.98, partnerNum: 0,
tax: 9878.00, recordedAmountSum: 0,
recorededAmount: 728698.98 taxPersonalSum: 0
} }
_$expand = false; _$expand = false;
@ -43,8 +43,6 @@ export class PartnerRecordedRecordComponent implements OnInit {
constructor(public service: RecordedService, private nzModalService: NzModalService, constructor(public service: RecordedService, private nzModalService: NzModalService,
private router: Router, public ar: ActivatedRoute, public shipperSrv: ShipperBaseService) { private router: Router, public ar: ActivatedRoute, public shipperSrv: ShipperBaseService) {
this.accountName = this.ar.snapshot.queryParams?.userIdLabel || '';
this.ltdId = this.ar.snapshot.queryParams?.ltdId || ''; this.ltdId = this.ar.snapshot.queryParams?.ltdId || '';
} }
@ -308,7 +306,7 @@ export class PartnerRecordedRecordComponent implements OnInit {
widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.amount }) } widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.amount }) }
}, },
{ title: '提交时间', index: 'submitTime', width: 160, className: 'text-center' }, { title: '提交时间', index: 'submitTime', width: 180, className: 'text-center' },
{ title: '入账状态', index: 'stsLabel', width: 120, className: 'text-center' }, { title: '入账状态', index: 'stsLabel', width: 120, className: 'text-center' },
{ {
title: '操作', title: '操作',
@ -347,4 +345,19 @@ export class PartnerRecordedRecordComponent implements OnInit {
} }
}); });
} }
search() {
this.st.load(1);
this.getSummary();
}
/**
* 底部统计
*/
getSummary() {
this.service.request(this.service.$api_get_list_summary, { ...this.sf.value }).subscribe(res => {
if (res) {
this.totalInfo = res;
}
})
}
} }

View File

@ -11,6 +11,7 @@ export class RecordedService extends BaseService {
$api_disagree_recorded = ``; // 拒绝审核 $api_disagree_recorded = ``; // 拒绝审核
$api_agree_recorded = ``; // 同意审核 $api_agree_recorded = ``; // 同意审核
$api_audit_recored = `/api/bpc/partnerInvoiceEntry/oprationAudit`; // 审核单据 $api_audit_recored = `/api/bpc/partnerInvoiceEntry/oprationAudit`; // 审核单据
$api_get_list_summary = `/api/bpc/partnerInvoiceEntry/invoiceEntrySummary`; // 每页统计
constructor(public injector: Injector) { constructor(public injector: Injector) {
super(injector); super(injector);
} }

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-27 21:08:36 * @Date : 2021-12-27 21:08:36
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-02-24 10:50:46 * @LastEditTime : 2022-03-25 13:56:06
* @FilePath : \\tms-obc-web\\src\\app\\routes\\passport\\components\\order-agreement\\order-agreement.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\passport\\components\\order-agreement\\order-agreement.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -13,7 +13,7 @@
<h1 class="mb-md mt-md"> <h1 class="mb-md mt-md">
{{ agreementContent?.agreementName }} {{ agreementContent?.agreementName }}
</h1> </h1>
<p class="md">最新版本生效日期:{{ agreementContent?.modifyTime }}</p> <p class="md" *ngIf="agreementContent?.modifyTime">最新版本生效日期:{{ agreementContent?.modifyTime }}</p>
<div [innerHTML]="agreementContent?.agreementContent | safehtml"></div> <div [innerHTML]="agreementContent?.agreementContent || agreementContent?.contractContent | safehtml"></div>
</div> </div>
</div> </div>

View File

@ -1,3 +1,13 @@
/*
* @Description :
* @Version : 1.0
* @Author : Shiming
* @Date : 2022-03-14 14:17:38
* @LastEditors : Shiming
* @LastEditTime : 2022-03-25 13:52:54
* @FilePath : \\tms-obc-web\\src\\app\\routes\\passport\\components\\order-agreement\\order-agreement.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved.
*/
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { ActivatedRoute, Params } from '@angular/router'; import { ActivatedRoute, Params } from '@angular/router';
import { PassportService } from '../../services/passport.service'; import { PassportService } from '../../services/passport.service';
@ -10,16 +20,31 @@ import { PassportService } from '../../services/passport.service';
export class OrderAgreementComponent implements OnInit { export class OrderAgreementComponent implements OnInit {
agreementContent: any; agreementContent: any;
type = 2; type = 2;
data : any;
constructor(private ar: ActivatedRoute, private service: PassportService) { constructor(private ar: ActivatedRoute, private service: PassportService) {
ar.queryParams.subscribe((params: Params) => { ar.queryParams.subscribe((params: Params) => {
this.type = params.type || 2; console.log(params);
this.type = params?.type || 2;
this.data = JSON.parse(params?.data) || {};
}); });
} }
ngOnInit() { ngOnInit() {
this.service.request(this.service.$api_get_agreement, { type: this.type }).subscribe(res => { console.log(this.type);
if (res) { if(this.type == 3) {
this.agreementContent = res; console.log(this.data);
}
}); this.service.request(this.service.$api_get_getSupplementaryAgreement, { billId: this.data?.billId, billCode: this.data?.billCode }).subscribe(res => {
if (res) {
this.agreementContent = res;
}
});
} else {
this.service.request(this.service.$api_get_agreement, { type: this.type }).subscribe(res => {
if (res) {
this.agreementContent = res;
}
});
}
} }
} }

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-27 21:08:36 * @Date : 2021-12-27 21:08:36
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-01-18 17:24:52 * @LastEditTime : 2022-03-24 09:59:50
* @FilePath : \\tms-obc-web\\src\\app\\routes\\passport\\services\\passport.service.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\passport\\services\\passport.service.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -17,6 +17,8 @@ import { BaseService } from 'src/app/shared/services/core/base.service';
export class PassportService extends BaseService { export class PassportService extends BaseService {
// 登录协议,服务订购协议 // 登录协议,服务订购协议
public $api_get_agreement = `/api/mdc/pbc/agreementInfo/getAgreementInfoByType?_allow_anonymous=true`; public $api_get_agreement = `/api/mdc/pbc/agreementInfo/getAgreementInfoByType?_allow_anonymous=true`;
// 查看补充协议
public $api_get_getSupplementaryAgreement = `/api/sdc/billOperate/getSupplementaryAgreement?_allow_anonymous=true`;
// 未登录账号发送验证码 // 未登录账号发送验证码
public $getAccountSMVerificationCode = `/api/mdc/cuc/userBasicInfo/forgetPassword/getAccountSMVerificationCode?_allow_anonymous=true`; public $getAccountSMVerificationCode = `/api/mdc/cuc/userBasicInfo/forgetPassword/getAccountSMVerificationCode?_allow_anonymous=true`;
constructor(public injector: Injector) { constructor(public injector: Injector) {

View File

@ -74,8 +74,8 @@ const routes: Routes = [
{ {
path: 'download', path: 'download',
loadChildren: () => import('./download/download.module').then(m => m.DownloadModule) loadChildren: () => import('./download/download.module').then(m => m.DownloadModule)
} },
] { path: 'datatable', loadChildren: () => import('./datatable/datatable.module').then((m) => m.DatatableModule) },]
}, },
// passport // passport
{ {
@ -100,4 +100,4 @@ const routes: Routes = [
], ],
exports: [RouterModule] exports: [RouterModule]
}) })
export class RouteRoutingModule {} export class RouteRoutingModule { }

View File

@ -2,55 +2,61 @@
* @Description : * @Description :
* @Version : 1.0 * @Version : 1.0
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-21 10:58:48 * @Date : 2022-03-14 14:17:38
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-01-18 17:26:52 * @LastEditTime : 2022-03-24 19:31:03
* @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\add-driver\\add-driver.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\add-driver\\add-driver.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
<div class="modal-header"> <div class="modal-header">
<div class="modal-title">添加司机</div> <div class="modal-title">添加司机</div>
</div> </div>
<!-- <nz-spin *ngIf="!i" class="modal-spin"></nz-spin> -->
<div class="sfBox"> <div class="sfBox">
<sf #sf [compact]="true" [ui]="ui" [schema]="schema" [button]="'none'" *ngIf="schema"> <sf #sf [compact]="true" [ui]="ui" [schema]="schema" [button]="'none'" *ngIf="schema">
<ng-template sf-template="tipsA" let-me let-ui="ui" let-schema="schema"> <ng-template sf-template="tipsA" let-me let-ui="ui" let-schema="schema">
<div class="pr"> <div class="pr">
<dl class="tips"> <dl class="tips">
<dt>正面照</dt> <dt>正面照</dt>
<dd>示例</dd> <dd>示例</dd>
</dl> </dl>
<div class="pa"><img height="104" src="./assets/images/usercenter/certificate-demo-front.png" /></div> <div class="pa"><img height="104" src="./assets/images/usercenter/certificate-demo-front.png" /></div>
</div> </div>
</ng-template> </ng-template>
<ng-template sf-template="tipsB" let-me let-ui="ui" let-schema="schema"> <ng-template sf-template="tipsB" let-me let-ui="ui" let-schema="schema">
<div class="pr"> <div class="pr">
<dl class="tips"> <dl class="tips">
<dt>背面照</dt> <dt>背面照</dt>
<dd>示例</dd> <dd>示例</dd>
</dl> </dl>
<div class="pa"><img height="104" src="./assets/images/usercenter/certificate-demo-back.png" /></div> <div class="pa"><img height="104" src="./assets/images/usercenter/certificate-demo-back.png" /></div>
</div> </div>
</ng-template> </ng-template>
</sf>
<sf #sf1 [compact]="true" [ui]="ui2" [schema]="schema1" [button]="'none'" *ngIf="schema1">
<ng-template sf-template="roadImg" let-me let-ui="ui" let-schema="schema">
<img height="104" src="/assets/images/drivercard.png" class="borderImg" />
</ng-template>
</sf>
<sf #sf2 [compact]="true" [ui]="ui3" [schema]="schema2" [button]="'none'" *ngIf="schema2">
<ng-template sf-template="agreeImg" let-me let-ui="ui" let-schema="schema">
<img height="104" src="/assets/images/jopcard.png" class="borderImg" />
</ng-template>
</sf> </sf>
<sf #sf1 [compact]="true" [ui]="ui" [schema]="schema1" [button]="'none'" *ngIf="schema1"> </sf>
<sf #sf2 [compact]="true" [ui]="ui" [schema]="schema2" [button]="'none'" *ngIf="schema2"> </sf>
<img class="drivercard" height="104" src="/assets/images/drivercard.png" />
<img class="jopcard" height="104" src="/assets/images/jopcard.png" />
<!-- <div class="example" (click)="showExample()"> <!-- <div class="example" (click)="showExample()">
查看示例 查看示例
<div class="popBox" *ngIf="showCardFlag"> <div class="popBox" *ngIf="showCardFlag">
<img src="https://ng.ant.design/assets/img/logo.svg" alt=""> <img src="https://ng.ant.design/assets/img/logo.svg" alt="">
</div> </div>
</div> </div>
<div class="example positionSet" (click)="showJopExample()"> <div class="example positionSet" (click)="showJopExample()">
查看示例 查看示例
<div class="popBox" *ngIf="showJopFlag"> <div class="popBox" *ngIf="showJopFlag">
<img src="https://ng.ant.design/assets/img/logo.svg" alt=""> <img src="https://ng.ant.design/assets/img/logo.svg" alt="">
</div> </div>
</div> --> </div> -->
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button nz-button type="button" (click)="close()">关闭</button> <button nz-button type="button" (click)="close()">关闭</button>
<button nz-button type="button" nzType="primary" (click)="submitForm()">确定</button> <button nz-button type="button" nzType="primary" (click)="submitForm()" [disabled]="!(sf?.valid && sf1?.valid && sf2?.valid)" [nzLoading]="service.http.loading">确定</button>
</div> </div>

View File

@ -1,25 +1,57 @@
.sfBox{
position: relative;
}
.pr { .pr {
position: relative; position: relative;
}
.pa {
position: absolute;
top: 35px;
left: 150px;
img{border: solid 1px #ebf0fb;}
}
.tips {
display: flex;
margin-bottom: 0;
color: #333;
dt {
width: 150px;
} }
.pa { dd {
position: absolute; width: 190px;
top: 35px;
left: 150px;
}
.tips {
display: flex;
margin-bottom: 0; margin-bottom: 0;
color: #333; text-align: center;
}
dt { }
width: 150px; .drivercard{
position: absolute;
top: 620px;
left: 330px;
border: solid 1px #ebf0fb;
}
.jopcard{
position: absolute;
top: 1034px;
left: 330px;
border: solid 1px #ebf0fb;
}
:host{
::ng-deep {
.ant-input-borderless{
padding: 0;
padding-top: 4px;
color: black;
resize:none;
} }
.setCustom .ant-form-item-control{
dd { margin-left: -100px !important
width: 190px; }
margin-bottom: 0; .borderImg{
text-align: center; border: solid 1px #ebf0fb;
} }
} }
}

View File

@ -4,11 +4,12 @@ import { cacheConf } from '@conf/cache.conf';
import { SFComponent, SFUISchema, SFSchema, SFUploadWidgetSchema, SFDateWidgetSchema } from '@delon/form'; import { SFComponent, SFUISchema, SFSchema, SFUploadWidgetSchema, SFDateWidgetSchema } from '@delon/form';
import { _HttpClient } from '@delon/theme'; import { _HttpClient } from '@delon/theme';
import { EACacheService, EAEnvironmentService } from '@shared'; import { EACacheService, EAEnvironmentService } from '@shared';
import { AnyRecord } from 'dns';
import { NzModalRef } from 'ng-zorro-antd/modal'; import { NzModalRef } from 'ng-zorro-antd/modal';
import { Observable, Observer } from 'rxjs'; import { NzUploadFile } from 'ng-zorro-antd/upload';
import { Observable, Observer, of } from 'rxjs';
import { map } from 'rxjs/operators'; import { map } from 'rxjs/operators';
import { SupplyManagementService } from '../../services/supply-management.service'; import { SupplyManagementService } from '../../services/supply-management.service';
@Component({ @Component({
selector: 'app-car-add-driver', selector: 'app-car-add-driver',
templateUrl: './add-driver.component.html', templateUrl: './add-driver.component.html',
@ -21,6 +22,8 @@ export class CarAddDriverComponent implements OnInit {
record: any = {}; record: any = {};
i: any; i: any;
ui: SFUISchema = {}; ui: SFUISchema = {};
ui2: SFUISchema = {};
ui3: SFUISchema = {};
schema: SFSchema = {}; schema: SFSchema = {};
schema1: SFSchema = {}; schema1: SFSchema = {};
schema2: SFSchema = {}; schema2: SFSchema = {};
@ -32,17 +35,18 @@ export class CarAddDriverComponent implements OnInit {
userPracticeSeniorityDTO: {} userPracticeSeniorityDTO: {}
}; };
companyData: any = {}; companyData: any = {};
mobile = ''; mobile = ''
checked = false
constructor( constructor(
private modal: NzModalRef, private modal: NzModalRef,
public service: SupplyManagementService, public service: SupplyManagementService,
private envSrv: EAEnvironmentService, private envSrv: EAEnvironmentService,
private eaCacheSrv: EACacheService private eaCacheSrv: EACacheService,
) {} ) { }
ngOnInit(): void { ngOnInit(): void {
this.companyData = this.eaCacheSrv.get(cacheConf.env); this.companyData = this.eaCacheSrv.get(cacheConf.env)
this.initSF(); this.initSF()
} }
initSF() { initSF() {
this.schema = { this.schema = {
@ -51,44 +55,45 @@ export class CarAddDriverComponent implements OnInit {
title: '司机信息(必填)', title: '司机信息(必填)',
type: 'string', type: 'string',
ui: { ui: {
widget: 'text' widget: 'text',
}, },
default: '照片上传后会自动识别文字并填充下列内容栏' default: '照片上传后会自动识别文字并填充下列内容栏'
}, },
mobile: { mobile: {
title: '手机号', title: '手机号',
type: 'string', type: 'string',
format: 'email',
maxLength: 11, maxLength: 11,
ui: { ui: {
widget: 'text' widget: '',
}, },
default: this.mobile default: this.mobile
}, },
showName: { showName: {
title: '身份证照片', title: '身份证照片',
type: 'string', type: 'string',
readOnly: true,
ui: { ui: {
widget: 'text', widget: 'textarea',
showRequired: true borderless:true,
showRequired: true,
}, },
default: '请上传身份证原件的高清照片,若上传复印件,则需加盖公司印章及法人签字;上传后系统会自动识别并填写' default: '请上传身份证原件的高清照片,若上传复印件,则需加盖公司印章及法人签字;上传后系统会自动识别并填写',
}, },
tipsA: { tipsA: {
title: '', title: '',
type: 'string', type: 'string',
ui: { ui: {
widget: 'custom', widget: 'custom',
offsetControl: 6 offsetControl: 6,
} },
}, },
certificatePhotoFrontWatermark: { certificatePhotoFrontWatermark: {
type: 'string', type: 'string',
title: '', title: '',
ui: { ui: {
offsetControl: 6, offsetControl: 6,
action: apiConf.fileUpload, action: apiConf.waterFileUpload,
fileType: 'image/png,image/jpeg,image/jpg,image/gif', accept: 'image/png,image/jpeg,image/jpg,image/gif',
limit: 1, limit: 1,
limitFileCount: 1, limitFileCount: 1,
resReName: 'data.fullFileWatermarkPath', resReName: 'data.fullFileWatermarkPath',
@ -96,18 +101,32 @@ export class CarAddDriverComponent implements OnInit {
widget: 'upload', widget: 'upload',
descriptionI18n: '图片支持jpg、jpeg、png、gif格式大小不超过2M', descriptionI18n: '图片支持jpg、jpeg、png、gif格式大小不超过2M',
data: { data: {
appId: this.envSrv.env.appId appId: this.envSrv.env.appId,
}, },
name: 'multipartFile', name: 'multipartFile',
multiple: false, multiple: false,
listType: 'picture-card', listType: 'picture-card',
change: args => { change: (args: any) => {
if (args.type === 'success') { if (args.type === 'success') {
this.detailData.certificatePhotoFront = args.file.response.data.fullFilePath; const avatar = [
{
uid: -1,
name: 'LOGO',
status: 'done',
url: args.file.response.data.fullFileWatermarkPath,
response: {
url: args.file.response.data.fullFileWatermarkPath,
},
},
];
this.sf?.setValue('/certificatePhotoFrontWatermark', avatar);
this.detailData.certificatePhotoFront = args.file.response.data.fullFilePath
this.checkIdCard(args.file.response.data.fullFilePath, 'front', 0); this.checkIdCard(args.file.response.data.fullFilePath, 'front', 0);
} else {
this.detailData.certificatePhotoFront = ''
} }
}, },
beforeUpload: (file: any, _fileList) => { beforeUpload: (file: any, _fileList: any) => {
return new Observable((observer: Observer<boolean>) => { return new Observable((observer: Observer<boolean>) => {
const isLt2M = file.size / 1024 / 1024 < 2; const isLt2M = file.size / 1024 / 1024 < 2;
if (!isLt2M) { if (!isLt2M) {
@ -118,24 +137,25 @@ export class CarAddDriverComponent implements OnInit {
observer.next(isLt2M); observer.next(isLt2M);
observer.complete(); observer.complete();
}); });
} },
} as SFUploadWidgetSchema previewFile: (file: NzUploadFile) => of(file.url),
},
}, },
tipsB: { tipsB: {
title: '', title: '',
type: 'string', type: 'string',
ui: { ui: {
widget: 'custom', widget: 'custom',
offsetControl: 6 offsetControl: 6,
} },
}, },
certificatePhotoBackWatermark: { certificatePhotoBackWatermark: {
type: 'string', type: 'string',
title: '', title: '',
ui: { ui: {
offsetControl: 6, offsetControl: 6,
action: apiConf.fileUpload, action: apiConf.waterFileUpload,
fileType: 'image/png,image/jpeg,image/jpg,image/gif', accept: 'image/png,image/jpeg,image/jpg,image/gif',
limit: 1, limit: 1,
limitFileCount: 1, limitFileCount: 1,
resReName: 'data.fullFileWatermarkPath', resReName: 'data.fullFileWatermarkPath',
@ -143,18 +163,32 @@ export class CarAddDriverComponent implements OnInit {
widget: 'upload', widget: 'upload',
descriptionI18n: '图片支持jpg、jpeg、png、gif格式大小不超过2M', descriptionI18n: '图片支持jpg、jpeg、png、gif格式大小不超过2M',
data: { data: {
appId: this.envSrv.env.appId appId: this.envSrv.env.appId,
}, },
name: 'multipartFile', name: 'multipartFile',
multiple: false, multiple: false,
listType: 'picture-card', listType: 'picture-card',
change: args => { change: (args: any) => {
if (args.type === 'success') { if (args.type === 'success') {
this.detailData.certificatePhotoBack = args.file.response.data.fullFilePath; const avatar = [
{
uid: -1,
name: 'LOGO',
status: 'done',
url: args.file.response.data.fullFileWatermarkPath,
response: {
url: args.file.response.data.fullFileWatermarkPath,
},
},
];
this.sf?.setValue('/certificatePhotoBackWatermark', avatar);
this.detailData.certificatePhotoBack = args.file.response.data.fullFilePath
this.checkIdCard(args.file.response.data.fullFilePath, 'back', 0); this.checkIdCard(args.file.response.data.fullFilePath, 'back', 0);
} else {
this.detailData.certificatePhotoBack = ''
} }
}, },
beforeUpload: (file: any, _fileList) => { beforeUpload: (file: any, _fileList: any) => {
return new Observable((observer: Observer<boolean>) => { return new Observable((observer: Observer<boolean>) => {
const isLt2M = file.size / 1024 / 1024 < 2; const isLt2M = file.size / 1024 / 1024 < 2;
if (!isLt2M) { if (!isLt2M) {
@ -165,8 +199,8 @@ export class CarAddDriverComponent implements OnInit {
observer.next(isLt2M); observer.next(isLt2M);
observer.complete(); observer.complete();
}); });
} },
} as SFUploadWidgetSchema previewFile: (file: NzUploadFile) => of(file.url),}
}, },
name: { name: {
title: '姓名', title: '姓名',
@ -174,8 +208,8 @@ export class CarAddDriverComponent implements OnInit {
maxLength: 32, maxLength: 32,
ui: { ui: {
widget: '', widget: '',
placeholder: '请输入姓名' placeholder: '请输入姓名',
} },
}, },
certificateNumber: { certificateNumber: {
title: '身份证号', title: '身份证号',
@ -187,12 +221,17 @@ export class CarAddDriverComponent implements OnInit {
widget: '', widget: '',
placeholder: '请输入法定代表人证件号', placeholder: '请输入法定代表人证件号',
errors: { errors: {
required: '请输入18位身份证号码' required: '请输入18位身份证号码',
} },
} },
} },
}, },
required: ['certificatePhotoFrontWatermark', 'certificatePhotoBackWatermark', 'name', 'certificateNumber'] required: [
'certificatePhotoFrontWatermark',
'certificatePhotoBackWatermark',
'name',
'certificateNumber'
],
}; };
this.schema1 = { this.schema1 = {
properties: { properties: {
@ -200,7 +239,7 @@ export class CarAddDriverComponent implements OnInit {
title: '驾驶证信息(必填)', title: '驾驶证信息(必填)',
type: 'string', type: 'string',
ui: { ui: {
widget: 'text' widget: 'text',
}, },
default: '照片上传后会自动识别文字并填充下列内容栏' default: '照片上传后会自动识别文字并填充下列内容栏'
}, },
@ -209,7 +248,7 @@ export class CarAddDriverComponent implements OnInit {
title: '驾驶证照片', title: '驾驶证照片',
ui: { ui: {
action: apiConf.fileUpload, action: apiConf.fileUpload,
fileType: 'image/png,image/jpeg,image/jpg,image/gif', accept: 'image/png,image/jpeg,image/jpg,image/gif',
limit: 1, limit: 1,
limitFileCount: 1, limitFileCount: 1,
resReName: 'data.fullFileWatermarkPath', resReName: 'data.fullFileWatermarkPath',
@ -217,169 +256,80 @@ export class CarAddDriverComponent implements OnInit {
widget: 'upload', widget: 'upload',
descriptionI18n: '请上传驾驶证照片支持JPG、PNG格式文件小于5M。照片信息缺失、拼凑、过度PS、模糊不清都不会通过审核。', descriptionI18n: '请上传驾驶证照片支持JPG、PNG格式文件小于5M。照片信息缺失、拼凑、过度PS、模糊不清都不会通过审核。',
data: { data: {
appId: this.envSrv.env.appId appId: this.envSrv.env.appId,
}, },
name: 'multipartFile', name: 'multipartFile',
multiple: false, multiple: false,
listType: 'picture-card', listType: 'picture-card',
change: args => { change: (args: any) => {
if (args.type === 'success') { if (args.type === 'success') {
this.detailData.userDriverLicenseDTO.certificatePhoto = args.file.response.data.fullFilePath; this.detailData.userDriverLicenseDTO.certificatePhoto = args.file.response.data.fullFilePath
this.checkDriverCard(args.file.response.data.fullFilePath, 'front', 0); this.checkDriverCard(args.file.response.data.fullFilePath, 'front', 0);
} else {
this.detailData.userDriverLicenseDTO.certificatePhoto = ''
} }
}, },
beforeUpload: (file: any, _fileList) => { beforeUpload: (file: any, _fileList: any) => {
return new Observable((observer: Observer<boolean>) => { return new Observable((observer: Observer<boolean>) => {
const isLt4M = file.size / 1024 / 1024 < 4; const isLt4M = file.size / 1024 / 1024 < 5;
if (!isLt4M) { if (!isLt4M) {
this.service.msgSrv.warning('图片大小超过4M!'); this.service.msgSrv.warning('图片大小超过5M!');
observer.complete(); observer.complete();
return; return;
} }
observer.next(isLt4M); observer.next(isLt4M);
observer.complete(); observer.complete();
}); });
} },
} as SFUploadWidgetSchema previewFile: (file: NzUploadFile) => of(file.url),}
},
roadImg: {
title: '',
type: 'boolean',
// enum: [{ label: '长期', value: true }],
ui: {
widget: 'custom',
}
}, },
licenseNo: { licenseNo: {
title: '驾驶证号', title: '驾驶证号',
type: 'string', type: 'string',
ui: { ui: {
// widget: 'text', // widget: 'text',
placeholder: '请输入' placeholder: '请输入',
} },
// default: this.ar.snapshot.queryParams.licenseNo // default: this.ar.snapshot.queryParams.licenseNo
}, },
driverModel: { driverModel: {
title: '准驾车型', title: '准驾车型',
type: 'string', type: 'string',
enum: [
{ label: 'A1', value: 0 },
{ label: 'B1', value: 1 }
],
ui: {
// widget: this.detailData.commitFlag !== 0 ? 'text' : '',
placeholder: '请输入'
}
},
validStartTime: {
title: '法人证件有效开始日期',
type: 'string',
ui: {
widget: 'date',
format: 'yyyy-MM-dd',
placeholder: '请选择',
errors: {
required: '请选择起始日期'
},
change: i => {}
} as SFDateWidgetSchema
},
validEndTime: {
title: '法人证件有效开始日期',
type: 'string',
ui: {
widget: 'date',
format: 'yyyy-MM-dd',
placeholder: '请选择',
errors: {
required: '请选择起始日期'
},
change: i => {}
} as SFDateWidgetSchema
},
signingOrganization: {
title: '签发机关',
type: 'string',
maxLength: 30,
ui: {
// widget: this.detailData.commitFlag !== 0 ? 'text' : '',
placeholder: '请输入'
}
}
},
required: ['certificatePhotoWatermark', 'licenseNo', 'driverModel', 'validStartTime', 'validEndTime']
};
this.schema2 = {
properties: {
titleC: {
title: '从业资格证(选填)',
type: 'string',
ui: {
widget: 'text'
},
default: '照片上传后会自动识别文字并填充下列内容栏'
},
certificatePhotoWatermark: {
type: 'string',
title: '',
ui: {
offsetControl: 6,
action: apiConf.fileUpload,
fileType: 'image/png,image/jpeg,image/jpg,image/gif',
limit: 1,
limitFileCount: 1,
resReName: 'data.fullFileWatermarkPath',
urlReName: 'data.fullFileWatermarkPath',
widget: 'upload',
descriptionI18n: '图片支持jpg、jpeg、png、gif格式大小不超过5M',
data: {
appId: this.envSrv.env.appId
},
name: 'multipartFile',
multiple: false,
listType: 'picture-card',
change: args => {
if (args.type === 'success') {
this.detailData.userPracticeSeniorityDTO.certificatePhoto = args.file.response.data.fullFilePath;
//this.checkIdCard(args.file.response.data.fullFile, 0, 0);
}
},
beforeUpload: (file: any, _fileList) => {
return new Observable((observer: Observer<boolean>) => {
const isLt2M = file.size / 1024 / 1024 < 2;
if (!isLt2M) {
this.service.msgSrv.warning('图片大小超过2M!');
observer.complete();
return;
}
observer.next(isLt2M);
observer.complete();
});
}
} as SFUploadWidgetSchema
},
licenseNo: {
title: '从业资格证号',
type: 'string',
maxLength: 30,
ui: {
// widget: this.detailData.commitFlag !== 0 ? 'text' : '',
placeholder: '请输入'
}
},
regionCode: {
title: '签发省份',
type: 'string',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', mode: 'multiple',
asyncData: () => this.getProvinceData() containsAllLabel: false,
} as SFDateWidgetSchema placeholder: '请选择准驾车型',
asyncData: () =>
this.service.request(this.service.$api_getDictValue, { dictKey: 'driverModel' }).pipe(
map((data: any) => {
return data.map((m: any) => {
return { label: m.label, value: m.label };
});
}),
),
},
}, },
validStartTime: { validStartTime: {
title: '发证日期', title: '有效期起',
type: 'string', type: 'string',
ui: { ui: {
widget: 'date', widget: 'date',
format: 'yyyy-MM-dd', format: 'yyyy-MM-dd',
placeholder: '请选择', placeholder: '请选择',
errors: { errors: {
required: '请选择起始日期' required: '请选择起始日期',
}, },
change: i => {} change: (i) => { },
} as SFDateWidgetSchema } as SFDateWidgetSchema,
}, },
validEndTime: { validEndTime: {
title: '有效期止', title: '有效期止',
@ -389,67 +339,210 @@ export class CarAddDriverComponent implements OnInit {
format: 'yyyy-MM-dd', format: 'yyyy-MM-dd',
placeholder: '请选择', placeholder: '请选择',
errors: { errors: {
required: '请选择起始日期' required: '请选择终止日期',
}, },
change: i => {} change: (i) => { },
} as SFDateWidgetSchema } as SFDateWidgetSchema,
} },
signingOrganization: {
title: '签发机关',
type: 'string',
maxLength: 30,
ui: {
// widget: this.detailData.commitFlag !== 0 ? 'text' : '',
placeholder: '请输入',
},
},
}, },
required: [] required: [
'certificatePhotoWatermark',
'licenseNo',
'driverModel',
'validStartTime',
'validEndTime',
],
};
this.schema2 = {
properties: {
titleC: {
title: '从业资格证(选填)',
type: 'string',
ui: {
widget: 'text',
},
default: '照片上传后会自动识别文字并填充下列内容栏',
},
certificatePhotoWatermark: {
type: 'string',
title: '',
ui: {
offsetControl: 6,
action: apiConf.fileUpload,
accept: 'image/png,image/jpeg,image/jpg,image/gif',
limit: 1,
limitFileCount: 1,
resReName: 'data.fullFileWatermarkPath',
urlReName: 'data.fullFileWatermarkPath',
widget: 'upload',
descriptionI18n: '图片支持jpg、jpeg、png、gif格式大小不超过5M',
data: {
appId: this.envSrv.env.appId,
},
name: 'multipartFile',
multiple: false,
listType: 'picture-card',
change: (args: any) => {
if (args.type === 'success') {
this.detailData.userPracticeSeniorityDTO.certificatePhoto = args.file.response.data.fullFilePath
this.checkQualificationCertificate(args.file.response.data.fullFilePath);
} else{
this.detailData.userPracticeSeniorityDTO.certificatePhoto = ''
}
},
beforeUpload: (file: any, _fileList: any) => {
return new Observable((observer: Observer<boolean>) => {
const isLt2M = file.size / 1024 / 1024 < 5;
if (!isLt2M) {
this.service.msgSrv.warning('图片大小超过5M!');
observer.complete();
return;
}
observer.next(isLt2M);
observer.complete();
});
},
previewFile: (file: NzUploadFile) => of(file.url),}
},
agreeImg: {
title: '',
type: 'boolean',
// enum: [{ label: '长期', value: true }],
ui: {
widget: 'custom',
}
},
licenseNo: {
title: '从业资格证号',
type: 'string',
maxLength: 30,
ui: {
// widget: this.detailData.commitFlag !== 0 ? 'text' : '',
placeholder: '请输入',
},
},
regionCode: {
title: '签发省份',
type: 'string',
ui: {
widget: 'select',
placeholder: '请选择',
asyncData: () => this.getProvinceData(),
} as SFDateWidgetSchema,
},
validStartTime: {
title: '发证日期',
type: 'string',
ui: {
widget: 'date',
format: 'yyyy-MM-dd',
placeholder: '请选择',
errors: {
required: '请选择起始日期',
},
change: (i) => { },
} as SFDateWidgetSchema,
},
validEndTime: {
title: '有效期止',
type: 'string',
ui: {
widget: 'date',
format: 'yyyy-MM-dd',
placeholder: '请选择',
errors: {
required: '请选择终止日期',
},
change: (i) => { },
} as SFDateWidgetSchema,
},
},
required: [
],
}; };
this.ui = { this.ui = {
'*': { '*': {
spanLabelFixed: 180, spanLabelFixed: 180,
grid: { span: 24 }, grid: { span: 24 },
width: 700 width: 700,
}, },
$title1: {
spanLabelFixed: 0
},
$title2: {
spanLabelFixed: 0
},
$title3: {
spanLabelFixed: 0
},
$title4: {
spanLabelFixed: 0
},
$enterpriseRegistrationTime: {
width: 680
},
$operatingEndTime: {
grid: { span: 9 }
},
$dateType: {
grid: { span: 4 }
},
$validEndTime: {
grid: { span: 9 }
},
$dateType01: {
grid: { span: 4 }
},
$registrationCapital: {
grid: { span: 12 }
},
$unit: {
spanLabelFixed: 20,
grid: { span: 3 }
}
}; };
this.ui2 = {
'*': {
spanLabelFixed: 180,
grid: { span: 18 },
width: 600,
},
$titleB:{
grid: { span: 24 },
},
$certificatePhotoWatermark: {
grid: { span: 12 },
},
$roadImg: {
grid: { span: 4 },
class: 'setCustom'
},
};
this.ui3 = {
'*': {
spanLabelFixed: 180,
grid: { span: 18 },
width: 600,
},
$titleC:{
grid: { span: 24 },
},
$certificatePhotoWatermark: {
grid: { span: 12 },
},
$agreeImg: {
grid: { span: 4 },
class: 'setCustom'
},
};
}
checkQualificationCertificate(imgurl: any) {
// 识别从业资格证 参数side0-正面、1-背面type0-申请人身份证1-法定代表人身份证
const params = {
qualificationCertificateUrl: imgurl,
};
this.service.request(this.service.$api_recognizeQualificationCertificate, params).subscribe((res: any) => {
if (res) {
this.sf2.setValue('/licenseNo', res.certificateNumber);
this.sf2.setValue('/regionCode', res.addressRegionCodes[0]);
res.qualificationCategoryList.forEach((item: any) => {
console.log(item.category.indexOf('道路货物运输驾驶员') !== -1)
if (item.category.indexOf('道路货物运输驾驶员') !== -1) {
this.sf2.setValue('/validStartTime', item.initialIssueDate.split(' ')[0]);
this.sf2.setValue('/validEndTime', item.expiryDate.split(' ')[0]);
}
})
}
});
} }
getProvinceData() { getProvinceData() {
return this.service.request(this.service.$api_getRegionByCode, { regionCode: '' }).pipe( return this.service.request(this.service.$api_getRegionByCode, { regionCode: '' }).pipe(
map((res: any) => { map((res: any) => {
const result: any = []; const result: any = []
if (res) { if (res) {
res.map((m: any) => { res.map((m: any) => {
const item = { label: m.name, value: m.regionCode }; const item = { label: m.name, value: m.regionCode }
result.push(item); result.push(item)
}); });
} }
return result; return result
}) })
); );
} }
@ -457,9 +550,9 @@ export class CarAddDriverComponent implements OnInit {
// 识别身份证 参数side0-正面、1-背面type0-申请人身份证1-法定代表人身份证 // 识别身份证 参数side0-正面、1-背面type0-申请人身份证1-法定代表人身份证
const params = { const params = {
idCardUrl: imgurl, idCardUrl: imgurl,
side side,
}; };
this.service.request(this.service.$api_checkIdCard, params).subscribe((res: any) => { this.service.request(this.service.$api_checkIdCard, params).subscribe((res: any)=> {
if (res) { if (res) {
if (type === 0) { if (type === 0) {
// 法定代表人身份证 // 法定代表人身份证
@ -476,7 +569,7 @@ export class CarAddDriverComponent implements OnInit {
// 识别身份证 参数side0-正面、1-背面type0-申请人身份证1-法定代表人身份证 // 识别身份证 参数side0-正面、1-背面type0-申请人身份证1-法定代表人身份证
const params = { const params = {
driverLicenseUrl: imgurl, driverLicenseUrl: imgurl,
side side,
}; };
this.service.request(this.service.$api_recognizeDriverLicense, params).subscribe((res: any) => { this.service.request(this.service.$api_recognizeDriverLicense, params).subscribe((res: any) => {
if (res) { if (res) {
@ -485,7 +578,7 @@ export class CarAddDriverComponent implements OnInit {
if (side === 'front') { if (side === 'front') {
// 正面 // 正面
this.sf1.setValue('/licenseNo', res.number); this.sf1.setValue('/licenseNo', res.number);
this.sf1.setValue('/driverModel', res.number); this.sf1.setValue('/driverModel', [(res.classType).toUpperCase()]);
this.sf1.setValue('/validStartTime', res.validFrom); this.sf1.setValue('/validStartTime', res.validFrom);
this.sf1.setValue('/validEndTime', res.validTo); this.sf1.setValue('/validEndTime', res.validTo);
this.sf1.setValue('/signingOrganization', res.issuingAuthority); this.sf1.setValue('/signingOrganization', res.issuingAuthority);
@ -497,59 +590,51 @@ export class CarAddDriverComponent implements OnInit {
close(): void { close(): void {
this.modal.destroy(); this.modal.destroy();
} }
showExample() { showExample(){
this.showCardFlag = !this.showCardFlag; this.showCardFlag = !this.showCardFlag
} }
showJopExample() { showJopExample(){
this.showJopFlag = !this.showJopFlag; this.showJopFlag = !this.showJopFlag
} }
submitForm() { submitForm(){
const params: any = { const params:any = {
enterpriseId: this.companyData.enterpriseId,
enterpriseProjectId: this.companyData.projectId,
source: 1, source: 1,
mobile: this.mobile, mobile: this.sf.value.mobile,
identityInfoDTO: { identityInfoDTO:{
...this.sf.value, ...this.sf.value,
certificatePhotoFront: this.detailData.certificatePhotoFront, certificatePhotoFront: this.detailData.certificatePhotoFront,
certificatePhotoBack: this.detailData.certificatePhotoBack certificatePhotoBack: this.detailData.certificatePhotoBack,
}, },
userDriverLicenseDTO: { userDriverLicenseDTO: {
...this.sf1.value, ...this.sf1.value,
certificatePhoto: this.detailData.userDriverLicenseDTO.certificatePhoto certificatePhoto: this.detailData.userDriverLicenseDTO.certificatePhoto,
}, },
userPracticeSeniorityDTO: { userPracticeSeniorityDTO: {
...this.sf2.value, ...this.sf2.value,
certificatePhoto: this.detailData.userPracticeSeniorityDTO.certificatePhoto certificatePhoto: this.detailData.userPracticeSeniorityDTO.certificatePhoto,
} },
}; };
Object.assign(params, { if(params.userPracticeSeniorityDTO.certificatePhoto === '' || params.userPracticeSeniorityDTO.certificatePhotoWatermark === '') {
identityInfoDTO: { delete params.userPracticeSeniorityDTO.certificatePhotoWatermark
certificatePhotoFrontWatermark: this.sf?.value.certificatePhotoFrontWatermark, delete params.userPracticeSeniorityDTO.certificatePhoto
certificatePhotoBackWatermark: this.sf?.value.certificatePhotoBackWatermark }
}, params.userDriverLicenseDTO.driverModel = params.userDriverLicenseDTO.driverModel.join(',')
userDriverLicenseDTO: { delete params.identityInfoDTO.showName;
certificatePhotoWatermark: this.sf?.value.certificatePhotoWatermark
},
userPracticeSeniorityDTO: {
certificatePhotoWatermark: this.sf?.value.certificatePhotoWatermark
}
});
// params.identityInfoDTO.certificatePhotoFrontWatermark = this.sf?.value.certificatePhotoFrontWatermark;
// params.identityInfoDTO.certificatePhotoBackWatermark = this.sf?.value.certificatePhotoBackWatermark;
// params.userDriverLicenseDTO.certificatePhotoWatermark = this.sf1?.value.certificatePhotoWatermark;
// params.userPracticeSeniorityDTO.certificatePhotoWatermark = this.sf2?.value.certificatePhotoWatermark;
delete params.identityInfoDTO.titleA; delete params.identityInfoDTO.titleA;
delete params.identityInfoDTO.titleB; delete params.userDriverLicenseDTO.titleB;
delete params.identityInfoDTO.titleC; delete params.userPracticeSeniorityDTO.titleC;
delete params.userDriverLicenseDTO.tipsA; delete params.userDriverLicenseDTO.tipsA;
delete params.userPracticeSeniorityDTO.tipsC; delete params.userPracticeSeniorityDTO.tipsC;
delete params.showName; if(JSON.stringify(params.userPracticeSeniorityDTO) === '{}') {
params.userPracticeSeniorityDTO = null
}
this.checked = true
this.service.request(this.service.$api_enterpriseVehicleSave, params).subscribe((res: any) => { this.service.request(this.service.$api_enterpriseVehicleSave, params).subscribe((res: any) => {
if (res) { this.checked = false
this.service.msgSrv.success('添加成功'); if(res){
this.modal.close(true); this.service.msgSrv.success('添加成功')
this.modal.close(true)
} }
}); })
} }
} }

View File

@ -119,7 +119,15 @@ export class SupplyManagementVehicleAssignedCarComponent implements OnInit {
nzContent: '<b>该司机还未注册,是否邀请他注册?点击"是"系统将发送邀请短信给司机</b>', nzContent: '<b>该司机还未注册,是否邀请他注册?点击"是"系统将发送邀请短信给司机</b>',
nzOkText: '确定', nzOkText: '确定',
nzCancelText: '取消', nzCancelText: '取消',
nzOnOk: () => console.log('OK') nzOnOk: () => {
this.sendMsg(this.sf?.value?.nameOrPhone).subscribe((res => {
if (res.code === '1') {
this.service.msgSrv.success('发送成功');
} else {
this.service.msgSrv.success('发送失败');
}
}));
}
}); });
return []; return [];
} }
@ -256,5 +264,11 @@ export class SupplyManagementVehicleAssignedCarComponent implements OnInit {
}); });
} }
/**
* 发送邀请司机注册短信
*/
sendMsg(phoneNumber: string) {
return this.service.request(this.service.$api_send_msg_code, phoneNumber)
}
} }

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-12 10:52:50 * @Date : 2022-01-12 10:52:50
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-04 15:45:58 * @LastEditTime : 2022-03-25 16:51:13
* @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\bulk\\bulk.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\bulk\\bulk.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -86,7 +86,7 @@
<ng-template st-row="resourceCode" let-item let-index="index"> <ng-template st-row="resourceCode" let-item let-index="index">
<a [routerLink]="'bulk-detail/' + item?.id">{{ item?.resourceCode }}</a> <a [routerLink]="'bulk-detail/' + item?.id">{{ item?.resourceCode }}</a>
<div>{{ item?.resourceTypeLabel }}{{ item?.serviceTypeLabel }}</div> <div>{{ item?.resourceTypeLabel }}{{ item?.serviceTypeLabel }}</div>
<div>{{ item?.resourceStatusLabel }}</div> <div>{{ item?.resourceStatusLabel === '已完成' ? '已完结' : item?.resourceStatusLabel }}</div>
</ng-template> </ng-template>
<!-- 服务类型 --> <!-- 服务类型 -->
<ng-template st-row="serviceType" let-item let-index="index"> <ng-template st-row="serviceType" let-item let-index="index">

View File

@ -246,7 +246,15 @@ export class PublishGoodsChooseFamifiarComponent implements OnInit {
nzContent: '<b>该司机还未注册,是否邀请他注册?点击"是"系统将发送邀请短信给司机</b>', nzContent: '<b>该司机还未注册,是否邀请他注册?点击"是"系统将发送邀请短信给司机</b>',
nzOkText: '确定', nzOkText: '确定',
nzCancelText: '取消', nzCancelText: '取消',
nzOnOk: () => console.log('OK') nzOnOk: () => {
this.sendMsg(this.sf?.value?.nameOrPhone).subscribe((res => {
if (res.code === '1') {
this.service.msgSrv.success('发送成功');
} else {
this.service.msgSrv.success('发送失败');
}
}));
}
}); });
return []; return [];
} }
@ -327,4 +335,11 @@ export class PublishGoodsChooseFamifiarComponent implements OnInit {
} }
}); });
} }
/**
* 发送邀请司机注册短信
*/
sendMsg(phoneNumber: string) {
return this.service.request(this.service.$api_send_msg_code, phoneNumber)
}
} }

View File

@ -1,15 +1,15 @@
/* /*
* @Description : * @Description :
* @Version : 1.0 * @Version : 1.0
* @Author : Shiming * @Author : Shiming
* @Date : 2022-02-24 20:19:51 * @Date : 2022-02-24 20:19:51
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-10 10:27:21 * @LastEditTime : 2022-03-23 19:57:34
* @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\tran-agreement\\tran-agreement.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\tran-agreement\\tran-agreement.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
/* /*
* @Description : * @Description :
* @Version : 1.0 * @Version : 1.0
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-06 15:01:40 * @Date : 2022-01-06 15:01:40
@ -28,111 +28,136 @@ import { SupplyManagementService } from '../../services/supply-management.servic
styleUrls: ['./tran-agreement.component.less'] styleUrls: ['./tran-agreement.component.less']
}) })
export class TranAgreementComponent { export class TranAgreementComponent {
enterpriseInfo:any; // 网络货运人 enterpriseInfo: any; // 网络货运人
type:any; type: any;
object: any; object: any;
agreement:any; agreement: any;
envCache:any; envCache: any;
shipperName:any; shipperName: any;
constructor(private modal: NzModalRef,public service: SupplyManagementService,) { constructor(private modal: NzModalRef, public service: SupplyManagementService) {}
}
ngOnInit() { ngOnInit() {
console.log(this.object) console.log(this.object);
// 获取托运人承运人信息 // 获取托运人承运人信息
this.service.request(this.service.$api_getContractAtr,{id:this.object?.shipperAppUserId}).subscribe(res => { this.service.request(this.service.$api_getContractAtr, { id: this.object?.shipperAppUserId }).subscribe(res => {
if (res) { if (res) {
this.enterpriseInfo = res this.enterpriseInfo = res;
this.getContent(); this.getContent();
} }
}); });
} }
getContent() { getContent() {
let params:any; let params: any;
if(this.type ==='onecar'){ if (this.type === 'onecar') {
params = {
contractType:'1',
resourceType: '1',
signingObject: '1',
templateType: 'MX',
parametersDTO: {
contractCode:'',
shipperLegalPersonName:this.enterpriseInfo.legalPersonName || '', //托运法定代表人
carrierLegalPersonName:this.enterpriseInfo.netLegalPersonName || '', //承运法定代表人
shipperName:this?.shipperName || '', //托运人
carrierName:this.object?.enterpriseInfoName || '', //承运人
consignorInfo: `${this.object?.unLoadingPlaceDTOList[0]?.appUserName || ''} ${this.object?.unLoadingPlaceDTOList[0]?.contractTelephone || ''}`, // 发货信息
consignorAddress: this.object?.unLoadingPlaceDTOList[0].detailedAddress || '', // 发货地址
consignorDate: this.object?.loadingTime || '', // 发货时间
consigneeInfo: `${this.object?.unLoadingPlaceDTOList[this.object?.unLoadingPlaceDTOList.length-1].appUserName} ${this.object?.unLoadingPlaceDTOList[this.object?.unLoadingPlaceDTOList.length-1].contractTelephone}`, // 收货信息
consigneeDate: this.object?.unloadingTime || '', // 收货时间
consigneeAddress: this.object?.unLoadingPlaceDTOList[this.object?.unLoadingPlaceDTOList.length-1].detailedAddress || '', // 收货地址
goodsName:this.object?.goodsInfoDTOList[0].goodsName || '', // 货物名称
shippingType:'整车运输',
consignmentVolume:`${this.object?.goodsInfoDTOList[0]?.weight || '-'}吨/${this.object?.goodsInfoDTOList[0]?.volume || '-'}方/${this.object?.goodsInfoDTOList[0]?.number || '-'}`, //托运量
transporterInfo:'', //运输方信息
freightAmount:this.object?.total || '', // 订单运费金额(元)
pre:this.object?.expenseDTOList?.filter((item:any) => item.expenseCode === 'PRE')[0].price || '', //预付
rece:this.object?.expenseDTOList?.filter((item:any) => item.expenseCode === 'RECE')[0].price || '',// 到付
back:this.object?.expenseDTOList?.filter((item:any) => item.expenseCode === 'BACK')[0].price || '', // 回单付
lunarKnot:0,
total:this.object?.subtotal || '', // 合计(元)
paymentTime:`到货后${this.object?.paymentDays || ''}`, // 承诺支付运费时间
year:new Date().getFullYear() || '', // 签约年份
month:new Date().getMonth()+1 || '', // 签约月份
day:new Date().getDate() || '', // 签约日期
}
}
} else if(this.type ==='bulk'){
params = { params = {
contractType:'1', contractType: '1',
resourceType: '1',
signingObject: '1',
templateType: 'MX',
parametersDTO: {
contractCode: '',
shipperLegalPersonName: this.enterpriseInfo.legalPersonName || '', //托运法定代表人
carrierLegalPersonName: this.enterpriseInfo.netLegalPersonName || '', //承运法定代表人
shipperName: this?.shipperName || '', //托运人
carrierName: this.object?.enterpriseInfoName || '', //承运人
consignorInfo: `${this.object?.unLoadingPlaceDTOList[0]?.appUserName || ''} ${
this.object?.unLoadingPlaceDTOList[0]?.contractTelephone || ''
}`, // 发货信息
consignorAddress: this.object?.unLoadingPlaceDTOList[0].detailedAddress || '', // 发货地址
consignorDate: this.object?.loadingTime || '', // 发货时间
consigneeInfo: `${this.object?.unLoadingPlaceDTOList[this.object?.unLoadingPlaceDTOList.length - 1].appUserName} ${
this.object?.unLoadingPlaceDTOList[this.object?.unLoadingPlaceDTOList.length - 1].contractTelephone
}`, // 收货信息
consigneeDate: this.object?.unloadingTime || '', // 收货时间
consigneeAddress: this.object?.unLoadingPlaceDTOList[this.object?.unLoadingPlaceDTOList.length - 1].detailedAddress || '', // 收货地址
goodsName: this.object?.goodsInfoDTOList[0].goodsName || '', // 货物名称
shippingType: '整车运输',
consignmentVolume: `${this.object?.goodsInfoDTOList[0]?.weight || '-'}吨/${this.object?.goodsInfoDTOList[0]?.volume || '-'}方/${
this.object?.goodsInfoDTOList[0]?.number || '-'
}`, //托运量
transporterInfo: '', //运输方信息
freightAmount: this.object?.total || '', // 订单运费金额(元)
pre: this.object?.expenseDTOList?.filter((item: any) => item.expenseCode === 'PRE')[0].price || '', //预付
rece: this.object?.expenseDTOList?.filter((item: any) => item.expenseCode === 'RECE')[0].price || '', // 到付
back: this.object?.expenseDTOList?.filter((item: any) => item.expenseCode === 'BACK')[0].price || '', // 回单付
lunarKnot: 0,
total: this.object?.subtotal || '', // 合计(元)
paymentTime: `到货后${this.object?.paymentDays || ''}`, // 承诺支付运费时间
year: new Date().getFullYear() || '', // 签约年份
month: new Date().getMonth() + 1 || '', // 签约月份
day: new Date().getDate() || '' // 签约日期
}
};
} else if (this.type === 'bulk') {
params = {
contractType: '1',
resourceType: '2', resourceType: '2',
signingObject: '1', signingObject: '1',
templateType: 'MX', templateType: 'MX',
parametersDTO: { parametersDTO: {
contractCode:'', contractCode: '',
shipperName:this?.shipperName || '', //托运人 shipperName: this?.shipperName || '', //托运人
carrierName:this.object?.enterpriseInfoName || '', //承运人 carrierName: this.object?.enterpriseInfoName || '', //承运人
shipperLegalPersonName:this.enterpriseInfo.legalPersonName || '', //托运法定代表人 shipperLegalPersonName: this.enterpriseInfo.legalPersonName || '', //托运法定代表人
carrierLegalPersonName:this.enterpriseInfo.netLegalPersonName || '', //承运法定代表人 carrierLegalPersonName: this.enterpriseInfo.netLegalPersonName || '', //承运法定代表人
consignorInfo: `${this.object.unLoadingPlaceDTOList[0]?.appUserName || ''} ${this.object.unLoadingPlaceDTOList[0]?.contractTelephone || ''}`, // 发货信息 consignorInfo: `${this.object.unLoadingPlaceDTOList[0]?.appUserName || ''} ${
this.object.unLoadingPlaceDTOList[0]?.contractTelephone || ''
}`, // 发货信息
consignorAddress: this.object.unLoadingPlaceDTOList[0].detailedAddress, // 发货地址 consignorAddress: this.object.unLoadingPlaceDTOList[0].detailedAddress, // 发货地址
consignorDate: '', // 发货时间 consignorDate: '', // 发货时间
consigneeInfo: `${this.object.unLoadingPlaceDTOList[this.object.unLoadingPlaceDTOList.length-1]?.appUserName || ''} ${this.object.unLoadingPlaceDTOList[this.object.unLoadingPlaceDTOList.length-1]?.contractTelephone || ''}`, // 收货信息 consigneeInfo: `${this.object.unLoadingPlaceDTOList[this.object.unLoadingPlaceDTOList.length - 1]?.appUserName || ''} ${
this.object.unLoadingPlaceDTOList[this.object.unLoadingPlaceDTOList.length - 1]?.contractTelephone || ''
}`, // 收货信息
consigneeDate: '', // 收货时间 consigneeDate: '', // 收货时间
consigneeAddress: this.object.unLoadingPlaceDTOList[this.object.unLoadingPlaceDTOList.length-1]?.detailedAddress || '', // 收货地址 consigneeAddress: this.object.unLoadingPlaceDTOList[this.object.unLoadingPlaceDTOList.length - 1]?.detailedAddress || '', // 收货地址
goodsName:this.object.goodsInfoDTOList[0]?.goodsName || '', // 货物名称 goodsName: this.object.goodsInfoDTOList[0]?.goodsName || '', // 货物名称
shippingType:'大宗运输', shippingType: '大宗运输',
consignmentVolume:`${this.object?.goodsInfoDTOList?.[0]?.weight|| '-'}吨/${this.object?.goodsInfoDTOList?.[0]?.volume || '-'}/${this.object.goodsInfoDTOList?.[0]?.number || '-'}`, //托运量 consignmentVolume: `${this.object?.goodsInfoDTOList?.[0]?.weight || '-'}/${
transporterInfo:'', //运输方信息 this.object?.goodsInfoDTOList?.[0]?.volume || '-'
freightAmount:'', // 订单运费金额(元) }方/${this.object.goodsInfoDTOList?.[0]?.number || '-'}`, //托运量
pre:'', //预付 transporterInfo: '', //运输方信息
rece:'',// 到付 freightAmount: '', // 订单运费金额(元)
back:'',// 回单 pre: '', //
lunarKnot:'', rece: '', // 到付
total:'', // 合计(元) back: '', // 回单付
paymentTime:`到货后${this.object?.paymentDays || ''}`, // 承诺支付运费时间 lunarKnot: '',
year:new Date().getFullYear() || '', // 签约年份 total: '', // 合计(元)
month:new Date().getMonth()+1 || '', // 签约月份 paymentTime: `到货后${this.object?.paymentDays || ''}`, // 承诺支付运费时间
day:new Date().getDate() || '', // 签约日期 year: new Date().getFullYear() || '', // 签约年份
}, month: new Date().getMonth() + 1 || '', // 签约月份
} day: new Date().getDate() || '' // 签约日期
}
};
} }
console.log(params) if (params.parametersDTO.freightAmount) {
this.service.request(this.service.$api_getContractContent,params).subscribe((res) => { params.parametersDTO.freightAmount = this.toThousands(params.parametersDTO.freightAmount);
}
if (params.parametersDTO.pre) {
params.parametersDTO.pre = this.toThousands(params.parametersDTO.pre);
}
if (params.parametersDTO.rece) {
params.parametersDTO.rece = this.toThousands(params.parametersDTO.rece);
}
if (params.parametersDTO.back) {
params.parametersDTO.back = this.toThousands(params.parametersDTO.back);
}
if (params.parametersDTO.total) {
params.parametersDTO.total = this.toThousands(params.parametersDTO.total);
}
console.log(params);
this.service.request(this.service.$api_getContractContent, params).subscribe(res => {
if (res) { if (res) {
this.agreement = res.contractContent; this.agreement = res.contractContent;
} }
}); });
} }
handleOk(){
toThousands(num: any) {
let str = num.toString();
return '¥' + str.replace(/(\d)(?=(?:\d{3})+$)/g, '$1,');
}
handleOk() {
this.modal.close(true); this.modal.close(true);
} }
} }

View File

@ -147,11 +147,52 @@ export class SupplyManagementVehicleComponent implements OnInit {
this.st.load(1); this.st.load(1);
}, 500); }, 500);
} }
/** /**
* 导入货源 * 导入货源
*/ */
importGoodsSource() { } importGoodsSource() {
const modalRef = this.modal.create({
nzTitle: '货源导入',
nzWidth: 600,
nzContent: SupplyManagementImportSupplyComponent,
nzComponentParams: {
// i: item
},
nzFooter: null
});
modalRef.afterClose.subscribe(result => {
if (result) {
const tipsModal = this.modal.create({
nzTitle: '上传提示',
nzWidth: 600,
nzContent: `<div>文件上传完成!成功<span class="text-blue-dark">${result?.successNumber}</span>条,失败<span class="text-red-dark">${result?.failNumber}</span>条!</div>`,
nzFooter: [
{
label: '取 消',
type: 'default',
onClick: () => {
tipsModal.destroy();
}
},
{
label: '下载失败数据',
type: 'primary',
loading: this.service.http.loading,
onClick: () => {
if(!result?.failNumber) {
this.service.msgSrv.error('没有失败数据!');
tipsModal.destroy();
return;
}
this.service.downloadFile(this.service.$api_getFailUploadGoodsOperateResource, result.ids)
tipsModal.destroy();
}
},
]
})
}
});
}
/** /**
* 修改运费 * 修改运费
@ -425,7 +466,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
title: '所属项目', title: '所属项目',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', placeholder: '请选择货主',
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
} }

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-03 11:10:14 * @Date : 2021-12-03 11:10:14
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-07 13:54:46 * @LastEditTime : 2022-03-24 19:35:52
* @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\services\\supply-management.service.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\services\\supply-management.service.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -119,6 +119,8 @@ export class SupplyManagementService extends BaseService {
public $api_getContractContent = '/api/sdc/contractTemplate/getContractContent'; public $api_getContractContent = '/api/sdc/contractTemplate/getContractContent';
// 获取运价 // 获取运价
public $api_getFreight = '/api/mdc/cuc/freightConfig/getFreight'; public $api_getFreight = '/api/mdc/cuc/freightConfig/getFreight';
// 从业资格证
$api_recognizeQualificationCertificate = '/api/mdc/pbc/hwc/ocr/recognizeQualificationCertificate';
/** /**
* 获取车型、车长字典数据 * 获取车型、车长字典数据
* @returns * @returns
@ -175,6 +177,8 @@ export class SupplyManagementService extends BaseService {
$api_asyncExportWholeList = '/api/sdc/goodsResourceOperate/asyncExportWholeList'; $api_asyncExportWholeList = '/api/sdc/goodsResourceOperate/asyncExportWholeList';
// 根据货主ID查询合同签署属性 // 根据货主ID查询合同签署属性
public $api_getContractAtr = '/api/mdc/cuc/enterpriseInfo/cargoOwner/getContractAtr'; public $api_getContractAtr = '/api/mdc/cuc/enterpriseInfo/cargoOwner/getContractAtr';
// 发送邀请司机短信
$api_send_msg_code = `/api/mdc/pbc/smsSend/sendInviteDriver`;
getDictByKey(dictKey: string) { getDictByKey(dictKey: string) {
const params = { dictKey: dictKey }; const params = { dictKey: dictKey };

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-24 15:54:08 * @Date : 2021-12-24 15:54:08
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-02-17 19:58:06 * @LastEditTime : 2022-03-24 11:10:44
* @FilePath : \\tms-obc-web\\src\\app\\routes\\sys-setting\\components\\network-freight\\network-freight.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\sys-setting\\components\\network-freight\\network-freight.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -96,7 +96,7 @@
</st> </st>
</nz-card> </nz-card>
<nz-modal [(nzVisible)]="isVisible" [nzFooter]="nzModalFooter" nzTitle="财务设置" (nzOnOk)="handleOK()" (nzOnCancel)="handleCancel()"> <!-- <nz-modal [(nzVisible)]="isVisible" [nzFooter]="nzModalFooter" nzTitle="财务设置" (nzOnOk)="handleOK()" (nzOnCancel)="handleCancel()">
<ng-container *nzModalContent> <ng-container *nzModalContent>
<sf #sfFre [schema]="addSchema" [ui]="ui2" [formData]="formData" [compact]="false" [button]="'none'"> </sf> <sf #sfFre [schema]="addSchema" [ui]="ui2" [formData]="formData" [compact]="false" [button]="'none'"> </sf>
</ng-container> </ng-container>
@ -104,7 +104,7 @@
<button nz-button nzType="primary" (click)="handleCancel()" [disabled]="">取消</button> <button nz-button nzType="primary" (click)="handleCancel()" [disabled]="">取消</button>
<button nz-button nzType="default" (click)="handleOK()">确 定</button> <button nz-button nzType="default" (click)="handleOK()">确 定</button>
</ng-template> </ng-template>
</nz-modal> </nz-modal> -->
<nz-modal [(nzVisible)]="isVisibleTicket" [nzFooter]="nzModalFooterTiket" nzTitle="财务设置" (nzOnCancel)="handleCancelTicket()"> <nz-modal [(nzVisible)]="isVisibleTicket" [nzFooter]="nzModalFooterTiket" nzTitle="财务设置" (nzOnCancel)="handleCancelTicket()">
<ng-container *nzModalContent> <ng-container *nzModalContent>
@ -117,9 +117,11 @@
</ul> </ul>
</div> </div>
<div nz-col [nzSpan]="18" style="overflow: scroll"> <div nz-col [nzSpan]="18" style="overflow: scroll">
<sf #sfTicket [schema]="ticketSchema" [ui]="ui3" *ngIf="!taxStatus" [formData]="formDataTicket" [compact]="false" [button]="'none'"> <sf #sfTicket [schema]="ticketSchema" [ui]="ui3" *ngIf="TicketStatus" [formData]="formDataTicket" [compact]="false" [button]="'none'">
</sf> </sf>
<sf #sfTax [schema]="TaxSchema" [ui]="ui4" *ngIf="taxStatus" [formData]="formDataTax" [compact]="false" [button]="'none'"> </sf> <sf #sfTax [schema]="TaxSchema" [ui]="ui4" *ngIf="taxStatus" [formData]="formDataTax" [compact]="false" [button]="'none'"> </sf>
<sf #sfNC [schema]="NCSchema" [ui]="ui5" *ngIf="NCStatus" [formData]="formDataNC" [compact]="false" [button]="'none'"> </sf>
</div> </div>
</div> </div>
</ng-container> </ng-container>

View File

@ -1,10 +1,19 @@
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { STComponent, STColumn, STChange } from '@delon/abc/st'; import { STComponent, STColumn, STChange } from '@delon/abc/st';
import { SFCascaderWidgetSchema, SFComponent, SFRadioWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; import {
SFCascaderWidgetSchema,
SFComponent,
SFRadioWidgetSchema,
SFSchema,
SFSchemaEnum,
SFSelectWidgetSchema,
SFUISchema
} from '@delon/form';
import { DynamicSettingModalComponent, SinglepageSettingModalComponent } from '@shared'; import { DynamicSettingModalComponent, SinglepageSettingModalComponent } from '@shared';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
import { takeLast } from 'rxjs/operators'; import { of } from 'rxjs';
import { map, takeLast } from 'rxjs/operators';
import { AccountDetailComponent } from 'src/app/shared/components/account-detail/account-detail.component'; import { AccountDetailComponent } from 'src/app/shared/components/account-detail/account-detail.component';
import { SystemService } from '../../services/system.service'; import { SystemService } from '../../services/system.service';
@ -20,26 +29,33 @@ export class NetworkFreightComponent implements OnInit {
@ViewChild('sfFre', { static: false }) sfFre!: SFComponent; @ViewChild('sfFre', { static: false }) sfFre!: SFComponent;
@ViewChild('sfTicket', { static: false }) sfTicket!: SFComponent; @ViewChild('sfTicket', { static: false }) sfTicket!: SFComponent;
@ViewChild('sfTax', { static: false }) sfTax!: SFComponent; @ViewChild('sfTax', { static: false }) sfTax!: SFComponent;
@ViewChild('sfNC', { static: false }) sfNC!: SFComponent;
ui: SFUISchema = {}; ui: SFUISchema = {};
ui2: SFUISchema = {}; ui2: SFUISchema = {};
ui3: SFUISchema = {}; ui3: SFUISchema = {};
ui4: SFUISchema = {}; ui4: SFUISchema = {};
ui5: SFUISchema = {};
schema: SFSchema = {}; schema: SFSchema = {};
addSchema: SFSchema = {}; addSchema: SFSchema = {};
ticketSchema: SFSchema = {}; ticketSchema: SFSchema = {};
TaxSchema: SFSchema = {}; TaxSchema: SFSchema = {};
_$expand = false; NCSchema: SFSchema = {};
taxStatus = false; _$expand: boolean = false;
taxStatus: boolean = false;
TicketStatus: boolean = true;
NCStatus: boolean = false;
formData: any; formData: any;
ticketId: any; ticketId: any;
ticketItem: any; ticketItem: any;
formDataTicket: any; formDataTicket: any;
formDataNC: any;
formDataTax: any; formDataTax: any;
NCID: string = '';
isVisible = false; isVisible = false;
isVisibleTicket = false; isVisibleTicket = false;
edit = false; edit = false;
editId = false; editId = false;
tabs: any[] = [{ name: '开票设置' }, { name: '税务设置' }]; tabs: any[] = [{ name: '开票设置' }, { name: '税务设置' }, { name: 'NC设置' }];
columns: STColumn[] = [ columns: STColumn[] = [
{ {
@ -109,29 +125,28 @@ export class NetworkFreightComponent implements OnInit {
fixed: 'right', fixed: 'right',
className: 'text-center', className: 'text-center',
buttons: [ buttons: [
{ type: 'divider' },
{ {
text: '基础设置', text: '基础设置<br>',
click: item => this.creat(item) click: item => this.creat(item)
}, },
{ {
text: '财务设置', text: '财务设置<br>',
click: item => this.ticket(item) click: item => this.ticket(item)
}, },
{ {
text: '充值账户', text: '充值账户<br>',
click: item => this.settingPay(item) click: item => this.settingPay(item)
}, },
{ {
text: '应用设置', text: '应用设置<br>',
click: item => this.settingApp(item) click: item => this.settingApp(item)
}, },
{ {
text: '系统配置', text: '系统配置<br>',
click: item => this.settingAction(item) click: item => this.settingAction(item)
}, },
{ type: 'divider' },
// { // {
// text: '合同设置', // text: '合同设置',
// click: item => this.roleAction(item, 2) // click: item => this.roleAction(item, 2)
@ -329,9 +344,9 @@ export class NetworkFreightComponent implements OnInit {
'drawer' 'drawer'
] ]
}; };
this.ui3 = { this.ui3 = {
'*': { spanLabelFixed: 150, grid: { span: 24 } }, '*': { spanLabelFixed: 150, grid: { span: 24 } },
'$taxClassificationVersion': { spanLabelFixed: 150, grid: { span: 24 } }, $taxClassificationVersion: { spanLabelFixed: 150, grid: { span: 24 } }
}; };
} }
initSFTax() { initSFTax() {
@ -350,6 +365,41 @@ export class NetworkFreightComponent implements OnInit {
}; };
this.ui4 = { '*': { spanLabelFixed: 120, grid: { span: 24 } } }; this.ui4 = { '*': { spanLabelFixed: 120, grid: { span: 24 } } };
} }
initSFNC() {
this.NCSchema = {
properties: {
crmCustomerId: {
type: 'string',
title: 'CRM客户编码',
ui: {
widget: 'select',
serverSearch: true,
searchDebounceTime: 300,
searchLoadingText: '搜索中...',
visibleIf: {
_$expand: (value: boolean) => value
},
allowClear: true,
onSearch: (q: any) => {
let str = q.replace(/^\s+|\s+$/g, '');
if (str) {
console.log(str);
return this.service
.request(this.service.$api_get_crmCustomer_page, { customerName: str })
.pipe(map((res: any) => (res.records as any[]).map(i => ({ label: i.customerName, value: i.id } as SFSchemaEnum))))
.toPromise();
} else {
return of([]);
}
}
} as SFSelectWidgetSchema
}
},
required: ['crmCustomerId']
};
this.ui5 = { '*': { spanLabelFixed: 120, grid: { span: 24 } } };
}
initSFFre() { initSFFre() {
this.addSchema = { this.addSchema = {
properties: { properties: {
@ -397,36 +447,62 @@ export class NetworkFreightComponent implements OnInit {
// 财务设置 // 财务设置
ticket(value: any) { ticket(value: any) {
this.formDataTicket = []; this.formDataTicket = [];
this.formDataNC = [];
this.formDataTax = []; this.formDataTax = [];
this.ticketItem = value; this.ticketItem = value;
this.taxStatus = false;
this.TicketStatus = true;
this.NCStatus = false;
this.initSFTax(); this.initSFTax();
this.initSFNC();
this.initSFTicket(); this.initSFTicket();
this.service.request(this.service.$api_getTicketByNetworkTransporterId, { id: value.id }).subscribe((res: any) => { this.NCID = value.id;
if (this.TicketStatus) {
console.log('9999999');
this.service.request(this.service.$api_getTicketByNetworkTransporterId, { id: value.id }).subscribe((res: any) => {
console.log(res);
if (res) {
let List = {
...res
};
delete List.senderRegionCode;
(List.senderRegionCode = this.getProvinceData(res?.senderRegionCode)), (this.formDataTicket = List);
this.ticketId = res.id;
}
});
}
if (this.NCStatus) {
this.getNcSetData();
}
this.isVisibleTicket = true;
}
getNcSetData() {
const List: any = [];
console.log(99999);
this.service.request(this.service.$api_get_crmCustomer, { id: this.ticketItem.crmCustomerId }).subscribe((res: any) => {
console.log(res); console.log(res);
if (res) { if (res) {
let List = { List.push({ label: res.customerName, value: res.id });
...res console.log(List);
};
delete List.senderRegionCode; this.sfNC.getProperty('/crmCustomerId')!.schema.enum = List;
(List.senderRegionCode = this.getProvinceData(res?.senderRegionCode)), (this.formDataTicket = List); this.sfNC.getProperty('/crmCustomerId')!.widget.reset(List);
this.ticketId = res.id; this.sfNC.setValue('/crmCustomerId', res?.id);
} }
}); });
this.isVisibleTicket = true;
} }
getProvinceData(value: any) { getProvinceData(value: any) {
this.service.http.post(this.service.$api_getRegionDetailByCode, { regionCode: value }).subscribe(res => { this.service.http.post(this.service.$api_getRegionDetailByCode, { regionCode: value }).subscribe(res => {
console.log(res.data);
console.log(this.formDataTicket);
let enterpriseAddressCode: any = []; let enterpriseAddressCode: any = [];
let regioin = res?.data?.regionFullCodes.split(','); let regioin = res?.data?.regionFullCodes.split(',');
console.log(regioin);
regioin?.forEach((element: any) => { regioin?.forEach((element: any) => {
enterpriseAddressCode.push(Number(element)); enterpriseAddressCode.push(Number(element));
}); });
console.log(enterpriseAddressCode); if (this.TicketStatus) {
this.sfTicket.setValue('/senderRegionCode', enterpriseAddressCode); this.sfTicket.setValue('/senderRegionCode', enterpriseAddressCode);
return enterpriseAddressCode; return enterpriseAddressCode;
}
}); });
} }
deleteAction(item?: any) { deleteAction(item?: any) {
@ -517,27 +593,55 @@ export class NetworkFreightComponent implements OnInit {
this.isVisibleTicket = false; this.isVisibleTicket = false;
} }
handleOKTicket() { handleOKTicket() {
console.log(this.sfTicket.valid); console.log(this.taxStatus, this.TicketStatus, this.NCStatus);
console.log(this.sfTicket.value); if (this.TicketStatus) {
if (!this.sfTicket.valid) { console.log(this.sfTicket);
this.service.msgSrv.warning('请正确填写完整!'); console.log(this.sfTicket.value);
return;
} if (!this.sfTicket.valid) {
const params = { this.service.msgSrv.warning('请正确填写完整!');
...this.sfTicket.value return;
};
if (this.ticketId) {
params.id = this.ticketId;
}
params.senderRegionCode = this.sfTicket.value.senderRegionCode[2];
console.log(params);
this.service.request(this.service.$api_networkTransporterTicket_save, params).subscribe((res: any) => {
if (res) {
this.service.msgSrv.success('保存成功!');
this.isVisibleTicket = false;
this.st.reload(1);
} }
}); const params = {
...this.sfTicket.value
};
if (this.ticketId) {
params.id = this.ticketId;
}
params.senderRegionCode = this.sfTicket.value.senderRegionCode[2];
console.log(params);
this.service.request(this.service.$api_networkTransporterTicket_save, params).subscribe((res: any) => {
if (res) {
this.service.msgSrv.success('保存成功!');
this.isVisibleTicket = false;
this.st.reload(1);
}
});
} else if (this.NCStatus) {
console.log(this.sfNC);
console.log(this.formDataNC);
console.log(this.sfNC?.value);
if (!this.sfNC.valid) {
this.service.msgSrv.warning('请正确填写完整!');
return;
}
const params = {
...this.sfNC.value
};
if (this.NCID) {
params.id = this.NCID;
}
console.log(params);
this.service.request(this.service.$api_setCrmCustomer, params).subscribe((res: any) => {
if (res) {
this.service.msgSrv.success('保存成功!');
this.isVisibleTicket = false;
this.st.reload(1);
}
});
// api_setCrmCustomer
}
} }
handleOK() { handleOK() {
@ -571,10 +675,18 @@ export class NetworkFreightComponent implements OnInit {
return this.service.request(this.service.$api_get_region_by_code, { regionCode }); return this.service.request(this.service.$api_get_region_by_code, { regionCode });
} }
changeType(value: any) { changeType(value: any) {
console.log(value);
if (value.name === '税务设置') { if (value.name === '税务设置') {
this.taxStatus = true; this.taxStatus = true;
} else { this.TicketStatus = false;
this.NCStatus = false;
} else if (value.name === '开票设置') {
this.TicketStatus = true;
this.NCStatus = false;
this.taxStatus = false;
} else if (value.name === 'NC设置') {
this.getNcSetData();
this.NCStatus = true;
this.TicketStatus = false;
this.taxStatus = false; this.taxStatus = false;
} }
} }

View File

@ -173,6 +173,8 @@ export class SystemService extends BaseService {
$api_ocr_recognize_id_card = '/api/mdc/pbc/hwc/ocr/recognizeIdCard'; $api_ocr_recognize_id_card = '/api/mdc/pbc/hwc/ocr/recognizeIdCard';
// 获取字典 // 获取字典
$api_getDictValue = '/api/mdc/pbc/dictItems/getDictValue'; $api_getDictValue = '/api/mdc/pbc/dictItems/getDictValue';
// 设置crm客户
$api_setCrmCustomer = '/api/mdc/cuc/networkTransporter/setCrmCustomer';
// 获取一、二、三级地区详情 // 获取一、二、三级地区详情
$api_getRegionToThree = '/api/mdc/pbc/region/getRegionToThree'; $api_getRegionToThree = '/api/mdc/pbc/region/getRegionToThree';
$api_getRoleTemplateInfo: string = ''; $api_getRoleTemplateInfo: string = '';

View File

@ -45,12 +45,11 @@
</ng-template> </ng-template>
<st #st [scroll]="{ x: '2000px' }" [data]="service.$api_ficoVatinvHList" [columns]="columns" [page]="{}" <st #st [scroll]="{ x: '2000px' }" [data]="service.$api_ficoVatinvHList" [columns]="columns" [page]="{}"
[req]="{process: beforeReq }" [res]="{process:afterRes }" [loading]="false" [req]="{process: beforeReq }" [res]="{process:afterRes }" [loading]="false" (change)="stChange($event)">
(change)="stChange($event)">
<ng-template st-row="vatinvcode" let-item let-index="index" let-column="column"> <ng-template st-row="vatinvcode" let-item let-index="index" let-column="column">
{{ item.vatinvcode }} <br> {{ item.vatinvcode }} <br>
<label class="text-primary" >{{item.stsLabel}}</label> <label class="text-primary">{{item.stsLabel}}</label>
</ng-template> </ng-template>
</st> </st>
</nz-card> </nz-card>
@ -58,6 +57,28 @@
<ng-template #requestedModal> <ng-template #requestedModal>
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<div nz-col nzSpan="24" se-container [labelWidth]="100"> <div nz-col nzSpan="24" se-container [labelWidth]="100">
<se [col]="1" label="开票信息" class="mb-sm">
<p style="margin: 0;">公司名: {{openInfo?.artoname}}</p>
<p style="margin: 0;">税号: {{openInfo?.artotaxno}}</p>
<p style="margin: 0;">注册地址: {{openInfo?.artoadd}}</p>
<p style="margin: 0;">注册电话: {{openInfo?.artotel}}</p>
<p style="margin: 0;">开户行: {{openInfo?.artobank}}</p>
</se>
<se [col]="1" label="服务名称" class="mb-sm">
{{openInfo?.vatnameLable}}
</se>
<se [col]="1" label="发票备注栏" class="mb-sm">
{{openInfo?.vatremarks}}
</se>
<se [col]="1" label="其它要求" class="mb-sm">
{{openInfo?.otherremarks}}
</se>
<se [col]="1" label="销货清单" class="mb-sm">
{{openInfo?.isdetail?'需要':'不需要'}}
</se>
<se [col]="1" label="开票金额" class="mb-sm">
{{openInfo?.vatnotax | currency}}
</se>
<se [col]="1" label="开票日期" required> <se [col]="1" label="开票日期" required>
<nz-date-picker [(ngModel)]="openInfo.invoicedate" nzPlaceHolder="请选择" style=" width: 100%;"> <nz-date-picker [(ngModel)]="openInfo.invoicedate" nzPlaceHolder="请选择" style=" width: 100%;">
</nz-date-picker> </nz-date-picker>
@ -65,6 +86,9 @@
<se [col]="1" label="发票号码" required> <se [col]="1" label="发票号码" required>
<input nz-input [(ngModel)]="openInfo.invoiceno" placeholder="请输入" /> <input nz-input [(ngModel)]="openInfo.invoiceno" placeholder="请输入" />
</se> </se>
<se [col]="1" label="发票代码" required>
<input nz-input [(ngModel)]="openInfo.invoiceno2" placeholder="请输入" />
</se>
</div> </div>
</div> </div>
</ng-template> </ng-template>

View File

@ -2,9 +2,11 @@ import { CurrencyPipe } from '@angular/common';
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st'; import { STComponent, STColumn, STRequestOptions, STChange } from '@delon/abc/st';
import { SFComponent, SFSchema, SFDateWidgetSchema, SFSelectWidgetSchema } from '@delon/form'; import { SFComponent, SFSchema, SFDateWidgetSchema, SFSelectWidgetSchema, SFSchemaEnum } from '@delon/form';
import { dateTimePickerUtil } from '@delon/util'; import { dateTimePickerUtil } from '@delon/util';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
import { of } from 'rxjs';
import { map } from 'rxjs/operators';
import { TicketService } from '../../services/ticket.service'; import { TicketService } from '../../services/ticket.service';
import { RequestedInvoiceModalComponent } from '../invoice-requested/requested-invoice-modal/requested-invoice-modal.component'; import { RequestedInvoiceModalComponent } from '../invoice-requested/requested-invoice-modal/requested-invoice-modal.component';
import { PushInvoiceComponent } from './push-invoice/push-invoice.component'; import { PushInvoiceComponent } from './push-invoice/push-invoice.component';
@ -29,10 +31,10 @@ export class CancellationInvoiceComponent implements OnInit {
selectedRows: any[] = []; selectedRows: any[] = [];
totalCallNo = 0; totalCallNo = 0;
openInfo: any = { invoicedate: null, invoiceno: null }; openInfo: any = { invoicedate: null, invoiceno: null, invoiceno2: null };
constructor(public service: TicketService, private nzModalService: NzModalService, private router: Router) { } constructor(public service: TicketService, private nzModalService: NzModalService, private router: Router) {}
ngOnInit(): void { } ngOnInit(): void {}
beforeReq = (requestOptions: STRequestOptions) => { beforeReq = (requestOptions: STRequestOptions) => {
if (this.sf) { if (this.sf) {
@ -78,34 +80,41 @@ export class CancellationInvoiceComponent implements OnInit {
* @param item * @param item
*/ */
requestedAction(item: any) { requestedAction(item: any) {
this.openInfo = { invoicedate: null, invoiceno: null }; this.openInfo = { invoicedate: null, invoiceno: null, invoiceno2: null };
const modal = this.nzModalService.create({ this.service.request(this.service.$api_get_apply_fico_info, { id: item.vatappHId }).subscribe(info => {
nzTitle: '发票确认', if (info) {
nzContent: this.requestedModal, console.log(info);
nzOnOk: () => { Object.assign(this.openInfo, { ...info });
if (!this.openInfo?.invoicedate || !this.openInfo?.invoiceno) { const modal = this.nzModalService.create({
this.service.msgSrv.warning('请填开票信息'); nzTitle: '发票确认',
return false; nzContent: this.requestedModal,
} nzOnOk: () => {
const params = { if (!this.openInfo?.invoicedate || !this.openInfo?.invoiceno) {
invoiceno: this.openInfo.invoiceno, this.service.msgSrv.warning('请填开票信息');
invoicedate: dateTimePickerUtil.format(this.openInfo.invoicedate) return false;
};
this.service
.request(this.service.$api_apply_fico_invoic, {
id: item.id,
vatinvcode: item.vatinvcode,
...params
})
.subscribe(res => {
if (res) {
this.service.msgSrv.success('开票成功');
this.st.load(1);
modal.destroy();
} }
}); const params = {
invoiceno: this.openInfo.invoiceno,
invoicedate: dateTimePickerUtil.format(this.openInfo.invoicedate),
invoiceno2: this.openInfo.invoiceno2
};
this.service
.request(this.service.$api_apply_fico_invoic, {
id: item.id,
vatinvcode: item.vatinvcode,
...params
})
.subscribe(res => {
if (res) {
this.service.msgSrv.success('开票成功');
this.st.load(1);
modal.destroy();
}
});
return false; return false;
}
});
} }
}); });
} }
@ -154,7 +163,7 @@ export class CancellationInvoiceComponent implements OnInit {
this.nzModalService.warning({ this.nzModalService.warning({
nzTitle: '确定将所选待确认开票申请撤回?', nzTitle: '确定将所选待确认开票申请撤回?',
nzContent: '提交税控后发票信息不可修改,待税控开票完成后返回开票结果', nzContent: '提交税控后发票信息不可修改,待税控开票完成后返回开票结果',
nzOnOk: () => { } nzOnOk: () => {}
}); });
} }
@ -170,7 +179,7 @@ export class CancellationInvoiceComponent implements OnInit {
this.nzModalService.warning({ this.nzModalService.warning({
nzTitle: '确定将所选待确认开票申请撤回?', nzTitle: '确定将所选待确认开票申请撤回?',
nzContent: '提交税控后发票信息不可修改,待税控开票完成后返回开票结果', nzContent: '提交税控后发票信息不可修改,待税控开票完成后返回开票结果',
nzOnOk: () => { } nzOnOk: () => {}
}); });
} }
@ -196,6 +205,10 @@ export class CancellationInvoiceComponent implements OnInit {
}); });
} }
downLoadDetail(item: any) {
this.service.exportStart({ id: item.id }, this.service.$api_export_invoic_detail);
}
/** /**
* 推送发票 * 推送发票
* @param item * @param item
@ -250,13 +263,16 @@ export class CancellationInvoiceComponent implements OnInit {
placeholder: '请输入' placeholder: '请输入'
} }
}, },
receiveName2: { arto: {
type: 'string', type: 'string',
title: '购买人', title: '购买人',
enum: [{ label: '全部', value: '全部' }],
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择' serverSearch: true,
searchDebounceTime: 300,
searchLoadingText: '搜索中...',
allowClear: true,
onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q })
} }
}, },
ltdId: { ltdId: {
@ -273,7 +289,7 @@ export class CancellationInvoiceComponent implements OnInit {
} }
}, },
sts: { sts: {
title: '结算依据', title: '发票状态',
type: 'string', type: 'string',
ui: { ui: {
widget: 'dict-select', widget: 'dict-select',
@ -369,22 +385,27 @@ export class CancellationInvoiceComponent implements OnInit {
buttons: [ buttons: [
{ type: 'divider' }, { type: 'divider' },
{ {
text: '查看明细', text: '查看明细<br>',
click: item => click: item =>
this.router.navigate(['ticket/cancellation-invoice/detail/' + item.id], { this.router.navigate(['ticket/cancellation-invoice/detail/' + item.id], {
queryParams: { type: 1, expressno: item.expressno, ltdId: item.shipperId } queryParams: { type: 1, expressno: item.expressno, ltdId: item.shipperId }
}) })
}, },
{ {
text: '手工开票', text: '销货清单<br>',
iif: item => item.isdetail,
click: item => this.downLoadDetail(item)
},
{
text: '手工开票<br>',
iif: item => item.sts != '3', iif: item => item.sts != '3',
click: item => this.requestedAction(item) click: item => this.requestedAction(item)
}, },
{ {
text: '推送开票', text: '推送开票<br>',
iif: item => item.sts === '1', iif: item => item.sts === '1',
click: item => this.pushInvoiceAction(item) click: item => this.pushInvoiceAction(item)
}, }
// { // {
// text: '作废发票', // text: '作废发票',
// iif: item => item.sts === '3', // iif: item => item.sts === '3',

View File

@ -34,11 +34,11 @@ export class ExpressDetailModalComponent implements OnInit {
}, },
{ {
title: '金额', title: '金额',
index: 'vatnotax', index: 'vatmoney',
width: 90, width: 90,
type: 'widget', type: 'widget',
className: 'text-right', className: 'text-right',
widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.vatnotax }) } widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.vatmoney }) }
}, },
{ {
title: '税率', title: '税率',
@ -53,7 +53,7 @@ export class ExpressDetailModalComponent implements OnInit {
width: 90, width: 90,
type: 'widget', type: 'widget',
className: 'text-right', className: 'text-right',
widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.vatnotax }) } widget: { type: 'currency-chy', params: ({ record }) => ({ value: record.vattax }) }
}, },
{ title: '开票日期', index: 'invoicedate', type: 'date', width: 150, className: 'text-center' } { title: '开票日期', index: 'invoicedate', type: 'date', width: 150, className: 'text-center' }
]; ];

View File

@ -19,13 +19,13 @@
{{headerInfo?.vatinvHNum}} / {{headerInfo?.vatinvBillNum}} {{headerInfo?.vatinvHNum}} / {{headerInfo?.vatinvBillNum}}
</se> </se>
<se label="已开/全部发票金额"> <se label="已开/全部发票金额">
{{headerInfo?.vatinvHAmount}} / {{headerInfo?.vatinvHNumAmount}} {{headerInfo?.vatinvHAmount |currency}} / {{headerInfo?.vatinvHNumAmount |currency}}
</se> </se>
<se label="已开发票张数"> <se label="已开发票张数">
{{headerInfo?.vatinvHNum}} {{headerInfo?.vatinvHNum}}
</se> </se>
<se label="收件人"> <se label="收件人">
{{headerInfo?.reciname}} {{headerInfo?.reciname}}
</se> </se>
<se label="收件地址"> <se label="收件地址">
{{headerInfo?.provinceName}}{{headerInfo?.cityName}}{{headerInfo?.areaName}}{{headerInfo?.reciaddr}} {{headerInfo?.provinceName}}{{headerInfo?.cityName}}{{headerInfo?.areaName}}{{headerInfo?.reciaddr}}
@ -101,13 +101,13 @@
已选择 已选择
<strong class="text-red">{{ selectedRows.length }}</strong> 条数据&nbsp;&nbsp; 开票金额总计 <strong <strong class="text-red">{{ selectedRows.length }}</strong> 条数据&nbsp;&nbsp; 开票金额总计 <strong
class="text-red">{{ class="text-red">{{
totalCallNo }}</strong> totalCallNo |currency }}</strong>
<a *ngIf="selectedRows.length > 0" (click)="st.clearCheck()" class="ml-lg">清空</a> <a *ngIf="selectedRows.length > 0" (click)="st.clearCheck()" class="ml-lg">清空</a>
</div> </div>
</div> </div>
<st #st [data]="service.$api_get_invoice_requested_order_detail" [columns]="columns" [req]="{ process: beforeReq }" [page]="{}" <st #st [data]="service.$api_get_invoice_requested_order_detail" [columns]="columns" [req]="{ process: beforeReq }"
[res]="{ process: afterRes }" [loading]="false" [scroll]="{ x:'1200px',y: '200px' }" [page]="{}" [res]="{ process: afterRes }" [loading]="false" [scroll]="{ x:'1200px',y: '200px' }"
(change)="stChange($event)"> (change)="stChange($event)">
<ng-template st-row="billHCode" let-item let-index="index" let-column="column"> <ng-template st-row="billHCode" let-item let-index="index" let-column="column">
<a class="text-primary" (click)="routeToOrder(item)"> {{ item.billHCode }}</a> <a class="text-primary" (click)="routeToOrder(item)"> {{ item.billHCode }}</a>

View File

@ -34,27 +34,30 @@
<nz-tab nzTitle="待受理" (nzClick)="selectChange('1')"></nz-tab> <nz-tab nzTitle="待受理" (nzClick)="selectChange('1')"></nz-tab>
<nz-tab nzTitle="处理中" (nzClick)="selectChange('2')"></nz-tab> <nz-tab nzTitle="处理中" (nzClick)="selectChange('2')"></nz-tab>
<nz-tab nzTitle="已拒绝" (nzClick)="selectChange('4')"></nz-tab> <nz-tab nzTitle="已拒绝" (nzClick)="selectChange('4')"></nz-tab>
<nz-tab nzTitle="已完成" (nzClick)="selectChange('3')"></nz-tab> <nz-tab nzTitle="已撤销" (nzClick)="selectChange('5')"></nz-tab>
<nz-tab nzTitle="已受理" (nzClick)="selectChange('3')"></nz-tab>
<nz-tab nzTitle="全部" (nzClick)="selectChange(null)"></nz-tab> <nz-tab nzTitle="全部" (nzClick)="selectChange(null)"></nz-tab>
</nz-tabset> </nz-tabset>
<ng-template #extraTemplate> <ng-template #extraTemplate>
<div class="d-flex align-items-center" *ngIf="resourceStatus==='1' || resourceStatus==='3' || !resourceStatus"> <div class="d-flex align-items-center"
*ngIf="resourceStatus==='1'|| resourceStatus==='2' || resourceStatus==='3' || !resourceStatus">
<div class="mr-md"> <div class="mr-md">
已选择 已选择
<strong class="text-red">{{ selectedRows.length }}</strong> 条数据&nbsp;&nbsp; 开票金额总计 <strong class="text-red">{{ selectedRows.length }}</strong> 条数据&nbsp;&nbsp; 开票金额总计
<strong class="text-red">{{ totalCallNo }}</strong> <strong class="text-red">{{ totalCallNo }}</strong>
<a *ngIf="totalCallNo > 0" (click)="st.clearCheck()" class="ml-lg">清空</a> <a *ngIf="totalCallNo > 0" (click)="st.clearCheck()" class="ml-lg">清空</a>
</div> </div>
<button nz-button *ngIf="resourceStatus==='1' || !resourceStatus" (click)="this.batchRequested()">开票</button> <button nz-button *ngIf="resourceStatus==='1' || !resourceStatus" (click)="this.batchRequested()">批量受理</button>
<!-- <button nz-button (click)="this.rejectAction(selectedRows)">驳回</button> <button nz-button *ngIf="resourceStatus==='1' || !resourceStatus"
<button nz-button (click)="changePice(selectedRows)">修改地址</button>--> (click)="this.rejectAction(selectedRows)">驳回</button>
<button nz-button *ngIf="resourceStatus !=='4' && resourceStatus !=='5'"
(click)="changeAddress(selectedRows)">修改地址</button>
<button nz-button *ngIf="resourceStatus==='3' || !resourceStatus" (click)="printOrder(selectedRows)">打印面单</button> <button nz-button *ngIf="resourceStatus==='3' || !resourceStatus" (click)="printOrder(selectedRows)">打印面单</button>
</div> </div>
</ng-template> </ng-template>
<st #st [data]="service.$api_get_invoice_requested_page" [columns]="columns" [req]="{ process: beforeReq }" <st #st [data]="service.$api_get_invoice_requested_page" [columns]="columns" [req]="{ process: beforeReq }"
[page]="{}" [res]="{ process: afterRes }" [loading]="false" [scroll]="{ x: '1200px' }" [page]="{}" [res]="{ process: afterRes }" [loading]="false" [scroll]="{ x: '1200px' }" (change)="stChange($event)">
(change)="stChange($event)">
<ng-template st-row="vatappcode" let-item let-index="index" let-column="column"> <ng-template st-row="vatappcode" let-item let-index="index" let-column="column">
{{ item.vatappcode }} <br /> {{ item.vatappcode }} <br />
<label class="text-primary">{{item.stsLabel}}</label> <label class="text-primary">{{item.stsLabel}}</label>
@ -66,8 +69,9 @@
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<div nz-col nzSpan="24" se-container [labelWidth]="80"> <div nz-col nzSpan="24" se-container [labelWidth]="80">
<se [col]="1" label="备注" required> <se [col]="1" label="备注" required>
<textarea nz-input rows="3" placeholder="请说明驳回原因" style="width: 325px; margin-left: 14px"></textarea> <textarea nz-input rows="3" [(ngModel)]="rejectReason" placeholder="请说明驳回原因"
style="width: 325px; margin-left: 14px"></textarea>
</se> </se>
</div> </div>
</div> </div>
</ng-template> </ng-template>

View File

@ -12,6 +12,7 @@ import { NzModalService } from 'ng-zorro-antd/modal';
import { TicketService } from '../../services/ticket.service'; import { TicketService } from '../../services/ticket.service';
import { PrintOrderModalComponent } from './print-order-modal/print-order-modal.component'; import { PrintOrderModalComponent } from './print-order-modal/print-order-modal.component';
import { RequestedInvoiceModalComponent } from './requested-invoice-modal/requested-invoice-modal.component'; import { RequestedInvoiceModalComponent } from './requested-invoice-modal/requested-invoice-modal.component';
import { UpdateAddressModalComponent } from './update-address-modal/update-address-modal.component';
@Component({ @Component({
selector: 'app-invoice-requested', selector: 'app-invoice-requested',
@ -33,12 +34,9 @@ export class InvoiceRequestedComponent {
totalCallNo = 0; totalCallNo = 0;
selectedRows: any[] = []; selectedRows: any[] = [];
constructor(
public service: TicketService, rejectReason = '';
private nzModalService: NzModalService, constructor(public service: TicketService, private nzModalService: NzModalService, private router: Router) {}
private router: Router,
public shipperservice: ShipperBaseService
) {}
beforeReq = (requestOptions: STRequestOptions) => { beforeReq = (requestOptions: STRequestOptions) => {
if (this.resourceStatus) { if (this.resourceStatus) {
@ -73,54 +71,84 @@ export class InvoiceRequestedComponent {
} }
rejectAction(item: any[]) { rejectAction(item: any[]) {
this.rejectReason = '';
if (item.length <= 0) {
this.service.msgSrv.warning('请选择开票申请');
return;
}
if (item.find(item => item.sts !== '1')) {
this.service.msgSrv.warning('请勿选择非待处理订单');
return;
}
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '驳回', nzTitle: '驳回',
nzContent: this.rejectModal, nzContent: this.rejectModal,
nzFooter: [ nzOkLoading: this.service.http.loading,
{ nzOnOk: () => {
label: '拒绝', if (!this.rejectReason) {
type: 'default', this.service.msgSrv.warning('请填写驳回原因');
onClick: () => { return false;
modal.destroy();
}
},
{
label: '通过',
type: 'primary',
onClick: () => {
modal.destroy();
}
} }
] let ids = item.map(row => row.id);
this.service.request(this.service.$api_reject_invoice, { id: ids, rejectContent: this.rejectReason }).subscribe(res => {
if (res) {
this.service.msgSrv.success('驳回成功');
modal.destroy(true);
}
});
return false;
}
}); });
modal.afterClose.subscribe(res => { modal.afterClose.subscribe(res => {
this.st.load(); if (res) {
this.st.load();
}
}); });
} }
changePice(item: any[]) { /**
* 修改地址
* @param item
*/
changeAddress(item: any[]) {
this.rejectReason = '';
if (item.length <= 0) {
this.service.msgSrv.warning('请选择开票申请');
return;
}
if (item.find(item => item.sts !== '1')) {
this.service.msgSrv.warning('请勿选择非待处理订单');
return;
}
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '驳回', nzTitle: '修改地址',
nzContent: this.rejectModal, nzContent: UpdateAddressModalComponent,
nzFooter: [ nzOkLoading: this.service.http.loading,
{ nzOnOk: component => {
label: '拒绝', if (!component.sf.valid) {
type: 'default', this.service.msgSrv.warning('表单校验错误');
onClick: () => { return false;
modal.destroy();
}
},
{
label: '通过',
type: 'primary',
onClick: () => {
modal.destroy();
}
} }
] this.service
.request(this.service.$api_update_invoice_address, {
...component.sf.value,
ids: item.map(i => i.id)
})
.subscribe(res => {
if (res) {
this.service.msgSrv.success('修改成功');
modal.destroy(true);
}
});
return false;
}
}); });
modal.afterClose.subscribe(res => { modal.afterClose.subscribe(res => {
this.st.load(); if (res) {
this.st.load();
}
}); });
} }
@ -216,7 +244,7 @@ export class InvoiceRequestedComponent {
requestedInvoiceAction(item: any) { requestedInvoiceAction(item: any) {
const modal = this.nzModalService.create({ const modal = this.nzModalService.create({
nzTitle: '开票', nzTitle: '开票受理',
nzContent: RequestedInvoiceModalComponent, nzContent: RequestedInvoiceModalComponent,
nzWidth: 1200, nzWidth: 1200,
nzComponentParams: { nzComponentParams: {
@ -357,12 +385,14 @@ export class InvoiceRequestedComponent {
title: '货主名称', title: '货主名称',
ui: { ui: {
widget: 'select', widget: 'select',
placeholder: '请选择', serverSearch: true,
searchDebounceTime: 300,
searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
onSearch: (q: any) => this.service.getEnterpriceList({ enterpriseName: q }),
visibleIf: { visibleIf: {
expand: (value: boolean) => value expand: (value: boolean) => value
}, }
asyncData: () => this.shipperservice.getCRM()
} }
} }
} }
@ -440,14 +470,15 @@ export class InvoiceRequestedComponent {
buttons: [ buttons: [
{ type: 'divider' }, { type: 'divider' },
{ {
text: '开票<br/>', text: '开票受理<br/>',
click: item => this.requestedInvoiceAction(item), click: item => this.requestedInvoiceAction(item),
iif: item => item.sts === '1' iif: item => item.sts === '1'
}, },
// { {
// text: '驳回<br/>', text: '驳回申请<br/>',
// click: item => this.rejectAction([item]) click: item => this.rejectAction([item]),
// }, iif: item => item.sts === '1'
},
{ {
text: '订单明细<br/>', text: '订单明细<br/>',
click: item => this.router.navigate([`/ticket/invoice-requested/detail/${item?.id}`], { queryParams: { sts: item.sts } }) click: item => this.router.navigate([`/ticket/invoice-requested/detail/${item?.id}`], { queryParams: { sts: item.sts } })

View File

@ -38,7 +38,7 @@
{{headerInfo?.ordlines}} {{headerInfo?.ordlines}}
</se> </se>
<se label="开票金额"> <se label="开票金额">
{{headerInfo?.vatinvHNumAmount}} {{headerInfo?.vatinvHNumAmount | currency}}
</se> </se>
<se label="服务名称"> <se label="服务名称">
{{headerInfo?.vatnameLabel}} {{headerInfo?.vatnameLabel}}

View File

@ -32,7 +32,6 @@ export class RequestedDetailComponent implements OnInit {
initData() { initData() {
if(this.id) { if(this.id) {
this.service.request(this.service.$api_get_invoice_requested_header_detail, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_get_invoice_requested_header_detail, { id: this.id }).subscribe(res => {
console.log(res);
if (res) { if (res) {
this.headerInfo = res; this.headerInfo = res;
} }
@ -40,7 +39,6 @@ export class RequestedDetailComponent implements OnInit {
} }
if(this.Id) { if(this.Id) {
this.service.request(this.service.$api_get_invoice_requested_header_detail, { id: this.Id }).subscribe(res => { this.service.request(this.service.$api_get_invoice_requested_header_detail, { id: this.Id }).subscribe(res => {
console.log(res);
if (res) { if (res) {
this.headerInfo = res; this.headerInfo = res;
} }

View File

@ -32,5 +32,5 @@
<div class="modal-footer text-center"> <div class="modal-footer text-center">
<button nz-button type="button">移除</button> <button nz-button type="button">移除</button>
<button nz-button type="button" (click)="saveManage()">手工处理</button> <button nz-button type="button" (click)="saveManage()">手工处理</button>
<button nz-button type="submit" nzType="primary" [nzLoading]="false" (click)="saveManage()">自动开票</button> <!-- <button nz-button type="submit" nzType="primary" [nzLoading]="false" (click)="saveManage()">自动开票</button> -->
</div> </div>

View File

@ -7,6 +7,7 @@
* @FilePath : \\tms-obc-web\\src\\app\\routes\\ticket-management\\components\\invoice-requested\\requested-invoice-modal\\requested-invoice-modal.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\ticket-management\\components\\invoice-requested\\requested-invoice-modal\\requested-invoice-modal.component.ts
*/ */
import { Component, ViewChild } from '@angular/core'; import { Component, ViewChild } from '@angular/core';
import { Router } from '@angular/router';
import { STChange, STColumn, STComponent, STRequestOptions } from '@delon/abc/st'; import { STChange, STColumn, STComponent, STRequestOptions } from '@delon/abc/st';
import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal'; import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal';
@ -23,7 +24,7 @@ export class RequestedInvoiceModalComponent {
columns: STColumn[] = this.initST(); columns: STColumn[] = this.initST();
id: any; id: any;
selectedRows: any[] = []; selectedRows: any[] = [];
constructor(public service: TicketService, private nzModalService: NzModalService, private modal: NzModalRef) {} constructor(public service: TicketService, private nzModalService: NzModalService, private modal: NzModalRef, private router: Router) {}
beforeReq = (requestOptions: STRequestOptions) => { beforeReq = (requestOptions: STRequestOptions) => {
Object.assign(requestOptions.body, { vatappHId: this.id }); Object.assign(requestOptions.body, { vatappHId: this.id });
@ -127,8 +128,17 @@ export class RequestedInvoiceModalComponent {
}; };
this.service.request(this.service.$api_get_applyFicoVatinv, params).subscribe((res: any) => { this.service.request(this.service.$api_get_applyFicoVatinv, params).subscribe((res: any) => {
if (res) { if (res) {
this.service.msgSrv.success('开票成功'); this.nzModalService.confirm({
this.modal.destroy(true); nzTitle: '是否进入销票处理页面完成开票',
nzOnOk: () => {
this.service.msgSrv.success('开票成功');
this.modal.destroy(true);
this.router.navigate(['/ticket/cancellation-invoice']);
},
nzOnCancel: () => {
this.modal.destroy(true);
}
});
} }
}); });
} }

View File

@ -0,0 +1 @@
<sf #sf [schema]="schema" [ui]="{ '*': { spanLabelFixed: 110, span:24 } }" [compact]="true" [button]="'none'"></sf>

Some files were not shown because too many files have changed in this diff Show More