← Hub NetSuite Workflows & Automation
v10.0
NetSuite Workflows
Brand System v10.0 — NetSuite Automation
NetSuite
Workflows &
Automation
Approval chains, lifecycle states, scheduled jobs, and email alerts.
Complete workflow and automation reference for Global Food Solutions NetSuite implementation. Covers approval routing, status transitions, scheduled scripts, and notification templates built for food distribution at scale.
Approvals Lifecycles Schedules Alerts Best Practices
Document ID GFS-2026-WKFL
Region Edgewood / Hermitage
Status Active
Version 9.0
Date 05 / 19 / 2026
Classification Workflow Automation
Platform NetSuite SuiteFlow / SuiteScript 2.1
Owner Global Food Solutions, Inc.
02 Approval Workflows Threshold-based routing for POs, SOs, JEs, vendor bills, and RMAs
Purchase Order Approval
Threshold-Based
Draft Submit Pending Review Route Approver Queue Approve Reject Approved Rejected Create PO PO Created Revise & Resubmit
Approval Thresholds
Amount Range Approver SLA Escalation
< $5,000 Auto-Approved Immediate N/A
$5,000 – $24,999 Department Manager 24 hours VP after 24h
$25,000 – $49,999 VP of Operations 48 hours CFO after 48h
≥ $50,000 CFO (Michael Levine) 72 hours CEO after 72h
Conditions
Triggered on purchaseorder record save when status = Pending Approval. Amount evaluated from total field. Multi-subsidiary: route to subsidiary-specific approver first.
Actions
Set approver field. Send email notification. Create approval task. Log audit trail entry. On approval: set status to Approved, trigger PO creation. On reject: set status to Rejected, notify requester.
Script Reference
Workflow: customworkflow_gfs_po_approval
Script: customscript_gfs_po_approve_ue
Deployment: customdeploy_gfs_po_approve
Sales Order Credit Check
Auto + Manual
SO Created Credit Check Pass Auto-Approved Fail Credit Hold Manager Review Fulfilled
Conditions
Customer creditlimit vs. balance + new order total. Auto-pass if balance + order ≤ 80% of limit. Hold if exceeded or customer has past-due invoices > 30 days.
Actions
On pass: auto-approve, set SO status to Pending Fulfillment. On fail: set Credit Hold, email AR manager, create task for review. Manager can override or reject.
Script Reference
Workflow: customworkflow_gfs_so_credit
Script: customscript_gfs_credit_check_ue
Deployment: customdeploy_gfs_credit_check
Journal Entry Approval
Sequential
Draft Pending Review Controller Review CFO Approval Posted All JEs > $0 > $10,000 > $50,000
Conditions
Sequential approval: all JEs require at least one review. JEs over $10,000 require Controller. JEs over $50,000 require CFO sign-off. Intercompany JEs always route to CFO.
Actions
Lock record during review. Email next approver. Post on final approval. Rejected JEs return to draft with comments. Audit log captures all approver actions and timestamps.
Script Reference
Workflow: customworkflow_gfs_je_approval
Script: customscript_gfs_je_approve_wfa
Deployment: customdeploy_gfs_je_approve
Vendor Bill 3-Way Match Approval
3-Way Match
Bill Entered 3-Way Match PO + Receipt + Bill Match Auto-Approved Variance Variance Review AP Manager Ready to Pay
Conditions
Compare bill lines against PO lines and item receipt quantities. Tolerance: ≤ 2% price variance, ≤ 5% quantity variance. Exceeding either threshold routes to AP Manager for review.
Actions
On match: auto-approve bill, schedule for next payment run. On variance: flag line items with discrepancies, create AP task, email vendor if quantity short. Manager can approve, adjust, or reject.
Script Reference
Workflow: customworkflow_gfs_vb_3way
Script: customscript_gfs_3way_match_ue
Deployment: customdeploy_gfs_vb_match
RMA Authorization
Multi-Step
Requested QA Inspection Authorized Receiving Credit Issued Photo + temp log required Hermitage or Edgewood
Conditions
Customer submits return request. QA must review photos, temperature logs, and reason code. Food safety issues (allergen, contamination) get priority routing. Returns > $5,000 require manager authorization.
Actions
Generate RMA number. Email customer with shipping label. On receipt: inspect product, update disposition (restock, destroy, vendor return). Issue credit memo or replacement SO. Log lot/batch for traceability.
Script Reference
Workflow: customworkflow_gfs_rma
Script: customscript_gfs_rma_auth_ue
Deployment: customdeploy_gfs_rma_auth
■ All approval workflows include audit trail logging, email notifications, and escalation timers. Thresholds configurable via GFS Config custom record.
03 Status Transition Workflows Lifecycle state machines for orders, POs, work orders, and cases
Order Lifecycle
8 States
Draft Pending Approved Processing Shipped Delivered Invoiced Closed
Key Transitions
Draft → Pending on submit. Pending → Approved after credit check. Processing → Shipped on item fulfillment. Delivered triggers invoice generation. Closed after full payment.
Backward Transitions
Approved → Draft (cancel). Processing → Pending (hold). Shipped → Processing (return to warehouse). All backward transitions require manager approval and audit log entry.
Automation Hooks
Each transition fires User Event scripts for validation, notification, and related record creation. Temperature monitoring active during Shipped and Delivered states for cold chain compliance.
Purchase Order Lifecycle
7 States
Draft Pend. Approval Approved Sent to Vendor Partial Receipt Fully Received Closed
Work Order Lifecycle
6 States
Planned Released In Progress QA Review Completed Closed
Case Lifecycle
7 States
New Assigned In Progress Pend. Customer Escalated Resolved Closed
■ All lifecycle workflows enforce state-valid transitions. Invalid transitions are blocked at the User Event before-submit level with user-friendly error messages.
04 Scheduled Automations Daily, weekly, and monthly automated jobs with governance budgets
Daily Automations
Daily 6:00 AM ET
Inventory Snapshot
Captures on-hand, committed, available, and in-transit quantities for all active items across Edgewood and Hermitage warehouses. Writes to custom inventory history record for trend analysis.
Script Type Map/Reduce
Script ID customscript_gfs_inv_snapshot
Governance ~4,000 units
Dependencies Item records, Location records
Daily 7:00 AM ET
Temperature Compliance Report
Pulls IoT sensor data for all cold storage units, flags any excursions outside 33-41F range. Generates compliance report and alerts QA team if violations detected in the last 24 hours.
Script Type Scheduled
Script ID customscript_gfs_temp_compliance
Governance ~1,200 units
Dependencies IoT API, QA alert workflow
Daily 8:00 AM ET
Delivery ETA Updates
Queries carrier APIs (FedEx, USPS, LTL partners) for all in-transit shipments. Updates delivery date estimates on sales orders and sends proactive notifications for delays exceeding 24 hours.
Script Type Scheduled
Script ID customscript_gfs_delivery_eta
Governance ~2,500 units
Dependencies Carrier APIs, SO records
Weekly Automations
Monday 6:00 AM ET
Vendor Scorecard Calculation
Calculates on-time delivery rate, fill rate, quality score, and price competitiveness for all active vendors. Updates vendor custom records and flags vendors falling below 85% composite score.
Script Type Map/Reduce
Script ID customscript_gfs_vendor_score
Governance ~6,000 units
Dependencies PO, IR, QA records
Tuesday 7:00 AM ET
Customer Health Check
Analyzes order frequency, average order value, payment timeliness, and case volume per customer. Assigns health score (Green/Yellow/Red) and alerts sales reps to at-risk accounts.
Script Type Map/Reduce
Script ID customscript_gfs_cust_health
Governance ~5,000 units
Dependencies SO, Invoice, Case records
Friday 6:00 AM ET
AR Aging Email
Generates AR aging summary grouped by 0-30, 31-60, 61-90, 90+ day buckets. Emails finance team with past-due totals and top 10 delinquent accounts requiring collection attention.
Script Type Scheduled
Script ID customscript_gfs_ar_aging_email
Governance ~1,800 units
Dependencies Invoice records, Email template
Monthly Automations
1st of Month 2:00 AM ET
Rebate Calculation
Processes all rebate-eligible transactions for the prior month. Calculates volume-based rebate tiers, generates credit memos or vendor debit memos, and updates rebate accrual journal entries.
Script Type Map/Reduce
Script ID customscript_gfs_rebate_calc
Governance ~8,000 units
Dependencies SO, Invoice, Rebate config
1st of Month 4:00 AM ET
Financial Close Tasks
Creates checklist of month-end close tasks: bank reconciliation, accrual JEs, intercompany eliminations, inventory valuation, revenue recognition. Assigns to finance team members with due dates.
Script Type Scheduled
Script ID customscript_gfs_close_tasks
Governance ~800 units
Dependencies Task records, Employee records
15th of Month 6:00 AM ET
Compliance Cert Check
Scans all vendor and facility certifications (USDA, FDA, SQF, organic, kosher) for upcoming expirations within 30/60/90 days. Sends renewal reminders and flags non-compliant vendors.
Script Type Scheduled
Script ID customscript_gfs_cert_check
Governance ~1,500 units
Dependencies Vendor records, Cert custom records
■ All scheduled scripts include governance monitoring, checkpoint/resume for long-running jobs, and failure notification emails to the GFS IT team.
05 Email Alerts Automated notifications for orders, shipments, invoices, and compliance events
Order Confirmation
Trigger
Sales Order saved with status = Pending Fulfillment
Template
gfs_order_confirm_v2
Recipients
Customer primary contact, Sales rep (CC), Order entry team (BCC)
Content
Order number, line items, estimated delivery, GFS-branded header with tracking link
Shipment Notification
Trigger
Item Fulfillment record created with tracking number populated
Template
gfs_shipment_notify_v2
Recipients
Customer shipping contact, Sales rep (CC)
Content
Tracking number with carrier link, shipped items, estimated arrival, temperature monitoring status
Invoice Delivery
Trigger
Invoice created from Sales Order (after submit)
Template
gfs_invoice_email_v2
Recipients
Customer billing contact, Customer AP email (if set)
Content
Invoice PDF attachment, amount due, payment terms, remittance instructions, online payment link
Payment Receipt
Trigger
Customer Payment applied to invoice(s)
Template
gfs_payment_receipt_v2
Recipients
Customer billing contact
Content
Payment amount, method, invoices applied, remaining balance, thank-you message
Past Due Reminder
Trigger
Invoice past due by 7, 14, 30, 60 days (escalating sequence)
Template
gfs_pastdue_remind_{n} (4 templates)
Recipients
Customer AP contact, escalates to customer executive contact at 60+ days
Content
Outstanding amount, days past due, payment link, tone escalates from friendly to firm
Temperature Excursion Alert
Trigger
IoT sensor reading outside 33-41F for > 15 minutes
Template
gfs_temp_excursion_alert
Recipients
QA Manager, Warehouse Supervisor, Facility Manager (immediate), VP Ops (if > 1 hour)
Content
Sensor ID, location, current temp, duration, affected lots, recommended action protocol
Compliance Expiry Warning
Trigger
Vendor/facility cert expires within 30/60/90 days (USDA, FDA, SQF, Kosher)
Template
gfs_cert_expiry_warn
Recipients
Compliance Officer, Vendor contact, Procurement Manager
Content
Cert type, vendor name, expiry date, renewal instructions, consequence of lapse (PO hold)
■ All email templates use GFS-branded HTML with cobalt header bar, company logo, and footer. Templates stored as NetSuite email template records with merge field support.
06 Workflow Best Practices Naming conventions, error handling, testing, deployment guidelines
Naming Conventions
Workflows: customworkflow_gfs_{module}_{action}
Scripts: customscript_gfs_{module}_{type}
Deployments: customdeploy_gfs_{module}_{action}
Always prefix with gfs_ to distinguish from native and third-party customizations
Use lowercase with underscores, max 40 characters for script IDs
State Naming
Use past tense for completed states: Approved, Rejected, Shipped, Closed
Use present participle for active states: Processing, Receiving, Reviewing
Use "Pending" prefix for waiting states: Pending Approval, Pending Customer
Keep state names under 20 characters for dashboard display
Assign sort order values in increments of 10 to allow future insertions
Error Handling
Wrap all workflow actions in try/catch blocks with meaningful error messages
Log errors to a custom GFS Audit Log record, not just the execution log
Send email to IT team on critical failures (workflow stuck, script timeout)
Include record type, internal ID, and user context in all error logs
Never silently swallow exceptions; always re-throw after logging if needed
Logging
Use log.audit() for state transitions and approvals
Use log.error() for failures, never log.debug() in production
Include timestamp, user, record ID, old state, new state in transition logs
Structured log format: [GFS] {module} | {action} | {detail}
Retain execution logs for 90 days minimum for compliance audits
Testing
Test all workflow paths in Sandbox before production deployment
Verify forward and backward state transitions with each role type
Test edge cases: zero-amount orders, multi-subsidiary, intercompany
Confirm email templates render correctly in Outlook, Gmail, and Apple Mail
Validate escalation timers fire correctly (use shortened intervals in sandbox)
Deployment Checklist
Document all workflow states, transitions, and conditions in change log
Export workflow as SDF (SuiteCloud Development Framework) for version control
Schedule deployment during off-hours (after 8 PM ET, before 6 AM ET)
Notify affected users 48 hours before workflow changes go live
Keep previous workflow version inactive (not deleted) for 30-day rollback window
■ All GFS workflow customizations are tracked in the customization registry. Contact IT before creating new workflows to avoid duplicate logic.
← Back to Hub · GFS Design System v10.0 · Global Food Solutions, Inc. · Edgewood, NY