@feedmepos/mf-report 5.27.38 → 5.27.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. package/README.md +18 -3
  2. package/dist/{App-D0egtvQ-.js → App-S90BTDsA.js} +4 -4
  3. package/dist/{DateRangeSelect-CqMwZ27u.js → DateRangeSelect-D8yWjVRH.js} +1 -1
  4. package/dist/{Default.vue_vue_type_script_setup_true_lang-D39cFe6x.js → Default.vue_vue_type_script_setup_true_lang-CPKHc9Ij.js} +1 -1
  5. package/dist/{DynamicWidget.vue_vue_type_script_setup_true_lang-625jnYWz.js → DynamicWidget.vue_vue_type_script_setup_true_lang-aP-DhJoD.js} +360 -365
  6. package/dist/{GlobalFilterSelect.vue_vue_type_script_setup_true_lang-CWYMdEeD.js → GlobalFilterSelect.vue_vue_type_script_setup_true_lang-HWUtlVoJ.js} +4 -4
  7. package/dist/{InsightView-94nHX-WA.js → InsightView-9dc7VxLd.js} +4 -4
  8. package/dist/{Integration-CtKBgWah.js → Integration-DgT3WP7T.js} +3 -3
  9. package/dist/{Integrations-CgdpQtx8.js → Integrations-DTjuN8ir.js} +2 -2
  10. package/dist/{Layout-XtPVe59c.js → Layout-BhTbEl_I.js} +1 -1
  11. package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-D7MNgCvE.js → MenuTab.vue_vue_type_script_setup_true_lang-B3NaH_DG.js} +4 -4
  12. package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-D3zMj_qy.js → NavigationTab.vue_vue_type_script_setup_true_lang-Cg-74bAB.js} +3 -3
  13. package/dist/{OverviewView-e_yLkpE7.js → OverviewView-CLUe1Opn.js} +4 -4
  14. package/dist/{Report-BJRREsz2.js → Report-BtKLh93q.js} +3 -3
  15. package/dist/{ReportEditor-DuNJhfDd.js → ReportEditor-BSoWyCZA.js} +6 -6
  16. package/dist/{ReportView-6vGSlxht.js → ReportView-DMah7z_A.js} +6 -6
  17. package/dist/{Setting-9lMuIq7F.js → Setting-DbZY2zk5.js} +3 -3
  18. package/dist/Template-CoM9-uOV.js +521 -0
  19. package/dist/{TileEditor-D4xAquwa.js → TileEditor-DDtA5B1e.js} +5 -5
  20. package/dist/{TileGrid.vue_vue_type_script_setup_true_lang-DoSQ6pxv.js → TileGrid.vue_vue_type_script_setup_true_lang-DdwPdPJ2.js} +2 -2
  21. package/dist/{TransitionFade-DokaTWBh.js → TransitionFade-cviixQkL.js} +4 -4
  22. package/dist/{app-CqDIZ6G6.js → app-CuP9NY1I.js} +1138 -1121
  23. package/dist/app.js +1 -1
  24. package/dist/assets/{formatChartData.worker-4gz12Ml-.js → formatChartData.worker-C3TaOBES.js} +1 -1
  25. package/dist/assets/{processTableData.worker-KnOy0AZ-.js → processTableData.worker-boBcpckx.js} +1 -1
  26. package/dist/{useRestaurantPermission-D26lLMqS.js → useRestaurantPermission-i9i6cu96.js} +1 -1
  27. package/package.json +17 -5
  28. package/dist/Template-pAXd86VQ.js +0 -482
@@ -1,6 +1,6 @@
1
1
  import { ref as R0, computed as c1, watch as V1, defineComponent as Yt, mergeModels as ot, useModel as Lt, resolveComponent as o1, createElementBlock as h1, openBlock as r1, createVNode as U0, withCtx as d1, createElementVNode as j0, createCommentVNode as It, Fragment as _e, renderList as Ft, createBlock as v1, createTextVNode as it, withDirectives as $a, toDisplayString as S1, unref as E0, vShow as ya, renderSlot as Gr, normalizeStyle as ma, normalizeClass as Rr, withModifiers as gt } from "vue";
2
- import { c as Cr, f as Qr, _ as Vr, D as qa, h as ga } from "./DateRangeSelect-CqMwZ27u.js";
3
- import { w as ha, n as Sa, u as G0, F as Q0, r as e1, x as Ta, a as le, b as Ea, t as Ra, h as jr, d as B0, c as Be, m as Gt, g as Ca } from "./app-CqDIZ6G6.js";
2
+ import { c as Cr, f as Qr, _ as Vr, D as qa, h as ga } from "./DateRangeSelect-D8yWjVRH.js";
3
+ import { w as ha, n as Sa, u as G0, F as Q0, r as e1, x as Ta, a as le, b as Ea, t as Ra, h as jr, d as B0, c as Be, m as Gt, g as Ca } from "./app-CuP9NY1I.js";
4
4
  import { storeToRefs as C0, defineStore as Ne } from "pinia";
5
5
  import { useSnackbar as Kr } from "@feedmepos/ui-library";
6
6
  import { u as Zr } from "./_plugin-vue_export-helper-onplcgja.js";
@@ -9123,7 +9123,7 @@ Arguments: [` + M + "]";
9123
9123
  var e = null, n = "itemCreatedAt", a = "billCompletedAt", o = "perXUnit", s = "takeawayId", u = "takeawayName", p = "productId", M = "isRefund", _ = "servedAt", d = "isTakeaway", z = "quantity", f = "unitQuantity", y = "billAdjustmentTotal", q = "itemAdjustmentTotal", g = "grossTotal", E = "takeawayPrice", R = "nettTotal", I = "layerNettTotal", B = "layerBillAdjustmentTotal", w = "layerItemAdjustmentTotal", F = "layerGrossTotal", J = "layerTakeawayPrice", H = "layerTaxTotal", Y = "layerScTotal", j = "layerOtherChargeTotal", $0 = "customAttributes", M0 = "layerZeroParentId", t1 = "collectedAt", n1 = "subCategories", i1 = "billAdjustmentInclusiveTaxTotal", p1 = "itemAdjustmentInclusiveTaxTotal", Y0 = "layerBillAdjustmentInclusiveTaxTotal", s1 = "layerItemAdjustmentInclusiveTaxTotal", M1 = "billAdjustmentExclusiveTaxTotal", z1 = "itemAdjustmentExclusiveTaxTotal", A1 = "layerBillAdjustmentExclusiveTaxTotal", b1 = "layerItemAdjustmentExclusiveTaxTotal", g1 = "priceGroup", me = "originalPrice";
9124
9124
  return t._setArrayType([t.Field_Field$string(e, e, !1, !1, !1, "ID", "id", "_id", e, r), t.Field_Field$string(e, e, !0, !1, !1, e, "docId", "_docId", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Time", "createdAt", "_createdAt", e, r), t.Field_Field$timestamp(e, e, !0, !1, e, "publishedAt", "_publishedAt", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Item time", n, n, e, r), t.Field_Field$timestamp(e, e, !1, !1, "Bill close time", a, a, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Bill ID", "billId", "billId", e, r), t.Field_Field$string("Values: DRAFT, VOIDED, SENT. DRAFT and SENT both considered valid sales.", e, !1, !1, !1, "Status", "status", "status", e, r), t.Field_Field$string(e, e, !1, !1, !0, "Name", "name", "name", e, r), t.Field_Field$numeric(e, e, !1, !1, "Per unit", o, o, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Unit", "unit", "unit", e, r), t.Field_Field$string(e, `IF(@categoryName IS NULL OR @productId IS NULL OR REGEXP_CONTAINS(@productId, r'^\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+([+-][0-2]\\d:[0-5]\\d|Z)$'), 'Other', @categoryName)
9125
9125
  `, !1, !1, !0, "Category", "categoryName", "category", `CASE WHEN @category_name IS NULL OR @product_id IS NULL OR @product_id ~ '^\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+([+-][0-2]\\d:[0-5]\\d|Z)$' THEN 'Other' ELSE @category_name END
9126
- `, r), t.Field_Field$string(e, e, !1, !1, !1, "Takeaway ID", s, s, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Takeaway name", u, u, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Code", "code", "code", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Remark", "remark", "remark", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Product ID", p, p, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Variant ID", "variantId", "variant.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Variant", "variantName", "variant.name", e, r), t.Field_Field$bool(e, e, !1, !1, "Refund", M, M, e, r), t.Field_Field$string(e, e, !1, !1, !1, "User id", "createdById", "createdBy.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "User", "createdByName", "createdBy.name", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Sent time", "sentAt", "sentAt", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Served time", _, _, e, r), t.Field_Field$timestamp(e, e, !1, !1, "Printed time", "printedAt", "printBy.printAt", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Void time", "voidAt", "void.voidAt", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Void reason", "voidReason", "void.reason", e, r), t.Field_Field$string(e, e, !0, !1, !1, e, "voidedById", "void.by.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Void user", "voidedByName", "void.by.name", e, r), t.Field_Field$string(e, e, !0, !1, !1, e, "voidApprovedById", "void.approvedBy.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Void approver", "voidApprovedByName", "void.approvedBy.name", e, r), t.Field_Field$bool(e, e, !0, !1, "SST before discount", "sstBeforeDiscount", "sst.beforeDiscount", e, r), t.Field_Field$bool(e, e, !0, !1, "SC before discount", "serviceChargeBeforeDiscount", "sc.beforeDiscount", e, r), t.Field_Field$bool(e, e, !1, !1, "Takeaway", d, d, e, r), t.Field_Field$numeric(e, "@quantity*IF(@isRefund, -1, 1)", !1, !1, "Qty", z, z, C.x40quant, r), t.Field_Field$numeric(e, "@unitQuantity*IF(@isRefund, -1, 1)", !1, !1, "Unit qty", f, f, C.x40unit_, r), t.Field_Field$numeric(e, "@sstTotal*IF(@isRefund, -1, 1)", !1, !1, "SST", "sstTotal", "sst.total", C.x40sst_t, r), t.Field_Field$numeric(e, e, !0, !1, "SST %", "sstPercentage", "sst.percentage", e, r), t.Field_Field$numeric(e, e, !0, !1, "SC %", "serviceChargePercentage", "sc.percentage", e, r), t.Field_Field$numeric(e, "@serviceChargeTotal*IF(@isRefund, -1, 1)", !1, !1, "SC", "serviceChargeTotal", "sc.total", C.x40servi, r), t.Field_Field$numeric(e, "@otherChargeTotal*IF(@isRefund, -1, 1)", !1, !1, "Other charge", "otherChargeTotal", "otherCharge.total", C.x40other, r), t.Field_Field$numeric(e, C.x40billA, !1, !1, "Bill discount", y, y, C.x40bill_, r), t.Field_Field$numeric(e, C.x40itemA, !1, !1, "Item discount", q, q, C.x40item_, r), t.Field_Field$numeric(e, "@grossTotal*IF(@isRefund, -1, 1)", !1, !1, "Gross", g, g, C.x40gross, r), t.Field_Field$numeric(e, C.x28_grosT, !1, !1, "Gross w/ takeaway", "grossTotalWithoutTakeaway", e, C.x28_gros_, r), t.Field_Field$numeric(e, "@takeawayPrice*IF(@isRefund, -1, 1)", !1, !1, "Takeaway price", E, E, C.x40takea, r), t.Field_Field$numeric(e, "@nettTotal*IF(@isRefund, -1, 1)", !1, !1, "Nett", R, R, C.x40nett_, r), t.Field_Field$string(e, e, !1, !1, !1, "Parent ID", "parentId", "parent.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Parent name", "parentName", "parent.name", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Addon type", "addonType", "addon.type", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Addon ID", "addonId", "addon.selectionId", e, r), t.Field_Field$string(e, "SPLIT(@addonId, '/')[OFFSET(0)]", !1, !1, !1, "Group ID", "groupId", e, "SPLIT_PART(@addon_id, '/',1)", r), t.Field_Field$numeric("Item depth: 0 = main item. 1+ = addon/modifier level. -1 = bill level modifier, usually not consider item sales.", e, !1, !1, "Layer", "layer", "layer", e, r), t.Field_Field$numeric(e, "@addonPrice*IF(@isRefund, -1, 1)", !1, !1, "Addon price", "addonPrice", "addon.price", C.x40addon, r), t.Field_Field$numeric(e, C.IFNULLtax, !1, !1, "Tax", "taxTotal", "tax.total", C.COALEStax_, r), t.Field_Field$numeric(e, C.x28IFNULb, !1, !1, "Discount", "discountTotal", e, C.x28COALEb, r), t.Field_Field$numeric(e, C.x28IFNULgx2b, !1, !1, "Gross before charges", "grossBeforeCharges", e, C.x28COALEgx2b, r), t.Field_Field$string(e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING([IF(@code='', NULL, @code), @name], ' '))", !1, !1, !1, "Summary", "summary", e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN @code='' THEN NULL ELSE @code END, @name], ' '))", r), t.Field_Field$numeric(e, "@layerNettTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer nett", I, I, "@layer_nett_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerBillAdjustmentTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer bill discount", B, B, "@layer_bill_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerItemAdjustmentTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer item discount", w, w, "@layer_item_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerGrossTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer gross total", F, F, "@layer_gross_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerTakeawayPrice*IF(@isRefund, -1, 1)", !1, !1, "Layer takeaway price", J, J, "@layer_takeaway_price*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer tax total", H, H, "@layer_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerScTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer sc", Y, Y, "@layer_sc_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerOtherChargeTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer other charge", j, j, "@layer_other_charge_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "(IFNULL(@layerGrossTotal,0)+IFNULL(@layerBillAdjustmentTotal,0)+IFNULL(@layerItemAdjustmentTotal,0))*IF(@isRefund, -1, 1)", !1, !1, "Layer gross before charges", "layerGrossBeforeCharges", e, "(COALESCE(@layer_gross_total,0)+COALESCE(@layer_bill_adjustment_total,0)+COALESCE(@layer_item_adjustment_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$string(e, e, !1, !1, !1, "Custom attributes", $0, $0, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent ID", M0, M0, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Charge variant", "chargeVariant", e, "(select variant from charges where charges.parent_id=@layer_zero_parent_id and charges.restaurant_id=@restaurant_id and charges.bill_id=@bill_id and charges.code != 'SERVICE_CHARGE')", r), t.Field_Field$timestamp(e, e, !1, !1, "Collected time", t1, t1, e, r), t.Field_Field$numeric(e, e, !1, !1, "Costing", "costing", "costing", e, r), t.Field_Field$numeric(e, "ROUND(TIMESTAMP_DIFF(IFNULL(@servedAt, CURRENT_TIMESTAMP), @sentAt, SECOND),0)", !1, !1, "Preparation seconds", "preparationSeconds", e, "ROUND(EXTRACT(EPOCH FROM AGE(COALESCE(@served_at, CURRENT_TIMESTAMP),@sent_at)),0)", r), t.Field_Field$numeric("Computed: nett total minus costing", "((@nettTotal-coalesce(@costing, 0))*IF(@isRefund, -1, 1))", !1, !1, "Profit", "profit", e, "((@nett_total-coalesce(@costing, 0))*CASE WHEN @is_refund THEN -1 ELSE 1 END)", r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent name", "layerZeroParentName", e, "(select name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent code", "layerZeroParentCode", e, "(select code from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent category", "layerZeroParentCategory", e, "(select category_name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", r), t.Field_Field$string(e, e, !1, !1, !1, "Sub categories", n1, n1, e, r), t.Field_Field$numeric(e, "@billAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Bill discount inc tax", i1, i1, "@bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@itemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Item discount inc tax", p1, p1, "@item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerBillAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer bill discount inc tax", Y0, Y0, "@layer_bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerItemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer item discount inc tax", s1, s1, "@layer_item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@billAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Bill discount exc tax", M1, M1, "@bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@itemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Item discount exc tax", z1, z1, "@item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerBillAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer bill discount exc tax", A1, A1, "@layer_bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerItemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer item discount exc tax", b1, b1, "@layer_item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$string(e, "IF(@variantId IS NULL OR @variantId = '', @productId, CONCAT(@productId, '/', @variantId))", !0, !1, !1, "Menu item ID", "menuItemId", e, "CASE WHEN @variant_id IS NULL OR @variant_id = '' THEN @product_id ELSE @product_id || '/' || @variant_id END", r), t.Field_Field$string("Special-price tier when a member/promotion PRICE_CHANGE effect set the item price (e.g. vip). Null for normal sales.", e, !1, !1, !1, "Price group", g1, g1, e, r), t.Field_Field$numeric(e, e, !1, !1, "Original price", me, me, e, r), t.Field_Field$numeric(e, e, !1, !1, "Price", "price", "price", e, r)], O.JSArray_Field);
9126
+ `, r), t.Field_Field$string(e, e, !1, !1, !1, "Takeaway ID", s, s, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Takeaway name", u, u, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Code", "code", "code", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Remark", "remark", "remark", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Product ID", p, p, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Variant ID", "variantId", "variant.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Variant", "variantName", "variant.name", e, r), t.Field_Field$bool(e, e, !1, !1, "Refund", M, M, e, r), t.Field_Field$string(e, e, !1, !1, !1, "User id", "createdById", "createdBy.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "User", "createdByName", "createdBy.name", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Sent time", "sentAt", "sentAt", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Served time", _, _, e, r), t.Field_Field$timestamp(e, e, !1, !1, "Printed time", "printedAt", "printBy.printAt", e, r), t.Field_Field$timestamp(e, e, !1, !1, "Void time", "voidAt", "void.voidAt", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Void reason", "voidReason", "void.reason", e, r), t.Field_Field$string(e, e, !0, !1, !1, e, "voidedById", "void.by.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Void user", "voidedByName", "void.by.name", e, r), t.Field_Field$string(e, e, !0, !1, !1, e, "voidApprovedById", "void.approvedBy.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Void approver", "voidApprovedByName", "void.approvedBy.name", e, r), t.Field_Field$bool(e, e, !0, !1, "SST before discount", "sstBeforeDiscount", "sst.beforeDiscount", e, r), t.Field_Field$bool(e, e, !0, !1, "SC before discount", "serviceChargeBeforeDiscount", "sc.beforeDiscount", e, r), t.Field_Field$bool(e, e, !1, !1, "Takeaway", d, d, e, r), t.Field_Field$numeric(e, "@quantity*IF(@isRefund, -1, 1)", !1, !1, "Qty", z, z, C.x40quant, r), t.Field_Field$numeric(e, "@unitQuantity*IF(@isRefund, -1, 1)", !1, !1, "Unit qty", f, f, C.x40unit_, r), t.Field_Field$numeric(e, "@sstTotal*IF(@isRefund, -1, 1)", !1, !1, "SST", "sstTotal", "sst.total", C.x40sst_t, r), t.Field_Field$numeric(e, e, !0, !1, "SST %", "sstPercentage", "sst.percentage", e, r), t.Field_Field$numeric(e, e, !0, !1, "SC %", "serviceChargePercentage", "sc.percentage", e, r), t.Field_Field$numeric(e, "@serviceChargeTotal*IF(@isRefund, -1, 1)", !1, !1, "SC", "serviceChargeTotal", "sc.total", C.x40servi, r), t.Field_Field$numeric(e, "@otherChargeTotal*IF(@isRefund, -1, 1)", !1, !1, "Other charge", "otherChargeTotal", "otherCharge.total", C.x40other, r), t.Field_Field$numeric(e, C.x40billA, !1, !1, "Bill discount", y, y, C.x40bill_, r), t.Field_Field$numeric(e, C.x40itemA, !1, !1, "Item discount", q, q, C.x40item_, r), t.Field_Field$numeric(e, "@grossTotal*IF(@isRefund, -1, 1)", !1, !1, "Gross", g, g, C.x40gross, r), t.Field_Field$numeric(e, C.x28_grosT, !1, !1, "Gross w/ takeaway", "grossTotalWithoutTakeaway", e, C.x28_gros_, r), t.Field_Field$numeric(e, "@takeawayPrice*IF(@isRefund, -1, 1)", !1, !1, "Takeaway price", E, E, C.x40takea, r), t.Field_Field$numeric(e, "@nettTotal*IF(@isRefund, -1, 1)", !1, !1, "Nett", R, R, C.x40nett_, r), t.Field_Field$string(e, e, !1, !1, !1, "Parent ID", "parentId", "parent.id", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Parent name", "parentName", "parent.name", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Addon type", "addonType", "addon.type", e, r), t.Field_Field$string(e, e, !1, !1, !1, "Addon ID", "addonId", "addon.selectionId", e, r), t.Field_Field$string(e, "SPLIT(@addonId, '/')[OFFSET(0)]", !1, !1, !1, "Group ID", "groupId", e, "SPLIT_PART(@addon_id, '/',1)", r), t.Field_Field$numeric("Item depth: 0 = main item. 1+ = addon/modifier level. -1 = bill level modifier, usually not consider item sales.", e, !1, !1, "Layer", "layer", "layer", e, r), t.Field_Field$numeric(e, "@addonPrice*IF(@isRefund, -1, 1)", !1, !1, "Addon price", "addonPrice", "addon.price", C.x40addon, r), t.Field_Field$numeric(e, C.IFNULLtax, !1, !1, "Tax", "taxTotal", "tax.total", C.COALEStax_, r), t.Field_Field$numeric(e, C.x28IFNULb, !1, !1, "Discount", "discountTotal", e, C.x28COALEb, r), t.Field_Field$numeric(e, C.x28IFNULgx2b, !1, !1, "Gross before charges", "grossBeforeCharges", e, C.x28COALEgx2b, r), t.Field_Field$string(e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING([IF(@code='', NULL, @code), @name], ' '))", !1, !1, !1, "Summary", "summary", e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN @code='' THEN NULL ELSE @code END, @name], ' '))", r), t.Field_Field$numeric(e, "@layerNettTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer nett", I, I, "@layer_nett_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerBillAdjustmentTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer bill discount", B, B, "@layer_bill_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerItemAdjustmentTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer item discount", w, w, "@layer_item_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerGrossTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer gross total", F, F, "@layer_gross_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerTakeawayPrice*IF(@isRefund, -1, 1)", !1, !1, "Layer takeaway price", J, J, "@layer_takeaway_price*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer tax total", H, H, "@layer_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerScTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer sc", Y, Y, "@layer_sc_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerOtherChargeTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer other charge", j, j, "@layer_other_charge_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "(IFNULL(@layerGrossTotal,0)+IFNULL(@layerBillAdjustmentTotal,0)+IFNULL(@layerItemAdjustmentTotal,0))*IF(@isRefund, -1, 1)", !1, !1, "Layer gross before charges", "layerGrossBeforeCharges", e, "(COALESCE(@layer_gross_total,0)+COALESCE(@layer_bill_adjustment_total,0)+COALESCE(@layer_item_adjustment_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$string(e, e, !1, !1, !1, "Custom attributes", $0, $0, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent ID", M0, M0, e, r), t.Field_Field$string(e, e, !1, !1, !1, "Charge variant", "chargeVariant", e, "(select variant from charges where charges.parent_id=@layer_zero_parent_id and charges.restaurant_id=@restaurant_id and charges.bill_id=@bill_id and charges.code != 'SERVICE_CHARGE')", r), t.Field_Field$timestamp(e, e, !1, !1, "Collected time", t1, t1, e, r), t.Field_Field$numeric(e, e, !1, !1, "Costing", "costing", "costing", e, r), t.Field_Field$numeric(e, "ROUND(TIMESTAMP_DIFF(IFNULL(@servedAt, CURRENT_TIMESTAMP), @sentAt, SECOND),0)", !1, !1, "Preparation seconds", "preparationSeconds", e, "ROUND(EXTRACT(EPOCH FROM AGE(COALESCE(@served_at, CURRENT_TIMESTAMP),@sent_at)),0)", r), t.Field_Field$numeric("Computed: nett total minus costing", "((@nettTotal-coalesce(@costing, 0))*IF(@isRefund, -1, 1))", !1, !1, "Profit", "profit", e, "((@nett_total-coalesce(@costing, 0))*CASE WHEN @is_refund THEN -1 ELSE 1 END)", r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent name", "layerZeroParentName", e, "(select name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent code", "layerZeroParentCode", e, "(select code from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", r), t.Field_Field$string(e, e, !1, !1, !1, "Layer 0 parent category", "layerZeroParentCategory", e, "(select category_name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", r), t.Field_Field$string(e, e, !1, !1, !1, "Sub categories", n1, n1, e, r), t.Field_Field$numeric(e, "@billAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Bill discount inc tax", i1, i1, "@bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@itemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Item discount inc tax", p1, p1, "@item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerBillAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer bill discount inc tax", Y0, Y0, "@layer_bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerItemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer item discount inc tax", s1, s1, "@layer_item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@billAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Bill discount exc tax", M1, M1, "@bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@itemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Item discount exc tax", z1, z1, "@item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerBillAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer bill discount exc tax", A1, A1, "@layer_bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(e, "@layerItemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, !1, "Layer item discount exc tax", b1, b1, "@layer_item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$string(e, "IF(@variantId IS NULL OR @variantId = '', @productId, CONCAT(@productId, '/', @variantId))", !0, !1, !1, "Menu item ID", "menuItemId", e, "CASE WHEN @variant_id IS NULL OR @variant_id = '' THEN @product_id ELSE @product_id || '/' || @variant_id END", r), t.Field_Field$string("Special-price tier when a member/promotion PRICE_CHANGE effect set the item price (e.g. vip). Null for normal sales.", e, !1, !1, !1, "Price group", g1, g1, e, r), t.Field_Field$numeric(e, e, !1, !1, "Original price", me, me, e, r), t.Field_Field$numeric(e, e, !1, !1, "Price", "price", "price", e, r), t.Field_Field$numeric("Sold price minus original price, per unit (not multiplied by quantity). Positive means marked up. Non-zero for member/promotion price tiers, open price (original price is 0, so this equals the full price) and manual overrides. Null when either side is unknown.", "@price - @originalPrice", !1, !1, "Price difference", "priceDifference", e, "@price - @original_price", r)], O.JSArray_Field);
9127
9127
  },
9128
9128
  $signature: 0
9129
9129
  }, t.flattenItemSchema_closure0.prototype = {
@@ -25224,7 +25224,7 @@ const Ql = "mf-reportreport-store", ye = Ne(Ql, () => {
25224
25224
  };
25225
25225
  });
25226
25226
  var ea = /* @__PURE__ */ ((c) => (c.generating = "GENERATING", c.completed = "COMPLETED", c.failed = "FAILED", c.canceled = "CANCELLED", c))(ea || {});
25227
- const Vl = "/assets/formatChartData.worker-4gz12Ml-.js", Ct = /* @__PURE__ */ new Map();
25227
+ const Vl = "/assets/formatChartData.worker-C3TaOBES.js", Ct = /* @__PURE__ */ new Map();
25228
25228
  function kr(c) {
25229
25229
  return new Worker(c, { type: "module" });
25230
25230
  }
@@ -1,13 +1,13 @@
1
1
  import { ref as I, defineComponent as S, watch as P, computed as $, onMounted as de, createElementBlock as r, openBlock as o, createElementVNode as s, renderSlot as J, toDisplayString as C, resolveDirective as K, createCommentVNode as D, Fragment as z, renderList as N, createBlock as R, withDirectives as T, resolveDynamicComponent as U, unref as m, withCtx as B, createVNode as p, normalizeClass as W, resolveComponent as M, useModel as ce, createTextVNode as ue, isRef as j, nextTick as fe } from "vue";
2
- import { _ as me } from "./Default.vue_vue_type_script_setup_true_lang-D39cFe6x.js";
3
- import { c as H, D as ge } from "./DateRangeSelect-CqMwZ27u.js";
4
- import { d as E, u as Q, F as ee, q as te, a as pe, h as ve, g as X, i as he, j as ye, k as we } from "./app-CqDIZ6G6.js";
2
+ import { _ as me } from "./Default.vue_vue_type_script_setup_true_lang-CPKHc9Ij.js";
3
+ import { c as H, D as ge } from "./DateRangeSelect-D8yWjVRH.js";
4
+ import { d as E, u as Q, F as ee, q as te, a as pe, h as ve, g as X, i as he, j as ye, k as we } from "./app-CuP9NY1I.js";
5
5
  import { storeToRefs as ae } from "pinia";
6
6
  import { C as le, r as xe } from "./chart-DDDh8zNk.js";
7
7
  import { components as Y, useSnackbar as be } from "@feedmepos/ui-library";
8
8
  import { u as se } from "./_plugin-vue_export-helper-onplcgja.js";
9
9
  import { _ as Ce } from "./SelectComponent.vue_vue_type_script_setup_true_lang-CGbb3b5G.js";
10
- import { a as ke, G as _e } from "./NavigationTab.vue_vue_type_script_setup_true_lang-D3zMj_qy.js";
10
+ import { a as ke, G as _e } from "./NavigationTab.vue_vue_type_script_setup_true_lang-Cg-74bAB.js";
11
11
  import { useCoreStore as $e } from "@feedmepos/mf-common";
12
12
  function Ae({ start: e, end: t }) {
13
13
  return `${E(t).format("DD MMM")}, ${E(t).format("YYYY")}`;
@@ -1,11 +1,11 @@
1
1
  import { defineComponent as ce, mergeModels as we, useModel as fe, computed as W, resolveComponent as I, createElementBlock as R, openBlock as w, createElementVNode as t, createCommentVNode as z, normalizeClass as et, Fragment as $e, renderList as ze, createBlock as ee, normalizeStyle as at, createVNode as l, withCtx as Ce, renderSlot as Vt, toDisplayString as S, unref as n, h as b, createTextVNode as $t, ref as ae, onUnmounted as He, watch as _e, isRef as Ee, resolveDynamicComponent as Be, mergeProps as st, withKeys as ot, withModifiers as dt, nextTick as kt, onMounted as pt } from "vue";
2
2
  import { useRouter as Se, useRoute as It } from "vue-router";
3
- import { B as he, E as nt, d as Ne, G as Tt, e as Le, a as De, H as be, J as Nt, p as Kt, y as pe, A as Ge, K as Ye, L as Oe, M as Qe, N as rt, O as Ft, P as Mt, Q as Ut, R as Rt, S as it, b as ut, T as Pt, U as Lt, t as jt, I as je, V as Ot, W as Et, X as Bt } from "./app-CqDIZ6G6.js";
3
+ import { B as he, E as nt, d as Ne, G as Tt, e as Le, a as De, H as be, J as Nt, p as Kt, y as pe, A as Ge, K as Ye, L as Oe, M as Qe, N as rt, O as Ft, P as Mt, Q as Ut, R as Rt, S as it, b as ut, T as Pt, U as Lt, t as jt, I as je, V as Ot, W as Et, X as Bt } from "./app-CuP9NY1I.js";
4
4
  import { u as ve, a as We, _ as Yt } from "./_plugin-vue_export-helper-onplcgja.js";
5
5
  import { u as Xe } from "./message-dialog-UoMWOnil.js";
6
6
  import { useSnackbar as Ae } from "@feedmepos/ui-library";
7
- import { s as St, D as Je } from "./DateRangeSelect-CqMwZ27u.js";
8
- import { u as qe, h as ke } from "./useRestaurantPermission-D26lLMqS.js";
7
+ import { s as St, D as Je } from "./DateRangeSelect-D8yWjVRH.js";
8
+ import { u as qe, h as ke } from "./useRestaurantPermission-i9i6cu96.js";
9
9
  import { storeToRefs as Ze } from "pinia";
10
10
  const qt = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-between" }, zt = { class: "w-[100%] overflow-hidden" }, Ht = { class: "inline-flex max-w-full items-center gap-2 align-top" }, Gt = { class: "text-nowrap min-w-0 overflow-hidden text-ellipsis font-semibold" }, Qt = {
11
11
  key: 0,