disable console.log

This commit is contained in:
Abdul Aziz Amrullah 2026-05-06 11:20:12 +07:00
parent f975a76d84
commit aa41dc5840

View File

@ -5,15 +5,15 @@ import { patch } from "@web/core/utils/patch";
patch(PosStore.prototype, {
async postProcessLoyalty(order) {
console.group(`[Loyalty Auto Level] Processing Loyalty for Order: ${order.name}`);
// console.group(`[Loyalty Auto Level] Processing Loyalty for Order: ${order.name}`);
const partner = order.getPartner();
console.log("Customer:", partner ? partner.name : "No Customer");
// console.log("Customer:", partner ? partner.name : "No Customer");
console.log("Coupon Point Changes (Before Sync):", JSON.parse(JSON.stringify(order.uiState.couponPointChanges)));
// console.log("Coupon Point Changes (Before Sync):", JSON.parse(JSON.stringify(order.uiState.couponPointChanges)));
try {
await super.postProcessLoyalty(order);
console.log("Loyalty processing completed successfully. The backend confirm_coupon_programs should have triggered point consolidation if a membership upgrade/downgrade occurred.");
// console.log("Loyalty processing completed successfully. The backend confirm_coupon_programs should have triggered point consolidation if a membership upgrade/downgrade occurred.");
} catch (error) {
console.error("Error during loyalty processing:", error);
throw error;