From 7d747a68462b2b036f3eabdbf0311bed51640e88 Mon Sep 17 00:00:00 2001 From: yuanye <418471657@qq.com> Date: Mon, 17 Jun 2024 17:02:15 +0800 Subject: [PATCH] 1 --- .../audit/audit-list/audit-list.component.ts | 6 ++-- .../goods-list/goods-list.component.html | 17 +++++++++-- .../goods/goods-list/goods-list.component.ts | 29 ++++++++++++++----- src/app/services/common/common.service.ts | 3 +- 4 files changed, 41 insertions(+), 14 deletions(-) diff --git a/src/app/pages/audit/audit-list/audit-list.component.ts b/src/app/pages/audit/audit-list/audit-list.component.ts index 5fd8098..2377b2b 100644 --- a/src/app/pages/audit/audit-list/audit-list.component.ts +++ b/src/app/pages/audit/audit-list/audit-list.component.ts @@ -185,12 +185,14 @@ export class AuditListComponent { this.postAudit.remarks = this.remarks; this.auditService.auditMsg(this.postAudit , (data: any) => { if (data['return_code'] == '000000') { - this.getRequest(true); + this.getRequest(false); + this.isVisibleAudit = false; + this.isVisibleDetail = false; this.msg.success("操作成功") } else { this.msg.error(data['return_msg']); } - this.isVisibleAudit = false; + }); } diff --git a/src/app/pages/goods/goods-list/goods-list.component.html b/src/app/pages/goods/goods-list/goods-list.component.html index 51b33be..4794481 100644 --- a/src/app/pages/goods/goods-list/goods-list.component.html +++ b/src/app/pages/goods/goods-list/goods-list.component.html @@ -21,6 +21,7 @@ +
商品品牌 @@ -54,6 +55,16 @@
+
+ + 商品商户 + + + + + + +
@@ -74,7 +85,7 @@ [nzData]="tableData.list" > - 商户 + 商户 商品名称 商品图片 商品类型 @@ -88,7 +99,7 @@ - {{data.merName}} + {{data.merName}} {{data.title}} @@ -124,7 +135,7 @@ 总计 {{ total }} 条 - +
diff --git a/src/app/pages/goods/goods-list/goods-list.component.ts b/src/app/pages/goods/goods-list/goods-list.component.ts index 2fb352f..d5a9eff 100644 --- a/src/app/pages/goods/goods-list/goods-list.component.ts +++ b/src/app/pages/goods/goods-list/goods-list.component.ts @@ -12,7 +12,7 @@ import {NzMessageService} from "ng-zorro-antd/message"; import {CommonService} from "../../../services/common/common.service"; import {GoodsService} from "../../../services/goods/goods.service"; import { fallbackImg } from '../../../data/goods/goods.namespace'; -import {GoodsMsgData, GoodsTypeData, SpecsData} from "../../../model/goods.interface"; +import {GoodsMsgData, SpecsData} from "../../../model/goods.interface"; import {NzDividerComponent} from "ng-zorro-antd/divider"; import {NzIconDirective} from "ng-zorro-antd/icon"; import {NzImageDirective, NzImageModule} from "ng-zorro-antd/image"; @@ -25,7 +25,6 @@ import { import {NzTreeSelectComponent} from "ng-zorro-antd/tree-select"; import {DictionaryPipe} from "../../../pipes/common/dictionary.pipe"; import {GoodsStatusPipe} from "../../../pipes/goods/goods-status.pipe"; -import {NzConfigService} from "ng-zorro-antd/core/config"; import {NzDropDownADirective, NzDropDownDirective, NzDropdownMenuComponent} from "ng-zorro-antd/dropdown"; import {NzMenuDirective, NzMenuItemComponent} from "ng-zorro-antd/menu"; import { @@ -37,6 +36,9 @@ import {NzSpaceItemDirective} from "ng-zorro-antd/space"; import {NzDatePickerComponent} from "ng-zorro-antd/date-picker"; import {NzTypographyComponent} from "ng-zorro-antd/typography"; import {Observable, Observer} from "rxjs"; +import {BrowserStorageService} from "../../../utils/localStorage.service"; +import {DATA} from "../../../data/login/localStorage.namespace"; +import {MerService} from "../../../services/merchant/mer.service"; const getBase64 = (file: File): Promise => new Promise((resolve, reject) => { @@ -133,27 +135,29 @@ export class GoodsListComponent { nodesBrand = []; nodesSpecs:SpecsData[] = []; nodesVpdSource; + merData: any; + objectType: number; goodsMsg?: GoodsMsgData; - - - protected readonly fallbackImg = fallbackImg; constructor(private fb: NonNullableFormBuilder, private msg: NzMessageService, - + private merService: MerService, + private storage: BrowserStorageService, private commonService: CommonService, private goodsService: GoodsService) { this.nodesVpdSource = new DictionaryPipe().getDictionaryList('GOODS_VPD_SOURCE'); - + this.objectType = this.storage.get(DATA)['account']['objectType']; + this.merList(); // 初始化搜索框 this.searchForm = this.fb.group({ title: [''], goodsType: [''], goodsBrand: [''], + merId: [''], type: [''], status: [''], }); @@ -490,5 +494,16 @@ export class GoodsListComponent { }); + merList() { + let params = { + pageNum: 1 , + pageSize: 10000 + } + this.merService.queryList(params, (data: any) => { + if (data['return_code'] == '000000') { + this.merData = data['return_data'].list; + } + }); + } } diff --git a/src/app/services/common/common.service.ts b/src/app/services/common/common.service.ts index 5370216..1230801 100644 --- a/src/app/services/common/common.service.ts +++ b/src/app/services/common/common.service.ts @@ -69,13 +69,12 @@ export class CommonService { for (const i of imgUrl.split(',')) { imgArray.push( { - uid: 1, + uid: i, name: i, status: 'done', url: environment.imageUrl + i }); } - console.log(imgArray); return imgArray; }