From 0c930be5fbff27e86d016619885eec3924f73d15 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Tue, 4 Jan 2022 16:05:44 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E8=BD=A6=E8=BE=86=E5=AF=B9=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../vehicle-detail.component.html | 4 +- .../bulk-publish/bulk-publish.component.ts | 53 +++++++++-- .../system-logs/system-logs.component.ts | 2 + .../system-supply-logs.component.html | 35 +++++++ .../system-supply-logs.component.less | 32 +++++++ .../system-supply-logs.component.ts | 91 +++++++++++++++++++ .../system-waybill-logs.component.html | 35 +++++++ .../system-waybill-logs.component.less | 32 +++++++ .../system-waybill-logs.component.ts | 90 ++++++++++++++++++ .../sys-setting/sys-setting-routing.module.ts | 4 + .../routes/sys-setting/sys-setting.module.ts | 14 ++- .../bulk-detail/bulk-detail.component.html | 8 +- .../vehicle-detail.component.html | 8 +- src/assets/mocks/menu-data.json | 8 ++ 14 files changed, 396 insertions(+), 20 deletions(-) create mode 100644 src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.html create mode 100644 src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.less create mode 100644 src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.ts create mode 100644 src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.html create mode 100644 src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.less create mode 100644 src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.ts diff --git a/src/app/routes/order-management/components/vehicle-detail/vehicle-detail.component.html b/src/app/routes/order-management/components/vehicle-detail/vehicle-detail.component.html index 70d0a013..fb8dbc9b 100644 --- a/src/app/routes/order-management/components/vehicle-detail/vehicle-detail.component.html +++ b/src/app/routes/order-management/components/vehicle-detail/vehicle-detail.component.html @@ -1,7 +1,7 @@ + + + + +
+
+ +
+
+ + + +
+
+
+ + + + \ No newline at end of file diff --git a/src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.less b/src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.less new file mode 100644 index 00000000..4d397f58 --- /dev/null +++ b/src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.less @@ -0,0 +1,32 @@ +:host::ng-deep { + .search-box { + .ant-card-body { + padding-bottom: 18px; + } + } + + .content-box { + .ant-card-body { + padding-top: 14px; + } + } + + nz-range-picker { + width: 100%; + } +} + +.expend-options { + margin-top: 0; +} + + +@media (min-width: 1200px) { + .expend-options { + position : absolute; + right : 0; + bottom : 25px; + max-width: 400px; + } + +} \ No newline at end of file diff --git a/src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.ts b/src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.ts new file mode 100644 index 00000000..720c58b9 --- /dev/null +++ b/src/app/routes/sys-setting/components/system-supply-logs/system-supply-logs.component.ts @@ -0,0 +1,91 @@ +/* + * @Author: your name + * @Date: 2022-01-04 14:42:30 + * @LastEditTime: 2022-01-04 16:04:46 + * @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\sys-setting\components\system-supply-logs\system-supply-logs.component.ts + */ +import { Component, OnInit, ViewChild } from '@angular/core'; +import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st'; +import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; +import { dateTimePickerUtil } from '@delon/util'; +import { NzModalService } from 'ng-zorro-antd/modal'; +import { SystemService } from '../../services/system.service'; + +@Component({ + selector: 'app-system-logs', + templateUrl: './system-supply-logs.component.html', + styleUrls: ['./system-supply-logs.component.less'] +}) +export class SystemSupplyLogsComponent implements OnInit { + @ViewChild('st', { static: true }) + st!: STComponent; + @ViewChild('sf', { static: false }) + sf!: SFComponent; + + searchSchema: SFSchema = { + properties: { + operateObject: { + type: 'string', + title: '货源编码', + ui: { + placeholder: '请输入', + } + }, + time: { + title: '登录时间', + type: 'string', + ui: { + widget: 'sl-from-to-search', + format: 'yyyy-MM-dd HH:mm:ss', + nzShowTime: true, + } as SFDateWidgetSchema + } + } + }; + + columns: STColumn[] = [ + + { title: 'ID', index: 'id' }, + { title: '货源编码', index: 'operateObject' }, + { title: '说明', index: 'operationContent' }, + { title: '操作人', index: 'operator' }, + { title: '操作时间', index: 'operatorTimestamp', type: 'date' }, + ]; + + _$expand = false; + + constructor(public service: SystemService, private nzModalService: NzModalService) {} + + ngOnInit(): void {} + + beforeReq = (requestOptions: STRequestOptions) => { + requestOptions.body.operateType = '4' + if (this.sf) { + Object.assign(requestOptions.body, { + ...this.sf.value, + operateType: '4', + endTime: this.sf.value.time?.[1] || null, + startTime: this.sf.value.time?.[0] || null + }); + } + return requestOptions; + }; + + /** + * 重置表单 + */ + resetSF() { + this.sf.reset(); + this._$expand = false; + } + + /** + * 伸缩查询条件 + */ + expandToggle() { + this._$expand = !this._$expand; + this.sf?.setValue('/expand', this._$expand); + } +} diff --git a/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.html b/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.html new file mode 100644 index 00000000..74de77e0 --- /dev/null +++ b/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.html @@ -0,0 +1,35 @@ + + + + + +
+
+ +
+
+ + + +
+
+
+ + + + \ No newline at end of file diff --git a/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.less b/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.less new file mode 100644 index 00000000..4d397f58 --- /dev/null +++ b/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.less @@ -0,0 +1,32 @@ +:host::ng-deep { + .search-box { + .ant-card-body { + padding-bottom: 18px; + } + } + + .content-box { + .ant-card-body { + padding-top: 14px; + } + } + + nz-range-picker { + width: 100%; + } +} + +.expend-options { + margin-top: 0; +} + + +@media (min-width: 1200px) { + .expend-options { + position : absolute; + right : 0; + bottom : 25px; + max-width: 400px; + } + +} \ No newline at end of file diff --git a/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.ts b/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.ts new file mode 100644 index 00000000..0a490d32 --- /dev/null +++ b/src/app/routes/sys-setting/components/system-waybill-logs/system-waybill-logs.component.ts @@ -0,0 +1,90 @@ +/* + * @Author: your name + * @Date: 2022-01-04 14:44:59 + * @LastEditTime: 2022-01-04 16:05:27 + * @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\sys-setting\components\system-waybill-logs\system-waybill-logs.component.ts + */ +import { Component, OnInit, ViewChild } from '@angular/core'; +import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st'; +import { SFComponent, SFDateWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; +import { dateTimePickerUtil } from '@delon/util'; +import { NzModalService } from 'ng-zorro-antd/modal'; +import { SystemService } from '../../services/system.service'; + +@Component({ + selector: 'app-system-logs', + templateUrl: './system-waybill-logs.component.html', + styleUrls: ['./system-waybill-logs.component.less'] +}) +export class SystemWaybillLogsComponent implements OnInit { + @ViewChild('st', { static: true }) + st!: STComponent; + @ViewChild('sf', { static: false }) + sf!: SFComponent; + + searchSchema: SFSchema = { + properties: { + operateObject: { + type: 'string', + title: '订单号', + ui: { + placeholder: '请输入', + } + }, + time: { + title: '登录时间', + type: 'string', + ui: { + widget: 'sl-from-to-search', + format: 'yyyy-MM-dd HH:mm:ss', + nzShowTime: true, + } as SFDateWidgetSchema + } + } + }; + + columns: STColumn[] = [ + { title: 'ID', index: 'id' }, + { title: '订单号', index: 'operateObject' }, + { title: '说明', index: 'operationContent' }, + { title: '操作人', index: 'operator' }, + { title: '操作时间', index: 'operatorTimestamp', type: 'date' }, + ]; + + _$expand = false; + + constructor(public service: SystemService, private nzModalService: NzModalService) {} + + ngOnInit(): void {} + + beforeReq = (requestOptions: STRequestOptions) => { + requestOptions.body.operateType = '3' + if (this.sf) { + Object.assign(requestOptions.body, { + ...this.sf.value, + operateType: '3', + endTime: this.sf.value.time?.[1] || null, + startTime: this.sf.value.time?.[0] || null + }); + } + return requestOptions; + }; + + /** + * 重置表单 + */ + resetSF() { + this.sf.reset(); + this._$expand = false; + } + + /** + * 伸缩查询条件 + */ + expandToggle() { + this._$expand = !this._$expand; + this.sf?.setValue('/expand', this._$expand); + } +} diff --git a/src/app/routes/sys-setting/sys-setting-routing.module.ts b/src/app/routes/sys-setting/sys-setting-routing.module.ts index 6faf0bba..c3763507 100644 --- a/src/app/routes/sys-setting/sys-setting-routing.module.ts +++ b/src/app/routes/sys-setting/sys-setting-routing.module.ts @@ -21,6 +21,8 @@ import { RoleManagementComponent } from './components/role-management/role-manag import { StaffManagementComponent } from './components/staff-management/staff-management.component'; import { SystemConfigComponent } from './components/system-config/system-config.component'; import { SystemLogsComponent } from './components/system-logs/system-logs.component'; +import { SystemSupplyLogsComponent } from './components/system-supply-logs/system-supply-logs.component'; +import { SystemWaybillLogsComponent } from './components/system-waybill-logs/system-waybill-logs.component'; import { UserLogsComponent } from './components/user-logs/user-logs.component'; import { VersionLogsComponent } from './components/version-logs/version-logs.component'; @@ -40,6 +42,8 @@ const routes: Routes = [ { path: 'crm-management', component: CrmManagementComponent }, { path: 'network-freight', component: NetworkFreightComponent }, { path: 'close-account', component: CloseAccountComponent }, + { path: 'system-supply-logs', component: SystemSupplyLogsComponent }, + { path: 'system-waybill-logs', component: SystemWaybillLogsComponent }, ]; @NgModule({ diff --git a/src/app/routes/sys-setting/sys-setting.module.ts b/src/app/routes/sys-setting/sys-setting.module.ts index 281188d1..74883e8c 100644 --- a/src/app/routes/sys-setting/sys-setting.module.ts +++ b/src/app/routes/sys-setting/sys-setting.module.ts @@ -1,3 +1,11 @@ +/* + * @Author: your name + * @Date: 2021-12-03 15:23:05 + * @LastEditTime: 2022-01-04 14:46:23 + * @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\sys-setting\sys-setting.module.ts + */ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { SharedModule } from '@shared'; @@ -24,6 +32,8 @@ import { GoodsNameConfigComponent } from './components/goods-name-config/goods-n import { CrmManagementComponent } from './components/crm-management/crm-management.component'; import { NetworkFreightComponent } from './components/network-freight/network-freight.component'; import { CloseAccountComponent } from './components/close-account/close-account.component'; +import { SystemSupplyLogsComponent } from './components/system-supply-logs/system-supply-logs.component'; +import { SystemWaybillLogsComponent } from './components/system-waybill-logs/system-waybill-logs.component'; const COMPONENTS = [ StaffManagementComponent, @@ -40,7 +50,9 @@ const COMPONENTS = [ GoodsNameConfigComponent, CrmManagementComponent, NetworkFreightComponent, - CloseAccountComponent + CloseAccountComponent, + SystemSupplyLogsComponent, + SystemWaybillLogsComponent ]; const NOTROUTECOMPONENTS = [ BuyerTranspowerComponent, diff --git a/src/app/routes/waybill-management/components/bulk-detail/bulk-detail.component.html b/src/app/routes/waybill-management/components/bulk-detail/bulk-detail.component.html index d71990b9..16bec8e7 100644 --- a/src/app/routes/waybill-management/components/bulk-detail/bulk-detail.component.html +++ b/src/app/routes/waybill-management/components/bulk-detail/bulk-detail.component.html @@ -1,7 +1,7 @@