CorruFlow · Admin
Admin Console
ADMINISTRATOR
📋 Rate Master
⚙️ Settings
👥 Users
🔧 Data Tools
Paper Rate Master
GSMBF Grade / TypeRate (₹/kg) RCT MD
kN/m (opt.)
RCT CD
kN/m (opt.)
Est. Eff. RCT
kN/m
Flute Master
FluteSpeed (LM/min)Take-up factor
Process / Labour Master
Process namePer HrSetup (min)Salary/mo (₹)
Rate Change History
Date & TimeGradeOld rateNew rateChangeChanged by
Click Refresh to load history
Labour Cost Model

Choose how labour cost is calculated across all box costings. Applies to every quote generated by your team.

Overhead Formula

Overhead = Area with wastage × multiplier. Switches on weight per UP threshold.

Material Rate Factors
Company
Quote Number Settings

Preview: AIC-2026-0001

Labour Quantity Multiplier Bands
Qty ≤Multiplier
100
499
999
2999
4999
Database Connection
Not connected
⚠ Service Role Key Required
Get it from Supabase Dashboard → Project Settings → API → service_role key
User Accounts — your organisation
EmailFull Name Role Last sign-in Status
Loading…
Roles: Admin (full access) · Approver (rate approval) · Standard (general use)
App Access Control
Check = user can access that module
Loading access grid…
✅ = access granted · Changes take effect on next login · Admin users always have full access.

Sync customers with CRM

Merges the customer master with CRM contacts — adds missing entries to both, removes duplicates.

Push all approved rates to database

Re-uploads every locked rate from the costing engine to Supabase. Use if approved rates are missing for other users.

Push all quotes to database

Re-uploads all quotes from this browser's localStorage to Supabase.

Export all data

Download a full JSON backup of quotes, approved rates, customers and rate master from Supabase.

⚠ Clear local quote history

Clears quotes from this browser only. All data remains safe in Supabase.

Create Coupon
Active Coupons
Code Description Discount Plans Expires Uses Status
Loading…
Supabase Setup — Run once

Run this SQL in your Supabase SQL editor to create the coupons table and set your super admin role:

create table if not exists cf_coupons (
  id          uuid primary key default gen_random_uuid(),
  code        text unique not null,
  description text,
  discount_type  text not null check (discount_type in ('percent','flat')),
  discount_value numeric not null,
  applies_to  text default 'all',  -- 'all','growth','profit'
  expires_at  timestamptz,
  max_uses    int,
  use_count   int default 0,
  is_active   boolean default true,
  created_at  timestamptz default now(),
  created_by  text
);

-- Allow any authenticated user to READ coupons (for validation on upgrade page)
alter table cf_coupons enable row level security;
create policy "anyone can read active coupons"
  on cf_coupons for select
  using (is_active = true);

-- Only admins can insert/update/delete (via service role or admin token)
create policy "admins can manage coupons"
  on cf_coupons for all
  using (true)
  with check (true);

-- Set YOUR account as super_admin (replace with your user id from auth.users)
-- update cf_profiles set role = 'super_admin' where id = 'YOUR-USER-UUID-HERE';