Skip to content

Commit e8c5d25

Browse files
committed
feat: Add Todo Manager application with ObjectStack Protocol
- Created objectstack.config.ts to define the Todo Manager app stack. - Added package.json for project dependencies and scripts. - Implemented action definitions for task management in task.actions.ts. - Developed app structure with navigation and branding in todo.app.ts. - Created dashboards for task metrics in task.dashboard.ts. - Implemented flows for task reminders and escalations in task.flow.ts. - Defined task object schema with fields and validations in task.object.ts. - Added reports for task summaries and time tracking in task.report.ts. - Implemented hooks for task logic in task.hook.ts. - Created seed test to verify initial data seeding. - Configured TypeScript settings in tsconfig.json.
1 parent 04d54ff commit e8c5d25

91 files changed

Lines changed: 6392 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

examples/crm/CHANGELOG.md

Lines changed: 218 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,218 @@
1+
# @objectstack/example-crm
2+
3+
## 0.9.15
4+
5+
### Patch Changes
6+
7+
- Updated dependencies
8+
- @objectstack/spec@1.0.12
9+
10+
## 0.9.14
11+
12+
### Patch Changes
13+
14+
- @objectstack/spec@1.0.11
15+
16+
## 0.9.13
17+
18+
### Patch Changes
19+
20+
- @objectstack/spec@1.0.10
21+
22+
## 0.9.12
23+
24+
### Patch Changes
25+
26+
- @objectstack/spec@1.0.9
27+
28+
## 0.9.11
29+
30+
### Patch Changes
31+
32+
- @objectstack/spec@1.0.8
33+
34+
## 0.9.10
35+
36+
### Patch Changes
37+
38+
- @objectstack/spec@1.0.7
39+
40+
## 0.9.9
41+
42+
### Patch Changes
43+
44+
- Updated dependencies [a7f7b9d]
45+
- @objectstack/spec@1.0.6
46+
47+
## 0.9.8
48+
49+
### Patch Changes
50+
51+
- Updated dependencies [b1d24bd]
52+
- @objectstack/spec@1.0.5
53+
54+
## 0.9.7
55+
56+
### Patch Changes
57+
58+
- @objectstack/spec@1.0.4
59+
60+
## 0.9.6
61+
62+
### Patch Changes
63+
64+
- @objectstack/spec@1.0.3
65+
66+
## 0.9.5
67+
68+
### Patch Changes
69+
70+
- Updated dependencies [a0a6c85]
71+
- Updated dependencies [109fc5b]
72+
- @objectstack/spec@1.0.2
73+
74+
## 0.9.4
75+
76+
### Patch Changes
77+
78+
- @objectstack/spec@1.0.1
79+
80+
## 0.9.3
81+
82+
### Patch Changes
83+
84+
- Updated dependencies
85+
- @objectstack/spec@1.0.0
86+
87+
## 0.9.2
88+
89+
### Patch Changes
90+
91+
- Updated dependencies
92+
- @objectstack/spec@0.9.2
93+
94+
## 0.9.1
95+
96+
### Patch Changes
97+
98+
- Updated dependencies
99+
- @objectstack/spec@0.9.1
100+
101+
## 0.7.5
102+
103+
### Patch Changes
104+
105+
- Updated dependencies [555e6a7]
106+
- @objectstack/spec@0.8.2
107+
108+
## 0.7.4
109+
110+
### Patch Changes
111+
112+
- @objectstack/spec@0.8.1
113+
114+
## 0.7.3
115+
116+
### Patch Changes
117+
118+
- Updated dependencies
119+
- @objectstack/spec@1.0.0
120+
121+
## 0.7.2
122+
123+
### Patch Changes
124+
125+
- Updated dependencies [fb41cc0]
126+
- @objectstack/spec@0.7.2
127+
128+
## 0.7.1
129+
130+
### Patch Changes
131+
132+
- Updated dependencies
133+
- @objectstack/spec@0.7.1
134+
135+
## 0.6.1
136+
137+
### Patch Changes
138+
139+
- Updated dependencies
140+
- @objectstack/spec@0.6.1
141+
142+
## 0.6.0
143+
144+
### Minor Changes
145+
146+
- b2df5f7: Unified version bump to 0.5.0
147+
148+
- Standardized all package versions to 0.5.0 across the monorepo
149+
- Fixed driver-memory package.json paths for proper module resolution
150+
- Ensured all packages are in sync for the 0.5.0 release
151+
152+
### Patch Changes
153+
154+
- Updated dependencies [b2df5f7]
155+
- @objectstack/spec@0.6.0
156+
157+
## 1.0.9
158+
159+
### Patch Changes
160+
161+
- Updated dependencies
162+
- @objectstack/spec@0.4.2
163+
164+
## 1.0.8
165+
166+
### Patch Changes
167+
168+
- Updated dependencies
169+
- @objectstack/spec@0.4.1
170+
171+
## 1.0.7
172+
173+
### Patch Changes
174+
175+
- Updated dependencies
176+
- @objectstack/spec@0.3.3
177+
178+
## 1.0.6
179+
180+
### Patch Changes
181+
182+
- Patch release for maintenance and stability improvements
183+
- Updated dependencies
184+
- @objectstack/spec@0.3.2
185+
186+
## 1.0.5
187+
188+
### Patch Changes
189+
190+
- @objectstack/spec@0.3.1
191+
192+
## 1.0.4
193+
194+
### Patch Changes
195+
196+
- Updated dependencies
197+
- @objectstack/spec@1.0.0
198+
199+
## 1.0.3
200+
201+
### Patch Changes
202+
203+
- Updated dependencies
204+
- @objectstack/spec@0.3.0
205+
206+
## 1.0.2
207+
208+
### Patch Changes
209+
210+
- Updated dependencies
211+
- @objectstack/spec@0.2.0
212+
213+
## 1.0.1
214+
215+
### Patch Changes
216+
217+
- Updated dependencies
218+
- @objectstack/spec@0.1.2

examples/crm/README.md

Lines changed: 164 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,164 @@
1+
# ObjectStack Enterprise CRM Application
2+
3+
[English](#english) | [中文](#中文)
4+
5+
---
6+
7+
## English
8+
9+
### 🎯 Overview
10+
11+
**Enterprise CRM** is a comprehensive, production-ready Customer Relationship Management system built on the ObjectStack Protocol. It demonstrates all 128+ protocol modules across 15 categories, showcasing enterprise-grade architecture following Salesforce and ServiceNow best practices.
12+
13+
### ✨ Key Features
14+
15+
#### 📊 **Complete Data Model**
16+
- **10 Core Objects** organized by domain (Sales, Service, Marketing, Products)
17+
- **50+ Field Types** including advanced types (Location, Color, Address)
18+
- **Comprehensive Relationships** with lookups and master-detail
19+
- **Smart Validations** with script-based rules and formulas
20+
21+
#### 🔒 **Enterprise Security**
22+
- **5 User Profiles** (Admin, Sales Manager, Sales Rep, Service Agent, Marketing User)
23+
- **Role Hierarchy** with 10 roles
24+
- **Sharing Rules** (criteria-based, owner-based, territory-based)
25+
- **Field-Level Security** for sensitive data
26+
- **Organization-Wide Defaults** for baseline access control
27+
28+
#### 🤖 **AI-Powered Automation**
29+
- **5 AI Agents** (Sales Assistant, Service Agent, Lead Enrichment, Revenue Intelligence, Email Campaign)
30+
- **4 RAG Pipelines** for knowledge retrieval
31+
- **Natural Language Queries** for intuitive data access
32+
- **Predictive Analytics** (lead scoring, revenue forecasting)
33+
34+
#### **Business Process Automation**
35+
- **5 Automated Flows** (Lead Conversion, Opportunity Approval, Case Escalation, Quote Generation, Campaign Enrollment)
36+
- **Workflow Rules** for field updates and notifications
37+
- **Approval Processes** for large deals and contracts
38+
- **Scheduled Jobs** for batch processing
39+
40+
#### 📈 **Analytics & Reporting**
41+
- **3 Interactive Dashboards** (Sales, Service, Executive)
42+
- **8 Pre-built Reports** (opportunities, accounts, cases, leads, tasks)
43+
- **Real-time Metrics** with KPIs and trends
44+
- **Custom Charts** (funnel, bar, line, pie, table)
45+
46+
### 📁 Architecture
47+
48+
Follows the **by-type** directory layout — the ObjectStack standard aligned with Salesforce DX:
49+
50+
```
51+
src/
52+
├── objects/ # 📦 10 Core Objects (account, contact, lead, opportunity, ...)
53+
├── actions/ # ⚡ Custom Actions (lead, contact, opportunity, case, global)
54+
├── apis/ # 🌐 REST Endpoints (pipeline-stats, lead-convert)
55+
├── apps/ # 🚀 App Configuration (crm.app.ts)
56+
├── dashboards/ # 📊 3 Dashboards (sales, service, executive)
57+
├── reports/ # 📈 8 Reports (opportunity, account, case, lead, contact, task)
58+
├── flows/ # 🔄 5 Flows (lead-conversion, opportunity-approval, ...)
59+
├── agents/ # 🤖 5 AI Agents (sales, service, lead-enrichment, ...)
60+
├── rag/ # 🧠 4 RAG Pipelines (sales-knowledge, support, product, ...)
61+
├── profiles/ # 🔒 5 Profiles (admin, sales-manager, sales-rep, ...)
62+
└── sharing/ # 🛡️ Sharing Rules & Role Hierarchy
63+
```
64+
65+
### 📚 Documentation
66+
67+
Comprehensive guides covering all aspects:
68+
69+
1. **[Data Modeling](./docs/01-data-modeling.md)** - Objects, fields, relationships, validations
70+
2. **[Business Logic](./docs/02-business-logic.md)** - Workflows, triggers, formulas
71+
3. **[Security](./docs/05-security.md)** - Profiles, roles, sharing, permissions
72+
4. **[AI Capabilities](./docs/08-ai-capabilities.md)** - Agents, RAG, NLQ, ML
73+
74+
### 🚀 Quick Start
75+
76+
```bash
77+
# Install dependencies
78+
pnpm install
79+
80+
# Build the application
81+
pnpm --filter @example/app-crm build
82+
83+
# Run development server
84+
pnpm --filter @example/app-crm dev
85+
```
86+
87+
### 📦 What's Included
88+
89+
| Category | Count | Examples |
90+
|----------|-------|----------|
91+
| **Objects** | 10 | Account, Opportunity, Case, Product |
92+
| **Fields** | 100+ | AutoNumber, Formula, Lookup, Address |
93+
| **Profiles** | 5 | Admin, Sales Manager, Sales Rep |
94+
| **Sharing Rules** | 5+ | Criteria-based, Territory-based |
95+
| **AI Agents** | 5 | Sales Assistant, Service Agent |
96+
| **RAG Pipelines** | 4 | Sales Knowledge, Support KB |
97+
| **Flows** | 5 | Lead Conversion, Approval |
98+
| **Dashboards** | 3 | Sales, Service, Executive |
99+
| **Reports** | 8 | Opportunities, Cases, Leads |
100+
101+
---
102+
103+
## 中文
104+
105+
### 🎯 概述
106+
107+
**企业级CRM** 是基于 ObjectStack 协议构建的综合性、生产就绪的客户关系管理系统。它展示了15个类别中的128+协议模块,遵循 Salesforce 和 ServiceNow 的企业级架构最佳实践。
108+
109+
### ✨ 核心特性
110+
111+
#### 📊 **完整数据模型**
112+
- **10个核心对象** 按领域组织(销售、服务、营销、产品)
113+
- **50+字段类型** 包括高级类型(位置、颜色、地址)
114+
- **全面的关系** 查找和主从关系
115+
- **智能验证** 基于脚本的规则和公式
116+
117+
#### 🔒 **企业级安全**
118+
- **5种用户配置文件** (管理员、销售经理、销售代表、服务代表、营销用户)
119+
- **角色层次结构** 包含10个角色
120+
- **共享规则** (基于条件、基于所有者、基于区域)
121+
- **字段级安全** 保护敏感数据
122+
- **组织范围默认值** 基线访问控制
123+
124+
#### 🤖 **AI驱动自动化**
125+
- **5个AI代理** (销售助手、服务代理、线索丰富、收入智能、邮件营销)
126+
- **4个RAG管道** 用于知识检索
127+
- **自然语言查询** 直观的数据访问
128+
- **预测分析** (线索评分、收入预测)
129+
130+
#### **业务流程自动化**
131+
- **5个自动化流程** (线索转换、商机审批、案例升级、报价生成、营销注册)
132+
- **工作流规则** 字段更新和通知
133+
- **审批流程** 大型交易和合同
134+
- **定时任务** 批处理
135+
136+
#### 📈 **分析与报表**
137+
- **3个交互式仪表板** (销售、服务、高管)
138+
- **8个预制报表** (商机、客户、案例、线索、任务)
139+
- **实时指标** KPI和趋势
140+
- **自定义图表** (漏斗、柱状、折线、饼图、表格)
141+
142+
### 📚 文档
143+
144+
1. **[数据建模](./docs/01-data-modeling.md)** - 对象、字段、关系、验证
145+
2. **[业务逻辑](./docs/02-business-logic.md)** - 工作流、触发器、公式
146+
3. **[安全模型](./docs/05-security.md)** - 配置文件、角色、共享、权限
147+
4. **[AI能力](./docs/08-ai-capabilities.md)** - 代理、RAG、NLQ、机器学习
148+
149+
### 🚀 快速开始
150+
151+
```bash
152+
# 安装依赖
153+
pnpm install
154+
155+
# 构建应用
156+
pnpm --filter @example/app-crm build
157+
158+
# 运行开发服务器
159+
pnpm --filter @example/app-crm dev
160+
```
161+
162+
---
163+
164+
**构建全球最顶级的企业管理软件平台** 🚀

0 commit comments

Comments
 (0)