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

This commit is contained in:
Taric Xin
2021-12-08 15:56:26 +08:00
14 changed files with 320 additions and 170 deletions

View File

@ -1,7 +1,15 @@
<!--
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-07 19:51:34
* @LastEditors: your name
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\assigned-car\assigned-car.component.html
-->
<div>
<sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf>
<div>
<st #st [data]="service.$api_get_catalogue_member" [columns]="columns">
</st>
<!-- <st #st [data]="service.$api_get_catalogue_member" [columns]="columns"> -->
<!-- </st> -->
</div>
</div>

View File

@ -1,3 +1,11 @@
/*
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-07 19:51:21
* @LastEditors: your name
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\bulk-detail\bulk-detail.component.ts
*/
import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { STColumn } from '@delon/abc/st';
@ -65,14 +73,14 @@ export class SupplyManagementBulkDetailComponent implements OnInit {
nzTitle: '<i>删除确认</i>',
nzContent: `请仔细核对,避免误操作!<br>是否删除?</br>`,
nzOnOk: () => {
this.service.http.post(this.service.$api_del_driver, { id }).subscribe((res) => {
if (res) {
this.service.msgSrv.success('数据删除成功!');
// this.st1.reload();
} else {
this.service.msgSrv.error('删除失败!');
}
});
// this.service.http.post(this.service.$api_del_driver, { id }).subscribe((res) => {
// if (res) {
// this.service.msgSrv.success('数据删除成功!');
// // this.st1.reload();
// } else {
// this.service.msgSrv.error('删除失败!');
// }
// });
},
});
}

View File

@ -49,7 +49,19 @@
</nz-alert>
</div>
<div style="margin-top: 15px;">
<st #st [data]="url" [columns]="columns">
<st
#st
size="small"
[bordered]="true"
[scroll]="{ x: '2000px' }"
[data]="service.$api_get_bulkPage_list"
[columns]="columns"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
[loadingDelay]="500"
[loading]="service.http.loading"
>
<ng-template st-row="goodsId" let-item let-index="index">
<a [routerLink]="'/supply-management/bulk-detail/'+item.id">{{item.no}}</a>
</ng-template>

View File

@ -53,7 +53,14 @@ export class SupplyManagementBulkComponent implements OnInit {
this.initST();
this.initSFFre();
}
/**
* 查询参数
*/
get reqParams() {
return {
...this.sf?.value,
};
}
/**
* 初始化查询表单
*/
@ -315,13 +322,13 @@ export class SupplyManagementBulkComponent implements OnInit {
getCatalogueMember() {
const params = {
};
return this.service.request(this.service.$api_get_catalogue_member, params, 'GET').pipe(
map((res) => {
if (res) {
console.log(res)
}
}),
);
// return this.service.request(this.service.$api_get_catalogue_member, params, 'GET').pipe(
// map((res) => {
// if (res) {
// console.log(res)
// }
// }),
// );
}
selectChange(e: number) {

View File

@ -1,25 +1,17 @@
<page-header-wrapper [title]="''"></page-header-wrapper>
<page-header-wrapper [title]="'整车发货'" [logo]="logo">
<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>
<div class="card-title">货源单设置</div>
<sf #sf1 [schema]="schema1" [button]="'none'" [ui]="ui1"></sf>
<sf #sf1 [schema]="schema1" [formData]="dataList" [button]="'none'" [ui]="ui1"></sf>
</nz-card>
<nz-card>
<div class="card-title">装卸货信息<span class="tip-font">预计公里数:-km预计行程耗时-小时</span></div>
<!-- <sf #sf2 [schema]="schema2" [button]="'none'" [ui]="ui2">
<ng-template sf-template="name1" let-i let-ui="ui">
<div nz-row class="align-center">
<div nz-col nzSpan="16">
<input nz-input [ngModel]="i.value" (ngModelChange)="i.setValue($event)" />
</div>
<div nz-col nzSpan="8">
<span style="padding: 0 10px"><i nz-icon nzType="menu" nzTheme="outline" style="color: #1890ff"></i></span>
<label nz-checkbox [(ngModel)]="newTempchecked" [ngModelOptions]="{ standalone: true }"></label>
<span style="padding-left: 10px">发布后存入新模板</span>
</div>
</div>
</ng-template>
</sf> -->
<form nz-form [formGroup]="validateForm1" role="form">
<div nz-row [nzGutter]="24">
<div nz-col [nzSpan]="8">

View File

@ -1,8 +1,7 @@
import { Component, OnInit, ViewChild } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { Router } from '@angular/router';
import { FormBuilder, FormGroup } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import {
SFArrayWidgetSchema,
SFComponent,
SFNumberWidgetSchema,
SFSchema,
@ -12,10 +11,9 @@ import {
} from '@delon/form';
import { _HttpClient } from '@delon/theme';
import { AmapPoiPickerComponent } from '@shared';
import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal';
import { NzModalService } from 'ng-zorro-antd/modal';
import { PublishGoodsChooseFamifiarComponent } from '../choose-famifiar/choose-famifiar.component';
import { GaodeMapComponent } from '../gaode-map/gaode-map.component';
import { SupplyManagementService } from '../../services/supply-management.service';
@Component({
selector: 'app-publish-goods-onecar-publish',
templateUrl: './onecar-publish.component.html',
@ -24,7 +22,7 @@ import { GaodeMapComponent } from '../gaode-map/gaode-map.component';
export class SupplyManagementOnecarPublishComponent implements OnInit {
validateForm1: FormGroup;
newTempchecked = false; //是否存入新模板
id = this.route.snapshot.params.id;
// // 单位
unit1 = '吨';
unit2 = '方';
@ -43,10 +41,8 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
phone: '18888888888'
}
];
// formatterRmb = (value: number): string => `¥ ${value}`;
// parserRmb = (value: string): string => value.replace('¥ ', '');
constructor(private http: _HttpClient, fb: FormBuilder, private router: Router, private modalService: NzModalService) {
dataList: any;
constructor(private http: _HttpClient, fb: FormBuilder, private router: Router, private route: ActivatedRoute, private modalService: NzModalService, public service: SupplyManagementService) {
this.validateForm1 = fb.group({
name1: [null, []],
name2: [null, []],
@ -89,12 +85,13 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
this.initSF5();
this.initSF6();
this.initSF7();
this.initdata();
}
initSF1() {
this.schema1 = {
properties: {
name3: {
shipperAdispatchNameppUserNmae: {
type: 'string',
title: '货主',
maxLength: 30,
@ -102,7 +99,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
placeholder: '请输入'
}
},
name4: {
enterpriseProjectName: {
type: 'string',
title: '项目',
enum: [
@ -124,7 +121,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
// change: (i) => this.updateCategory(i, '/categoryId2'),
} as SFSelectWidgetSchema
},
no1: {
enterpriseInfoName: {
type: 'string',
title: '网络货运人',
ui: {
@ -132,7 +129,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
},
default: 0
},
name8: {
externalResourceCode: {
type: 'string',
title: '外部货源号',
maxLength: 30,
@ -140,7 +137,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
placeholder: '请输入'
}
},
name2: {
dispatchName: {
type: 'string',
title: '调度员',
enum: [
@ -494,4 +491,15 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
nzWidth: 848
});
}
goBack() {
window.history.go(-1);
}
// 初始化信息
initdata() {
console.log(this.id)
this.service.request(`${this.service.$api_get_getCompleteVehicleDetail}`, {id:this.id}).subscribe((res) => {
console.log(res)
this.dataList = res;
})
}
}

View File

@ -1,3 +1,11 @@
<!--
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-07 19:50:54
* @LastEditors: your name
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\update-price\update-price.component.html
-->
<div class="mb-lg">
<nz-spin *ngIf="!i" class="modal-spin"></nz-spin>
<sf *ngIf="i" #sf mode="edit" [schema]="schema" [ui]="ui" [formData]="i" button="none">
@ -15,10 +23,10 @@
</div>
<div>
<h4>变更日志</h4>
<st #st [data]="service.$api_get_catalogue_member" [bordered]="true" [columns]="columns" [page]="{show:false}">
<!-- <st #st [data]="service.$api_get_catalogue_member" [bordered]="true" [columns]="columns" [page]="{show:false}">
<ng-template st-row="operator" let-item let-index="index">
<div>黎日湛</div>
<div>18811112222</div>
</ng-template>
</st>
</st> -->
</div>

View File

@ -1,3 +1,11 @@
/*
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-07 19:50:40
* @LastEditors: your name
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\update-price\update-price.component.ts
*/
import { Component, OnInit, ViewChild } from '@angular/core';
import { STColumn } from '@delon/abc/st';
import { SFComponent, SFSchema, SFUISchema } from '@delon/form';

View File

@ -6,17 +6,20 @@
</ng-template>
</page-header-wrapper>
<nz-card>
<nz-spin *ngIf="!i" class="modal-spin"></nz-spin>
<div nz-row>
<div nz-col nzSpan="4">
<div nz-col nzSpan="6">
<sv-container class="bdr">
<sv label="货源编号" col="1">{{ i?.no }}</sv>
<sv-title class="text-center text-lg">待接单</sv-title>
<sv label="货源编号" col="1">{{ dataList?.resourceCode }}</sv>
<sv-title class="text-center text-lg">
<span *ngIf="dataList?.resourceType === 1">待接单</span>
<span *ngIf="dataList?.resourceType === 2">已接单</span>
<span *ngIf="dataList?.resourceType === 3">已取消</span>
</sv-title>
<sv-title>
<div class="">
<a class="btn-size">修改单价</a>
<a class="btn-size" (click)="modification()">修改货源</a>
<a class="btn-size m-lg mr-lg">取消货源</a>
<a class="btn-size">再下一单</a>
<a class="btn-size" (click)="nextOrder()">再下一单</a>
</div>
</sv-title>
</sv-container>
@ -24,70 +27,90 @@
<div nz-col nzSpan="16" class="approval-status">
<nz-steps style="width: 80%; margin: 0 auto" [nzLabelPlacement]="'vertical'">
<nz-step nzStatus="finish" nzIcon="user" [nzDescription]="i?.createAt" nzTitle="下单"></nz-step>
<nz-step nzStatus="finish" nzIcon="solution" nzTitle="完结"></nz-step>
<nz-step nzStatus="finish" nzIcon="user" nzTitle="完结"></nz-step>
</nz-steps>
</div>
</div>
<nz-divider></nz-divider>
<div sv-container *ngIf="i">
<sv label="外部货源号">{{ i?.owner }}</sv>
<sv label="项目名称">32943898021309809423</sv>
<sv label="服务类型">3321944288191034921</sv>
<sv label="录单员">18112345678</sv>
<sv label="调度员">曲丽丽 18100000000 </sv>
<sv label="承诺付款时间">曲丽丽 18100000000 </sv>
<div sv-container >
<sv label="项目名称">{{ dataList?.enterpriseProjectId }}</sv>
<sv label="外部货源号">{{ dataList?.externalResourceCode }}</sv>
<sv label="录单员">{{ dataList?.enterpriseProjectId }}</sv>
<sv label="调度员">{{ dataList?.dispatchName }}</sv>
</div>
<nz-divider></nz-divider>
<div nz-row>
<div nz-col nzSpan="6">
<div class="source-info">
<h3>装卸货信息</h3>
<p>装货地:广东省深圳市龙岗区怡亚通大厦</p>
<p>联系人:奥利给/13680058545</p>
<p>货地:广东省深圳市福田区岗厦村9巷8号405新村</p>
<p>联系人:花花世界/13680058545</p>
<p>发货日期广东省深圳市福田区岗厦村9巷8号405新村</p>
<p>卸货日期:花花世界/13680058545</p>
<div *ngFor="let item of dataList?.unLoadingPlaceList; let i = index">
<h3 *ngIf="i === 0" style="font-weight: 700;">装卸货信息</h3>
<div *ngIf="item?.type === 1">
<p>货地:{{item?.detailedAddress}}</p>
<p>联系人:{{item?.appUserName}}/{{item?.contractTelephone}}</p>
</div>
<div *ngIf="item.type === 2">
<p>卸货地:{{item?.detailedAddress}}</p>
<p>联系人:{{item?.appUserName}}/{{item?.contractTelephone}}</p>
</div>
<p>发货日期:{{item?.createTime}}</p>
<p>卸货日期:{{item?.modifyTime}}</p>
</div>
</div>
<div nz-col nzSpan="6">
</div>
<div nz-col nzSpan="5">
<div class="source-info bdr bdl pl-md">
<h3>货物信息</h3>
<p>货物名称:广东省深圳市龙岗区怡亚通大厦</p>
<p>重量/体积广东省深圳市福田区岗厦村9巷8号405新村</p>
<p>车型/车长:花花世界/13680058545</p>
<div *ngFor="let item of dataList?.goodsInfoList; let i = index">
<h3 *ngIf="i === 0" style="font-weight: 700;">货物信息</h3>
<p>货物名称:{{item?.goodsName}}</p>
<p>货物数量:{{item?.weight}}吨/{{item?.volume}}立方</p>
<p>用车需求:{{item?.vehicleDemand}}</p>
</div>
</div>
<div nz-col nzSpan="6">
</div>
<div nz-col nzSpan="5">
<div class="source-info bdr pl-md">
<h3>承运信息</h3>
<p>司机:广东省深圳市龙岗区怡亚通大厦</p>
<p>车牌号广东省深圳市福田区岗厦村9巷8号405新村</p>
<p>车型/车长/承重:{{'拖车'}} | {{'4.5米'}} | {{'15吨'}}</p>
<h3 style="font-weight: 700;">承运信息</h3>
<p>网络货运人:{{dataList?.carrierInformationVO?.enterpriseInfoName}}</p>
<p>服务类型:{{dataList?.carrierInformationVO?.serviceType === 1 ? '抢单' : '指派'}}</p>
<p>司机姓名:{{dataList?.carrierInformationVO?.driverName}}</p>
<p>手机号:{{dataList?.carrierInformationVO?.driverTelephone}}</p>
<p>车牌号:{{dataList?.carrierInformationVO?.driverLicensePlate}}</p>
</div>
</div>
<div nz-col nzSpan="5">
<div class="source-info bdr pl-md">
<h3 style="font-weight: 700;">服务信息</h3>
<p>货物价值:{{dataList?.goodsInfoList?.goodsName}}</p>
<p>保价费金额:{{dataList?.goodsInfoList?.goodsName}}</p>
</div>
</div>
<div class="source-info pl-md">
<h3>补充信息</h3>
<p>需要回单</p>
<p>备注:奥利给/13680058545</p>
<h3 style="font-weight: 700;">补充信息</h3>
<p>{{dataList?.supplementaryInformationVO?.stateReceipt === 2 ? '不需要回单' : '需要回单'}}</p>
<p>联系人:{{dataList?.supplementaryInformationVO?.receiptUserId}}</p>
<p>联系电话:{{dataList?.supplementaryInformationVO?.remarks}}</p>
<p>所在地区:{{dataList?.supplementaryInformationVO?.remarks}}</p>
<p>详细地址:{{dataList?.supplementaryInformationVO?.receiptAddress}}</p>
<p>备注:{{dataList?.supplementaryInformationVO?.remarks}}</p>
</div>
</div>
<nz-divider></nz-divider>
<div nz-row>
<div class="freight-info-box">
<h3>运费信息</h3>
<h3 style="font-weight: 700;">运费信息</h3>
<div class="text-right">
<p><label class="freigth-label">预付:</label><span>{{400 | currency }}</span></p>
<p><label class="freigth-label">油卡:</label><span>{{400 | currency }}</span></p>
<p><label class="freigth-label">到付:</label><span>{{400 | currency }}</span></p>
<p><label class="freigth-label">回单付:</label><span>{{400 | currency}}</span></p>
<p><label class="freigth-label">附加费:</label><span>{{400 | currency }}</span></p>
<p>预付:{{dataList?.expenseList?.prePay | currency: '¥' }}</p>
<p>油卡:{{dataList?.expenseList?.oilCardPay | currency: '¥'}}</p>
<p>到付:{{dataList?.expenseList?.toPay | currency: '¥'}}</p>
<p>回单付:{{dataList?.expenseList?.receiptPay | currency: '¥'}}</p>
<p>保险费:{{dataList?.expenseList?.insuranceFee | currency: '¥'}}</p>
<p>附加费保险费:{{dataList?.expenseList?.appendFee | currency: '¥'}}</p>
</div>
</div>
<nz-divider></nz-divider>
<div class="freight-info-box" nz-row>
<div nz-col nzSpan="24">
<h3 class="text-right"><label>总计 :</label> <span class="text-error-dark text-xl">{{400 | currency }}</span></h3>
<h3 class="text-right"><label>总计 :</label> <span class="text-error-dark text-xl">{{dataList?.expenseList?.totalFee | currency: '¥' }}</span></h3>
</div>
</div>

View File

@ -1,5 +1,13 @@
/*
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-08 14:35:47
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\vehicle-detail\vehicle-detail.component.ts
*/
import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { ActivatedRoute, Router } from '@angular/router';
import { STColumn } from '@delon/abc/st';
import { _HttpClient } from '@delon/theme';
import { NzMessageService } from 'ng-zorro-antd/message';
@ -14,6 +22,7 @@ export class SupplyManagementVehicleDetailComponent implements OnInit {
id = this.route.snapshot.params.id;
i: any;
dataList: any;
logColumns: STColumn[] = [
{ title: '内容', index: 'theme' },
{ title: '操作人', index: 'operationUserPhone' },
@ -24,18 +33,40 @@ export class SupplyManagementVehicleDetailComponent implements OnInit {
private route: ActivatedRoute,
private msgSrv: NzMessageService,
private service: SupplyManagementService,
private router: Router,private ar: ActivatedRoute
) {
}
ngOnInit(): void {
this.service.http.get(`/user/${this.id}?_allow_anonymous=true&_allow_badcode=true`).subscribe(res => {
console.log(res);
this.i = res
});
console.log(this.id)
if(this.id) {
this.getDetailList(this.id)
}
}
// 获取录单员
getDetailList(id: any) {
const params = {
id: id
};
this.service.request(`${this.service.$api_get_getCompleteVehicleDetail}`, params).subscribe((res) => {
console.log(res)
this.dataList = res
})
}
// 修改货源
modification() {
this.router.navigate(['/supply-management/vehicle-amend', this.id], {
relativeTo: this.ar
})
}
// 再下一单
nextOrder() {
this.router.navigate(['/supply-management/vehicle-amend', this.id], {
relativeTo: this.ar
})
}

View File

@ -1,7 +1,7 @@
<!--
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-03 14:51:38
* @LastEditTime: 2021-12-08 09:57:47
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\vehicle\vehicle.component.html
@ -41,10 +41,6 @@
</nz-tab>
</nz-tabset>
<div style="margin-top: 15px;">
<!-- [req]="{ method: 'GET', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
[loadingDelay]="500" [loading]="service.http.loading" -->
<!-- 选中提示框 -->
<div style="position: relative">
<nz-alert
@ -55,15 +51,32 @@
>
</nz-alert>
</div>
<st #st [scroll]="{ x: '1200px' }" [data]="service.$api_get_catalogue_member" [columns]="columns">
<ng-template st-row="goodsId" let-item let-index="index">
<a [routerLink]="'/supply-management/vehicle-detail/'+item.id">{{item.no}}</a>
<st
#st
size="small"
[bordered]="true"
[scroll]="{ x: '2000px' }"
[data]="service.$api_get_wholePage_list"
[columns]="columns"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
[loadingDelay]="500"
[loading]="service.http.loading"
>
<ng-template st-row="resourceCode" let-item let-index="index">
<a [routerLink]="'/supply-management/vehicle-detail/'+item.id">{{item.resourceCode}}</a>
</ng-template>
<!-- <ng-template st-row="externalSn" let-item let-index="index">
<span class="mr-xs">{{111111}}</span>
<a (click)="editEnternalSn(item)">编辑</a>
</ng-template> -->
<ng-template st-row="enStatusStr27878" let-item let-index="index">
<ng-template st-row="LoadingAddressArr" let-item let-index="index">
<div *ngFor="let i of item?.LoadingAddressArr">
<span>{{item?.LoadingAddressArr[i]}}</span>
</div>
</ng-template>
<ng-template st-row="serviceType" let-item let-index="index">
<span *ngIf="item?.serviceType === 1 || item?.serviceType === '1'">抢单</span>
<span *ngIf="item?.serviceType === 2 || item?.serviceType === '2'">指派</span>
</ng-template>
<ng-template st-row="totalAmount" let-item let-index="index">
<div class="mr-xs" nzPopoverTitle="Title" nz-popover [nzPopoverContent]="contentTemplate">{{item.no}}</div>
</ng-template>
<ng-template #contentTemplate>

View File

@ -16,7 +16,6 @@ import { SupplyManagementUpdateFreightComponent } from '../update-freight/update
styleUrls: ['./vehicle.component.less']
})
export class SupplyManagementVehicleComponent implements OnInit {
url = `/user?_allow_anonymous=true`;
ui: SFUISchema = {};
ui2: SFUISchema = {};
schema: SFSchema = {};
@ -30,32 +29,40 @@ export class SupplyManagementVehicleComponent implements OnInit {
columns: STColumn[] = [];
tabs = [ {
name: '全部',
type: 5,
type: 0,
count: 0,
},
{
name: '待接单',
type: 5,
type: 1,
count: 0,
},
{
name: '已接单',
type: 5,
type: 2,
count: 0,
},
{
name: '已取消',
type: 5,
type: 3,
count: 0,
},
];
resourceStatus: any;
constructor(public service: SupplyManagementService, private modal: NzModalService, private router: Router,private ar: ActivatedRoute) { }
/**
* 查询参数
*/
get reqParams() {
console.log(this.resourceStatus)
const a:any = {};
if(this.resourceStatus) {
a.resourceStatus = this.resourceStatus
}
console.log(a)
return {
...a,
...this.sf?.value,
};
}
@ -77,35 +84,35 @@ export class SupplyManagementVehicleComponent implements OnInit {
this.schema = {
properties: {
_$expand: { type: 'boolean', ui: { hidden: true } },
no: {
resourceCode: {
type: 'string',
title: '货源编号',
},
sex2: {
serviceType: {
title: '服务类型',
type: 'string',
default: 0,
enum: [
{ label: '未知', value: 0 },
{ label: '', value: 1 },
{ label: '女', value: 2 },
{ label: '保密', value: 3 },
{ label: '抢单', value: 1 },
{ label: '指派', value: 2 },
],
ui: {
widget: 'select',
} as SFSelectWidgetSchema,
},
categoryId: {
goodsName: {
type: 'string',
title: '货物名称',
// enum: this.secondCatList || [],
enum: [
{ label: '普货', value: 1 },
{ label: '指派', value: 2 },
],
ui: {
widget: 'select',
placeholder: '请选择',
} as SFSelectWidgetSchema,
},
no2: {
loadingPlace: {
type: 'string',
title: '装货地',
ui: {
@ -114,7 +121,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
},
}
},
no1: {
dischargePlace: {
type: 'string',
title: '卸货地',
ui: {
@ -123,7 +130,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
},
}
},
no4: {
shipperAppUserName: {
type: 'string',
title: '货主',
ui: {
@ -132,15 +139,14 @@ export class SupplyManagementVehicleComponent implements OnInit {
},
}
},
sex: {
auditStatus: {
title: '审核状态',
type: 'string',
default: 0,
enum: [
{ label: '未知', value: 0 },
{ label: '', value: 1 },
{ label: '', value: 2 },
{ label: '保密', value: 3 },
{ label: '待审核', value: 1 },
{ label: '审核通过', value: 2 },
{ label: '不通过', value: 3 },
{ label: '已取消', value: 4 },
],
ui: {
widget: 'select',
@ -149,7 +155,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
},
} as SFSelectWidgetSchema,
},
appId: {
enterpriseInfoName: {
type: 'string',
title: '网络货运人',
ui: {
@ -159,7 +165,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
_$expand: (value: boolean) => value,
},
allowClear: true,
asyncData: () => this.getCatalogueMember(),
// asyncData: () => this.getCatalogueMember(),
},
},
},
@ -193,26 +199,31 @@ export class SupplyManagementVehicleComponent implements OnInit {
title: '货源编号',
width: '100px',
className: 'text-center',
render: 'goodsId'
render: 'resourceCode'
},
{ title: '服务类型', index: 'externalSn', width: '120px', className: 'text-center' },
{ title: '货主', index: 'linkUrl', width: '120px', className: 'text-center' },
{ title: '服务类型', index: 'serviceType', width: '120px', className: 'text-center',render: 'serviceType'},
{ title: '货主', index: 'shipperAppUserName', width: '120px', className: 'text-center' },
{
title: '项目名称',
index: 'enterpriseProjectName',
className: 'text-center',
width: '120px',
},
{
title: '装货地',
index: 'loadingAddressArr',
className: 'text-center',
width: '120px',
render: 'loadingAddressArr'
}, {
title: '卸货地',
index: 'unloadingAddressArr',
className: 'text-center',
width: '120px',
},
{
title: '货物名称',
index: 'goodsName',
className: 'text-center',
width: '120px',
},
@ -220,9 +231,12 @@ export class SupplyManagementVehicleComponent implements OnInit {
title: '货物数量',
className: 'text-center',
width: '120px',
index: 'goodsNumber',
},
{
title: '用车需求',
index: 'vehicleDemand',
className: 'text-center',
width: '120px',
},
@ -230,41 +244,43 @@ export class SupplyManagementVehicleComponent implements OnInit {
title: '总费用',
className: 'text-center',
width: '120px',
index: 'goodsId',
render: 'enStatusStr27878'
index: 'totalAmount',
render: 'totalAmount'
},
{
title: '附加费',
className: 'text-center',
width: '120px',
index: 'surcharge',
},
{
title: '货源状态',
className: 'text-center',
index: 'enStatusStr2',
index: 'resourceStatus',
type: 'badge',
width: '120px',
badge: {
: { text: '正常', color: 'success' },
: { text: '冻结', color: 'warning' },
: { text: '废弃', color: 'default' },
1: { text: '待接单', color: 'success' },
2: { text: '已接单', color: 'warning' },
},
},
{
title: '创建时间',
width: '170px',
index: 'releaseTime',
className: 'text-center',
},
{
title: '审核状态',
className: 'text-center',
index: 'enStatusStr3',
index: 'auditStatus',
type: 'badge',
width: '170px',
badge: {
: { text: '正常', color: 'success' },
: { text: '冻结', color: 'warning' },
: { text: '废弃', color: 'default' },
1: { text: '待审核', color: 'warning' },
2: { text: '审核通过', color: 'success' },
3: { text: '不通过', color: 'default' },
4: { text: '已取消', color: 'default' },
},
},
{
@ -276,10 +292,12 @@ export class SupplyManagementVehicleComponent implements OnInit {
{
text: '货源审核',
click: (_record) => this.audit(_record, 1),
// iif: item => item.auditStatus === 1,
},
{
text: '修改货源',
click: (_record) => this.amend(_record),
// iif: item => item.auditStatus === 1 || item.auditStatus === 2,
},
{
text: '修改运费',
@ -287,15 +305,17 @@ export class SupplyManagementVehicleComponent implements OnInit {
},
{
text: '取消货源',
// iif: item => item.auditStatus === 1 || item.auditStatus === 2,
// click: (_record) => this.delOne(_record),
},
{
text: '再下一单',
// click: (_record) => this.editOne(_record),
click: (_record) => this.nextOrder(_record),
},
{
text: '重新指派',
click: (_record) => this.assignedCar(_record),
// iif: item => item.auditStatus === 2,
},
],
},
@ -332,21 +352,14 @@ export class SupplyManagementVehicleComponent implements OnInit {
// 获取录单员
getCatalogueMember() {
const params = {
};
return this.service.request(this.service.$api_get_catalogue_member, params, 'GET').pipe(
map((res) => {
if (res) {
console.log(res)
}
}),
);
}
selectChange(e: number) {
console.log(e);
this.resourceStatus = e;
this.initST();
setTimeout(() => {
this.st.load();
}, 500);
}
/**
@ -435,4 +448,9 @@ export class SupplyManagementVehicleComponent implements OnInit {
relativeTo: this.ar
})
}
nextOrder(item: any) {
this.router.navigate(['/supply-management/vehicle-amend', item.id], {
relativeTo: this.ar
})
}
}

View File

@ -1,3 +1,11 @@
/*
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2021-12-07 20:09:14
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\supply-management\services\supply-management.service.ts
*/
import { Injectable, Injector } from '@angular/core';
import { BaseService } from 'src/app/shared/services';
@ -5,9 +13,15 @@ import { BaseService } from 'src/app/shared/services';
providedIn: 'root'
})
export class SupplyManagementService extends BaseService {
// 整车获取货源表详情
$api_get_getCompleteVehicleDetail = `api/sdc/goodsResourceOperate/getCompleteVehicleDetail`;
// 大宗获取货源表详情
$api_get_getBulkDetail = `api/sdc/goodsResourceOperate/getBulkDetail`;
// 查询运营后台大宗货源列表
$api_get_bulkPage_list = `api/sdc/goodsResourceOperate/list/bulkPage`;
// 查询运营后台整车货源列表
$api_get_wholePage_list = `api/sdc/goodsResourceOperate/list/wholePage`;
$api_get_catalogue_member = `/user?_allow_anonymous=true`;
$api_del_driver = ``;
constructor(public injector: Injector) {
super(injector)
}

View File

@ -2,8 +2,8 @@
* @Description:
* @Author: wsm
* @Date: 2021-06-22 10:25:33
* @LastEditTime: 2021-06-23 20:25:05
* @LastEditors: Do not edit
* @LastEditTime: 2021-12-08 15:40:21
* @LastEditors: Please set LastEditors
* @Reference:
*/
import { Inject, Injectable, Injector } from '@angular/core';
@ -25,11 +25,11 @@ export class EAUserService extends BaseService {
/**
* 账号密码登录
*/
$api_login_by_account = `/api/mdc/cuc/user/login?_allow_anonymous=true`;
$api_login_by_account = `api/mdc/cuc/user/login?_allow_anonymous=true`;
/**
* 手机号登录
*/
$api_login_by_mobile = `/api/mdc/cuc/user/sms/login?_allow_anonymous=true`;
$api_login_by_mobile = `api/mdc/cuc/user/sms/login?_allow_anonymous=true`;
// 登录路径
private $api_login = `/scce/cuc/cuc/user/login?_allow_anonymous=true`;
private $api_captcha_login = `/scce/cuc/cuc/user/sms/login?_allow_anonymous=true`;