frontend / api/suppliers/supplierMutations / updateSupplier
Function: updateSupplier()
updateSupplier(
id,supplier):Promise<{error?:string;success:null|SupplierRow; }>
Defined in: src/api/suppliers/supplierMutations.ts:75
Update existing supplier.
Parameters
id
string
Supplier ID
supplier
Updated supplier data
Returns
Promise<{ error?:
string; success: null |
SupplierRow;
}>
Updated supplier, or error message
Example
const { success, error } = await updateSupplier('sup-123', {
name: 'ACME Corp Updated',
email: 'newemail@acme.com'
});