* 'dev' of http://139.159.177.244:3000/yuanye/high-web:
  提交代码
  提交代码
pull/1/head
袁野 2 years ago
commit 8ce9fd755c
  1. 10
      src/app/admin/coupon/coupon-edit/coupon-edit.component.html
  2. 182
      src/app/admin/order/order-coupon-list/order-coupon-list.component.html
  3. 0
      src/app/admin/order/order-coupon-list/order-coupon-list.component.scss
  4. 134
      src/app/admin/order/order-coupon-list/order-coupon-list.component.ts
  5. 2
      src/app/admin/order/order-list/order-list.component.ts
  6. 2
      src/app/admin/order/order-routing.module.ts
  7. 3
      src/app/admin/order/order.module.ts
  8. 5
      src/app/admin/promotion/distribution-integral-list/distribution-integral-list.component.ts
  9. 4
      src/app/admin/promotion/promotion-order-list/promotion-order-list.component.ts
  10. 4
      src/app/admin/promotion/promotion.module.ts
  11. 8
      src/app/pipes/paytype.pipe.ts
  12. 2
      src/app/services/distribution.service.ts
  13. 26
      src/app/services/order.service.ts

@ -12,6 +12,14 @@
<nz-content class="inner-content">
<form nz-form [formGroup]="validateForm" class="ant-advanced-search-form">
<div nz-row [nzGutter]="24">
<div nz-col [nzSpan]="8">
<nz-form-item>
<nz-form-label [nzFor]="'couponKey'">卡券key</nz-form-label>
<nz-form-control nzErrorTip="请输入卡券名称!">
<input nz-input placeholder="请输入卡券key..." [formControlName]="'couponKey'" id="'couponKey'" />
</nz-form-control>
</nz-form-item>
</div>
<div nz-col [nzSpan]="8">
<nz-form-item>
<nz-form-label [nzFor]="'couponName'" nzRequired>卡券名称</nz-form-label>
@ -40,11 +48,11 @@
<nz-option nzValue="2" nzLabel="消费券"></nz-option>
<nz-option nzValue="4" nzLabel="贵州中石化"></nz-option>
<nz-option nzValue="3" nzLabel="其他卡券"></nz-option>
<nz-option nzValue="5" nzLabel="重庆中石油"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
</div>
<div nz-col [nzSpan]="8" *ngIf="validateForm.value.couponSource !== '2'">
<nz-form-item>
<nz-form-label [nzFor]="'displayArea'" nzRequired>展示区域</nz-form-label>

@ -0,0 +1,182 @@
<!-- start 面包屑 -->
<app-breadcrumb></app-breadcrumb>
<!-- end 面包屑 -->
<!--条件搜索-->
<nz-spin [nzSpinning]="loadingObject.spinning" nzTip="{{loadingObject.msg}}">
<div class="inner-content">
<form nz-form [formGroup]="searchForm" (ngSubmit)="search(searchForm.value)">
<div nz-row>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">订单号</nz-form-label>
<nz-form-control [nzSpan]="14">
<input nz-input formControlName="orderNo" />
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">客户电话</nz-form-label>
<nz-form-control [nzSpan]="14">
<input nz-input formControlName="memPhone" />
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">卡券名称</nz-form-label>
<nz-form-control [nzSpan]="14">
<input nz-input formControlName="couponName" />
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">支付卡号</nz-form-label>
<nz-form-control [nzSpan]="14">
<input nz-input formControlName="couponName" />
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">支付方式</nz-form-label>
<nz-form-control [nzSpan]="14">
<nz-select nzAllowClear formControlName="payType">
<nz-option nzValue="1" nzLabel="支付宝"></nz-option>
<nz-option nzValue="2" nzLabel="微信"></nz-option>
<nz-option nzValue="3" nzLabel="积分抵扣"></nz-option>
<nz-option nzValue="4" nzLabel="汇联通工会卡"></nz-option>
<nz-option nzValue="5" nzLabel="银联"></nz-option>
<nz-option nzValue="6" nzLabel="银联分期"></nz-option>
<nz-option nzValue="7" nzLabel="嗨森逛油卡"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">订单状态</nz-form-label>
<nz-form-control [nzSpan]="14">
<nz-select nzAllowClear formControlName="orderStatus">
<nz-option nzValue="1" nzLabel="待支付"></nz-option>
<nz-option nzValue="2" nzLabel="已支付"></nz-option>
<nz-option nzValue="3" nzLabel="已完成"></nz-option>
<nz-option nzValue="4" nzLabel="已退款"></nz-option>
<nz-option nzValue="5" nzLabel="已取消"></nz-option>
</nz-select>
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">创建时间</nz-form-label>
<nz-form-control [nzSpan]="14">
<nz-range-picker [nzShowTime]="{ nzFormat: 'yyyy-MM-dd HH:mm:ss' }" formControlName="createTime"></nz-range-picker>
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">支付时间</nz-form-label>
<nz-form-control [nzSpan]="14">
<nz-range-picker [nzShowTime]="{ nzFormat: 'yyyy-MM-dd HH:mm:ss' }" formControlName="payTime"></nz-range-picker>
</nz-form-control>
</nz-form-item>
</div>
<div nz-col nzSpan="8">
<nz-form-item>
<nz-form-label [nzSpan]="8">完成时间</nz-form-label>
<nz-form-control [nzSpan]="14">
<nz-range-picker [nzShowTime]="{ nzFormat: 'yyyy-MM-dd HH:mm:ss' }" formControlName="finishTime"></nz-range-picker>
</nz-form-control>
</nz-form-item>
</div>
</div>
<div nz-row>
<div nz-col nzSpan="24" class="search-button">
<button nz-button nzType="primary"><i nz-icon nzType="search" nzTheme="outline"></i>搜索</button>
<button nz-button nzType="default" (click)="resetForm()"><i nz-icon nzType="reload" nzTheme="outline"></i>重置</button>
</div>
</div>
</form>
</div>
<div class="inner-content">
<span>共计 {{dataObject.total?dataObject.total:0}} 条数据</span>
<div class="operating-button">
<button nz-button nzType="primary" class="right-btn" (click)="exportExcel()" ><i nz-icon nzType="export" nzTheme="outline"></i>导出Excel</button>
</div>
<!--数组表格 -->
<nz-table #basicTable
[nzData]="dataObject.list"
[nzTotal]="dataObject.total"
[nzFrontPagination]="false"
[nzLoading]="tableLoading"
[nzPageIndex]="whereObject.pageNum"
(nzPageIndexChange)="requestData($event)"
[nzScroll]="{ x: '1100px'}">
<thead>
<tr>
<th nzWidth="60px">序号</th>
<th nzWidth="200px">订单号</th>
<th nzWidth="120px">客户电话</th>
<th nzWidth="200px">卡券名称</th>
<th nzWidth="100px">订单总额</th>
<th nzWidth="100px">优惠金额</th>
<th nzWidth="100px">应付金额</th>
<th nzWidth="100px">积分抵扣</th>
<th nzWidth="100px">实付金额</th>
<th nzWidth="100px">支付方式</th>
<th nzWidth="140px">支付卡号</th>
<th nzWidth="100px">订单状态</th>
<th nzWidth="180px">创建时间</th>
<th nzWidth="180px">支付时间</th>
<th nzWidth="180px">完成时间</th>
<!-- <th nzWidth="110px" nzRight="0px">操作</th>-->
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data;let i = index">
<td>{{i+1}}</td>
<td>{{data.orderNo}}</td>
<td>{{data.memPhone}}</td>
<td>{{data.couponName}}</td>
<td>{{data.totalPrice}}</td>
<td>{{data.deductionPrice}}</td>
<td>{{data.payablePrice}}</td>
<td>{{data.payGold / 100}}</td>
<td>{{data.payPrice}}</td>
<td>{{data.payType}}</td>
<td>{{data.memCardNo}}</td>
<td>{{data.orderStatus}}</td>
<td>{{data.createTime | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
<td>{{data.payTime | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
<td>{{data.finishTime | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
<!-- <td nzRight="0px" class="table-td-operation">
<a nz-dropdown [nzDropdownMenu]="menu"> 操作列表 <i nz-icon nzType="down"></i> </a>
<nz-dropdown-menu #menu="nzDropdownMenu">
<ul nz-menu nzSelectable>
<li nz-menu-item ><a>二维码</a></li>
</ul>
</nz-dropdown-menu>
</td>-->
</tr>
</tbody>
</nz-table>
</div>
</nz-spin>

@ -0,0 +1,134 @@
import { Component, OnInit } from '@angular/core';
import {environment} from '../../../../environments/environment';
import {FormBuilder, FormGroup} from '@angular/forms';
import {NzMessageService, NzModalService} from 'ng-zorro-antd';
import {LocalStorageService} from '../../../services/local-storage.service';
import {GasStaffService} from '../../../services/gas-staff.service';
import {CommonsService} from '../../../services/commons.service';
import {Router} from '@angular/router';
import {ADMIN_INFO_OBJECT} from '../../../services/local-storage.namespace';
import {OrderService} from '../../../services/order.service';
@Component({
selector: 'app-order-coupon-list',
templateUrl: './order-coupon-list.component.html',
styleUrls: ['./order-coupon-list.component.scss']
})
export class OrderCouponListComponent implements OnInit {
FILE_URL = environment.imageUrl;
roleType;
adminFlag;
loadingObject = {
spinning: false,
msg: '加载中'
};
dataObject: any = {};
tableLoading = true;
searchForm: FormGroup;
pageNum: number;
whereObject: any = {};
positionTypeArray = [];
gasStaffQrCodeImgUrl: string;
gasStaffQrCodeModal = false;
constructor(private modal: NzModalService,
private message: NzMessageService,
private store: LocalStorageService,
private orderService: OrderService,
private commonsService: CommonsService,
private router: Router,
private form: FormBuilder) {
this.roleType = Number(this.store.get(ADMIN_INFO_OBJECT)['secRole'].roleType);
this.adminFlag = Number(this.store.get(ADMIN_INFO_OBJECT)['secUser'].adminFlag);
}
ngOnInit(): void {
this.searchForm = this.form.group({
orderNo: [null],
memPhone: [null],
couponName: [null],
payType: [null],
orderStatus: [null],
createTime: [null],
payTime: [null],
finishTime: [null],
});
this.requestData(1);
}
/**
*
*/
requestData(pageNum) {
this.tableLoading = true;
this.whereObject['pageNum'] = pageNum;
this.whereObject['pageSize'] = 10;
this.orderService.getOrderCouponList(this.whereObject, data => {
if (data['return_code'] === '000000') {
this.dataObject = data['return_data'];
} else {
this.modal.error(data['return_msg']);
}
this.tableLoading = false;
});
}
/**
*
* @param whereObject
*/
search(whereObject: object) {
if (whereObject['createTime'] != null) {
whereObject['createTimeS'] = whereObject['createTime'][0].getTime();
whereObject['createTimeE'] = whereObject['createTime'][1].getTime();
} else {
whereObject['createTimeS'] = null;
whereObject['createTimeE'] = null;
}
if (whereObject['payTime'] != null) {
whereObject['payTimeS'] = whereObject['payTime'][0].getTime();
whereObject['payTimeE'] = whereObject['payTime'][1].getTime();
} else {
whereObject['payTimeS'] = null;
whereObject['payTimeE'] = null;
}
if (whereObject['finishTime'] != null) {
whereObject['finishTimeS'] = whereObject['finishTime'][0].getTime();
whereObject['finishTimeE'] = whereObject['finishTime'][1].getTime();
} else {
whereObject['finishTimeS'] = null;
whereObject['finishTimeE'] = null;
}
this.whereObject = whereObject;
this.requestData(1);
}
/**
*
*/
resetForm(): void {
this.searchForm.reset();
}
/**
* Excel
*/
exportExcel(): void {
this.loadingObject.spinning = true;
this.loadingObject.msg = '处理中...';
this.orderService.exportOrderCouponExcel(this.whereObject, data => {
this.loadingObject.spinning = false;
if (data['return_code'] === '000000') {
window.location.href = this.FILE_URL + data['return_data'];
}
});
}
}

@ -97,7 +97,7 @@ export class OrderListComponent implements OnInit {
}
whereObject['pageNum'] = this.pageNum;
whereObject['pageSize'] = this.pageSize;
this.order.getOrderCouponList(whereObject, data => {
this.order.getGoodsOrderList(whereObject, data => {
if (data['return_code'] === '000000') {
this.requestData = data['return_data'].list;
this.total = data['return_data'].total;

@ -14,6 +14,7 @@ import {PackageRecordListComponent} from './package-record-list/package-record-l
import {DiscountUseConditionListComponent} from './discount-use-condition-list/discount-use-condition-list.component';
import {DicountPackageOrderListComponent} from './dicount-package-order-list/dicount-package-order-list.component';
import {OilStationOrderComponent} from './oil-station-order/oil-station-order.component';
import {OrderCouponListComponent} from './order-coupon-list/order-coupon-list.component';
const routes: Routes = [
@ -22,6 +23,7 @@ const routes: Routes = [
{ path: 'order-detail', component: OrderDetailComponent },
{ path: 'order-coupons', component: OrderCouponsComponent },
{ path: 'order-coupon', component: OrderCouponComponent },
{ path: 'order-coupon-list', component: OrderCouponListComponent },
{ path: 'order-c-list', component: OrderCListComponent },
{ path: 'order-k-list', component: OrderKListComponent },
{ path: 'order-h-list', component: OrderHListComponent },

@ -23,9 +23,10 @@ import { DiscountUseConditionListComponent } from './discount-use-condition-list
import {DicountPackageOrderListComponent} from "./dicount-package-order-list/dicount-package-order-list.component";
import {NzSpaceModule} from "ng-zorro-antd/space";
import { OilStationOrderComponent } from './oil-station-order/oil-station-order.component';
import { OrderCouponListComponent } from './order-coupon-list/order-coupon-list.component';
@NgModule({
declarations: [OrderListComponent, OrderDetailComponent, OrderCouponsComponent, OrderCouponComponent , OrderTListComponent, OrderKListComponent , OrderCListComponent, OrderHListComponent, OrderAgentComponent, PreOrderComponent, PackageRecordListComponent, DiscountUseConditionListComponent, DicountPackageOrderListComponent, OilStationOrderComponent],
declarations: [OrderListComponent, OrderDetailComponent, OrderCouponsComponent, OrderCouponComponent , OrderTListComponent, OrderKListComponent , OrderCListComponent, OrderHListComponent, OrderAgentComponent, PreOrderComponent, PackageRecordListComponent, DiscountUseConditionListComponent, DicountPackageOrderListComponent, OilStationOrderComponent, OrderCouponListComponent],
imports: [
CommonModule,
OrderRoutingModule,

@ -1,11 +1,10 @@
import { Component, OnInit } from '@angular/core';
import {environment} from '../../../../environments/environment';
import {FormBuilder, FormGroup} from '_@angular_forms@9.0.7@@angular/forms';
import {IconService} from '../../../services/icon.service';
import {NzMessageService} from '_ng-zorro-antd@9.3.0@ng-zorro-antd';
import {Router} from '_@angular_router@9.0.7@@angular/router';
import {CommonsService} from '../../../services/commons.service';
import {DistributionService} from '../../../services/distribution.service';
import {FormBuilder, FormGroup} from '@angular/forms';
import {NzMessageService} from 'ng-zorro-antd';
@Component({
selector: 'app-distribution-integral-list',

@ -1,9 +1,9 @@
import { Component, OnInit } from '@angular/core';
import {environment} from '../../../../environments/environment';
import {FormBuilder, FormGroup} from '_@angular_forms@9.0.7@@angular/forms';
import {DistributionService} from '../../../services/distribution.service';
import {IconService} from '../../../services/icon.service';
import {NzMessageService} from '_ng-zorro-antd@9.3.0@ng-zorro-antd';
import {FormBuilder, FormGroup} from '@angular/forms';
import {NzMessageService} from 'ng-zorro-antd';
@Component({
selector: 'app-promotion-order-list',

@ -4,10 +4,10 @@ import { CommonModule } from '@angular/common';
import { PromotionRoutingModule } from './promotion-routing.module';
import { DistributionIntegralListComponent } from './distribution-integral-list/distribution-integral-list.component';
import { PromotionOrderListComponent } from './promotion-order-list/promotion-order-list.component';
import {NgZorroAntdModule} from '_ng-zorro-antd@9.3.0@ng-zorro-antd';
import {SeparateModule} from '../../common/separate/separate.module';
import {FormsModule, ReactiveFormsModule} from '_@angular_forms@9.0.7@@angular/forms';
import {BreadcrumbModule} from '../../common/breadcrumb/breadcrumb.module';
import {NgZorroAntdModule} from 'ng-zorro-antd';
import {FormsModule, ReactiveFormsModule} from '@angular/forms';
@NgModule({

@ -12,11 +12,15 @@ export class PaytypePipe implements PipeTransform {
case 2:
return '微信';
case 3:
return '金币';
return '积分抵扣';
case 4:
return '汇联通工会卡';
return '贵州汇联通工会卡';
case 5:
return '银联';
case 6:
return '银联分期';
case 7:
return '嗨森逛油卡';
}
}
}

@ -1,7 +1,7 @@
import { Injectable } from '@angular/core';
import {HttpClient} from '_@angular_common@9.0.7@@angular/common/http';
import {CommonsService} from './commons.service';
import {environment} from '../../environments/environment';
import {HttpClient} from '@angular/common/http';
@Injectable({
providedIn: 'root'

@ -34,12 +34,36 @@ export class OrderService {
* @param paramsObject
* @param callBack
*/
public getOrderCouponList(paramsObject: object, callBack) {
public getGoodsOrderList(paramsObject: object, callBack) {
this.http.get(environment.baseUrl + 'highOrder/getGoodsOrderList?' + this.common.getWhereCondition(paramsObject)).subscribe(data => {
callBack(data);
});
}
/**
*
*
* @param paramsObject
* @param callBack
*/
public getOrderCouponList(paramsObject: object, callBack) {
this.http.get(environment.baseUrl + 'highOrder/getOrderCouponList?' + this.common.getWhereCondition(paramsObject)).subscribe(data => {
callBack(data);
});
}
/**
*
*
* @param paramsObject
* @param callBack
*/
public exportOrderCouponExcel(paramsObject: object, callBack) {
this.http.get(environment.baseUrl + 'highOrder/exportOrderCouponExcel?' + this.common.getWhereCondition(paramsObject)).subscribe(data => {
callBack(data);
});
}
/**
*
*

Loading…
Cancel
Save