Create a new customer record from the customer management module.
npx uiskill install @fan/create-customer{
"id": "crm:customer:create",
"kind": "atomic",
"name": "Create Customer",
"states": {
"error_handle": {
"if": "@toast(type='error') || @form_error()",
"then": "report_validation_error"
},
"pre_condition": "current_page == '/customers'",
"success_criteria": {
"type": "url_change",
"match": "/customers/*"
}
},
"anchors": {
"form": "@form(name='customer_create')",
"submit": "@button(text='Save')",
"trigger": "@button(text='New Customer')"
},
"uiskill": "0.1.0",
"category": "Record Creation",
"parameters": {
"type": "object",
"required": [
"customer_name",
"owner"
],
"properties": {
"owner": {
"type": "string",
"description": "Assigned account owner."
},
"status": {
"enum": [
"active",
"prospect",
"inactive"
],
"type": "string",
"default": "prospect",
"description": "Initial customer status."
},
"industry": {
"type": "string",
"description": "Customer industry."
},
"customer_name": {
"type": "string",
"description": "Customer display name."
}
}
},
"description": "Create a new customer record from the customer management module."
}