车辆接口更新
This commit is contained in:
@ -19,6 +19,7 @@ import { SupplyManagementService } from '../../services/supply-management.servic
|
||||
import { PublishGoodsChooseFamifiarComponent } from '../choose-famifiar/choose-famifiar.component';
|
||||
import { PublishAddressListComponent } from '../onecar-publish/address-list/address-list.component';
|
||||
import { PublishSuccessComponent } from '../onecar-publish/publish-success/publish-success.component';
|
||||
import { TranAgreementComponent } from '../tran-agreement/tran-agreement.component';
|
||||
@Component({
|
||||
selector: 'app-publish-goods-bulk-publish',
|
||||
templateUrl: './bulk-release-publish.component.html',
|
||||
@ -53,7 +54,9 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
private route: ActivatedRoute,
|
||||
private amapService: AmapService,
|
||||
public shipperSrv: ShipperBaseService
|
||||
) {}
|
||||
) {
|
||||
|
||||
}
|
||||
@ViewChild('sf1', { static: false }) sf1!: SFComponent;
|
||||
schema1: SFSchema = {};
|
||||
ui1!: SFUISchema;
|
||||
@ -114,6 +117,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
serverSearch: true,
|
||||
searchDebounceTime: 300,
|
||||
searchLoadingText: '搜索中...',
|
||||
allowClear: true,
|
||||
onSearch: (q: any) => {
|
||||
if (!!q) {
|
||||
return this.service
|
||||
@ -135,7 +139,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
allowClear: true
|
||||
allowClear: true,
|
||||
} as SFSelectWidgetSchema
|
||||
},
|
||||
// enterpriseInfoName: {
|
||||
@ -161,6 +165,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
type: 'string',
|
||||
format: 'date-time',
|
||||
ui: {
|
||||
|
||||
placeholder: '请输入',
|
||||
format: 'yyyy-MM-dd HH:mm:ss'
|
||||
}
|
||||
@ -569,19 +574,35 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
nzComponentParams: { type: 'bulk' }
|
||||
});
|
||||
}
|
||||
// 提交前确认,委托运输协议弹窗
|
||||
submitConfirm(submitType?: any) {
|
||||
// 校验规则
|
||||
Object.keys(this.ngForm.form.controls).forEach(key => {
|
||||
this.ngForm.form.controls[key].markAsDirty();
|
||||
this.ngForm.form.controls[key].updateValueAndValidity();
|
||||
});
|
||||
this.sf1.validator({ emitError: true });
|
||||
this.sf3.validator({ emitError: true });
|
||||
this.sf4.validator({ emitError: true });
|
||||
this.sf6.validator({ emitError: true });
|
||||
if (this.ngForm.form.invalid || !this.sf1.valid || !this.sf3.valid || !this.sf4.valid || !this.sf6.valid) {
|
||||
return;
|
||||
}
|
||||
|
||||
const modalRef = this.modalService.create({
|
||||
nzTitle: '运输协议',
|
||||
nzContent: TranAgreementComponent,
|
||||
nzWidth: 900,
|
||||
nzFooter: null
|
||||
});
|
||||
modalRef.afterClose.subscribe(result => {
|
||||
if (result) {
|
||||
this.submit(submitType);
|
||||
}
|
||||
});
|
||||
}
|
||||
// 确认提交(下单)
|
||||
submit(submitType: string): void {
|
||||
Object.keys(this.ngForm.form.controls).forEach(key => {
|
||||
this.ngForm.form.controls[key].markAsDirty();
|
||||
this.ngForm.form.controls[key].updateValueAndValidity();
|
||||
});
|
||||
this.sf1.validator({ emitError: true });
|
||||
this.sf3.validator({ emitError: true });
|
||||
this.sf4.validator({ emitError: true });
|
||||
this.sf6.validator({ emitError: true });
|
||||
if (this.ngForm.form.invalid || !this.sf1.valid || !this.sf3.valid || !this.sf4.valid || !this.sf6.valid) {
|
||||
return;
|
||||
}
|
||||
// //装卸货信息
|
||||
const LoadingList = this.startInfo.concat(this.endInfo);
|
||||
// 货物信息
|
||||
|
||||
Reference in New Issue
Block a user