袁野 3 months ago
parent dce6544e92
commit 92080b696e
  1. 9
      src/app/pages/account/sys-role/sys-role.component.ts
  2. 97
      src/app/pages/goods/goods-list/goods-list.component.html
  3. 93
      src/app/pages/goods/goods-list/goods-list.component.ts
  4. 10
      src/app/pages/goods/jd-goods-list/jd-goods-list.component.html
  5. 34
      src/app/pages/goods/jd-goods-list/jd-goods-list.component.ts
  6. 18
      src/app/pages/marketing/discount-list/discount-list.component.html
  7. 27
      src/app/pages/marketing/discount-list/discount-list.component.ts
  8. 2
      src/app/pages/settlement/detail/detail.component.html
  9. 9
      src/app/pages/system/cms/cms.component.html
  10. 3
      src/app/pages/system/cms/cms.component.ts
  11. 2
      src/app/pages/trade/comp-order/comp-order.component.ts
  12. 15
      src/app/pages/trade/goods-logistics-list/goods-logistics-list.component.html
  13. 26
      src/app/pages/trade/goods-logistics-list/goods-logistics-list.component.ts
  14. 11
      src/app/pages/trade/order-after-sales/order-after-sales.component.ts
  15. 2
      src/app/pipes/goods/order-child-status.pipe.ts
  16. 43
      src/app/services/goods/goods.service.ts
  17. 6
      src/app/services/marketing/discount.service.ts
  18. 2
      src/app/services/trade/order-after-sales.service.ts
  19. 4
      src/environments/environment.ts

@ -83,7 +83,7 @@ export class SysRoleComponent {
// 菜单树
menuTree: NzTreeNodeOptions[] = [];
// 菜单已勾选数据
menuTreeCheckedKeys = [];
menuTreeCheckedKeys: any = [];
@ViewChild('nzTreeComponent', { static: false }) nzTreeComponent!: NzTreeComponent;
@ -105,7 +105,8 @@ export class SysRoleComponent {
});
this.menuService.queryMenuTree((data: any) => {
this.menuTree = data['return_data'];
console.log("树数据" , data['return_data']);
this.menuTree = data['return_data'];
});
this.queryData();
@ -228,7 +229,9 @@ export class SysRoleComponent {
showAssignRoleMenu(roleId: number) {
this.currentAssignRoleId = roleId;
this.menuService.queryRoleMenuArray(roleId, (data: any) => {
this.menuTreeCheckedKeys = data['return_data'];
console.log("角色权限菜单" , data['return_data']);
console.log("树" , this.menuTree);
this.menuTreeCheckedKeys = data['return_data'];
});
this.assignRoleMenuVisible = true;
}

@ -102,7 +102,8 @@
<td *ngIf="objectType != 2">{{data.merName}}</td>
<td>{{data.title}}</td>
<td>
<img nz-image width="60px" height="60px" nzSrc="{{imageUrl + data.listImg }}" [nzFallback]="fallbackImg" alt="" />
<img *ngIf="data.thirdId == null" nz-image width="60px" height="60px" nzSrc="{{imageUrl + data.listImg }}" [nzFallback]="fallbackImg" alt="" />
<img *ngIf="data.thirdId != null" nz-image width="60px" height="60px" nzSrc="{{data.listImg }}" [nzFallback]="fallbackImg" alt="" />
</td>
<td>{{data.type == 1 ? '实物商品' : '虚拟商品'}}</td>
<td>{{data.goodsTypeName}}</td>
@ -144,7 +145,12 @@
<input nzSize="large" nz-input formControlName="title" placeholder="请输入" />
</nz-form-control>
</nz-form-item>
<nz-form-item >
<nz-form-label [nzSm]="6" [nzXs]="24" >排序</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="请输入排序!">
<nz-input-number style="width: 100%" formControlName="sort" [nzSize]="'large'" [nzMin]="1" [nzMax]="99999" [nzStep]="1" ></nz-input-number>
</nz-form-control>
</nz-form-item>
<nz-form-item >
<nz-form-label [nzSm]="6" [nzXs]="24" >商品分类</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24">
@ -165,6 +171,15 @@
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item >
<nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>展示类型</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24">
<nz-select nzSize="large" nzShowSearch nzAllowClear nzPlaceHolder="请选择" formControlName="showType">
<nz-option nzLabel="正常展示" nzValue="1"></nz-option>
<nz-option nzLabel="不展示在用户端" nzValue="2"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item >
<nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>商品品牌</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24">
@ -295,7 +310,7 @@
<th colspan="2">时间</th>
<th colspan="4" *ngIf="goodsMsg?.type == 2">虚拟产品</th>
<th colspan="3" >跳转信息</th>
<th *ngIf="goodsMsg?.status == 2" rowspan="2" nzRight>操作</th>
<th rowspan="2" nzRight>操作</th>
</tr>
<tr>
<th rowspan="1">售价</th>
@ -336,10 +351,42 @@
<td>{{data.jumpUrl}}</td>
<td>{{data.appid}}</td>
<td *ngIf="goodsMsg?.status == 2" nzRight>
<a (click)="showEditSpecs(data)">修改</a>
<nz-divider nzType="vertical"></nz-divider>
<a nz-popconfirm nzPopconfirmTitle="是否确认删除?" (nzOnConfirm)="deleteGoodsSpecs(data.specsId)">删除</a>
<td nzRight>
<a (click)="showEditSpecs(data)" *ngIf="goodsMsg?.status == 2">修改</a>
<nz-divider nzType="vertical" *ngIf="goodsMsg?.status == 2"></nz-divider>
<a *ngIf="goodsMsg?.status == 2" nz-popconfirm nzPopconfirmTitle="是否确认删除?" (nzOnConfirm)="deleteGoodsSpecs(data.specsId)">删除</a>
<nz-divider nzType="vertical" *ngIf="goodsMsg?.status == 2"></nz-divider>
<a *ngIf="objectType == 1" (click)="showPresent(data.id , data.name)">赠送列表</a>
</td>
</tr>
</tbody>
</nz-table>
</ng-container>
</nz-modal>
<nz-modal [nzWidth]="1400" [(nzVisible)]="isVisiblePresent" nzTitle="{{specsName}}-赠送列表" [nzFooter]="null" (nzOnCancel)="isVisiblePresent= false">
<!--列表-->
<ng-container *nzModalContent>
<button nz-button (click)="showEditPresent()" nzType="primary">创建</button>
<button nz-button [nzType]="'default'" (click)="getPresentList()">查询</button>
<br />
<br />
<nz-table #basicTable [nzData]="dataSet">
<thead>
<tr>
<th>名称</th>
<th>KEY</th>
<th>类型</th>
<th>操作</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data">
<td>{{data.name}}</td>
<td>{{data.key}}</td>
<td>{{data.type == 1 ? '内部优惠券包' : '嗨加油优惠券包'}}</td>
<td>
<a nz-popconfirm nzPopconfirmTitle="是否确认删除?" (nzOnConfirm)="deletePresent(data.id)">删除</a>
</td>
</tr>
</tbody>
@ -347,6 +394,31 @@
</ng-container>
</nz-modal>
<!--添加弹出框-->
<nz-modal [(nzVisible)]="editPresent" [nzMaskClosable] = false nzTitle="编辑规格" (nzOnCancel)="editPresent = false" (nzOnOk)="handleEditPresent()">
<ng-container *nzModalContent>
<form nz-form [formGroup]="editPresentForm">
<nz-form-item >
<nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>类型</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="请选择!">
<nz-select nzSize="large" nzShowSearch nzAllowClear nzPlaceHolder="请选择" formControlName="type" (ngModelChange)="discountPackageList($event)">
<nz-option nzValue="1" nzLabel="普惠GO"></nz-option>
<nz-option nzValue="2" nzLabel="嗨加油"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item>
<nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>优惠券包</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="请选择券包!">
<nz-select nzSize="large" nzShowSearch nzAllowClear formControlName="key" nzPlaceHolder="请选择">
<nz-option *ngFor="let item of nodesPresent" nzValue="{{item.key}}" nzLabel="{{item.title}}"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
</form>
</ng-container>
</nz-modal>
<!--添加弹出框-->
<nz-modal [(nzVisible)]="editSpecs" [nzMaskClosable] = false nzTitle="编辑规格" (nzOnCancel)="editSpecs = false" (nzOnOk)="handleEditSpecs()">
<ng-container *nzModalContent>
@ -411,17 +483,8 @@
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item *ngIf="goodsMsg?.type == 2">
<nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>类型</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="请选择类型!">
<nz-select nzSize="large" nzShowSearch nzAllowClear nzPlaceHolder="请选择" formControlName="type" >
<nz-option nzLabel="内部虚拟商品" nzValue="1"></nz-option>
<nz-option nzLabel="外部虚拟产品" nzValue="2"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item *ngIf="editSpecsForm.value.type == 2">
<nz-form-item>
<nz-form-label [nzSm]="6" [nzXs]="24">卡密</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24">
<input nzSize="large" nz-input formControlName="key" placeholder="请输入" />

@ -36,6 +36,7 @@ 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";
import {DiscountService} from "../../../services/marketing/discount.service";
const getBase64 = (file: File): Promise<string | ArrayBuffer | null> =>
new Promise((resolve, reject) => {
@ -121,20 +122,27 @@ export class GoodsListComponent {
// 编辑产品类型表单
editForm: FormGroup;
editSpecsForm: FormGroup;
editPresentForm: FormGroup;
// 编辑弹出框
isVisibleEdit = false;
// 编辑商品规格弹出框
isVisibleSpecs = false;
isVisiblePresent = false;
editSpecs = false;
editPresent = false;
loadingSpecs = false;
// 商品类型数据
dataSet: any = [];
nodes = [];
nodesBrand = [];
nodesPresent: any = [];
nodesSpecs: SpecsData[] = [];
nodesVpdSource;
merData: any;
objectType: number;
goodsMsg?: GoodsMsgData;
specsName: string | undefined;
specsId: number | undefined;
protected readonly fallbackImg = fallbackImg;
@ -142,11 +150,13 @@ export class GoodsListComponent {
private msg: NzMessageService,
private merService: MerService,
private storage: BrowserStorageService,
private discount: DiscountService,
private commonService: CommonService,
private goodsService: GoodsService) {
this.nodesVpdSource = new DictionaryPipe().getDictionaryList('GOODS_VPD_SOURCE');
this.objectType = this.storage.get(DATA)['account']['objectType'];
console.log("objectType", this.objectType);
this.merList();
// 初始化搜索框
@ -158,7 +168,11 @@ export class GoodsListComponent {
type: [''],
status: [''],
});
// 初始化
this.editPresentForm = this.fb.group({
type: ['', [Validators.required]],
key: ['', [Validators.required]],
});
// 初始化
this.editForm = this.fb.group({
title: ['', [Validators.required]],
@ -167,6 +181,8 @@ export class GoodsListComponent {
goodsBrand: ['', [Validators.required]],
id: [null],
goodsLabel: [''],
sort: [''],
showType: [''],
goodsExplain: [''],
});
// 初始化
@ -178,7 +194,6 @@ export class GoodsListComponent {
stock: ['', [Validators.required]],
validDay: ['', [Validators.required]],
salesEndTime: [new Date(new Date().getFullYear(), new Date().getMonth(), new Date().getDay(), 23, 59, 59), [Validators.required]],
type: [''],
source: [''],
btnName: [''],
id: [null],
@ -308,6 +323,17 @@ export class GoodsListComponent {
});
}
deletePresent(id: number): void {
this.goodsService.deletePresent(id, (data: any) => {
if (data['return_code'] === '000000') {
this.msg.success("成功!");
this.getPresentList();
} else {
this.msg.error(data['return_msg']);
}
});
}
// 获取商品分类
getGoodsTypeNode() {
this.goodsService.getList({time: new Date().getTime()}, (data: any) => {
@ -346,17 +372,13 @@ export class GoodsListComponent {
this.isVisibleSpecs = true;
if (data.type == "1") {
this.editSpecsForm.controls['type'].clearValidators();
this.editSpecsForm.controls['type'].markAsPristine();
this.editSpecsForm.controls['source'].clearValidators();
this.editSpecsForm.controls['source'].markAsPristine();
this.editSpecsForm.controls['validDay'].clearValidators();
this.editSpecsForm.controls['validDay'].markAsPristine();
} else {
this.editSpecsForm.controls['type'].setValidators(Validators.required);
this.editSpecsForm.controls['type'].markAsDirty();
this.editSpecsForm.controls['source'].setValidators(Validators.required);
this.editSpecsForm.controls['source'].markAsDirty();
@ -364,7 +386,6 @@ export class GoodsListComponent {
this.editSpecsForm.controls['validDay'].setValidators(Validators.required);
this.editSpecsForm.controls['validDay'].markAsDirty();
}
this.editSpecsForm.controls['type'].updateValueAndValidity();
this.editSpecsForm.controls['validDay'].updateValueAndValidity();
this.editSpecsForm.controls['source'].updateValueAndValidity();
@ -386,6 +407,26 @@ export class GoodsListComponent {
});
}
getPresentList(): void {
let params = {
specsId: this.specsId,
time: new Date().getTime()
}
this.goodsService.getLisPresent(params, (data: any) => {
if (data['return_code'] == '000000') {
this.dataSet = data['return_data'];
}
});
}
showPresent(id: number , name: string): void {
this.specsName = name;
this.specsId = id;
this.isVisiblePresent = true;
this.getPresentList();
}
// 添加规格
showEditSpecs(item?: any): void {
@ -404,6 +445,24 @@ export class GoodsListComponent {
this.editSpecs = true;
}
showEditPresent(): void {
this.editPresent = true;
}
handleEditPresent(): void {
this.editPresentForm.value.specsId = this.specsId;
this.goodsService.createGoodPresent(this.editPresentForm.value, (data: any) => {
if (data['return_code'] === '000000') {
this.msg.success("成功!");
this.editPresent = false;
this.getPresentList();
} else {
this.msg.error(data['return_msg']);
}
});
}
handleEditSpecs(): void {
if (this.editSpecsForm.valid) {
if (this.showImg.length !== 0) {
@ -444,6 +503,24 @@ export class GoodsListComponent {
this.editSpecsForm.controls['appid'].updateValueAndValidity();
}
discountPackageList(type: string): void {
console.log("type" , type);
let params = {
type: type,
time: new Date().getTime()
}
this.discount.discountPackageList(params , (data: any) => {
if (data['return_code'] === '000000') {
this.nodesPresent = data['return_data'];
} else {
this.msg.error(data['return_msg']);
}
});
}
// 上下线
goodsAudit(id: number): void {
let params = {

@ -44,11 +44,20 @@
</nz-form-control>
</nz-form-item>
</div>
<div nz-col [nzSpan]="8">
<nz-form-item>
<nz-form-label>京东余额:</nz-form-label>
<nz-form-control>
<h1>{{balance}}</h1>
</nz-form-control>
</nz-form-item>
</div>
<div nz-col [nzSpan]="6" class="search-area">
<button nz-button [nzType]="'primary'" (click)="getRequest(true)">查询</button>
<button nz-button (click)="searchForm.reset()">重置</button>
<button nz-button [nzType]="'primary'" (click)="getExport()">导出</button>
</div>
</div>
</form>
@ -57,6 +66,7 @@
[nzBordered]="true"
[nzFrontPagination]="false"
[nzShowQuickJumper]="true"
[nzLoading]="tableData.loading"
[nzShowTotal]="totalTemplate"
[(nzPageIndex)]="tablePageNum"
(nzPageIndexChange)="getRequest(false)"

@ -5,14 +5,12 @@ import {NzColDirective, NzRowDirective} from "ng-zorro-antd/grid";
import {NzFormControlComponent, NzFormDirective, NzFormItemComponent, NzFormLabelComponent} from "ng-zorro-antd/form";
import {NzInputDirective} from "ng-zorro-antd/input";
import {NzOptionComponent, NzSelectComponent} from "ng-zorro-antd/select";
import {FormGroup, FormsModule, NonNullableFormBuilder, ReactiveFormsModule, Validators} from "@angular/forms";
import {NzUploadComponent, NzUploadFile} from "ng-zorro-antd/upload";
import {environment} from "../../../../environments/environment";
import {FormGroup, FormsModule, NonNullableFormBuilder, ReactiveFormsModule} from "@angular/forms";
import {NzUploadComponent} from "ng-zorro-antd/upload";
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, SpecsData} from "../../../model/goods.interface";
import {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";
@ -27,15 +25,12 @@ import {NzMenuDirective, NzMenuItemComponent} from "ng-zorro-antd/menu";
import {
NzInputNumberComponent,
NzInputNumberGroupComponent,
NzInputNumberGroupWhitSuffixOrPrefixDirective, NzInputNumberModule
NzInputNumberGroupWhitSuffixOrPrefixDirective,
NzInputNumberModule
} from "ng-zorro-antd/input-number";
import {NzSpaceComponent, 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";
import {CommunicationService} from "../../../services/common/communication.service";
const getBase64 = (file: File): Promise<string | ArrayBuffer | null> =>
@ -113,7 +108,7 @@ export class JdGoodsListComponent {
previewImage: string | undefined = '';
// 上传是否展示
previewVisible = false;
balance:any;
loadingSpecs = false;
// 商品类型数据
nodes = [];
@ -137,6 +132,7 @@ export class JdGoodsListComponent {
});
this.getRequest();
this.checkAccountBalance();
this.getGoodsTypeNode();
this.getGoodsBrandNode();
@ -144,6 +140,7 @@ export class JdGoodsListComponent {
// 查询列表
public getRequest(reset: boolean = false) {
this.checkAccountBalance();
this.tableData.loading = true;
if (reset) {
this.tablePageNum = 1;
@ -163,11 +160,22 @@ export class JdGoodsListComponent {
}
checkAccountBalance(): void {
this.goodsService.checkAccountBalance((data: any) => {
if (data['return_code'] == '000000') {
this.balance = data['return_data'];
} else {
this.msg.error(data['return_msg']);
}
});
}
// 获取商品分类
getGoodsTypeNode() {
this.goodsService.getList({time: new Date().getTime()}, (data: any) => {
if (data['return_code'] === '000000') {
this.getNode(data['return_data']);
let tree = data['return_data'].filter((d: { opId: null; }) => d.opId == null);
this.getNode(tree);
}
});
}
@ -190,7 +198,7 @@ export class JdGoodsListComponent {
getGoodsBrandNode() {
this.goodsService.getListBrandAll((data: any) => {
if (data['return_code'] == '000000') {
this.nodesBrand = data['return_data'];
this.nodesBrand = data['return_data'].filter((d: { opId: null; }) => d.opId == null);
}
});
}

@ -248,12 +248,26 @@
<nz-modal [(nzVisible)]="isVisibleBind" nzTitle="绑定商品" (nzOnCancel)="isVisibleBind= false" (nzOnOk)="handleOk()">
<!--列表-->
<ng-container *nzModalContent>
<!-- <nz-select-->
<!-- nzMode="multiple"-->
<!-- nzPlaceHolder="请选择绑定商品规格"-->
<!-- [(ngModel)]="listOfSelectBind"-->
<!-- >-->
<!-- <nz-option *ngFor="let item of goodsSpecs" [nzLabel]="'【' + item.name + '】-【¥'+item.salePrice + '】'" [nzValue]="item.id"></nz-option>-->
<!-- </nz-select>-->
<nz-select
nzShowSearch
nzMode="multiple"
nzPlaceHolder="请选择绑定商品规格"
nzServerSearch
nzPlaceHolder="请输入需要绑定商品规格"
[(ngModel)]="listOfSelectBind"
[nzShowArrow]="false"
[nzFilterOption]="nzFilterOption"
(nzOnSearch)="search($event)"
>
<nz-option *ngFor="let item of goodsSpecs" [nzLabel]="item.goodsName + '-' + item.name + '-'+item.salePrice + ''" [nzValue]="item.id"></nz-option>
@for (item of goodsSpecs; track item) {
<nz-option [nzLabel]="'' + item.name + '-'+item.salePrice + ''" [nzValue]="item.id"></nz-option>
}
</nz-select>
</ng-container>
</nz-modal>

@ -134,7 +134,7 @@ export class DiscountListComponent {
goodsSpecs:any = [];
protected readonly fallbackImg = fallbackImg;
protected readonly platformCode = platformCode;
readonly nzFilterOption = (): boolean => true;
constructor(private fb: NonNullableFormBuilder,
private msg: NzMessageService,
@ -143,6 +143,7 @@ export class DiscountListComponent {
private discountService: DiscountService) {
this.discountType = new DictionaryPipe().getDictionaryList('DISCOUNT_TYPE');
console.log(this.discountType);
// 初始化搜索框
this.searchForm = this.fb.group({
@ -167,10 +168,23 @@ export class DiscountListComponent {
id: [null],
});
this.getRequest();
this.getGoodsSpecsListAll();
}
search(value: string): void {
let params = {
time: new Date().getTime() ,
name: value
}
this.goodsService.getGoodsSpecsListAll( params ,(data: any) => {
console.log("data" , data);
if (data['return_code'] == '000000') {
this.goodsSpecs = data['return_data'];
}
});
}
// 查询列表
public getRequest(reset: boolean = false) {
this.tableData.loading = true;
@ -312,15 +326,6 @@ export class DiscountListComponent {
});
}
// 查询所有商品规格
getGoodsSpecsListAll(): void {
this.goodsService.getGoodsSpecsListAll( (data: any) => {
if (data['return_code'] == '000000') {
this.goodsSpecs = data['return_data'];
}
});
}
handleOk(): void {
let params = {

@ -59,6 +59,7 @@
<th>子订单号</th>
<th>业务信息</th>
<th>支付金额</th>
<th>结算金额</th>
<th>支付方式</th>
<th>收货时间</th>
</tr>
@ -72,6 +73,7 @@
<td>{{data.orderNo}}</td>
<td>{{data.childOrderNo}}</td>
<td>{{data.business}}</td>
<td>¥{{data.payPrice}}</td>
<td>¥{{data.payRealPrice}}</td>
<td>{{data.payType}}</td>
<td>{{data.finishTime}}</td>

@ -115,6 +115,15 @@
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item>
<nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>展示数据类型</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24" >
<nz-select nzSize="large" nzShowSearch nzAllowClear nzPlaceHolder="请选择" formControlName="automatic">
<nz-option nzLabel="手动选择" nzValue="1"></nz-option>
<nz-option nzLabel="系统选择" nzValue="2"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item>
<nz-form-label [nzSm]="6" [nzXs]="24" >展示类型</nz-form-label>
<nz-form-control [nzSm]="14" [nzXs]="24" >

@ -140,6 +140,7 @@ export class CmsComponent {
id: [null],
img: [''],
jumpType: [null],
automatic: ['' , [Validators.required]],
showType: [null],
showDataId: [null],
jumpUrl: [null],
@ -174,6 +175,8 @@ export class CmsComponent {
showEdit(item?: any) {
if (item != null) {
item.jumpType = String(item.jumpType);
item.automatic = String(item.automatic);
item.showType = String(item.showType);
this.editForm.patchValue(item);
if (!this.commonService.whetherStringIsNull(item.img)) {
this.img = this.commonService.stitchImg(item.img);

@ -21,8 +21,6 @@ import {NzInputDirective} from "ng-zorro-antd/input";
import {NzMenuDirective, NzMenuItemComponent} from "ng-zorro-antd/menu";
import {NzModalComponent, NzModalModule, NzModalService} from "ng-zorro-antd/modal";
import {NzOptionComponent, NzSelectComponent} from "ng-zorro-antd/select";
import {SysAccountService} from "../../../services/account/sys-account.service";
import {RoleService} from "../../../services/role/role.service";
import {NzMessageService} from "ng-zorro-antd/message";
import {OrderCouponService} from "../../../services/trade/order-coupon.service";
import {NzDatePickerComponent, NzDatePickerModule, NzRangePickerComponent} from "ng-zorro-antd/date-picker";

@ -152,7 +152,8 @@
<td>{{data.goodsName}} - {{data.goodsSpecsName}}</td>
<td>{{data.merName}}</td>
<td>
<img nz-image width="60px" height="60px" nzSrc="{{imageUrl + data.img }}" [nzFallback]="fallbackImg" alt="" />
<img *ngIf="data.thirdOrderNo == null" nz-image width="60px" height="60px" nzSrc="{{imageUrl + data.img }}" [nzFallback]="fallbackImg" alt="" />
<img *ngIf="data.thirdOrderNo != null" nz-image width="60px" height="60px" nzSrc="{{data.img }}" [nzFallback]="fallbackImg" alt="" />
</td>
<td>{{data.goodsTypeName}}</td>
<td>{{data.goodsBrandName}}</td>
@ -203,14 +204,15 @@
<nz-tab nzTitle="订单信息">
<nz-descriptions nzTitle="订单信息" nzBordered>
<nz-descriptions-item nzTitle="商品名称">{{orderGoodsData?.goodsName}} - {{orderGoodsData?.goodsSpecsName}}</nz-descriptions-item>
<nz-descriptions-item nzTitle="用户手机号">{{ orderGoodsData?.userPhone }}</nz-descriptions-item>//.
0 <nz-descriptions-item nzTitle="商品分类">{{ orderGoodsData?.goodsTypeName }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="用户手机号">{{ orderGoodsData?.userPhone }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="商品分类">{{ orderGoodsData?.goodsTypeName }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="商品品牌">{{ orderGoodsData?.goodsBrandName }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="商品价格">{{ orderGoodsData?.goodsSpecsOriginalPrice }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="商品数量">{{ orderGoodsData?.goodsCount }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="图片" [nzSpan]="3">
<nz-image-group>
<img nz-image width="80px" [nzFallback]="fallbackImg" nzSrc="{{imageUrl + orderGoodsData.img }}" alt="" />
<img *ngIf="orderGoodsData.thirdOrderNo == null" nz-image width="80px" [nzFallback]="fallbackImg" nzSrc="{{imageUrl + orderGoodsData.img }}" alt="" />
<img *ngIf="orderGoodsData.thirdOrderNo != null" nz-image width="80px" [nzFallback]="fallbackImg" nzSrc="{{orderGoodsData.img }}" alt="" />
</nz-image-group>
</nz-descriptions-item>
<nz-descriptions-item nzTitle="物流状态" [nzSpan]="3">
@ -249,10 +251,7 @@
</nz-tab>
<nz-tab nzTitle="发货信息">
<nz-descriptions nzTitle="发货信息" nzBordered>
<nz-descriptions-item nzTitle="收货人">{{deliveryAddress?.consignee}}</nz-descriptions-item>
<nz-descriptions-item nzTitle="收货电话">{{ deliveryAddress?.phone }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="发货信息" [nzSpan]="3">{{ deliveryAddress?.regionName }} -{{deliveryAddress?.consignee}} -{{ deliveryAddress?.phone }} -{{ deliveryAddress?.address }}</nz-descriptions-item>
<nz-descriptions-item nzTitle="发货信息" [nzSpan]="3">{{ orderGoodsData?.deliveryAddress }}</nz-descriptions-item>
</nz-descriptions>
</nz-tab>
</nz-tabset>

@ -135,8 +135,6 @@ export class GoodsLogisticsListComponent {
private msg: NzMessageService,
private storage: BrowserStorageService,
private merService: MerService,
private iconService: IconService,
private route: ActivatedRoute,
private orderGoodsService: OrderGoodsService,
private goodsService: GoodsService) {
@ -256,12 +254,28 @@ export class GoodsLogisticsListComponent {
this.isVisible = true;
}
showDetail(data: OrderGoodsData): void {
this.orderGoodsData = data;
this.findDeliveryAddressById(data.deliveryAddressId);
this.orderDetailModal = true;
showDetail(object: OrderGoodsData): void {
this.orderGoodsService.getOrderGoods(object.childOrderNo, (data: any) => {
if (data['return_code'] == '000000') {
if (data['return_data']['status'] == 6) {
this.msg.create('error', '该订单申请售后中!');
return;
} else {
this.orderGoodsData = object;
this.findDeliveryAddressById(object.deliveryAddressId);
this.orderDetailModal = true;
}
} else {
this.msg.create('error', data['return_msg']);
return;
}
});
}
handleOk(): void {
let params = {
id: this.goodsOrderId,

@ -132,13 +132,14 @@ export class OrderAfterSalesComponent {
applyAuditVisible = false;
// 更多查询条件
isCollapse = false;
goodsOrderData: any;
goodsOrderData: any ={};
constructor(private fb: NonNullableFormBuilder,
private orderAfterSalesService : OrderAfterSalesService,
private communicationService: CommunicationService,
private goodsOrderService: OrderGoodsService,
private message: NzMessageService,
private modal: NzModalService) {
console.log("申请类型" ,this.applyTypeArray )
// 初始化搜索框
this.searchForm = this.fb.group({
type: [''],
@ -244,7 +245,12 @@ export class OrderAfterSalesComponent {
* @param data
*/
showAudit(data: any) {
this.getOrderGoods(data.childOrderNo);
console.log("data", data);
console.log(typeof data.productType);
console.log(1);
if (data.productType == 1) {
this.getOrderGoods(data.childOrderNo);
}
data.type = String(data.type);
data.remarks = '';
this.applyAuditForm.patchValue(data);
@ -323,6 +329,7 @@ export class OrderAfterSalesComponent {
// 查询实物订单
getOrderGoods(childOrderNo: string) {
this.goodsOrderService.getOrderGoods(childOrderNo, (data: any) => {
console.log("goodsOrderData", data);
if (data['return_code'] == '000000') {
this.goodsOrderData = data['return_data'];
} else {

@ -19,7 +19,7 @@ export class OrderChildStatusPipe implements PipeTransform {
case 5:
return '已取消';
case 6:
return '退款中';
return '售后中';
default:
return '未知状态'
}

@ -100,6 +100,12 @@ export class GoodsService {
});
}
public checkAccountBalance(callBack:any) {
this.http.get(environment.baseUrl + 'goods/checkAccountBalance?time=' + new Date().getTime()).subscribe(data => {
callBack(data);
});
}
/**
*
* @param param
@ -170,8 +176,8 @@ export class GoodsService {
* 线
* @param callBack
*/
public getGoodsSpecsListAll(callBack:any) {
this.http.get(environment.baseUrl + 'goods/getGoodsSpecsListAll?time=' + new Date().getTime()).subscribe(data => {
public getGoodsSpecsListAll(params: object, callBack:any) {
this.http.get(environment.baseUrl + 'goods/getGoodsSpecsListAll?' + ObjectData.objectByString(params)).subscribe(data => {
callBack(data);
});
}
@ -231,4 +237,37 @@ export class GoodsService {
});
}
/**
*
* @param specsId
* @param callBack
*/
public getLisPresent(params: object, callBack:any) {
this.http.get(environment.baseUrl + 'goodPresent/getLisPresent?' + ObjectData.objectByString(params)).subscribe(data => {
callBack(data);
});
}
/**
*
* @param params
* @param callBack
*/
public createGoodPresent(params: object, callBack:any) {
this.http.post(environment.baseUrl + 'goodPresent/createGoodPresent', params).subscribe(data => {
callBack(data);
});
}
/**
*
* @param id
* @param callBack
*/
public deletePresent(id: number, callBack:any) {
this.http.get(environment.baseUrl + 'goodPresent/delete?id=' + id ).subscribe(data => {
callBack(data);
});
}
}

@ -138,4 +138,10 @@ export class DiscountService {
});
}
public discountPackageList(params: object, callBack:any) {
this.http.get(environment.baseUrl + 'discountPackage/discountPackageList?' + ObjectData.objectByString(params)).subscribe(data => {
callBack(data);
});
}
}

@ -17,7 +17,7 @@ export class OrderAfterSalesService {
*/
public queryApplyList(param: any, callBack:any) {
param.time = new Date().getTime();
this.http.get(environment.orderUrl + 'afterSales/queryApplyList?'+ObjectData.objectByString(param)).subscribe(data => {
this.http.get(environment.orderUrl + 'afterSales/queryApplyList?'+ObjectData.objectByString(param)).subscribe(data => {
callBack(data);
});
}

@ -12,8 +12,9 @@ export const environment = {
baseUrl: 'http://localhost:9702/brest/', // 测试环境服务器地址(请求数据地址)
orderUrl: 'http://localhost:9703/order/', // 测试环境服务器地址(请求数据地址)
userUrl: 'http://localhost:9704/user/', // 测试环境服务器地址(请求数据地址)
imageUrl: 'https://phg-test.obs.cn-southwest-2.myhuaweicloud.com/',
// userUrl: 'https://phgcs.dctpay.com/user/', // 测试环境服务器地址(请求数据地址)
imageUrl: 'https://phg-test.obs.cn-southwest-2.myhuaweicloud.com/',
};
/*
@ -24,3 +25,4 @@ export const environment = {
* on performance if an error is thrown.
*/
// import 'zone.js/dist/zone-error'; // Included with Angular CLI.

Loading…
Cancel
Save