diff --git a/src/app/routes/routes-routing.module.ts b/src/app/routes/routes-routing.module.ts index 2b964c24..8786e534 100644 --- a/src/app/routes/routes-routing.module.ts +++ b/src/app/routes/routes-routing.module.ts @@ -1,7 +1,7 @@ /* * @Author: your name * @Date: 2021-11-29 10:20:33 - * @LastEditTime: 2021-12-01 09:53:56 + * @LastEditTime: 2021-12-01 20:37:48 * @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\routes-routing.module.ts @@ -32,7 +32,8 @@ const routes: Routes = [ loadChildren: () => import('./usercenter/usercenter.module').then(m => m.UsercenterModule) }, { path: 'system', loadChildren: () => import('./sys-setting/sys-setting.module').then(m => m.SysSettingModule) }, - { path: 'supplygoods', loadChildren: () => import('./supply-goods/supply-goods.module').then(m => m.SupplyGoodsModule) } + { path: 'supplygoods', loadChildren: () => import('./supply-goods/supply-goods.module').then(m => m.SupplyGoodsModule) }, + { path: 'vehicle', loadChildren: () => import('./vehicle/vehicle.module').then(m => m.VehicleModule) } ] }, // passport diff --git a/src/app/routes/supply-goods/components/carload/carload.component.html b/src/app/routes/supply-goods/components/carload/carload.component.html index 7eeedbcc..f7871ded 100644 --- a/src/app/routes/supply-goods/components/carload/carload.component.html +++ b/src/app/routes/supply-goods/components/carload/carload.component.html @@ -1,3 +1,11 @@ + @@ -37,11 +45,10 @@
- - +
- + 共 {{ total }} 条 - 商品 - 订单金额 - 收件人 - 下单商家 - 状态 + 货源编号 + 货源类型 + 货主 + 项目名称 + 装货地 + 卸货地 + 货物名称 + 重量/体积 + 用车需求 + 总费用 + 附加费 + 用车需求 + 货源状态 + 创建时间 + 审核状态 操作 - - -
-
- 订单号:{{ data.orderSn }}        下单时间:{{ - data.createTime - }}         订单类型:{{ - data.supplierType == 1 ? '普通订单' : 'GD订单' - }} -         支付方式:{{ data.payType === 1 ? '一次性付款,先货后款' : '-' - }}{{ data.payType === 2 ? '分批付款,先货后款' : '' }}         配送方式:{{ - data.deliveryTypeDesc - }} -
-
- - + -
-
- -
-
-

- {{ item.goodsName }}
- - {{ items.specName }}:{{ items.specValueName }} - -
-

数量:{{ item.goodsQuantity }}

-

-
-
- {{ item.sendType === 1 ? '已发货' : item.sendType === 2 ? '部分发货' : '' }}
- {{ item.returnStatusName }} -
+ {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + +
已接单
+
已取消
+
待接单
+ + + {{data.id3}} + + +
+
审核通过
+
不通过
+
待审核
+
- - - - ¥{{ data.payAmount.toFixed(2) }} - - {{ data.receiveName }}
- {{ data.receiveMobile }} - - - {{ data.tenantName }} - - - {{ data.orderStatusStr }}{{ - data.orderStatusDesc - }}
{{ - data.payStatusDesc - }}
- - -
- - - - 付款审核 - - - 审核
-
- - 修改价格 - - - 立即发货 -
- - 立即发货 -
- 查看详情 -
- -
-
- - + + + + - - - - - - {{ item }} - - - - + + + + +
+ {{this.sfFre.value.contactsName}} +
+
+ +    天内支付运费。 + + + 15.00(费率:5.3 ) + +
+
+ + + + +
+ + + + + + + + + + + + diff --git a/src/app/routes/supply-goods/components/carload/carload.component.less b/src/app/routes/supply-goods/components/carload/carload.component.less index c98cff00..36f9126d 100644 --- a/src/app/routes/supply-goods/components/carload/carload.component.less +++ b/src/app/routes/supply-goods/components/carload/carload.component.less @@ -1,128 +1,7 @@ -.order-goods { - display: flex; - text-align: left; - .order-goods-img { - width: 80px; - height: 80px; - margin-right: 10px; - overflow: hidden; - img { - width: 100%; - } - } - .order-goods-info { - flex: 1; - } - .order-goods-state { - width: 70px; - margin-left: 10px; - line-height: 28px; - text-align: right; - } -} -h2 { - font-size: 16px; -} -p { - font-size: 14px; -} -.form, -.table { - background-color: #fff; -} -.form { - padding: 20px; -} -.select-item { - width: 180px; -} -.ant-form-item { - margin-bottom: 16px; -} -.order-line { - display: flex; - justify-content: space-between; -} -.order-receiving { - .order-receiving-remark { - line-height: 26px; - span { - color: #1890ff; - } - input { - width: 130px; - margin-right: 6px; - padding: 0; - overflow: hidden; - color: #1890ff; - white-space: nowrap; - text-overflow: ellipsis; - background: none; - border: none; - &.have-edit { - color: #000000a6; - border: 1px solid #d9d9d9; - } - } - } -} -.order-operation { - div { - color: #1890ff; - cursor: pointer; - } - p { - margin-bottom: 10px; - } -} -.timeline { - span { - display: inline-block; - margin: 0 4px; - padding: 5px 6px; - color: #999; - background-color: #f2f2f2; - border-radius: 2px; - cursor: pointer; - } -} -.ant-table-tbody > tr.ant-table-row:hover > td { - background: #fff; -} - -.btnBox { - margin: 0 0 10px 0; -} -.searchAreaWrap { - display: flex; -} -.sfExpand { - display: block; -} -.actionBox { - margin: 0 0 0 10px; -} -.sfBox { - width: 60%; -} -.expandsfBox { - width: 100%; -} -.expandAcitonBox { - margin: 10px 0 20px 0; - text-align: right; -} -.actionAreaWrap { - margin: 0 0 20px 0; -} -.overflowText { - display: -webkit-box; - overflow: hidden; - text-align: left; - text-overflow: -o-ellipsis-lastline; - text-overflow: ellipsis; - -webkit-line-clamp: 2; - line-clamp: 2; - -webkit-box-orient: vertical; +.status-point { + display: inline-block; + width: 6px; + height: 6px; + border-radius: 50%; } diff --git a/src/app/routes/supply-goods/components/carload/carload.component.ts b/src/app/routes/supply-goods/components/carload/carload.component.ts index 1145ae70..fc356fb0 100644 --- a/src/app/routes/supply-goods/components/carload/carload.component.ts +++ b/src/app/routes/supply-goods/components/carload/carload.component.ts @@ -2,15 +2,15 @@ * @Description: * @Author: wsm * @Date: 2021-07-15 09:42:57 - * @LastEditTime: 2021-12-01 10:36:54 + * @LastEditTime: 2021-12-01 19:59:38 * @LastEditors: Please set LastEditors * @Reference: */ import { AfterViewInit, Component, OnInit, TemplateRef, ViewChild } from '@angular/core'; import { FormBuilder, FormGroup } from '@angular/forms'; import { ActivatedRoute, NavigationEnd, Router } from '@angular/router'; -import { STComponent } from '@delon/abc/st'; -import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; +import { STChange, STColumn, STComponent } from '@delon/abc/st'; +import { SFComponent, SFDateWidgetSchema, SFRadioWidgetSchema, SFSchema, SFTextWidgetSchema, SFUISchema } from '@delon/form'; import { ModalHelper } from '@delon/theme'; import { NzModalService } from 'ng-zorro-antd/modal'; import { filter } from 'rxjs/operators'; @@ -23,27 +23,34 @@ import { filter } from 'rxjs/operators'; }) export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterViewInit { @ViewChild('st', { static: true }) st!: STComponent; + @ViewChild('stAssign', { static: true }) stAssign!: STComponent; @ViewChild('sf', { static: false }) sf!: SFComponent; - validateForm!: FormGroup; - @ViewChild('exportTemplate') - exportTemplate!: TemplateRef; + @ViewChild('sfAssign', { static: false }) sfAssign!: SFComponent; + @ViewChild('sfFre', { static: false }) sfFre!: SFComponent; + isVisible = false; + isVisibleAssign = false; + ColumnsAssign!: STColumn[]; ui: SFUISchema = {}; + uiFre: SFUISchema = {}; mode: any = 'search'; - tabs = ['全部', '待审核', '待支付', '待发货', '待收货', '已完成']; - exportFieldList = [ - '订单号', - '下单时间', - '支付方式', - '订单金额', - '订单状态', - '下单商家', - 'SKU信息(SKUID,商品名称+规格名称,数量)', - '配送方式', - '收件人', - '收件人电话', - '收件人地址', - ]; - listData: any; + demoValue: any; + tabs = ['全部', '待接单', '已接单', '已取消']; + listData: any =[ + { + id: 1, + id2: 2, + id3:3, + id4: 4, + } + ] + listData2: any = [ + { + clientGroupName: '姓名', + clientCount: '姓名', + clientCount2: '姓名', + clientCount3: '姓名', + } + ] orderStatus: any = '0'; // 订单状态, 10为已提交待付款, 20为已付款待发,30为已发货待收货,50取消订单,40 已完成 nzSelectedIndex = 0; total = 1; @@ -55,8 +62,10 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi addTimeEnd = ''; sfExpand = false; _$expand = false; - + ssdsad: any; schema!: SFSchema; + schemaAssign!: SFSchema; + freightSchema!: SFSchema; payStatus: any; constructor( private fb: FormBuilder, @@ -70,6 +79,8 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi this.getList(); this.initSF(); this.initUI(); + this.initSFFre(); + this.initSFAssign(); } ngAfterViewInit() { @@ -77,7 +88,99 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi // // }); } - + /** + * 指定客户分组查询参数 + */ + get reqParamsAssign() { + const params = Object.assign({}); + return { ...params, ...this.sfAssign?.value }; + } + change(change: STChange) { + console.log(change.checkbox) + } + initSFFre() { + this.freightSchema = { + properties: { + btn: { + type: 'string', + title: '是否回单', + enum: ['需要', '不需要'], + ui: { + widget: 'radio', + } as SFRadioWidgetSchema, + default: '需要', + }, + contactsName: { + title: '预付', + type: 'string', + ui: { + showRequired: false, + }, + }, + unifiedSocialCreditCode: { + title: '到付', + type: 'string', + ui: { + showRequired: false, + }, + }, + unifiedSocialCreditCode2: { + title: '油卡', + type: 'string', + ui: { + showRequired: false, + }, + }, + unifiedSocialCreditCode3: { + title: '回单付', + type: 'string', + ui: { + showRequired: false, + }, + }, + '小计': { type: 'number', ui: { widget: 'text', defaultText: '5000 text' } as SFTextWidgetSchema }, + fujia: { type: 'string',title: '附加费', ui: { widget: 'custom'}}, + manys: { type: 'string',title: '总费用', ui: { widget: 'custom'}}, + unifiedSocia: { type: 'string',title: '总费用', ui: { widget: 'custom'}}, + + }, + }; + this.schemaAssign = { + properties: { + clientGroupName: { + title: '分组名称', + type: 'string', + ui: { + placeholder: '请输入司机姓名/手机号', + enter: (e: KeyboardEvent) => { + this.stAssign.load(); + }, + }, + }, + clientGroupName2: { + title: '分组名称', + type: 'string', + ui: { + placeholder: '请输入车牌号', + enter: (e: KeyboardEvent) => { + this.stAssign.load(); + }, + }, + }, + }, + }; + this.uiFre = { '*': { spanLabelFixed: 90, grid: { span: 16 }, enter: () => this.st.load() } }; + } + initSFAssign() { + this.ColumnsAssign = [ + { title: '', type: 'checkbox', width: '40px', className: 'text-center' }, + { title: '司机姓名', index: 'clientGroupName', width: '300px', className: 'text-center' }, + { title: '手机号', index: 'clientCount', width: '300px', className: 'text-center' }, + { title: '车牌号', index: 'clientCount2', width: '300px', className: 'text-center' }, + { title: '状态', index: 'clientCount3', width: '300px', className: 'text-center' }, + ]; + } + initSF() { this.schema = { properties: { @@ -87,33 +190,36 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi hidden: true, }, }, - storeName: { title: '企业名称', type: 'string', ui: { showRequired: false } }, + storeName: { title: '货源编号', type: 'string', ui: { showRequired: false } }, contactsName: { - title: '联系人', + title: '货物名称', type: 'string', ui: { showRequired: false, }, }, unifiedSocialCreditCode: { - title: '税源地', + title: '装货地', type: 'string', ui: { showRequired: false, }, }, - enStatus: { + unifiedSocialCreditCode2: { + title: '卸货地', type: 'string', - title: '货主状态', - enum: [ - { label: '全部', value: '' }, - { label: '正常', value: 0 }, - { label: '冻结', value: 1 }, - { label: '废弃', value: 2 }, - ], - default: '', ui: { - widget: 'select', + showRequired: false, + visibleIf: { + expand: (value: boolean) => value, + }, + }, + }, + unifiedSocialCreditCode3: { + title: '货主', + type: 'string', + ui: { + showRequired: false, visibleIf: { expand: (value: boolean) => value, }, @@ -121,7 +227,7 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi }, enStatus2: { type: 'string', - title: 'CRM审核状态', + title: '审核状态', enum: [ { label: '全部', value: '' }, { label: '正常', value: 0 }, @@ -138,6 +244,7 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi }, }, }; + this.ui = { '*': { spanLabelFixed: 90, grid: { span: 8, gutter: 4 }, enter: () => this.st.load() } }; } initUI() { @@ -149,6 +256,7 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi }; } tabChange(i: number) { + console.log(i) this.changeIndex(i); this.getList(); } @@ -165,12 +273,6 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi } else if (i === 3) { this.orderStatus = '20'; this.payStatus = null; - } else if (i === 4) { - this.orderStatus = '30'; - this.payStatus = null; - } else if (i === 5) { - this.orderStatus = '40'; - this.payStatus = null; } this.pageIndex = 1; } @@ -213,7 +315,7 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi // this.service.exportStart(params, this.service.$api_export); this.modal.create({ nzTitle: '订单导出', - nzContent: this.exportTemplate, + // nzContent: this.exportTemplate, // nzContent: `待导出订单总数:${this.pageInfo.total}条,确定要导出吗?`, nzOnOk: () => { const params: any = { @@ -232,10 +334,7 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi this.router.navigate(['../order-detail', data.orderSn], { relativeTo: this.ar }); } - // 批量发货 - deliverBelivery() { - this.router.navigate(['../order-batch-delivery'], { relativeTo: this.ar }); - } + changePageIndex(pageIndex: number) { this.pageIndex = pageIndex; this.getList(); @@ -249,80 +348,22 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi this.sf?.setValue('/expand', this.sfExpand); } - // 修改运单 - updateLogistics(data: any) { - // 如果是多个运单 - if (data.deliveryList.length > 1) { - this.updateLogisticsList(data); - } else { - data.deliveryAddrId = data.deliveryList[0].deliveryAddrId; - data.deliveryCorpSn = data.deliveryList[0].deliveryCorpSn; - data.deliverySn = data.deliveryList[0].deliverySn; // 原物流单号 - data.expressName = data.deliveryList[0].expressName; // 原物流公司 - data.sendName = data.deliveryList[0].sendName; - data.sendMobile = data.deliveryList[0].sendMobile; - data.sendAddr = data.deliveryList[0].sendAddr; - data.orderExpressItemVOList = data.deliveryList[0].orderExpressItemVOList; // 运单对应的发货商品信息 - this.updateLogisticsPop(data); - } + showApply() { + this.isVisible = true } - - // 修改运单中间页List - updateLogisticsList(data: any) { - const modalRef = this.modal.create({ - nzTitle: '运单信息', - nzWidth: 1200, - // nzContent: OrderComponentsOrderLogisticsmessageComponent, - nzComponentParams: { - listData: data, - }, - nzFooter: null, - }); - modalRef.afterClose.subscribe((result) => { - if (result === true) { - this.getList(); - } - }); + showAssign() { + this.isVisibleAssign = true } + handleOK() { - // 修改运单弹窗 - updateLogisticsPop(data: any) { - const modalRef = this.modal.create({ - nzTitle: '已发货商品', - nzWidth: 1200, - // nzContent: OrderComponentsOrderDeliverGoodsUpdateComponent, - nzComponentParams: { - listData: data, - }, - nzFooter: null, - }); - modalRef.afterClose.subscribe((result) => { - if (result === true) { - this.getList(); - } - }); } - - // 立即发货 - deliverGoods(data: any) { - // const modalRef = this.modal.create({ - // nzTitle: '订单发货', - // nzWidth: 1200, - // nzContent: OrderComponentsOrderDelivergoodsComponent, - // nzComponentParams: { - // listData: data, - // }, - // nzFooter: null, - // }); - // modalRef.afterOpen.subscribe(() => {}); - // modalRef.afterClose.subscribe((result) => { - // if (result === true) { - // this.getList(); - // } - // }); - this.router.navigate(['../order-deliver-goods'], { relativeTo: this.ar }); +handleCancel(type: any) { + if(type === 'suppliersType') { + this.isVisible = false + } else if(type === 'assign') { + this.isVisibleAssign = false } - +} /** * 重置表单 */ @@ -330,65 +371,12 @@ export class SupplyGoodsComponentListCarloadComponent implements OnInit, AfterVi this.sf.reset(); this.sfExpand = false; } - /** - * 立即确认 - */ - deliversure(val: any) { - const modalRef = this.modal.create({ - nzTitle: '订单确认', - nzWidth: 700, - // nzContent: OrderComponentsOrderOrderlistOrderSureComponent, - nzComponentParams: { - record: val, - }, - nzFooter: null, - }); - modalRef.afterOpen.subscribe(() => {}); - modalRef.afterClose.subscribe((result) => { - if (result === true) { - this.getList(); - } - }); - } - /** - * 付款审核 - */ - paymentReview(data: any) { - const dialogData = { - ...data, - }; - // this.modalHelper.create(OrderComponentsOrderOrderlistPaymentReviewComponent, { dialogData }, { size: 900 }).subscribe((res) => { - // if (res === '2') { - // this.getList(); - // } - // }); - } - /** - * 修改价格 - */ - modifyPrice(data: any) { - const dialogData = { - ...data, - }; - // this.modalHelper.create(OrderComponentsOrderOrderlistModifyPriceComponent, { dialogData }, { size: 900 }).subscribe((res) => { - // if (res === '2') { - // this.getList(); - // } - // }); - } - /** - * 审核 - */ - orderReview(data: any) { - const dialogData = { - ...data, - }; - // this.modalHelper.create(OrderReviewComponent, { dialogData }, { size: 900 }).subscribe((res) => { - // if (res === '2') { - // this.getList(); - // } - // }); + resetSFAssign() { + this.sfAssign.reset(); } + + + /** * 查询字段个数navigate */ diff --git a/src/app/routes/supply-goods/components/large-amount/large-amount.component.html b/src/app/routes/supply-goods/components/large-amount/large-amount.component.html new file mode 100644 index 00000000..a0419cce --- /dev/null +++ b/src/app/routes/supply-goods/components/large-amount/large-amount.component.html @@ -0,0 +1,166 @@ + + + + + +
+ +
+ + +
+ + + + +
+ +
+
+ + + + +
+
+
+
+ + + + + + 共 {{ total }} 条 + + + 货源编号 + 货源类型 + 货主 + 项目名称 + 关联运单 + 货物信息 + 装货地 + 卸货地 + 用车需求 + 运费单价 + 结算重量 + 录单员 + 调度员 + 货源状态 + 截止时间 + 创建时间 + 审核状态 + 操作 + + + + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + + {{data.id3}} + + +
已接单
+
已取消
+
待接单
+ + + {{data.id3}} + + + + {{data.id3}} + + +
+
审核通过
+
不通过
+
待审核
+ +
+ + + + + + +
+
+
+
diff --git a/src/app/routes/supply-goods/components/large-amount/large-amount.component.less b/src/app/routes/supply-goods/components/large-amount/large-amount.component.less new file mode 100644 index 00000000..36f9126d --- /dev/null +++ b/src/app/routes/supply-goods/components/large-amount/large-amount.component.less @@ -0,0 +1,7 @@ + +.status-point { + display: inline-block; + width: 6px; + height: 6px; + border-radius: 50%; +} diff --git a/src/app/routes/supply-goods/components/large-amount/large-amount.component.spec.ts b/src/app/routes/supply-goods/components/large-amount/large-amount.component.spec.ts new file mode 100644 index 00000000..4511b1f3 --- /dev/null +++ b/src/app/routes/supply-goods/components/large-amount/large-amount.component.spec.ts @@ -0,0 +1,31 @@ +/* + * @Description: + * @Author: wsm + * @Date: 2021-07-08 15:46:29 + * @LastEditTime: 2021-12-01 10:02:07 + * @LastEditors: Please set LastEditors + * @Reference: + */ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; +import { SupplyGoodsComponentListLargeAmountComponent } from './large-amount.component'; + +describe('SupplyGoodsComponentListLargeAmountComponent', () => { + let component: SupplyGoodsComponentListLargeAmountComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [SupplyGoodsComponentListLargeAmountComponent], + }).compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(SupplyGoodsComponentListLargeAmountComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/src/app/routes/supply-goods/components/large-amount/large-amount.component.ts b/src/app/routes/supply-goods/components/large-amount/large-amount.component.ts new file mode 100644 index 00000000..4ff565d1 --- /dev/null +++ b/src/app/routes/supply-goods/components/large-amount/large-amount.component.ts @@ -0,0 +1,252 @@ +/* + * @Description: + * @Author: wsm + * @Date: 2021-07-15 09:42:57 + * @LastEditTime: 2021-12-01 15:06:11 + * @LastEditors: Please set LastEditors + * @Reference: + */ +import { AfterViewInit, Component, OnInit, TemplateRef, ViewChild } from '@angular/core'; +import { FormBuilder, FormGroup } from '@angular/forms'; +import { ActivatedRoute, NavigationEnd, Router } from '@angular/router'; +import { STComponent } from '@delon/abc/st'; +import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; +import { ModalHelper } from '@delon/theme'; +import { NzModalService } from 'ng-zorro-antd/modal'; +import { filter } from 'rxjs/operators'; + + +@Component({ + selector: 'app-supply-goods-components-list-large-amount', + templateUrl: './large-amount.component.html', + styleUrls: ['./large-amount.component.less'], +}) +export class SupplyGoodsComponentListLargeAmountComponent implements OnInit, AfterViewInit { + @ViewChild('st', { static: true }) st!: STComponent; + @ViewChild('sf', { static: false }) sf!: SFComponent; + validateForm!: FormGroup; + @ViewChild('exportTemplate') + exportTemplate!: TemplateRef; + ui: SFUISchema = {}; + mode: any = 'search'; + tabs = ['全部', '进行中', '已完结', '已取消']; + listData: any =[ + { + id: 1, + id2: 2, + id3:3, + id4: 4, + } + ] + orderStatus: any = '0'; // 订单状态, 10为已提交待付款, 20为已付款待发,30为已发货待收货,50取消订单,40 已完成 + nzSelectedIndex = 0; + total = 1; + loading = false; + pageSize = 20; + pageIndex = 1; + toSendCount = 0; + addTimeStart = ''; + addTimeEnd = ''; + sfExpand = false; + _$expand = false; + + schema!: SFSchema; + payStatus: any; + constructor( + private fb: FormBuilder, + private modal: NzModalService, + private router: Router, + private ar: ActivatedRoute, + private modalHelper: ModalHelper, + ) {} + + ngOnInit(): void { + this.getList(); + this.initSF(); + this.initUI(); + } + + ngAfterViewInit() { + // this.router.events.pipe(filter((evt) => evt instanceof NavigationEnd)).subscribe(() => { + // + // }); + } + + initSF() { + this.schema = { + properties: { + expand: { + type: 'boolean', + ui: { + hidden: true, + }, + }, + storeName: { title: '货源编号', type: 'string', ui: { showRequired: false } }, + contactsName: { + title: '货物名称', + type: 'string', + ui: { + showRequired: false, + }, + }, + unifiedSocialCreditCode: { + title: '装货地', + type: 'string', + ui: { + showRequired: false, + }, + }, + unifiedSocialCreditCode2: { + title: '卸货地', + type: 'string', + ui: { + showRequired: false, + visibleIf: { + expand: (value: boolean) => value, + }, + }, + }, + enStatus2: { + type: 'string', + title: '录单员', + enum: [ + { label: '全部', value: '' }, + { label: '正常', value: 0 }, + { label: '冻结', value: 1 }, + { label: '废弃', value: 2 }, + ], + default: '', + ui: { + widget: 'select', + visibleIf: { + expand: (value: boolean) => value, + }, + }, + }, + }, + }; + this.ui = { '*': { spanLabelFixed: 90, grid: { span: 8, gutter: 4 }, enter: () => this.st.load() } }; + } + initUI() { + this.ui = { + '*': { + spanLabelFixed: 90, + grid: { span: 8 }, + }, + }; + } + tabChange(i: number) { + console.log(i) + this.changeIndex(i); + this.getList(); + } + changeIndex(i: number) { + if (i === 0) { + this.orderStatus = '0'; + this.payStatus = null; + } else if (i === 1) { + this.orderStatus = '5'; + this.payStatus = null; + } else if (i === 2) { + this.orderStatus = null; + this.payStatus = '10'; + } else if (i === 3) { + this.orderStatus = '20'; + this.payStatus = null; + } + this.pageIndex = 1; + } + getList(type?: string) { + // this.loading = true; + const params: any = { + pageSize: this.pageSize, + pageIndex: this.pageIndex, + ...this.sf?.value, + orderStatus: this.orderStatus, + payStatus: this.payStatus, + createTime: this.sf?.value.createTime || [], + time: {}, + }; + if (this.sf?.value?.createTime) { + delete params.createTime; + params.time.start = this.sf?.value?.createTime[0]; + params.time.end = this.sf?.value?.createTime[1]; + } + delete params.expand; + if (type === 'search') { + params.pageIndex = 1; + } + // this.service.request(this.service.$api_get_page, params).subscribe((res) => { + // this.loading = false; + // this.listData = res.orderPage.records; + // this.toSendCount = res.toSendCount; + // this.listData.forEach((element: { goodsList: { goodsSpecJson: string }[] }) => { + // element.goodsList.forEach((item: { goodsSpecJson: string }) => { + // if (item.goodsSpecJson) { + // item.goodsSpecJson = JSON.parse(item.goodsSpecJson); + // } + // }); + // }); + // this.total = res.orderPage.total; + // }); + } + + orderExport() { + // this.service.exportStart(params, this.service.$api_export); + this.modal.create({ + nzTitle: '订单导出', + nzContent: this.exportTemplate, + // nzContent: `待导出订单总数:${this.pageInfo.total}条,确定要导出吗?`, + nzOnOk: () => { + const params: any = { + pageSize: this.pageSize, + pageIndex: this.pageIndex, + ...this.sf?.value, + orderStatus: this.orderStatus, + // createTime: this.sf?.value.createTime || [], + }; + delete params.expand; + }, + }); + } + + goDetail(data: any) { + this.router.navigate(['../order-detail', data.orderSn], { relativeTo: this.ar }); + } + + + changePageIndex(pageIndex: number) { + this.pageIndex = pageIndex; + this.getList(); + } + changePageSize(value: number) { + this.pageSize = value; + this.getList(); + } + expandToggle() { + this.sfExpand = !this.sfExpand; + this.sf?.setValue('/expand', this.sfExpand); + } + + showApply() { + + } + + + /** + * 重置表单 + */ + resetSF() { + this.sf.reset(); + this.sfExpand = false; + } + + + + /** + * 查询字段个数navigate + */ + get queryFieldCount(): number { + return Object.keys(this.schema?.properties || {}).length; + } +} diff --git a/src/app/routes/supply-goods/components/list/list.component.html b/src/app/routes/supply-goods/components/list/list.component.html index 97942916..a4d06ef5 100644 --- a/src/app/routes/supply-goods/components/list/list.component.html +++ b/src/app/routes/supply-goods/components/list/list.component.html @@ -1,19 +1,17 @@ - - + - + - diff --git a/src/app/routes/supply-goods/supply-goods.module.ts b/src/app/routes/supply-goods/supply-goods.module.ts index 399a3c44..64b64a4b 100644 --- a/src/app/routes/supply-goods/supply-goods.module.ts +++ b/src/app/routes/supply-goods/supply-goods.module.ts @@ -1,20 +1,22 @@ /* * @Author: your name * @Date: 2021-11-29 15:22:34 - * @LastEditTime: 2021-12-01 10:03:01 + * @LastEditTime: 2021-12-01 15:03:22 * @LastEditors: Please set LastEditors * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE */ import { NgModule } from '@angular/core'; import { SharedModule } from '@shared'; import { SupplyGoodsComponentListCarloadComponent } from './components/carload/carload.component'; +import { SupplyGoodsComponentListLargeAmountComponent } from './components/large-amount/large-amount.component'; import { SupplyGoodsComponentListComponent } from './components/list/list.component'; import { SupplyGoodsRoutingModule } from './supply-goods-routing.module'; const COMPONENTS = [ SupplyGoodsComponentListComponent, - SupplyGoodsComponentListCarloadComponent + SupplyGoodsComponentListCarloadComponent, + SupplyGoodsComponentListLargeAmountComponent ]; @NgModule({ diff --git a/src/app/routes/vehicle/components/list/detail/detail.component.html b/src/app/routes/vehicle/components/list/detail/detail.component.html new file mode 100644 index 00000000..4aafe892 --- /dev/null +++ b/src/app/routes/vehicle/components/list/detail/detail.component.html @@ -0,0 +1,289 @@ + + + + + + + + + + + + +
+ + + +
确定冻结该企业吗?
+
+ 停用后,该企业将被限制使用,不限于访问受限、无法发布货源等,请谨慎操作 +
+
+
+ +
+ + + +
确定启用该企业吗?
+
+ 启用后,该企业将恢复正常使用功能,请再次确认 +
+
+
+ +
+ + + +
确定关闭该企业支付权限吗?
+
+ 停用后,该企业将被限制使用支付功能,请谨慎操作 +
+
+
+ +
+ + + +
确定开通该企业支付权限吗?
+
+ 启用后,该企业将恢复正常支付功能,请再次确认 +
+
+
+
+ + + 联系信息人 + + {{ detailData?.contactsName }} + + + {{ detailData?.contactsPhone }} + + + {{ detailData?.contactsPhone }} + + + + + + + + 公司基本信息 + + {{ detailData?.enterpriseName }} + + + {{ detailData?.unifiedSocialCreditCode }} + + + {{ detailData?.enterpriseType }} + + + {{ detailData?.registrationCapital }} + 万元 + + + {{ detailData?.enterpriseRegistrationTime }} + + +
+ {{ detailData?.operatingStartTime }} 至 {{ detailData?.operatingEndTime }} +
+
长期
+
{{ detailData?.operatingStartTime }} 至 长期
+
+
+ + + {{ detailData?.enterpriseAddressCodeStr }} + + + {{ detailData?.enterpriseAddress }} + + + + + {{ detailData?.enterpriseAddressCodeStr }} + + + {{ detailData?.enterpriseAddress }} + + + + + {{ detailData?.enterpriseAddressCodeStr }} + + + {{ detailData?.enterpriseAddress }} + + + + + {{ detailData?.businessScope }} + + + + + + + + 法人信息 + + {{ detailData?.name }} + + + {{ detailData?.certificateNumber }} + + + {{ detailData?.validStartTime }} - + {{ detailData?.validEndTime ? detailData?.validEndTime : '长期' }} + + + + + + + + 银行结算信息 + + {{ detailData?.name }} + + + {{ detailData?.certificateNumber }} + + + {{ detailData?.validStartTime }} + + +
+
+ + +
+ + +
+
diff --git a/src/app/routes/vehicle/components/list/detail/detail.component.less b/src/app/routes/vehicle/components/list/detail/detail.component.less new file mode 100644 index 00000000..48f605d9 --- /dev/null +++ b/src/app/routes/vehicle/components/list/detail/detail.component.less @@ -0,0 +1,46 @@ +@import '~@delon/theme/index'; +:host { + ::ng-deep { + .ant-steps-dot { + .ant-steps-item-content { + width: 200px; + } + .ant-steps-item-icon { + margin-left: 96px; + } + .ant-steps-item-tail::after { + margin-left: 40px; + } + } + .success { + color: @success-color; + } + + .warning { + color: @warning-color; + } + + .error { + color: @error-color; + } + } + .mt16 { + margin-top: 16px; + } + .user-info { + display: flex; + font-size: 16px; + .enterprise-name { + margin-right: 15px; + } + img { + width: 64px; + height: 64px; + margin-right: 15px; + border-radius: 50%; + } + .user-info-des { + margin-bottom: 5px; + } + } +} diff --git a/src/app/routes/vehicle/components/list/detail/detail.component.spec.ts b/src/app/routes/vehicle/components/list/detail/detail.component.spec.ts new file mode 100644 index 00000000..00666a0b --- /dev/null +++ b/src/app/routes/vehicle/components/list/detail/detail.component.spec.ts @@ -0,0 +1,31 @@ +/* + * @Author: your name + * @Date: 2021-11-29 20:19:08 + * @LastEditTime: 2021-11-29 20:31:00 + * @LastEditors: your name + * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE + * @FilePath: \tms-obc-web\src\app\routes\usercenter\components\freight\list\detail\detail.component.spec.ts + */ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; +import { FreightComponentsListDetailComponent } from './detail.component'; + +describe('FreightComponentsListDetailComponent', () => { + let component: FreightComponentsListDetailComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [FreightComponentsListDetailComponent], + }).compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(FreightComponentsListDetailComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/src/app/routes/vehicle/components/list/detail/detail.component.ts b/src/app/routes/vehicle/components/list/detail/detail.component.ts new file mode 100644 index 00000000..809f567f --- /dev/null +++ b/src/app/routes/vehicle/components/list/detail/detail.component.ts @@ -0,0 +1,255 @@ +import { Component, OnInit, ViewChild } from '@angular/core'; +import { ActivatedRoute } from '@angular/router'; +import { STColumn, STComponent } from '@delon/abc/st'; +import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; +import { ModalHelper, _HttpClient } from '@delon/theme'; +import { NzMessageService } from 'ng-zorro-antd/message'; +import { UsermanageService } from '../../../../services/usercenter.service'; + +@Component({ + selector: 'app-supplier-components-list-view', + templateUrl: './detail.component.html', + styleUrls: ['./detail.component.less'], +}) +export class FreightComponentsListDetailComponent implements OnInit { + i: any; + url = `/rule?_allow_anonymous=true`; + @ViewChild('st', { static: false }) st!: STComponent; + detailData: any; + isShow = false; + isVisible = false; + modalTitle = '有效期'; + modalName = ''; + ui!: SFUISchema; + schema!: SFSchema; + @ViewChild('sf', { static: false }) sf!: SFComponent; + schema1!: SFSchema; + @ViewChild('sf1', { static: false }) sf1!: SFComponent; + validData: any = ['suppliersType']; + suppliersData: any = {}; + + constructor( + private http: _HttpClient, + private modal: ModalHelper, + public service: UsermanageService, + private route: ActivatedRoute, + private modalHelper: ModalHelper, + private msgSrv: NzMessageService, + ) {} + + ngOnInit() { + console.log(this.route.snapshot); + // this.initData(); + this.initSF(); + this.initSF1(); + // this.launchSign(); + } + /** + * 初始化查询表单 + */ + initSF() { + this.schema = { + properties: { + _$expand: { type: 'boolean', ui: { hidden: true } }, + effectiveDate: { + title: '有效期', + type: 'string', + ui: { + widget: 'date', + format: 'yyyy-MM-dd 00:00:00', + // hidden: this.modalName === 'effectiveDate' ? false : true, + } as SFDateWidgetSchema, + }, + }, + required: ['effectiveDate'], + }; + this.ui = { '*': { spanLabelFixed: 120, grid: { span: 24 } } }; + } + initSF1() { + this.schema1 = { + properties: { + _$expand: { type: 'boolean', ui: { hidden: true } }, + suppliersType: { + type: 'string', + title: '类型', + enum: [ + { label: '非外部供应商', value: 0 }, + { label: '外部供应商', value: 1 }, + ], + default: '', + ui: { + widget: 'select', + change: (args: any) => { + console.log(args, 'args'); + this.suppliersData.suppliersType = args; + if (args === 1) { + this.validData = ['suppliersType', 'externalSuppliersId']; + } else { + this.validData = ['suppliersType']; + this.suppliersData.externalSuppliersId = ''; + } + this.initSF1(); + }, + }, + }, + externalSuppliersId: { + title: '外部供应商id', + type: 'string', + default: '', + ui: { + visibleIf: { suppliersType: (value: any) => value === 1 }, + }, + }, + }, + required: this.validData, + }; + } + showModal(name: any) { + this.modalName = name; + if (name === 'effectiveDate') { + this.isShow = true; + } else { + this.isVisible = true; + } + } + async initData() { + console.log(this.route.snapshot, 'this.route.snapshot'); + + const params = { + tenantId: this.route.snapshot.params.id, + // tenantId: this.route.snapshot.queryParams.tenantId, + }; + const res = await this.service.asyncRequest(this.service.$api_get_supplier_info, params); + // // 商品资质 + // if (res.enterpriseBusinessJson) { + // res.enterpriseBusinessJson.aptitudes = res.enterpriseBusinessJson?.aptitudes ? res.enterpriseBusinessJson.aptitudes.split(',') : []; + // } + // // // 申请人身份证证件 + // // res.applyUserJson.imagelist = []; + // // res.applyUserJson.imagelist.push(res.applyUserJson.certificatePhotoFront); + // // res.applyUserJson.imagelist.push(res.applyUserJson.certificatePhotoBack); + // // res.applyUserJson.imagelist.push(res.applyUserJson.handCertificate); + + // 法人身份证证件 + const imagelist = []; + imagelist.push(res?.certificatePhotoFront); + imagelist.push(res?.certificatePhotoBack); + res.certificatePhoto = imagelist; + + // 营业执照 + res.enterpriseQualificationCertificate = res.enterpriseQualificationCertificate + ? res.enterpriseQualificationCertificate.split(',') + : []; + + // 返回所在地 + res.enterpriseAddressCodeStr = await this.getRegionFullName(res.enterpriseAddressCode); + + this.detailData = res; + this.suppliersData = { + suppliersType: res?.suppliersType, + externalSuppliersId: res?.externalSuppliersId, + }; + } + + /** + * 根据地区code查询地区详情 + * @param code 地区代码 + */ + async getRegionFullName(code: any) { + const params = { + regionCode: code, + }; + const res = await this.service.asyncRequest(this.service.$api_get_region_detailByCode, params, 'POST', true); + // if (res && res.regionFullName) { + // const arr = res.regionFullName.split(','); + // res.regionFullName = arr.reverse().join('-'); + // } + return res && res.regionFullName; + } + add() { + // this.modal + // .createStatic(FormEditComponent, { i: { id: 0 } }) + // .subscribe(() => this.st.reload()); + } + goBack() { + window.history.go(-1); + } + /** + * 冻结 + */ + freezeOrResume(type: number) { + console.log(type) + // this.service.http + // .post(this.service.$api_set_freezeOrResume, { + // tenantId: this.route.snapshot.params.id, + // // tenantId: this.route.snapshot.queryParams.tenantId, + // status: type, + // }) + // .subscribe((res) => { + // if (res.data === true) { + // if (type === 0) { + // this.service.msgSrv.success(`启用成功!`); + // } else if (type === 1) { + // this.service.msgSrv.success(`冻结成功!`); + // } + // this.ngOnInit(); + // } else { + // this.service.msgSrv.error(res.msg || '操作失败!'); + // } + // }); + } + PayOrResume(type: number) { + console.log(type) + // this.service.http + // .post(this.service.$api_set_freezeOrResume, { + // tenantId: this.route.snapshot.params.id, + // // tenantId: this.route.snapshot.queryParams.tenantId, + // status: type, + // }) + // .subscribe((res) => { + // if (res.data === true) { + // if (type === 0) { + // this.service.msgSrv.success(`启用成功!`); + // } else if (type === 1) { + // this.service.msgSrv.success(`冻结成功!`); + // } + // this.ngOnInit(); + // } else { + // this.service.msgSrv.error(res.msg || '操作失败!'); + // } + // }); + } + + handleCancel(name: any) { + if (name === 'effectiveDate') { + this.isShow = false; + } else { + this.isVisible = false; + } + } + handleOK(name: any) { + const params: any = { + tenantId: this.route.snapshot.params.id, + // tenantId: this.route.snapshot.queryParams.tenantId, + }; + + if (name === 'effectiveDate') { + params.effectiveDate = this.sf?.value?.effectiveDate; + } else { + Object.assign(params, this.sf1?.value); + } + this.service.http.post(this.service.$api_set_freezeOrResume, params).subscribe((res) => { + if (res.data === true) { + this.service.msgSrv.success(`编辑成功!`); + this.ngOnInit(); + } else { + this.service.msgSrv.error(res.msg || '编辑失败!'); + } + if (name === 'effectiveDate') { + this.isShow = false; + } else { + this.isVisible = false; + } + }); + } +} diff --git a/src/app/routes/vehicle/components/list/list.component.html b/src/app/routes/vehicle/components/list/list.component.html new file mode 100644 index 00000000..b0d2de52 --- /dev/null +++ b/src/app/routes/vehicle/components/list/list.component.html @@ -0,0 +1,84 @@ + + + + + + +
+ +
+ + +
+ + + + +
+ +
+
+ + + + + +
+
+
+
+ + + + + + +
+
+ {{ item.enterpriseName }} +
+
+
+ +
+ {{ item.contactsPhone }} +
+
+ + 冻结 + 正常 + +
+
diff --git a/src/app/routes/vehicle/components/list/list.component.spec.ts b/src/app/routes/vehicle/components/list/list.component.spec.ts new file mode 100644 index 00000000..e815b19d --- /dev/null +++ b/src/app/routes/vehicle/components/list/list.component.spec.ts @@ -0,0 +1,31 @@ +/* + * @Author: your name + * @Date: 2021-12-01 20:05:59 + * @LastEditTime: 2021-12-01 20:35:33 + * @LastEditors: your name + * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE + * @FilePath: \tms-obc-web\src\app\routes\vehicle\components\list\list.component.spec.ts + */ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; +import { VehicleComponentsListComponent } from './list.component'; + +describe('VehicleComponentsListComponent', () => { + let component: VehicleComponentsListComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [VehicleComponentsListComponent], + }).compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(VehicleComponentsListComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/src/app/routes/vehicle/components/list/list.component.ts b/src/app/routes/vehicle/components/list/list.component.ts new file mode 100644 index 00000000..227549e8 --- /dev/null +++ b/src/app/routes/vehicle/components/list/list.component.ts @@ -0,0 +1,228 @@ +import { Component, OnInit, ViewChild } from '@angular/core'; +import { ActivatedRoute, Router } from '@angular/router'; +import { STColumn, STColumnBadge, STComponent, STData } from '@delon/abc/st'; +import { SFComponent, SFSchema, SFUISchema } from '@delon/form'; +import { NzModalService } from 'ng-zorro-antd/modal'; +import { UsermanageService } from '../../../vehicle/services/vehicle.service'; +@Component({ + selector: 'app-Freight-components-list', + templateUrl: './list.component.html', +}) +export class VehicleComponentsListComponent implements OnInit { + _$expand = false; + url = `/rule?_allow_anonymous=true`; + + ui!: SFUISchema; + schema!: SFSchema; + columns!: STColumn[]; + datalist = [ + { + storeName: '企业名称', + contactsName: '152746565', + enterpriseName: '湖南', + unifiedSocialCreditCode: '45454', + contactsPhone: '*97889461561', + effectiveDateStr: '废弃eww', + enStatusStr2: '正常', + enStatusStr3: '正常', + unifiedSocialCreditCode3: '常用服务', + unifiedSocialCreditCode2: '正常', + tenantId: 1 + }, + { + storeName: '企业名称', + contactsName: '152746565', + enterpriseName: '湖南', + unifiedSocialCreditCode: '45454', + contactsPhone: '*97889461561', + effectiveDateStr: '废弃eww', + enStatusStr2: '正常', + enStatusStr3: '正常', + unifiedSocialCreditCode3: '常用服务', + unifiedSocialCreditCode2: '正常', + tenantId: 2 + }, + ] + @ViewChild('st', { static: false }) st!: STComponent; + @ViewChild('sf', { static: false }) sf!: SFComponent; + + constructor(public service: UsermanageService, private modal: NzModalService, private router: Router, private ar: ActivatedRoute) {} + /** + * 查询字段个数navigate + */ + get queryFieldCount(): number { + return Object.keys(this.schema?.properties || {}).length; + } + + /** + * 查询参数 + */ + get reqParams() { + const params: any = { + ...(this.sf && this.sf.value), + }; + if (this.sf?.value.effectiveDate) { + params.effectiveDateStart = this.sf?.value.effectiveDate[0]; + params.effectiveDateEnd = this.sf?.value.effectiveDate[1]; + } + delete params.effectiveDate; + delete params.expand; + return params; + } + + get selectedRows() { + return this.st?.list.filter((item) => item.checked) || []; + } + + ngOnInit() { + this.initSF(); + this.initST(); + this.ar.url.subscribe((params) => { + this.st?.load(1); + }); + } + dataProcess(data: STData[]): STData[] { + return data.map((i, index) => { + i.showSortFlag = false; + return i; + }); + } + initSF() { + this.schema = { + properties: { + expand: { + type: 'boolean', + ui: { + hidden: true, + }, + }, + storeName: { title: '企业名称', type: 'string', ui: { showRequired: false } }, + contactsName: { + title: '联系人', + type: 'string', + ui: { + showRequired: false, + }, + }, + unifiedSocialCreditCode: { + title: '税源地', + type: 'string', + ui: { + showRequired: false, + }, + }, + enStatus: { + type: 'string', + title: '货主状态', + enum: [ + { label: '全部', value: '' }, + { label: '正常', value: 0 }, + { label: '冻结', value: 1 }, + { label: '废弃', value: 2 }, + ], + default: '', + ui: { + widget: 'select', + visibleIf: { + expand: (value: boolean) => value, + }, + }, + }, + enStatus2: { + type: 'string', + title: 'CRM审核状态', + enum: [ + { label: '全部', value: '' }, + { label: '正常', value: 0 }, + { label: '冻结', value: 1 }, + { label: '废弃', value: 2 }, + ], + default: '', + ui: { + widget: 'select', + visibleIf: { + expand: (value: boolean) => value, + }, + }, + }, + }, + }; + this.ui = { '*': { spanLabelFixed: 90, grid: { span: 8, gutter: 4 }, enter: () => this.st.load() } }; + } + + initST() { + this.columns = [ + // { title: '', type: 'checkbox', className: 'text-center' }, + { title: '企业名称', className: 'text-center', index: 'storeName' }, + { title: '联系人', className: 'text-center', index: 'contactsName' }, + { title: '税源地', className: 'text-center', render: 'enterpriseName' }, + { title: '累计运单金额', className: 'text-center', index: 'unifiedSocialCreditCode' }, + { title: '道运证', className: 'text-center', index: 'contactsPhone', + render: 'contactsPhone' + }, + { title: '企业状态', className: 'text-center', index: 'effectiveDateStr', + type: 'badge', + badge: { + 正常: { text: '正常', color: 'success' }, + 冻结: { text: '冻结', color: 'warning' }, + 废弃: { text: '废弃', color: 'default' }, + }, + }, + { + title: 'CRM审核状态', + className: 'text-center', + index: 'enStatusStr2', + type: 'badge', + badge: { + 正常: { text: '正常', color: 'success' }, + 冻结: { text: '冻结', color: 'warning' }, + 废弃: { text: '废弃', color: 'default' }, + }, + }, + { + title: '代收权限', + className: 'text-center', + index: 'enStatusStr3', + type: 'badge', + badge: { + 正常: { text: '正常', color: 'success' }, + 冻结: { text: '冻结', color: 'warning' }, + 废弃: { text: '废弃', color: 'default' }, + }, + }, + { title: '常用服务', className: 'text-center', index: 'unifiedSocialCreditCode3' }, + { title: '推广业务员', className: 'text-center', index: 'unifiedSocialCreditCode2' }, + { + title: '操作', + width: '170px', + className: 'text-center', + buttons: [ + { + text: '查看', + click: (item) => { + this.router.navigate(['./detail', item.tenantId], { relativeTo: this.ar }); + // this.router.navigate(['./view', item.id], { relativeTo: this.ar, queryParams: { tenantId: item.tenantId } }); + }, + }, + ], + }, + ]; + } + daoyun(item: any) { + this.router.navigate(['./view', item.tenantId], { relativeTo: this.ar }); + } + expandToggle() { + this._$expand = !this._$expand; + this.sf?.setValue('/expand', this._$expand); + } + creat() { + this.router.navigate(['./new',], { relativeTo: this.ar }); + } + /** + * 重置表单 + */ + resetSF() { + this.sf.reset(); + this._$expand = false; + } +} diff --git a/src/app/routes/vehicle/services/vehicle.service.ts b/src/app/routes/vehicle/services/vehicle.service.ts new file mode 100644 index 00000000..f73600a1 --- /dev/null +++ b/src/app/routes/vehicle/services/vehicle.service.ts @@ -0,0 +1,91 @@ +/* + * @Author: your name + * @Date: 2021-11-29 15:22:34 + * @LastEditTime: 2021-11-29 15:43:42 + * @LastEditors: your name + * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE + * @FilePath: \tms-obc-web\src\app\routes\usercenter\services\usercenter.service.ts + */ +import { Injectable, Injector } from '@angular/core'; +import { _HttpClient } from '@delon/theme'; +import { NzMessageService } from 'ng-zorro-antd/message'; +import { BaseService } from 'src/app/shared/services/core/base.service'; +import { EAFileUtil } from 'src/app/shared/utils/file.util'; + +@Injectable({ + providedIn: 'root', +}) +export class UsermanageService extends BaseService { + public $api_add_one!: string; + public $api_add_many!: string; + public $api_edit_one!: string; + public $api_edit_many!: string; + public $api_del_one!: string; + public $api_del_many!: string; + public $api_get_many!: string; + public $api_get_one!: string; + public $api_get_page!: string; + public $api_export!: string; + public $api_import!: string; + public $api_import_download_tpl!: string; + // 平台用户列表 + $api_get_page_user = '/cuc/userApp/getOperatorUserList?_allow_anonymous=true'; + // 获取供应商采购商应用 + $api_get_supplier_purchaserApp = '/cuc/appInfo/getSupplierPurchaserApp?_allow_anonymous=true'; + + // 供应商列表 + $api_get_supplier_page = '/cuc/operator/list/listSupplierPage?_allow_anonymous=true'; + // 供应商详情 + $api_get_supplier_info = '/cuc/operator/selectSupplierDetailInfo?_allow_anonymous=true'; + // 用户冻结或恢复应用用户 + $api_set_freezeOrResume = '/cuc/operator/updateSupplierInfo?_allow_anonymous=true'; + // 获取一、二、三级地区详情 + $api_getRegionToThree = '/cms/region/getRegionToThree?_allow_anonymous=true'; + // 根据地区code查询列表 + $api_getRegionByCode = '/cms/region/getRegionByCode?_allow_anonymous=true'; + + // 根据地区code查询地区详情 + $api_get_region_detailByCode = '/cms/region/getRegionDetailByCode?_allow_anonymous=true'; + // 查询供应商申请列表分页 + $api_get_supplier_audit_page = `/cuc/operator/audit/listSupplierPage?_allow_anonymous=true`; + // 查询供应商入驻详情 + $api_get_supplier_entryInfo = `/cuc/operator/selectSupplierEntryDetailInfo?_allow_anonymous=true`; + // 审核供应商 + $api_auditSupplier = `/cuc/operator/auditSupplier?_allow_anonymous=true`; + // 查询采购商列表分页 + $api_get_purchaserList = `/cuc/operator/list/queryPurchaserPage`; + // 查询采购商申请列表分页 + $api_get_purchaserAudit = `/cuc/operator/audit/queryPurchaserPage`; + // 查询采购商认证详情 + $api_get_purchaser_detailInfo = `/cuc/operator/selectPurchaserDetailInfo`; + + // 查询采购商审核总数 + $api_query_purchaser_count = `/cuc/operator/queryPurchaserCount`; + // 获取供应商审核总数 + $api_query_supplier_count = `/cuc/operator/querySupplierCount`; + + // 审核企业详情 + $api_get_cache_enterprise_info = ''; + // 获取审核进度 + $api_get_progress = '/cuc/reviewRecordInfo/getReviewProgress'; + // 查询流程信息列表 + $api_get_progressInfoList = '/cuc/processInfo/getProcessInfoList'; + // 审核通过 + $api_set_audit_pass = '/cuc/reviewRecordInfo/reviewPassed'; + // 审核拒绝 + $api_set_audit_reject = '/cuc/reviewRecordInfo/reviewRejected'; + + // 发起签约 //撤回签约 + $api_get_startSigning = `/cuc/operator/startSigning?_allow_badcode=true`; + + // 发起续约 //撤回续约 + $api_get_startRenewalContract = `/cuc/operator/startRenewalContract?_allow_badcode=true`; + // 获取审核记录 + $api_get_reviewRecordInfoList = '/cuc/reviewRecordInfo/getReviewRecordInfoList'; + // 查看合同详情 + $api_get_contract_detail = `/scce/etc/etc/contractDetail/getContractByContractNo`; + + constructor(public injector: Injector) { + super(injector); + } +} diff --git a/src/app/routes/vehicle/vehicle-routing.module.ts b/src/app/routes/vehicle/vehicle-routing.module.ts new file mode 100644 index 00000000..983d9e64 --- /dev/null +++ b/src/app/routes/vehicle/vehicle-routing.module.ts @@ -0,0 +1,24 @@ +/* + * @Author: your name + * @Date: 2021-11-29 15:22:34 + * @LastEditTime: 2021-12-01 20:38:01 + * @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\usercenter\usercenter-routing.module.ts + */ +import { NgModule } from '@angular/core'; +import { RouterModule, Routes } from '@angular/router'; +import { VehicleComponentsListComponent } from './components/list/list.component'; + + + +const routes: Routes = [ + + { path: 'list', component: VehicleComponentsListComponent }, +]; + +@NgModule({ + imports: [RouterModule.forChild(routes)], + exports: [RouterModule], +}) +export class VehicleRoutingModule {} diff --git a/src/app/routes/vehicle/vehicle.module.ts b/src/app/routes/vehicle/vehicle.module.ts new file mode 100644 index 00000000..bcf9b1f7 --- /dev/null +++ b/src/app/routes/vehicle/vehicle.module.ts @@ -0,0 +1,23 @@ +/* + * @Author: your name + * @Date: 2021-11-29 15:22:34 + * @LastEditTime: 2021-12-01 20:36:45 + * @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\usercenter\usercenter.module.ts + */ +import { NgModule } from '@angular/core'; +import { SharedModule } from '@shared'; +import { VehicleComponentsListComponent } from './components/list/list.component'; +import { VehicleRoutingModule } from './vehicle-routing.module'; + + +const COMPONENTS = [ + VehicleComponentsListComponent +]; + +@NgModule({ + imports: [SharedModule, VehicleRoutingModule], + declarations: [...COMPONENTS], +}) +export class VehicleModule {} diff --git a/src/app/shared/shared-zorro.module.ts b/src/app/shared/shared-zorro.module.ts index 4051261b..bc6ebba4 100644 --- a/src/app/shared/shared-zorro.module.ts +++ b/src/app/shared/shared-zorro.module.ts @@ -1,3 +1,4 @@ +import { NzInputNumberModule } from 'ng-zorro-antd/input-number'; import { NzTreeModule } from 'ng-zorro-antd/tree'; import { NzProgressModule } from 'ng-zorro-antd/progress'; import { NzPopoverModule } from 'ng-zorro-antd/popover'; @@ -6,7 +7,7 @@ import { NzToolTipModule } from 'ng-zorro-antd/tooltip'; /* * @Author: your name * @Date: 2021-11-29 10:20:33 - * @LastEditTime: 2021-11-30 09:54:47 + * @LastEditTime: 2021-12-01 16:50:17 * @LastEditors: Please set LastEditors * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @FilePath: \tms-obc-web\src\app\shared\shared-zorro.module.ts @@ -35,7 +36,6 @@ import { NzTabsModule } from 'ng-zorro-antd/tabs'; import { NzRadioModule } from 'ng-zorro-antd/radio'; import { NzTimePickerModule } from 'ng-zorro-antd/time-picker'; import { NzCheckboxModule } from 'ng-zorro-antd/checkbox'; -import { NzInputNumberModule } from 'ng-zorro-antd/input-number'; export const SHARED_ZORRO_MODULES = [ NzButtonModule, NzGridModule, @@ -60,7 +60,6 @@ export const SHARED_ZORRO_MODULES = [ NzRateModule, NzResultModule, NzTreeModule, - NzTableModule, NzTabsModule, NzRadioModule, NzTimePickerModule, diff --git a/src/assets/images/user/yuandian.svg b/src/assets/images/user/yuandian.svg new file mode 100644 index 00000000..69353e5e --- /dev/null +++ b/src/assets/images/user/yuandian.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/assets/mocks/menu-data.json b/src/assets/mocks/menu-data.json index 77e27649..77326531 100644 --- a/src/assets/mocks/menu-data.json +++ b/src/assets/mocks/menu-data.json @@ -112,6 +112,17 @@ } ] }, + { + "text": "车辆管理", + "icon": "anticon anticon-dashboard", + "group": true, + "children": [ + { + "text": "车辆列表", + "link": "/vehicle/list" + } + ] + }, { "text": "系统设置", "icon": "anticon anticon-dashboard",