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> <div>
<sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf> <sf #sf [schema]="schema" [ui]="ui" [compact]="true" [button]="'none'"></sf>
<div> <div>
<st #st [data]="service.$api_get_catalogue_member" [columns]="columns"> <!-- <st #st [data]="service.$api_get_catalogue_member" [columns]="columns"> -->
</st> <!-- </st> -->
</div> </div>
</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 { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router'; import { ActivatedRoute } from '@angular/router';
import { STColumn } from '@delon/abc/st'; import { STColumn } from '@delon/abc/st';
@ -65,14 +73,14 @@ export class SupplyManagementBulkDetailComponent implements OnInit {
nzTitle: '<i>删除确认</i>', nzTitle: '<i>删除确认</i>',
nzContent: `请仔细核对,避免误操作!<br>是否删除?</br>`, nzContent: `请仔细核对,避免误操作!<br>是否删除?</br>`,
nzOnOk: () => { nzOnOk: () => {
this.service.http.post(this.service.$api_del_driver, { id }).subscribe((res) => { // this.service.http.post(this.service.$api_del_driver, { id }).subscribe((res) => {
if (res) { // if (res) {
this.service.msgSrv.success('数据删除成功!'); // this.service.msgSrv.success('数据删除成功!');
// this.st1.reload(); // // this.st1.reload();
} else { // } else {
this.service.msgSrv.error('删除失败!'); // this.service.msgSrv.error('删除失败!');
} // }
}); // });
}, },
}); });
} }

View File

@ -49,7 +49,19 @@
</nz-alert> </nz-alert>
</div> </div>
<div style="margin-top: 15px;"> <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"> <ng-template st-row="goodsId" let-item let-index="index">
<a [routerLink]="'/supply-management/bulk-detail/'+item.id">{{item.no}}</a> <a [routerLink]="'/supply-management/bulk-detail/'+item.id">{{item.no}}</a>
</ng-template> </ng-template>

View File

@ -53,7 +53,14 @@ export class SupplyManagementBulkComponent implements OnInit {
this.initST(); this.initST();
this.initSFFre(); this.initSFFre();
} }
/**
* 查询参数
*/
get reqParams() {
return {
...this.sf?.value,
};
}
/** /**
* 初始化查询表单 * 初始化查询表单
*/ */
@ -315,13 +322,13 @@ export class SupplyManagementBulkComponent implements OnInit {
getCatalogueMember() { getCatalogueMember() {
const params = { const params = {
}; };
return this.service.request(this.service.$api_get_catalogue_member, params, 'GET').pipe( // return this.service.request(this.service.$api_get_catalogue_member, params, 'GET').pipe(
map((res) => { // map((res) => {
if (res) { // if (res) {
console.log(res) // console.log(res)
} // }
}), // }),
); // );
} }
selectChange(e: number) { 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> <nz-card>
<div class="card-title">货源单设置</div> <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>
<nz-card> <nz-card>
<div class="card-title">装卸货信息<span class="tip-font">预计公里数:-km预计行程耗时-小时</span></div> <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"> <form nz-form [formGroup]="validateForm1" role="form">
<div nz-row [nzGutter]="24"> <div nz-row [nzGutter]="24">
<div nz-col [nzSpan]="8"> <div nz-col [nzSpan]="8">

View File

@ -1,8 +1,7 @@
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms'; import { FormBuilder, FormGroup } from '@angular/forms';
import { Router } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { import {
SFArrayWidgetSchema,
SFComponent, SFComponent,
SFNumberWidgetSchema, SFNumberWidgetSchema,
SFSchema, SFSchema,
@ -12,10 +11,9 @@ import {
} from '@delon/form'; } from '@delon/form';
import { _HttpClient } from '@delon/theme'; import { _HttpClient } from '@delon/theme';
import { AmapPoiPickerComponent } from '@shared'; 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 { PublishGoodsChooseFamifiarComponent } from '../choose-famifiar/choose-famifiar.component';
import { GaodeMapComponent } from '../gaode-map/gaode-map.component'; import { SupplyManagementService } from '../../services/supply-management.service';
@Component({ @Component({
selector: 'app-publish-goods-onecar-publish', selector: 'app-publish-goods-onecar-publish',
templateUrl: './onecar-publish.component.html', templateUrl: './onecar-publish.component.html',
@ -24,7 +22,7 @@ import { GaodeMapComponent } from '../gaode-map/gaode-map.component';
export class SupplyManagementOnecarPublishComponent implements OnInit { export class SupplyManagementOnecarPublishComponent implements OnInit {
validateForm1: FormGroup; validateForm1: FormGroup;
newTempchecked = false; //是否存入新模板 newTempchecked = false; //是否存入新模板
id = this.route.snapshot.params.id;
// // 单位 // // 单位
unit1 = '吨'; unit1 = '吨';
unit2 = '方'; unit2 = '方';
@ -43,10 +41,8 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
phone: '18888888888' phone: '18888888888'
} }
]; ];
dataList: any;
// formatterRmb = (value: number): string => `¥ ${value}`; constructor(private http: _HttpClient, fb: FormBuilder, private router: Router, private route: ActivatedRoute, private modalService: NzModalService, public service: SupplyManagementService) {
// parserRmb = (value: string): string => value.replace('¥ ', '');
constructor(private http: _HttpClient, fb: FormBuilder, private router: Router, private modalService: NzModalService) {
this.validateForm1 = fb.group({ this.validateForm1 = fb.group({
name1: [null, []], name1: [null, []],
name2: [null, []], name2: [null, []],
@ -89,12 +85,13 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
this.initSF5(); this.initSF5();
this.initSF6(); this.initSF6();
this.initSF7(); this.initSF7();
this.initdata();
} }
initSF1() { initSF1() {
this.schema1 = { this.schema1 = {
properties: { properties: {
name3: { shipperAdispatchNameppUserNmae: {
type: 'string', type: 'string',
title: '货主', title: '货主',
maxLength: 30, maxLength: 30,
@ -102,7 +99,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
placeholder: '请输入' placeholder: '请输入'
} }
}, },
name4: { enterpriseProjectName: {
type: 'string', type: 'string',
title: '项目', title: '项目',
enum: [ enum: [
@ -124,7 +121,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
// change: (i) => this.updateCategory(i, '/categoryId2'), // change: (i) => this.updateCategory(i, '/categoryId2'),
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
}, },
no1: { enterpriseInfoName: {
type: 'string', type: 'string',
title: '网络货运人', title: '网络货运人',
ui: { ui: {
@ -132,7 +129,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
}, },
default: 0 default: 0
}, },
name8: { externalResourceCode: {
type: 'string', type: 'string',
title: '外部货源号', title: '外部货源号',
maxLength: 30, maxLength: 30,
@ -140,7 +137,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
placeholder: '请输入' placeholder: '请输入'
} }
}, },
name2: { dispatchName: {
type: 'string', type: 'string',
title: '调度员', title: '调度员',
enum: [ enum: [
@ -494,4 +491,15 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
nzWidth: 848 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"> <div class="mb-lg">
<nz-spin *ngIf="!i" class="modal-spin"></nz-spin> <nz-spin *ngIf="!i" class="modal-spin"></nz-spin>
<sf *ngIf="i" #sf mode="edit" [schema]="schema" [ui]="ui" [formData]="i" button="none"> <sf *ngIf="i" #sf mode="edit" [schema]="schema" [ui]="ui" [formData]="i" button="none">
@ -15,10 +23,10 @@
</div> </div>
<div> <div>
<h4>变更日志</h4> <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"> <ng-template st-row="operator" let-item let-index="index">
<div>黎日湛</div> <div>黎日湛</div>
<div>18811112222</div> <div>18811112222</div>
</ng-template> </ng-template>
</st> </st> -->
</div> </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 { Component, OnInit, ViewChild } from '@angular/core';
import { STColumn } from '@delon/abc/st'; import { STColumn } from '@delon/abc/st';
import { SFComponent, SFSchema, SFUISchema } from '@delon/form'; import { SFComponent, SFSchema, SFUISchema } from '@delon/form';

View File

@ -6,17 +6,20 @@
</ng-template> </ng-template>
</page-header-wrapper> </page-header-wrapper>
<nz-card> <nz-card>
<nz-spin *ngIf="!i" class="modal-spin"></nz-spin>
<div nz-row> <div nz-row>
<div nz-col nzSpan="4"> <div nz-col nzSpan="6">
<sv-container class="bdr"> <sv-container class="bdr">
<sv label="货源编号" col="1">{{ i?.no }}</sv> <sv label="货源编号" col="1">{{ dataList?.resourceCode }}</sv>
<sv-title class="text-center text-lg">待接单</sv-title> <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> <sv-title>
<div class=""> <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 m-lg mr-lg">取消货源</a>
<a class="btn-size">再下一单</a> <a class="btn-size" (click)="nextOrder()">再下一单</a>
</div> </div>
</sv-title> </sv-title>
</sv-container> </sv-container>
@ -24,70 +27,90 @@
<div nz-col nzSpan="16" class="approval-status"> <div nz-col nzSpan="16" class="approval-status">
<nz-steps style="width: 80%; margin: 0 auto" [nzLabelPlacement]="'vertical'"> <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="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> </nz-steps>
</div> </div>
</div> </div>
<nz-divider></nz-divider> <nz-divider></nz-divider>
<div sv-container *ngIf="i"> <div sv-container >
<sv label="外部货源号">{{ i?.owner }}</sv> <sv label="项目名称">{{ dataList?.enterpriseProjectId }}</sv>
<sv label="项目名称">32943898021309809423</sv> <sv label="外部货源号">{{ dataList?.externalResourceCode }}</sv>
<sv label="服务类型">3321944288191034921</sv> <sv label="录单员">{{ dataList?.enterpriseProjectId }}</sv>
<sv label="录单员">18112345678</sv> <sv label="调度员">{{ dataList?.dispatchName }}</sv>
<sv label="调度员">曲丽丽 18100000000 </sv>
<sv label="承诺付款时间">曲丽丽 18100000000 </sv>
</div> </div>
<nz-divider></nz-divider> <nz-divider></nz-divider>
<div nz-row> <div nz-row>
<div nz-col nzSpan="6"> <div nz-col nzSpan="6">
<div class="source-info"> <div class="source-info">
<h3>装卸货信息</h3> <div *ngFor="let item of dataList?.unLoadingPlaceList; let i = index">
<p>装货地:广东省深圳市龙岗区怡亚通大厦</p> <h3 *ngIf="i === 0" style="font-weight: 700;">装卸货信息</h3>
<p>联系人:奥利给/13680058545</p> <div *ngIf="item?.type === 1">
<p>货地:广东省深圳市福田区岗厦村9巷8号405新村</p> <p>货地:{{item?.detailedAddress}}</p>
<p>联系人:花花世界/13680058545</p> <p>联系人:{{item?.appUserName}}/{{item?.contractTelephone}}</p>
<p>发货日期广东省深圳市福田区岗厦村9巷8号405新村</p> </div>
<p>卸货日期:花花世界/13680058545</p> <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>
</div> </div>
<div nz-col nzSpan="6"> <div nz-col nzSpan="5">
<div class="source-info bdr bdl pl-md"> <div class="source-info bdr bdl pl-md">
<h3>货物信息</h3> <div *ngFor="let item of dataList?.goodsInfoList; let i = index">
<p>货物名称:广东省深圳市龙岗区怡亚通大厦</p> <h3 *ngIf="i === 0" style="font-weight: 700;">货物信息</h3>
<p>重量/体积广东省深圳市福田区岗厦村9巷8号405新村</p> <p>货物名称:{{item?.goodsName}}</p>
<p>车型/车长:花花世界/13680058545</p> <p>货物数量:{{item?.weight}}吨/{{item?.volume}}立方</p>
<p>用车需求:{{item?.vehicleDemand}}</p>
</div>
</div> </div>
</div> </div>
<div nz-col nzSpan="6"> <div nz-col nzSpan="5">
<div class="source-info bdr pl-md"> <div class="source-info bdr pl-md">
<h3>承运信息</h3> <h3 style="font-weight: 700;">承运信息</h3>
<p>司机:广东省深圳市龙岗区怡亚通大厦</p> <p>网络货运人:{{dataList?.carrierInformationVO?.enterpriseInfoName}}</p>
<p>车牌号广东省深圳市福田区岗厦村9巷8号405新村</p> <p>服务类型:{{dataList?.carrierInformationVO?.serviceType === 1 ? '抢单' : '指派'}}</p>
<p>车型/车长/承重:{{'拖车'}} | {{'4.5米'}} | {{'15吨'}}</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> </div>
<div class="source-info pl-md"> <div class="source-info pl-md">
<h3>补充信息</h3> <h3 style="font-weight: 700;">补充信息</h3>
<p>需要回单</p> <p>{{dataList?.supplementaryInformationVO?.stateReceipt === 2 ? '不需要回单' : '需要回单'}}</p>
<p>备注:奥利给/13680058545</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>
</div> </div>
<nz-divider></nz-divider> <nz-divider></nz-divider>
<div nz-row> <div nz-row>
<div class="freight-info-box"> <div class="freight-info-box">
<h3>运费信息</h3> <h3 style="font-weight: 700;">运费信息</h3>
<div class="text-right"> <div class="text-right">
<p><label class="freigth-label">预付:</label><span>{{400 | currency }}</span></p> <p>预付:{{dataList?.expenseList?.prePay | currency: '¥' }}</p>
<p><label class="freigth-label">油卡:</label><span>{{400 | currency }}</span></p> <p>油卡:{{dataList?.expenseList?.oilCardPay | currency: '¥'}}</p>
<p><label class="freigth-label">到付:</label><span>{{400 | currency }}</span></p> <p>到付:{{dataList?.expenseList?.toPay | currency: '¥'}}</p>
<p><label class="freigth-label">回单付:</label><span>{{400 | currency}}</span></p> <p>回单付:{{dataList?.expenseList?.receiptPay | currency: '¥'}}</p>
<p><label class="freigth-label">附加费:</label><span>{{400 | currency }}</span></p> <p>保险费:{{dataList?.expenseList?.insuranceFee | currency: '¥'}}</p>
<p>附加费保险费:{{dataList?.expenseList?.appendFee | currency: '¥'}}</p>
</div> </div>
</div> </div>
<nz-divider></nz-divider> <nz-divider></nz-divider>
<div class="freight-info-box" nz-row> <div class="freight-info-box" nz-row>
<div nz-col nzSpan="24"> <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>
</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 { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { STColumn } from '@delon/abc/st'; import { STColumn } from '@delon/abc/st';
import { _HttpClient } from '@delon/theme'; import { _HttpClient } from '@delon/theme';
import { NzMessageService } from 'ng-zorro-antd/message'; import { NzMessageService } from 'ng-zorro-antd/message';
@ -14,6 +22,7 @@ export class SupplyManagementVehicleDetailComponent implements OnInit {
id = this.route.snapshot.params.id; id = this.route.snapshot.params.id;
i: any; i: any;
dataList: any;
logColumns: STColumn[] = [ logColumns: STColumn[] = [
{ title: '内容', index: 'theme' }, { title: '内容', index: 'theme' },
{ title: '操作人', index: 'operationUserPhone' }, { title: '操作人', index: 'operationUserPhone' },
@ -24,18 +33,40 @@ export class SupplyManagementVehicleDetailComponent implements OnInit {
private route: ActivatedRoute, private route: ActivatedRoute,
private msgSrv: NzMessageService, private msgSrv: NzMessageService,
private service: SupplyManagementService, private service: SupplyManagementService,
private router: Router,private ar: ActivatedRoute
) { ) {
} }
ngOnInit(): void { ngOnInit(): void {
this.service.http.get(`/user/${this.id}?_allow_anonymous=true&_allow_badcode=true`).subscribe(res => { console.log(this.id)
console.log(res); if(this.id) {
this.i = res 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 * @Author: your name
* @Date: 2021-12-03 11:10:14 * @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 * @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @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 * @FilePath: \tms-obc-web\src\app\routes\supply-management\components\vehicle\vehicle.component.html
@ -41,10 +41,6 @@
</nz-tab> </nz-tab>
</nz-tabset> </nz-tabset>
<div style="margin-top: 15px;"> <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"> <div style="position: relative">
<nz-alert <nz-alert
@ -55,15 +51,32 @@
> >
</nz-alert> </nz-alert>
</div> </div>
<st #st [scroll]="{ x: '1200px' }" [data]="service.$api_get_catalogue_member" [columns]="columns"> <st
<ng-template st-row="goodsId" let-item let-index="index"> #st
<a [routerLink]="'/supply-management/vehicle-detail/'+item.id">{{item.no}}</a> 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>
<!-- <ng-template st-row="externalSn" let-item let-index="index"> <ng-template st-row="LoadingAddressArr" let-item let-index="index">
<span class="mr-xs">{{111111}}</span> <div *ngFor="let i of item?.LoadingAddressArr">
<a (click)="editEnternalSn(item)">编辑</a> <span>{{item?.LoadingAddressArr[i]}}</span>
</ng-template> --> </div>
<ng-template st-row="enStatusStr27878" let-item let-index="index"> </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> <div class="mr-xs" nzPopoverTitle="Title" nz-popover [nzPopoverContent]="contentTemplate">{{item.no}}</div>
</ng-template> </ng-template>
<ng-template #contentTemplate> <ng-template #contentTemplate>

View File

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

View File

@ -2,8 +2,8 @@
* @Description: * @Description:
* @Author: wsm * @Author: wsm
* @Date: 2021-06-22 10:25:33 * @Date: 2021-06-22 10:25:33
* @LastEditTime: 2021-06-23 20:25:05 * @LastEditTime: 2021-12-08 15:40:21
* @LastEditors: Do not edit * @LastEditors: Please set LastEditors
* @Reference: * @Reference:
*/ */
import { Inject, Injectable, Injector } from '@angular/core'; 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_login = `/scce/cuc/cuc/user/login?_allow_anonymous=true`;
private $api_captcha_login = `/scce/cuc/cuc/user/sms/login?_allow_anonymous=true`; private $api_captcha_login = `/scce/cuc/cuc/user/sms/login?_allow_anonymous=true`;