You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
953 B
38 lines
953 B
3 years ago
|
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";
|
||
|
|
||
|
@Injectable({
|
||
|
providedIn: 'root'
|
||
|
})
|
||
|
export class TyAgentPriceService {
|
||
|
|
||
|
constructor(
|
||
|
private http: HttpClient,
|
||
|
private common: CommonsService
|
||
|
) { }
|
||
|
|
||
|
/**
|
||
|
* 编辑价格
|
||
|
* @param paramObject 参数
|
||
|
* @param callBack
|
||
|
*/
|
||
|
editPrice(paramObject: object, callBack) {
|
||
|
this.http.post(environment.baseUrl + 'tyAgentPrice/editPrice', paramObject).subscribe(data => {
|
||
|
callBack(data);
|
||
|
});
|
||
|
}
|
||
|
|
||
|
/**
|
||
|
* 油站价格
|
||
|
* @param paramObject 参数
|
||
|
* @param callBack
|
||
|
*/
|
||
|
getOilStationPrice(oilStationId: number, callBack) {
|
||
|
this.http.get(environment.baseUrl + 'tyAgentPrice/getOilStationPrice?oilStationId=' + oilStationId).subscribe(data => {
|
||
|
callBack(data);
|
||
|
});
|
||
|
}
|
||
|
}
|