feat: 客户管理新增个人用户类型,双Tab分离管理
- customers 表新增 customer_type 列 (unit/individual) - 列表按个人优先排序,支持 customer_type 筛选 - PC端 el-radio-group 切换:单位客户 | 个人用户 - 个人用户表单: 仅姓名+备注,隐藏行业/地址/业务/月费/客户经理/联系人 - 所有业务模块客户搜索下拉中个人用户置顶 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -42,6 +42,10 @@ async def lifespan(app: FastAPI):
|
||||
await conn.run_sync(lambda c: c.exec_driver_sql(
|
||||
"ALTER TABLE customers ADD COLUMN IF NOT EXISTS last_visit_manager_id UUID"
|
||||
))
|
||||
# v0.9 — customer_type for unit vs individual
|
||||
await conn.run_sync(lambda c: c.exec_driver_sql(
|
||||
"ALTER TABLE customers ADD COLUMN IF NOT EXISTS customer_type VARCHAR(20) DEFAULT 'unit'"
|
||||
))
|
||||
# New columns for v0.4
|
||||
await conn.run_sync(lambda c: c.exec_driver_sql(
|
||||
"ALTER TABLE visits ADD COLUMN IF NOT EXISTS companion_names TEXT[] DEFAULT '{}'"
|
||||
|
||||
Reference in New Issue
Block a user