diff --git a/src/app/admin/agent/agent-list/agent-list.component.ts b/src/app/admin/agent/agent-list/agent-list.component.ts index 027d5fb..e6fa6d0 100644 --- a/src/app/admin/agent/agent-list/agent-list.component.ts +++ b/src/app/admin/agent/agent-list/agent-list.component.ts @@ -251,8 +251,9 @@ export class AgentListComponent implements OnInit { } this.isOkLoading = true; - this.validateFormDistribute.value['agentName'] = this.requestData.find(data => data.id = this.agentId).agentName; - this.validateFormDistribute.value['couponName'] = this.couponList.find(data => data.id = this.validateFormDistribute.value['couponId']).couponName; + + this.validateFormDistribute.value['agentName'] = this.requestData.find(data => data.id == this.agentId).agentName; + this.validateFormDistribute.value['couponName'] = this.couponList.find(data => data.id == this.validateFormDistribute.value['couponId']).couponName; this.validateFormDistribute.value['agentId'] = this.agentId; const whereObject = { diff --git a/src/app/admin/discount-package/discount-package-edit/discount-package-edit.component.ts b/src/app/admin/discount-package/discount-package-edit/discount-package-edit.component.ts index 9118007..ba6734b 100644 --- a/src/app/admin/discount-package/discount-package-edit/discount-package-edit.component.ts +++ b/src/app/admin/discount-package/discount-package-edit/discount-package-edit.component.ts @@ -131,8 +131,7 @@ export class DiscountPackageEditComponent implements OnInit { } // 图片判断 - // this.imgIsPost(); - + this.imgIsPost(); if (this.editFlag) { this.validateForm.value.id = this.id; diff --git a/src/app/admin/merchant-store/store-list/store-list.component.html b/src/app/admin/merchant-store/store-list/store-list.component.html index da6e1e2..5dca78b 100644 --- a/src/app/admin/merchant-store/store-list/store-list.component.html +++ b/src/app/admin/merchant-store/store-list/store-list.component.html @@ -75,7 +75,7 @@ 门店名称 门店电话 创建时间 - 操作 + 操作 @@ -87,15 +87,18 @@ {{data.telephone}} {{data.createTime | date: 'yyyy-MM-dd HH:mm'}} - 编辑 - - 详情 - - 增加余额 - - 删除 - - 设备管理 + 更多操作 + + + + diff --git a/src/app/admin/merchant-store/store-list/store-list.component.ts b/src/app/admin/merchant-store/store-list/store-list.component.ts index 6adb50d..54be2b8 100644 --- a/src/app/admin/merchant-store/store-list/store-list.component.ts +++ b/src/app/admin/merchant-store/store-list/store-list.component.ts @@ -137,6 +137,17 @@ export class StoreListComponent implements OnInit { }).then(r => console.log(r)); } + // 下载二维码 + public getQrCode(storeKey: string): void { + this.merchantStore.getQrCode(storeKey, data => { + if (data['return_code'] === '000000') { + window.location.href = data['return_data']; + } else { + this.message.warning(data['return_msg']); + } + }); + } + handleCancelError(): void { this.errorStudentVisible = false; } diff --git a/src/app/services/merchant-store.service.ts b/src/app/services/merchant-store.service.ts index 5854d19..4f93a65 100644 --- a/src/app/services/merchant-store.service.ts +++ b/src/app/services/merchant-store.service.ts @@ -100,6 +100,18 @@ export class MerchantStoreService { }); } + /** + * 下载二维码 + * + * @param storeKey 用户id + * @param callBack 返回参数 + */ + public getQrCode(storeKey: string, callBack) { + this.http.get(environment.baseUrl + 'highMerchantStore/getQrCode?storeKey=' + storeKey).subscribe(data => { + callBack(data); + }); + } + /** * 查询油站油品详情 * diff --git a/src/environments/environment.ts b/src/environments/environment.ts index a2d6d6f..cc5edd5 100644 --- a/src/environments/environment.ts +++ b/src/environments/environment.ts @@ -6,8 +6,8 @@ export const environment = { production: false, baseUrl: 'http://localhost:9302/brest/', // 测试环境服务器地址(请求数据地址) imageUrl: 'http://localhost:9302/filesystem/', - // baseUrl: 'https://hsgcs.dctpay.com/brest/', // 测试环境服务器地址(请求数据地址) - // imageUrl: 'https://hsgcs.dctpay.com/filesystem/', + // baseUrl: 'https://hsg.dctpay.com/brest/', // 测试环境服务器地址(请求数据地址) + // imageUrl: 'https://hsg.dctpay.com/filesystem/', key: 'https://hsgcs.dctpay.com/phone-recharge-H5/index.html?codeValue=', inviteUrl: 'https://hsgcs.dctpay.com/wx/?action=ic&id=', };