-- Add approve permissions for sales, purchases, and returns
INSERT IGNORE INTO permissions (strKey, strName, strGroup) VALUES
('sales.approve', 'Approve Sales Orders', 'Orders'),
('purchases.approve', 'Approve Purchase Orders', 'Orders'),
('returns.approve', 'Approve Returns', 'Orders');

-- Assign new permissions to Admin role (id=1)
INSERT IGNORE INTO role_permissions (intRoleId, intPermissionId)
SELECT 1, intId FROM permissions WHERE strKey IN ('sales.approve', 'purchases.approve', 'returns.approve');
