提交代码

pull/1/head
胡锐 3 years ago
parent 8088d941f2
commit f351509a0b
  1. 1
      src/app/admin/tuanyou-agent/order/ty-order-list/ty-order-list.component.html
  2. 19
      src/app/admin/tuanyou-agent/order/ty-order-list/ty-order-list.component.ts
  3. 12
      src/app/services/ty-agent-oil-station.service.ts
  4. 2
      src/environments/environment.ts

@ -60,6 +60,7 @@
<div class="inner-content"> <div class="inner-content">
<span>共计 {{dataObject.total?dataObject.total:0}} 条数据</span> <span>共计 {{dataObject.total?dataObject.total:0}} 条数据</span>
<div class="operating-button"> <div class="operating-button">
<button nz-button nzType="primary" class="right-btn" (click)="excelOrder()"><i nz-icon nzType="plus" nzTheme="outline"></i>导出订单</button>
</div> </div>
<!--数组表格 --> <!--数组表格 -->

@ -4,6 +4,7 @@ import {NzMessageService, NzModalService} from '_ng-zorro-antd@9.3.0@ng-zorro-an
import {TyAgentOilStationService} from '../../../../services/ty-agent-oil-station.service'; import {TyAgentOilStationService} from '../../../../services/ty-agent-oil-station.service';
import {ADMIN_INFO_OBJECT} from "../../../../services/local-storage.namespace"; import {ADMIN_INFO_OBJECT} from "../../../../services/local-storage.namespace";
import {LocalStorageService} from "../../../../services/local-storage.service"; import {LocalStorageService} from "../../../../services/local-storage.service";
import {environment} from "../../../../../environments/environment";
@Component({ @Component({
selector: 'app-ty-order-list', selector: 'app-ty-order-list',
@ -11,6 +12,7 @@ import {LocalStorageService} from "../../../../services/local-storage.service";
styleUrls: ['./ty-order-list.component.scss'] styleUrls: ['./ty-order-list.component.scss']
}) })
export class TyOrderListComponent implements OnInit { export class TyOrderListComponent implements OnInit {
FILE_URL = environment.imageUrl;
roleType; roleType;
adminFlag; adminFlag;
@ -72,4 +74,21 @@ export class TyOrderListComponent implements OnInit {
resetForm(): void { resetForm(): void {
this.searchForm.reset(); this.searchForm.reset();
} }
/**
*
*/
excelOrder() {
this.tyAgentOilStationService.excelOrder(this.whereObject, data => {
if (data['return_code'] === '000000') {
window.location.href = this.FILE_URL + 'temporary/' + data['return_data'];
} else {
this.modal.error({
nzTitle: '提示',
nzContent: data['return_msg']
});
}
});
}
} }

@ -100,4 +100,16 @@ export class TyAgentOilStationService {
}); });
} }
/**
*
* @param paramObject
* @param callBack
*/
excelOrder(paramObject: object, callBack) {
this.http.get(environment.baseUrl + 'tyAgentOilStation/excelOrder?' + this.common.getWhereCondition(paramObject)).subscribe(data => {
callBack(data);
});
}
} }

@ -6,7 +6,7 @@ export const environment = {
production: false, production: false,
// baseUrl: 'http://localhost:9302/brest/', // 测试环境服务器地址(请求数据地址) // baseUrl: 'http://localhost:9302/brest/', // 测试环境服务器地址(请求数据地址)
// imageUrl: 'http://localhost:9302/filesystem/', // imageUrl: 'http://localhost:9302/filesystem/',
baseUrl: 'http://localhost:9302/brest/', // 测试环境服务器地址(请求数据地址) baseUrl: 'https://hsgcs.dctpay.com/brest/', // 测试环境服务器地址(请求数据地址)
imageUrl: 'https://hsgcs.dctpay.com/filesystem/', imageUrl: 'https://hsgcs.dctpay.com/filesystem/',
key: 'https://hsgcs.dctpay.com/phone-recharge-H5/index.html?codeValue=', key: 'https://hsgcs.dctpay.com/phone-recharge-H5/index.html?codeValue=',
inviteUrl: 'https://hsgcs.dctpay.com/wx/?action=ic&id=', inviteUrl: 'https://hsgcs.dctpay.com/wx/?action=ic&id=',

Loading…
Cancel
Save