MVP底座①:数据四域命名 —— 项目/客户/情报/供应商
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KeDBx2PHLavbURXB8LJJ7m
This commit is contained in:
@@ -1,20 +1,19 @@
|
||||
/**
|
||||
* 数据域的人读短名 —— 左轨一枚钮只放得下 2-3 个字。
|
||||
* 数据域的人读短名 —— 导航一枚钮/一个页签只放得下 2-3 个字。
|
||||
*
|
||||
* 域键是活动的复合键(`quote_intake`),给人看要翻译;
|
||||
* 字典之外的域回落到键的最后一段(截 4 字符)—— 新装的活动没配短名时,轨上先有个能认的名字。
|
||||
* 数据按**经营对象**四分(docs/产品设计.md 附录):
|
||||
* 项目 = 每一单的流转单据;客户 / 情报 / 供应商 = 沉淀资产。
|
||||
* 字典之外的域回落到键的最后一段(截 4 字符)—— 新域没配短名时,先有个能认的名字。
|
||||
*/
|
||||
export const DOMAIN_SHORT: Readonly<Record<string, string>> = {
|
||||
quote_intake: '受理',
|
||||
quote_sourcing: '寻源',
|
||||
quote_pricing: '定价',
|
||||
quote_negotiate: '议价',
|
||||
quote_alternative: '替代',
|
||||
shared: '共享',
|
||||
project: '项目',
|
||||
customer: '客户',
|
||||
intel: '情报',
|
||||
supplier: '供应商',
|
||||
};
|
||||
|
||||
/** 业务序:受理 → 寻源 → 定价 → 议价 → 替代 → 共享 —— 左轨按流程走向排,不按字母 */
|
||||
const DOMAIN_ORDER = ['quote_intake', 'quote_sourcing', 'quote_pricing', 'quote_negotiate', 'quote_alternative', 'shared'];
|
||||
/** 业务序:项目(每天看的)→ 客户 → 情报 → 供应商 —— 按经营视角排,不按字母 */
|
||||
const DOMAIN_ORDER = ['project', 'customer', 'intel', 'supplier'];
|
||||
|
||||
export function sortDomains(domains: readonly string[]): string[] {
|
||||
return [...domains].sort((a, b) => {
|
||||
|
||||
Reference in New Issue
Block a user