mirror of
https://gitlab.com/mbugroup/lti-web-client.git
synced 2026-05-21 22:05:45 +00:00
Merge branch 'feat/FE/US-352/daily-kandang-hpp-report' into 'development'
[FEAT/FE][US#352] HPP Harian Per Kandang Report See merge request mbugroup/lti-web-client!114
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
import { BaseApiService } from '@/services/api/base';
|
||||
import { BaseApiResponse } from '@/types/api/api-general';
|
||||
import { HppPerKandangReport } from '@/types/api/report/hpp-per-kandang';
|
||||
|
||||
export class MarketingSaleReportService extends BaseApiService<
|
||||
HppPerKandangReport,
|
||||
unknown,
|
||||
unknown
|
||||
> {
|
||||
constructor(basePath: string) {
|
||||
super(basePath);
|
||||
}
|
||||
|
||||
async getHppPerKandangReport(
|
||||
area_id?: string,
|
||||
location_id?: string,
|
||||
kandang_id?: string,
|
||||
weight_min?: string,
|
||||
weight_max?: string,
|
||||
period?: string,
|
||||
sort_by?: string,
|
||||
show_unrecorded?: boolean,
|
||||
page?: number,
|
||||
limit?: number
|
||||
): Promise<BaseApiResponse<HppPerKandangReport> | undefined> {
|
||||
return await this.customRequest<BaseApiResponse<HppPerKandangReport>>(
|
||||
`hpp-per-kandang`,
|
||||
{
|
||||
method: 'GET',
|
||||
params: {
|
||||
area_id: area_id,
|
||||
location_id: location_id,
|
||||
kandang_id: kandang_id,
|
||||
weight_min: weight_min,
|
||||
weight_max: weight_max,
|
||||
period: period,
|
||||
sort_by: sort_by,
|
||||
show_unrecorded: show_unrecorded,
|
||||
page: page,
|
||||
limit: limit,
|
||||
},
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export const SaleReportApi = new MarketingSaleReportService(
|
||||
'reports/marketings'
|
||||
);
|
||||
|
||||
// export const SaleReportApi = new MarketingSaleReportService(
|
||||
// 'http://localhost:4010/api/reports/marketings'
|
||||
// );
|
||||
Reference in New Issue
Block a user