mirror of
https://gitlab.com/mbugroup/lti-web-client.git
synced 2026-05-25 15:55:48 +00:00
Merge branch 'fix/daily-marketing-report' into 'development'
[FIX/FE] Daily Marketing Report See merge request mbugroup/lti-web-client!220
This commit is contained in:
@@ -104,6 +104,10 @@ const ClosingsTable = () => {
|
|||||||
header: '#',
|
header: '#',
|
||||||
cell: (props) => props.row.index + 1,
|
cell: (props) => props.row.index + 1,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
accessorKey: 'project_name',
|
||||||
|
header: 'Flock',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
accessorKey: 'location_name',
|
accessorKey: 'location_name',
|
||||||
header: 'Lokasi',
|
header: 'Lokasi',
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ const DailyMarketingsTable = ({
|
|||||||
cell: (props) => formatNumber(props.row.original.average_weight_kg),
|
cell: (props) => formatNumber(props.row.original.average_weight_kg),
|
||||||
footer: () => {
|
footer: () => {
|
||||||
const totalAverageWeightKg = isResponseSuccess(dailyMarketings)
|
const totalAverageWeightKg = isResponseSuccess(dailyMarketings)
|
||||||
? dailyMarketings?.total?.total_average_weight
|
? dailyMarketings?.total?.average_weight_kg
|
||||||
: 0;
|
: 0;
|
||||||
|
|
||||||
return totalAverageWeightKg ? formatNumber(totalAverageWeightKg) : '-';
|
return totalAverageWeightKg ? formatNumber(totalAverageWeightKg) : '-';
|
||||||
@@ -149,7 +149,7 @@ const DailyMarketingsTable = ({
|
|||||||
cell: (props) => formatCurrency(props.row.original.sales_price_per_kg),
|
cell: (props) => formatCurrency(props.row.original.sales_price_per_kg),
|
||||||
footer: () => {
|
footer: () => {
|
||||||
const totalSalesPrice = isResponseSuccess(dailyMarketings)
|
const totalSalesPrice = isResponseSuccess(dailyMarketings)
|
||||||
? dailyMarketings?.total?.total_sales_price
|
? dailyMarketings?.total?.average_sales_price
|
||||||
: 0;
|
: 0;
|
||||||
|
|
||||||
return totalSalesPrice ? formatNumber(totalSalesPrice) : '-';
|
return totalSalesPrice ? formatNumber(totalSalesPrice) : '-';
|
||||||
|
|||||||
Vendored
+2
-2
@@ -41,9 +41,9 @@ export type DailyMarketingRow = BaseMetadata & BaseDailyMarketingRow;
|
|||||||
|
|
||||||
export interface SalesSummary {
|
export interface SalesSummary {
|
||||||
total_qty: number;
|
total_qty: number;
|
||||||
total_average_weight: number;
|
average_weight_kg: number;
|
||||||
total_weight_kg: number;
|
total_weight_kg: number;
|
||||||
total_sales_price: number;
|
average_sales_price: number;
|
||||||
total_sales_amount: number;
|
total_sales_amount: number;
|
||||||
total_hpp_amount: number;
|
total_hpp_amount: number;
|
||||||
total_hpp_price_per_kg: number;
|
total_hpp_price_per_kg: number;
|
||||||
|
|||||||
Reference in New Issue
Block a user