Merge branch 'develop' of https://gitlab.eascs.com/tms-ui/tms-obc-web into develop
This commit is contained in:
@ -473,7 +473,7 @@ export class OrderManagementBulkComponent implements OnInit {
|
||||
{
|
||||
text: '变更运费 ',
|
||||
click: _record => this.updateFreight(_record),
|
||||
iif: item => item.billStatus == '4' || item.billStatus == '5' || item.billStatus == '2' || item.billStatus == '3'
|
||||
iif: item => item.billStatus !== '1' && item.billStatus !== '6' && item.overallPaymentStatus != '2'
|
||||
},
|
||||
{
|
||||
text: '确认签收 ',
|
||||
|
||||
@ -424,7 +424,7 @@ resourceStatus: any;
|
||||
{
|
||||
text: '变更运费 ',
|
||||
click: (_record) => this.updateFreight(_record),
|
||||
iif: item => item.billStatus == '4' || item.billStatus == '5' || item.billStatus == '2' || item.billStatus == '3',
|
||||
iif: item => item.billStatus !== '1' && item.billStatus !== '6' && item.overallPaymentStatus != '2',
|
||||
},
|
||||
{
|
||||
text: '确认签收 ',
|
||||
@ -632,7 +632,7 @@ resourceStatus: any;
|
||||
// }
|
||||
});
|
||||
modal.afterClose.subscribe(_ => {
|
||||
this.st.load(1);
|
||||
this.st.load();
|
||||
this.getGoodsSourceStatistical()
|
||||
});
|
||||
}
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2021-12-15 13:17:42
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-02-11 11:06:40
|
||||
* @LastEditTime : 2022-02-14 09:34:18
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\update-freight\\update-freight.component.ts
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
*/
|
||||
@ -126,6 +126,7 @@ export class VehicleUpdateFreightComponent implements OnInit {
|
||||
this.service.msgSrv.error('请填写必填项!');
|
||||
return;
|
||||
}
|
||||
console.log(this.getParams())
|
||||
this.service.request(this.service.$api_get_insertFreightChangeWhole, this.getParams()).subscribe(res => {
|
||||
if (res) {
|
||||
this.modal.destroy(true);
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -4,7 +4,6 @@
|
||||
<button nz-button nzType="primary" (click)="add()">新增公里数</button>
|
||||
<button class="ml-md" nz-button nzType="primary" (click)="save()">保存</button>
|
||||
</div>
|
||||
|
||||
<nz-table #groupingTable [nzData]="data" nzBordered nzSize="small" [nzFrontPagination]="false"
|
||||
[nzScroll]="{ x: '1200px' }" [nzShowPagination]="false" class="ml-xl" style="max-width: 1100px;">
|
||||
<thead>
|
||||
|
||||
@ -1,3 +1,13 @@
|
||||
/*
|
||||
* @Description :
|
||||
* @Version : 1.0
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-01-25 16:03:45
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-02-11 17:12:52
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\shared\\components\\dynamic-setting\\freight-table\\freight-table.component.ts
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
*/
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { BaseService } from '@shared';
|
||||
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-01-25 20:18:52
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-02-09 14:57:23
|
||||
* @LastEditTime : 2022-02-14 10:14:19
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\shared\\components\\insurance-table\\insurance-table.component.html
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
-->
|
||||
@ -14,28 +14,28 @@
|
||||
<button nz-button nzType="primary" (click)="add()">新增公里数</button>
|
||||
<button class="ml-md" nz-button nzType="primary" (click)="save()">保存</button>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<sf #sf [schema]="schema" [formData]="sfdata" [button]="'none'" [ui]="ui">
|
||||
<ng-template sf-template="freightPrice" let-i let-ui="ui">
|
||||
<nz-input-group [nzAddOnAfter]="addOnAfterTemplate">
|
||||
<nz-input-number [(ngModel)]="minInsurancePrice" [nzMin]="0" style="width: 100%"></nz-input-number>
|
||||
</nz-input-group>
|
||||
<ng-template #addOnAfterTemplate>
|
||||
<span >元</span>
|
||||
</ng-template>
|
||||
</ng-template>
|
||||
</sf>
|
||||
|
||||
</div>
|
||||
<nz-table #groupingTable [nzData]="data" nzBordered nzSize="small" [nzFrontPagination]="false"
|
||||
[nzScroll]="{ x: '1200px' }" [nzShowPagination]="false" class="ml-xl" style="max-width: 1100px;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th rowspan="2" nzWidth="250px" nzAlign="center" nzLeft>险种</th>
|
||||
<!-- <th rowspan="2" nzWidth="130px" nzAlign="center">计算方式</th> -->
|
||||
<th nzWidth="220px" nzAlign="center" >普货-基本险</th>
|
||||
<th nzWidth="220px" nzAlign="center" >普货-综合险</th>
|
||||
<th rowspan="2" nzWidth="60px" nzAlign="center" nzRight>操作</th>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<th nzWidth="220px" nzAlign="center" *ngFor="let item of headers;let i = index">
|
||||
<div style="display: flex;align-items: center;justify-content: space-between;">
|
||||
<label style="width: 65px;text-align: right;"> {{item.startLength}}</label>
|
||||
<label>-</label>
|
||||
<nz-input-number [ngModel]="item.endLength" (ngModelChange)="changeEndLength($event,i)"
|
||||
[nzMin]="0" [nzFormatter]="formatterDollar" nzSize="small" class="mr-sm" disabled>
|
||||
</nz-input-number>
|
||||
</div>
|
||||
</th>
|
||||
</tr> -->
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr *ngFor="let item of groupingTable.data;let i = index">
|
||||
@ -55,7 +55,6 @@
|
||||
</div>
|
||||
|
||||
</td>
|
||||
<!-- <td nzWidth="130px" nzAlign="center">{{computeMode[item.computeMode] }}</td> -->
|
||||
<td nzWidth="220px" nzAlign="center" >
|
||||
<div style="display: flex;align-items: center;justify-content: center;" >
|
||||
<nz-input-number [(ngModel)]="item.baseInsuranceRate" [nzMin]="0" nzSize="small" style="width: 55px;"
|
||||
|
||||
@ -1,7 +1,8 @@
|
||||
import { debounceTime } from 'rxjs/operators';
|
||||
import { Subject } from 'rxjs';
|
||||
import { ChangeDetectionStrategy, ChangeDetectorRef, Component, OnInit } from '@angular/core';
|
||||
import { ChangeDetectionStrategy, ChangeDetectorRef, Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { BaseService } from '@shared';
|
||||
import { SFComponent, SFSchema, SFUISchema } from '@delon/form';
|
||||
|
||||
@Component({
|
||||
selector: 'app-insurance-table',
|
||||
@ -11,15 +12,22 @@ import { BaseService } from '@shared';
|
||||
export class InsuranceTableComponent implements OnInit {
|
||||
data: any[] = [];
|
||||
headers: any[] = [];
|
||||
sfdata: any; // 货源单设置回显
|
||||
|
||||
@ViewChild('sf', { static: false }) sf!: SFComponent;
|
||||
schema: SFSchema = {};
|
||||
ui!: SFUISchema;
|
||||
|
||||
formatterDollar = (value: number): string => `${value} (含)`;
|
||||
|
||||
minInsurancePrice: number = 0;
|
||||
changeSub = new Subject<string>();
|
||||
constructor(public service: BaseService, private cdr: ChangeDetectorRef) {}
|
||||
|
||||
ngOnInit(): void {
|
||||
this.loadData();
|
||||
this.initSF()
|
||||
this.changeEndKmAction();
|
||||
this.minInsurancePrice = 1000
|
||||
}
|
||||
|
||||
loadData() {
|
||||
@ -30,8 +38,40 @@ export class InsuranceTableComponent implements OnInit {
|
||||
this.cdr.detectChanges();
|
||||
}
|
||||
});
|
||||
this.service.request('/api/mdc/pbc/sysConfigItem/findItemValueByItemKeys', [
|
||||
"insurance.config.minInsurancePrice"
|
||||
]).subscribe(res => {
|
||||
if (res) {
|
||||
console.log(res);
|
||||
this.minInsurancePrice = Number(res[0].itemValue)
|
||||
}
|
||||
});
|
||||
}
|
||||
initSF() {
|
||||
this.schema = {
|
||||
properties: {
|
||||
freightPrice: {
|
||||
type: 'string',
|
||||
title: '单票投保最低保费',
|
||||
ui: {
|
||||
widget: 'custom',
|
||||
placeholder: '请输入',
|
||||
errors: { required: '请填写' }
|
||||
}
|
||||
},
|
||||
},
|
||||
required: ['freightPrice']
|
||||
};
|
||||
this.ui = {
|
||||
'*': {
|
||||
spanLabelFixed: 140,
|
||||
grid: { span: 24 }
|
||||
},
|
||||
$freightPrice: {
|
||||
grid: { span: 8 }
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改结束车长
|
||||
* @param event 车长
|
||||
@ -111,13 +151,20 @@ export class InsuranceTableComponent implements OnInit {
|
||||
|
||||
save() {
|
||||
console.log(this.data);
|
||||
// this.service.request('/api/mdc/cuc/freightConfig/saveBatch', this.data).subscribe(res => {
|
||||
// if (res) {
|
||||
// console.log(res);
|
||||
// this.service.msgSrv.success('修改成功');
|
||||
// this.loadData();
|
||||
// }
|
||||
// });
|
||||
console.log(this.minInsurancePrice);
|
||||
console.log(this.sf.value);
|
||||
let params= {
|
||||
minInsurancePrice: this.minInsurancePrice,
|
||||
insuranceConfigDTOS: this.data
|
||||
}
|
||||
console.log(params);
|
||||
this.service.request('/api/mdc/cuc/insuranceConfig/saveBatch', params).subscribe(res => {
|
||||
if (res) {
|
||||
console.log(res);
|
||||
this.service.msgSrv.success('修改成功');
|
||||
this.loadData();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-01-25 20:23:54
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-02-09 14:57:05
|
||||
* @LastEditTime : 2022-02-11 17:20:49
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\shared\\components\\insurance-table\\insurance-table.module.ts
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
*/
|
||||
@ -15,17 +15,18 @@ import { NzInputNumberModule } from 'ng-zorro-antd/input-number';
|
||||
import { NzTableModule } from 'ng-zorro-antd/table';
|
||||
import { InsuranceTableComponent } from './insurance-table.component';
|
||||
import { NzPopconfirmModule } from 'ng-zorro-antd/popconfirm';
|
||||
|
||||
const COMPONENTS = [InsuranceTableComponent];
|
||||
import { SHARED_ZORRO_MODULES } from '../../shared-zorro.module';
|
||||
import { SHARED_DELON_MODULES } from '../../shared-delon.module';
|
||||
const COMPONENTS = [InsuranceTableComponent,];
|
||||
const COMPONENTSs = [
|
||||
NzTableModule,
|
||||
NzInputNumberModule,
|
||||
NzPopconfirmModule
|
||||
NzPopconfirmModule,
|
||||
];
|
||||
|
||||
@NgModule({
|
||||
declarations: COMPONENTS,
|
||||
imports: [CommonModule, FormsModule,COMPONENTSs],
|
||||
imports: [CommonModule, FormsModule,COMPONENTSs,SHARED_ZORRO_MODULES, SHARED_DELON_MODULES],
|
||||
exports: COMPONENTS
|
||||
})
|
||||
export class InsuranceTableModule {}
|
||||
|
||||
Reference in New Issue
Block a user