openxiangda-cli 2.0.0-alpha.18 → 2.0.0-alpha.183
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -14
- package/bin/run.js +79 -1
- package/dist/base.d.ts +60 -5
- package/dist/base.d.ts.map +1 -1
- package/dist/base.js +197 -10
- package/dist/base.js.map +1 -1
- package/dist/commands/accept.d.ts +28 -0
- package/dist/commands/accept.d.ts.map +1 -0
- package/dist/commands/accept.js +21 -0
- package/dist/commands/accept.js.map +1 -0
- package/dist/commands/admin.d.ts +32 -0
- package/dist/commands/admin.d.ts.map +1 -0
- package/dist/commands/admin.js +25 -0
- package/dist/commands/admin.js.map +1 -0
- package/dist/commands/cancel.d.ts +19 -1
- package/dist/commands/cancel.d.ts.map +1 -1
- package/dist/commands/cancel.js +1 -1
- package/dist/commands/cancel.js.map +1 -1
- package/dist/commands/check.d.ts +23 -1
- package/dist/commands/check.d.ts.map +1 -1
- package/dist/commands/check.js +21 -4
- package/dist/commands/check.js.map +1 -1
- package/dist/commands/context.d.ts +27 -0
- package/dist/commands/context.d.ts.map +1 -0
- package/dist/commands/context.js +10 -0
- package/dist/commands/context.js.map +1 -0
- package/dist/commands/create.d.ts +40 -0
- package/dist/commands/create.d.ts.map +1 -0
- package/dist/commands/create.js +475 -0
- package/dist/commands/create.js.map +1 -0
- package/dist/commands/deploy.d.ts +28 -8
- package/dist/commands/deploy.d.ts.map +1 -1
- package/dist/commands/deploy.js +30 -18
- package/dist/commands/deploy.js.map +1 -1
- package/dist/commands/dev.d.ts +23 -1
- package/dist/commands/dev.d.ts.map +1 -1
- package/dist/commands/dev.js +28 -4
- package/dist/commands/dev.js.map +1 -1
- package/dist/commands/docs.d.ts +30 -0
- package/dist/commands/docs.d.ts.map +1 -0
- package/dist/commands/docs.js +20 -0
- package/dist/commands/docs.js.map +1 -0
- package/dist/commands/login.d.ts +29 -0
- package/dist/commands/login.d.ts.map +1 -0
- package/dist/commands/{auth/login.js → login.js} +27 -9
- package/dist/commands/login.js.map +1 -0
- package/dist/commands/logs.d.ts +22 -2
- package/dist/commands/logs.d.ts.map +1 -1
- package/dist/commands/logs.js +9 -5
- package/dist/commands/logs.js.map +1 -1
- package/dist/commands/retry.d.ts +19 -1
- package/dist/commands/retry.d.ts.map +1 -1
- package/dist/commands/retry.js +5 -2
- package/dist/commands/retry.js.map +1 -1
- package/dist/commands/rollback.d.ts +23 -4
- package/dist/commands/rollback.d.ts.map +1 -1
- package/dist/commands/rollback.js +18 -5
- package/dist/commands/rollback.js.map +1 -1
- package/dist/commands/skill.d.ts +32 -0
- package/dist/commands/skill.d.ts.map +1 -0
- package/dist/commands/skill.js +50 -0
- package/dist/commands/skill.js.map +1 -0
- package/dist/commands/spec.d.ts +42 -0
- package/dist/commands/spec.d.ts.map +1 -0
- package/dist/commands/spec.js +123 -0
- package/dist/commands/spec.js.map +1 -0
- package/dist/commands/start.d.ts +28 -0
- package/dist/commands/start.d.ts.map +1 -0
- package/dist/commands/start.js +18 -0
- package/dist/commands/start.js.map +1 -0
- package/dist/commands/status.d.ts +20 -1
- package/dist/commands/status.d.ts.map +1 -1
- package/dist/commands/status.js +11 -4
- package/dist/commands/status.js.map +1 -1
- package/dist/commands/stop.d.ts +28 -0
- package/dist/commands/stop.d.ts.map +1 -0
- package/dist/commands/stop.js +18 -0
- package/dist/commands/stop.js.map +1 -0
- package/dist/create-workspace.d.ts +67 -0
- package/dist/create-workspace.d.ts.map +1 -0
- package/dist/create-workspace.js +631 -0
- package/dist/create-workspace.js.map +1 -0
- package/dist/studio-events.d.ts +9 -0
- package/dist/studio-events.d.ts.map +1 -0
- package/dist/studio-events.js +30 -0
- package/dist/studio-events.js.map +1 -0
- package/dist/toolchain-capsule.d.ts +4 -0
- package/dist/toolchain-capsule.d.ts.map +1 -0
- package/dist/toolchain-capsule.js +116 -0
- package/dist/toolchain-capsule.js.map +1 -0
- package/package.json +17 -10
- package/template/.dockerignore +23 -0
- package/template/.env.example +3 -0
- package/template/AGENTS.md +26 -0
- package/template/README.md +45 -0
- package/template/_gitignore +14 -0
- package/template/apps/web/data-api-live.e2e.html +15 -0
- package/template/apps/web/e2e/client-fixture.ts +5 -0
- package/template/apps/web/e2e/component-defaults-fixture.css +15 -0
- package/template/apps/web/e2e/data-api-live-fixture.tsx +162 -0
- package/template/apps/web/e2e/data-api-live.spec.ts +144 -0
- package/template/apps/web/e2e/field-protocol-fixture.tsx +387 -0
- package/template/apps/web/e2e/field-protocol.spec.ts +285 -0
- package/template/apps/web/e2e/mobile-files.spec.ts +96 -0
- package/template/apps/web/e2e/mobile-reference-fixture.tsx +314 -0
- package/template/apps/web/e2e/mobile-reference.spec.ts +360 -0
- package/template/apps/web/e2e/mobile-selection.spec.ts +199 -0
- package/template/apps/web/e2e/resource-experience-fixture.tsx +491 -0
- package/template/apps/web/e2e/resource-platform-mock.ts +202 -0
- package/template/apps/web/e2e/resources.spec.ts +488 -0
- package/template/apps/web/e2e/standard-admin.spec.ts +511 -0
- package/template/apps/web/e2e/workflow-entry-fixture.tsx +107 -0
- package/template/apps/web/e2e/workflow-entry.spec.ts +556 -0
- package/template/apps/web/e2e/workflow-experience-fixture.tsx +338 -0
- package/template/apps/web/e2e/workflow.spec.ts +1265 -0
- package/template/apps/web/field-protocol.e2e.html +22 -0
- package/template/apps/web/index.html +12 -0
- package/template/apps/web/mobile-reference.e2e.html +27 -0
- package/template/apps/web/package.json +34 -0
- package/template/apps/web/playwright.config.ts +47 -0
- package/template/apps/web/resource-experience.e2e.html +16 -0
- package/template/apps/web/scripts/check.mjs +43 -0
- package/template/apps/web/scripts/verify-build.mjs +6 -0
- package/template/apps/web/src/document.css +5 -0
- package/template/apps/web/src/main.tsx +66 -0
- package/template/apps/web/src/user-end/tailwind.css +5 -0
- package/template/apps/web/test/contracts.test.ts +163 -0
- package/template/apps/web/test/loopback.test.ts +68 -0
- package/template/apps/web/test/standard-user-surfaces.typecheck.tsx +27 -0
- package/template/apps/web/tsconfig.json +12 -0
- package/template/apps/web/vite.config.ts +43 -0
- package/template/apps/web/workflow-entry.e2e.html +15 -0
- package/template/apps/web/workflow-experience.e2e.html +15 -0
- package/template/appspec/app.md +52 -0
- package/template/openxiangda.config.ts +55 -0
- package/template/package.json +28 -0
- package/template/packages/contracts/package.json +23 -0
- package/template/packages/contracts/src/generated.ts +265 -0
- package/template/packages/contracts/src/index.ts +1 -0
- package/template/packages/contracts/tsconfig.json +9 -0
- package/template/pnpm-workspace.yaml +7 -0
- package/template/tsconfig.base.json +13 -0
- package/dist/commands/app/create.d.ts +0 -15
- package/dist/commands/app/create.d.ts.map +0 -1
- package/dist/commands/app/create.js +0 -42
- package/dist/commands/app/create.js.map +0 -1
- package/dist/commands/app/info.d.ts +0 -9
- package/dist/commands/app/info.d.ts.map +0 -1
- package/dist/commands/app/info.js +0 -10
- package/dist/commands/app/info.js.map +0 -1
- package/dist/commands/app/link.d.ts +0 -10
- package/dist/commands/app/link.d.ts.map +0 -1
- package/dist/commands/app/link.js +0 -16
- package/dist/commands/app/link.js.map +0 -1
- package/dist/commands/app/provision.d.ts +0 -9
- package/dist/commands/app/provision.d.ts.map +0 -1
- package/dist/commands/app/provision.js +0 -10
- package/dist/commands/app/provision.js.map +0 -1
- package/dist/commands/auth/login.d.ts +0 -11
- package/dist/commands/auth/login.d.ts.map +0 -1
- package/dist/commands/auth/login.js.map +0 -1
- package/dist/commands/auth/logout.d.ts +0 -6
- package/dist/commands/auth/logout.d.ts.map +0 -1
- package/dist/commands/auth/logout.js +0 -30
- package/dist/commands/auth/logout.js.map +0 -1
- package/dist/commands/auth/status.d.ts +0 -6
- package/dist/commands/auth/status.d.ts.map +0 -1
- package/dist/commands/auth/status.js +0 -60
- package/dist/commands/auth/status.js.map +0 -1
- package/dist/commands/build.d.ts +0 -11
- package/dist/commands/build.d.ts.map +0 -1
- package/dist/commands/build.js +0 -23
- package/dist/commands/build.js.map +0 -1
- package/dist/commands/doctor.d.ts +0 -9
- package/dist/commands/doctor.d.ts.map +0 -1
- package/dist/commands/doctor.js +0 -7
- package/dist/commands/doctor.js.map +0 -1
- package/dist/commands/event/delivery/list.d.ts +0 -10
- package/dist/commands/event/delivery/list.d.ts.map +0 -1
- package/dist/commands/event/delivery/list.js +0 -14
- package/dist/commands/event/delivery/list.js.map +0 -1
- package/dist/commands/event/delivery/replay.d.ts +0 -13
- package/dist/commands/event/delivery/replay.d.ts.map +0 -1
- package/dist/commands/event/delivery/replay.js +0 -16
- package/dist/commands/event/delivery/replay.js.map +0 -1
- package/dist/commands/event/subscription/list.d.ts +0 -9
- package/dist/commands/event/subscription/list.d.ts.map +0 -1
- package/dist/commands/event/subscription/list.js +0 -10
- package/dist/commands/event/subscription/list.js.map +0 -1
- package/dist/commands/event/subscription/rotate-secret.d.ts +0 -15
- package/dist/commands/event/subscription/rotate-secret.d.ts.map +0 -1
- package/dist/commands/event/subscription/rotate-secret.js +0 -33
- package/dist/commands/event/subscription/rotate-secret.js.map +0 -1
- package/dist/commands/event/subscription/status.d.ts +0 -14
- package/dist/commands/event/subscription/status.d.ts.map +0 -1
- package/dist/commands/event/subscription/status.js +0 -19
- package/dist/commands/event/subscription/status.js.map +0 -1
- package/dist/commands/event/timer/list.d.ts +0 -9
- package/dist/commands/event/timer/list.d.ts.map +0 -1
- package/dist/commands/event/timer/list.js +0 -10
- package/dist/commands/event/timer/list.js.map +0 -1
- package/dist/commands/event/timer/status.d.ts +0 -14
- package/dist/commands/event/timer/status.d.ts.map +0 -1
- package/dist/commands/event/timer/status.js +0 -19
- package/dist/commands/event/timer/status.js.map +0 -1
- package/dist/commands/generate.d.ts +0 -10
- package/dist/commands/generate.d.ts.map +0 -1
- package/dist/commands/generate.js +0 -8
- package/dist/commands/generate.js.map +0 -1
- package/dist/commands/oauth/audit/list.d.ts +0 -12
- package/dist/commands/oauth/audit/list.d.ts.map +0 -1
- package/dist/commands/oauth/audit/list.js +0 -20
- package/dist/commands/oauth/audit/list.js.map +0 -1
- package/dist/commands/oauth/client/create.d.ts +0 -13
- package/dist/commands/oauth/client/create.d.ts.map +0 -1
- package/dist/commands/oauth/client/create.js +0 -34
- package/dist/commands/oauth/client/create.js.map +0 -1
- package/dist/commands/oauth/client/list.d.ts +0 -9
- package/dist/commands/oauth/client/list.d.ts.map +0 -1
- package/dist/commands/oauth/client/list.js +0 -10
- package/dist/commands/oauth/client/list.js.map +0 -1
- package/dist/commands/oauth/client/revoke.d.ts +0 -12
- package/dist/commands/oauth/client/revoke.d.ts.map +0 -1
- package/dist/commands/oauth/client/revoke.js +0 -12
- package/dist/commands/oauth/client/revoke.js.map +0 -1
- package/dist/commands/oauth/client/rotate.d.ts +0 -13
- package/dist/commands/oauth/client/rotate.d.ts.map +0 -1
- package/dist/commands/oauth/client/rotate.js +0 -20
- package/dist/commands/oauth/client/rotate.js.map +0 -1
- package/dist/commands/oauth/client/update.d.ts +0 -15
- package/dist/commands/oauth/client/update.d.ts.map +0 -1
- package/dist/commands/oauth/client/update.js +0 -23
- package/dist/commands/oauth/client/update.js.map +0 -1
- package/dist/commands/oauth/runtime/rotate.d.ts +0 -12
- package/dist/commands/oauth/runtime/rotate.d.ts.map +0 -1
- package/dist/commands/oauth/runtime/rotate.js +0 -31
- package/dist/commands/oauth/runtime/rotate.js.map +0 -1
- package/dist/commands/oauth/runtime/status.d.ts +0 -10
- package/dist/commands/oauth/runtime/status.d.ts.map +0 -1
- package/dist/commands/oauth/runtime/status.js +0 -17
- package/dist/commands/oauth/runtime/status.js.map +0 -1
- package/dist/commands/promote.d.ts +0 -13
- package/dist/commands/promote.d.ts.map +0 -1
- package/dist/commands/promote.js +0 -9
- package/dist/commands/promote.js.map +0 -1
- package/dist/commands/secret/audit/list.d.ts +0 -14
- package/dist/commands/secret/audit/list.d.ts.map +0 -1
- package/dist/commands/secret/audit/list.js +0 -16
- package/dist/commands/secret/audit/list.js.map +0 -1
- package/dist/commands/secret/create.d.ts +0 -18
- package/dist/commands/secret/create.d.ts.map +0 -1
- package/dist/commands/secret/create.js +0 -33
- package/dist/commands/secret/create.js.map +0 -1
- package/dist/commands/secret/delete.d.ts +0 -15
- package/dist/commands/secret/delete.d.ts.map +0 -1
- package/dist/commands/secret/delete.js +0 -20
- package/dist/commands/secret/delete.js.map +0 -1
- package/dist/commands/secret/list.d.ts +0 -10
- package/dist/commands/secret/list.d.ts.map +0 -1
- package/dist/commands/secret/list.js +0 -14
- package/dist/commands/secret/list.js.map +0 -1
- package/dist/commands/secret/rotate.d.ts +0 -18
- package/dist/commands/secret/rotate.d.ts.map +0 -1
- package/dist/commands/secret/rotate.js +0 -30
- package/dist/commands/secret/rotate.js.map +0 -1
- package/dist/commands/secret/update.d.ts +0 -17
- package/dist/commands/secret/update.d.ts.map +0 -1
- package/dist/commands/secret/update.js +0 -37
- package/dist/commands/secret/update.js.map +0 -1
- package/dist/commands/skill/install.d.ts +0 -11
- package/dist/commands/skill/install.d.ts.map +0 -1
- package/dist/commands/skill/install.js +0 -52
- package/dist/commands/skill/install.js.map +0 -1
- package/dist/commands/skill/validate.d.ts +0 -9
- package/dist/commands/skill/validate.d.ts.map +0 -1
- package/dist/commands/skill/validate.js +0 -32
- package/dist/commands/skill/validate.js.map +0 -1
- package/dist/commands/test.d.ts +0 -9
- package/dist/commands/test.d.ts.map +0 -1
- package/dist/commands/test.js +0 -7
- package/dist/commands/test.js.map +0 -1
- package/dist/commands/workflow/provider/list.d.ts +0 -10
- package/dist/commands/workflow/provider/list.d.ts.map +0 -1
- package/dist/commands/workflow/provider/list.js +0 -14
- package/dist/commands/workflow/provider/list.js.map +0 -1
- package/dist/commands/workflow/provider/rotate.d.ts +0 -15
- package/dist/commands/workflow/provider/rotate.d.ts.map +0 -1
- package/dist/commands/workflow/provider/rotate.js +0 -24
- package/dist/commands/workflow/provider/rotate.js.map +0 -1
- package/dist/secret-value.d.ts +0 -5
- package/dist/secret-value.d.ts.map +0 -1
- package/dist/secret-value.js +0 -15
- package/dist/secret-value.js.map +0 -1
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema: openxiangda.appspec/app/v1
|
|
3
|
+
app: "openxiangda-application"
|
|
4
|
+
title: "OpenXiangda 应用"
|
|
5
|
+
status: active
|
|
6
|
+
---
|
|
7
|
+
# OpenXiangda 应用
|
|
8
|
+
|
|
9
|
+
本文件保存当前有效目标与设计约束。正式变更关联 ChangeSpec;测试发布前核对设计与验收计划,生产晋级前核对实际验收。资源、字段、权限和动作的实现以
|
|
10
|
+
`openxiangda.config.ts` 与实时编译合同为准。
|
|
11
|
+
|
|
12
|
+
## 业务目标
|
|
13
|
+
|
|
14
|
+
<!-- 用业务语言说明应用解决的问题和可观察结果。 -->
|
|
15
|
+
|
|
16
|
+
## 角色
|
|
17
|
+
|
|
18
|
+
<!-- 只记录业务角色及其目标;稳定 role code 在能力规格中引用。 -->
|
|
19
|
+
|
|
20
|
+
## 范围
|
|
21
|
+
|
|
22
|
+
### 包含
|
|
23
|
+
|
|
24
|
+
### 不包含
|
|
25
|
+
|
|
26
|
+
## 能力目录
|
|
27
|
+
|
|
28
|
+
<!-- 复杂业务再在 capabilities/ 下增加 CAP-*;简单应用的稳定规则直接写在本文件。 -->
|
|
29
|
+
|
|
30
|
+
## 术语
|
|
31
|
+
|
|
32
|
+
## 跨能力约束
|
|
33
|
+
|
|
34
|
+
## 架构与数据关系
|
|
35
|
+
|
|
36
|
+
<!-- 写明领域边界、核心模型关系、平台能力与自定义动作的归属、状态转换与不变量。 -->
|
|
37
|
+
|
|
38
|
+
## 业务任务与页面
|
|
39
|
+
|
|
40
|
+
<!-- 按用户任务规划管理端、PC、移动入口与数据关系;辅助表不必有页面。 -->
|
|
41
|
+
|
|
42
|
+
## 权限矩阵与确认
|
|
43
|
+
|
|
44
|
+
<!-- 记录角色、页面、操作、行范围、字段和多角色组合;写明需求依据与未明确的边界。 -->
|
|
45
|
+
|
|
46
|
+
## 性能与容量预算
|
|
47
|
+
|
|
48
|
+
<!-- 记录数据量及增长、并发、分页与索引、请求次数、延迟目标和测量口径;区分估算、目标与实测。 -->
|
|
49
|
+
|
|
50
|
+
## 未确认问题
|
|
51
|
+
|
|
52
|
+
- 无。
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { defineAdminNavigation, defineOpenXiangdaApp } from 'openxiangda/config';
|
|
2
|
+
|
|
3
|
+
/** Start with business modules; select standard CRUD only for the models that need it. */
|
|
4
|
+
export default defineOpenXiangdaApp({
|
|
5
|
+
app: { code: 'openxiangda-application', name: 'OpenXiangda 应用' },
|
|
6
|
+
frontend: {
|
|
7
|
+
root: 'apps/web',
|
|
8
|
+
devicePolicy: {
|
|
9
|
+
kind: 'viewport-family',
|
|
10
|
+
mobileMaxWidthPx: 900,
|
|
11
|
+
desktopMinWidthPx: 901,
|
|
12
|
+
},
|
|
13
|
+
routes: [
|
|
14
|
+
{
|
|
15
|
+
code: 'application-home',
|
|
16
|
+
path: '/home',
|
|
17
|
+
label: '应用首页',
|
|
18
|
+
surface: 'user',
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
code: 'application-home-mobile',
|
|
22
|
+
path: '/m/home',
|
|
23
|
+
label: '移动首页',
|
|
24
|
+
surface: 'user',
|
|
25
|
+
},
|
|
26
|
+
],
|
|
27
|
+
authentication: {
|
|
28
|
+
accountMode: 'existing-platform-users-only',
|
|
29
|
+
registration: { mode: 'reject' },
|
|
30
|
+
methods: [
|
|
31
|
+
{
|
|
32
|
+
code: 'password',
|
|
33
|
+
type: 'password',
|
|
34
|
+
label: '账号密码登录',
|
|
35
|
+
presentation: 'primary',
|
|
36
|
+
required: true,
|
|
37
|
+
},
|
|
38
|
+
],
|
|
39
|
+
surfaces: {
|
|
40
|
+
desktop: {
|
|
41
|
+
routeCode: 'application-login',
|
|
42
|
+
path: '/login',
|
|
43
|
+
defaultRouteCode: 'application-home',
|
|
44
|
+
},
|
|
45
|
+
mobile: {
|
|
46
|
+
routeCode: 'application-login-mobile',
|
|
47
|
+
path: '/m/login',
|
|
48
|
+
defaultRouteCode: 'application-home-mobile',
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
admin: { navigation: defineAdminNavigation([]) },
|
|
53
|
+
},
|
|
54
|
+
modules: [],
|
|
55
|
+
});
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "openxiangda-application",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"private": true,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"packageManager": "pnpm@10.15.1",
|
|
7
|
+
"engines": {
|
|
8
|
+
"node": ">=22.12"
|
|
9
|
+
},
|
|
10
|
+
"scripts": {
|
|
11
|
+
"openxiangda": "openxiangda",
|
|
12
|
+
"prepare": "pnpm workspace:build",
|
|
13
|
+
"workspace:build": "pnpm --filter @app/contracts build",
|
|
14
|
+
"predev": "pnpm workspace:build",
|
|
15
|
+
"dev": "openxiangda dev",
|
|
16
|
+
"dev:web": "pnpm --filter @app/web dev",
|
|
17
|
+
"precheck": "pnpm workspace:build",
|
|
18
|
+
"check": "pnpm --recursive check",
|
|
19
|
+
"pretest": "pnpm workspace:build",
|
|
20
|
+
"test": "pnpm --recursive test",
|
|
21
|
+
"test:e2e": "pnpm --filter @app/web test:e2e",
|
|
22
|
+
"build": "pnpm --recursive build"
|
|
23
|
+
},
|
|
24
|
+
"devDependencies": {
|
|
25
|
+
"openxiangda": "2.0.0-alpha.110",
|
|
26
|
+
"typescript": "5.9.3"
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@app/contracts",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"private": true,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/index.js",
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"types": "./dist/index.d.ts",
|
|
11
|
+
"openxiangda-source": "./src/index.ts",
|
|
12
|
+
"import": "./dist/index.js"
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"scripts": {
|
|
16
|
+
"check": "tsc -p tsconfig.json --noEmit",
|
|
17
|
+
"test": "node -e \"process.stdout.write('generated contracts checked by TypeScript\\n')\"",
|
|
18
|
+
"build": "tsc -p tsconfig.json"
|
|
19
|
+
},
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"typescript": "5.9.3"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
// Generated by OpenXiangda 2.0 Native compiler. Do not edit by hand.
|
|
2
|
+
export const compilerContractVersion = "native-4" as const;
|
|
3
|
+
export const appCode = "openxiangda-application" as const;
|
|
4
|
+
export const appName = "OpenXiangda 应用" as const;
|
|
5
|
+
export const appPerspectives = [] as const;
|
|
6
|
+
export const resourceCodes = [] as const;
|
|
7
|
+
export const resourceSurfaces = {} as const;
|
|
8
|
+
export const resourceDefinitions = {} as const;
|
|
9
|
+
export const capabilities = [
|
|
10
|
+
"app:openxiangda-application:directory:read",
|
|
11
|
+
"app:role:assign",
|
|
12
|
+
"app:role:define",
|
|
13
|
+
"app:role:grant-capability",
|
|
14
|
+
"app:role:read",
|
|
15
|
+
"app:scope-grant:manage",
|
|
16
|
+
"app:super-admin:manage"
|
|
17
|
+
] as const;
|
|
18
|
+
export const appOperations = {} as const;
|
|
19
|
+
export const appRoutes = {
|
|
20
|
+
applicationHome: {
|
|
21
|
+
"code": "application-home",
|
|
22
|
+
"path": "/home",
|
|
23
|
+
"label": "应用首页",
|
|
24
|
+
"surface": "user",
|
|
25
|
+
"tabPersistence": "session",
|
|
26
|
+
"keepAlive": "none"
|
|
27
|
+
},
|
|
28
|
+
applicationHomeMobile: {
|
|
29
|
+
"code": "application-home-mobile",
|
|
30
|
+
"path": "/m/home",
|
|
31
|
+
"label": "移动首页",
|
|
32
|
+
"surface": "user",
|
|
33
|
+
"tabPersistence": "session",
|
|
34
|
+
"keepAlive": "none"
|
|
35
|
+
}
|
|
36
|
+
} as const;
|
|
37
|
+
export const authenticationMethods = [
|
|
38
|
+
{
|
|
39
|
+
"code": "password",
|
|
40
|
+
"type": "password",
|
|
41
|
+
"label": "账号密码登录",
|
|
42
|
+
"presentation": "primary",
|
|
43
|
+
"required": true
|
|
44
|
+
}
|
|
45
|
+
] as const;
|
|
46
|
+
export const authenticationSurfaces = {
|
|
47
|
+
applicationLogin: {
|
|
48
|
+
"device": "desktop",
|
|
49
|
+
"routeCode": "application-login",
|
|
50
|
+
"path": "/login",
|
|
51
|
+
"defaultRouteCode": "application-home"
|
|
52
|
+
},
|
|
53
|
+
applicationLoginMobile: {
|
|
54
|
+
"device": "mobile",
|
|
55
|
+
"routeCode": "application-login-mobile",
|
|
56
|
+
"path": "/m/login",
|
|
57
|
+
"defaultRouteCode": "application-home-mobile"
|
|
58
|
+
}
|
|
59
|
+
} as const;
|
|
60
|
+
export const applicationAuthentication = {
|
|
61
|
+
"accountMode": "existing-platform-users-only",
|
|
62
|
+
"registration": {
|
|
63
|
+
"mode": "reject"
|
|
64
|
+
},
|
|
65
|
+
"methods": [
|
|
66
|
+
{
|
|
67
|
+
"code": "password",
|
|
68
|
+
"type": "password",
|
|
69
|
+
"label": "账号密码登录",
|
|
70
|
+
"presentation": "primary",
|
|
71
|
+
"required": true
|
|
72
|
+
}
|
|
73
|
+
],
|
|
74
|
+
"surfaces": {
|
|
75
|
+
"desktop": {
|
|
76
|
+
"routeCode": "application-login",
|
|
77
|
+
"path": "/login",
|
|
78
|
+
"defaultRouteCode": "application-home"
|
|
79
|
+
},
|
|
80
|
+
"mobile": {
|
|
81
|
+
"routeCode": "application-login-mobile",
|
|
82
|
+
"path": "/m/login",
|
|
83
|
+
"defaultRouteCode": "application-home-mobile"
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
} as const;
|
|
87
|
+
export const anonymousPublicAccess = undefined;
|
|
88
|
+
export const platformAuthManifest = {
|
|
89
|
+
"schemaVersion": "openxiangda.platform-auth-manifest/v2",
|
|
90
|
+
"appCode": "openxiangda-application",
|
|
91
|
+
"protectedUserRouteCount": 2,
|
|
92
|
+
"methods": [
|
|
93
|
+
{
|
|
94
|
+
"code": "password",
|
|
95
|
+
"type": "password",
|
|
96
|
+
"label": "账号密码登录",
|
|
97
|
+
"presentation": "primary",
|
|
98
|
+
"required": true
|
|
99
|
+
}
|
|
100
|
+
],
|
|
101
|
+
"surfaces": [
|
|
102
|
+
{
|
|
103
|
+
"device": "desktop",
|
|
104
|
+
"routeCode": "application-login",
|
|
105
|
+
"path": "/login",
|
|
106
|
+
"defaultRouteCode": "application-home"
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
"device": "mobile",
|
|
110
|
+
"routeCode": "application-login-mobile",
|
|
111
|
+
"path": "/m/login",
|
|
112
|
+
"defaultRouteCode": "application-home-mobile"
|
|
113
|
+
}
|
|
114
|
+
]
|
|
115
|
+
} as const;
|
|
116
|
+
export const adminAccess = undefined;
|
|
117
|
+
export const routeManifest = {
|
|
118
|
+
"schemaVersion": "openxiangda.application-route-manifest/v3",
|
|
119
|
+
"appCode": "openxiangda-application",
|
|
120
|
+
"devicePolicy": {
|
|
121
|
+
"kind": "viewport-family",
|
|
122
|
+
"mobileMaxWidthPx": 900,
|
|
123
|
+
"desktopMinWidthPx": 901
|
|
124
|
+
},
|
|
125
|
+
"rootEntry": {
|
|
126
|
+
"code": "application-home",
|
|
127
|
+
"desktop": "/home",
|
|
128
|
+
"mobile": "/m/home"
|
|
129
|
+
},
|
|
130
|
+
"authentication": {
|
|
131
|
+
"desktop": {
|
|
132
|
+
"routeCode": "application-login",
|
|
133
|
+
"path": "/login"
|
|
134
|
+
},
|
|
135
|
+
"mobile": {
|
|
136
|
+
"routeCode": "application-login-mobile",
|
|
137
|
+
"path": "/m/login"
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
"routes": [],
|
|
141
|
+
"digest": "2c01252ac4415de49a2fe58bf21df94a77f8c235d739ec7a6af583fc695ba0cf"
|
|
142
|
+
} as const;
|
|
143
|
+
export const adminPages = [] as const;
|
|
144
|
+
export const adminNavigation = [] as const;
|
|
145
|
+
export const eventTypes = [] as const;
|
|
146
|
+
export const eventSubscriptionCodes = [] as const;
|
|
147
|
+
export const eventHandlerManifest = {
|
|
148
|
+
"schemaVersion": "openxiangda.event-handler-manifest/v2",
|
|
149
|
+
"appCode": "openxiangda-application",
|
|
150
|
+
"handlers": []
|
|
151
|
+
} as const;
|
|
152
|
+
export const eventHandlers = {} as const;
|
|
153
|
+
export const eventSchemas = [] as const;
|
|
154
|
+
export const workflowCodes = [] as const;
|
|
155
|
+
export const workflowDefinitions = [] as const;
|
|
156
|
+
export const notificationTemplateCodes = {
|
|
157
|
+
applicationInformational: "application.informational.standard",
|
|
158
|
+
} as const;
|
|
159
|
+
|
|
160
|
+
export type ResourceCode = (typeof resourceCodes)[number];
|
|
161
|
+
export type Capability = (typeof capabilities)[number];
|
|
162
|
+
export type AppOperation = (typeof appOperations)[keyof typeof appOperations];
|
|
163
|
+
export type AppRoute = (typeof appRoutes)[keyof typeof appRoutes];
|
|
164
|
+
export type AppRouteCode = AppRoute["code"];
|
|
165
|
+
export type ApplicationAuthenticationMethod = (typeof authenticationMethods)[number];
|
|
166
|
+
export type ApplicationAuthenticationSurface = (typeof authenticationSurfaces)[keyof typeof authenticationSurfaces];
|
|
167
|
+
export type ApplicationAuthenticationSurfaceCode = ApplicationAuthenticationSurface["routeCode"];
|
|
168
|
+
export type AnonymousPublicAccess = typeof anonymousPublicAccess;
|
|
169
|
+
export type AdminAccess = typeof adminAccess;
|
|
170
|
+
export type RouteManifest = typeof routeManifest;
|
|
171
|
+
export type AdminPage = (typeof adminPages)[number];
|
|
172
|
+
export type AdminNavigationGroup = (typeof adminNavigation)[number];
|
|
173
|
+
export type AppPerspective = (typeof appPerspectives)[number];
|
|
174
|
+
export type EventType = (typeof eventTypes)[number];
|
|
175
|
+
export type EventSubscriptionCode = (typeof eventSubscriptionCodes)[number];
|
|
176
|
+
export type EventTypesForSubscription<TCode extends EventSubscriptionCode> = never;
|
|
177
|
+
export type WorkflowCode = (typeof workflowCodes)[number];
|
|
178
|
+
export type NotificationTemplateCode = (typeof notificationTemplateCodes)[keyof typeof notificationTemplateCodes];
|
|
179
|
+
|
|
180
|
+
export interface OpenXiangdaCloudEvent<TType extends EventType = EventType, TData extends Record<string, unknown> = Record<string, unknown>> {
|
|
181
|
+
specversion: "1.0";
|
|
182
|
+
id: string;
|
|
183
|
+
source: string;
|
|
184
|
+
type: TType;
|
|
185
|
+
subject?: string;
|
|
186
|
+
time: string;
|
|
187
|
+
datacontenttype: "application/json";
|
|
188
|
+
dataschema?: string;
|
|
189
|
+
data: TData;
|
|
190
|
+
tenantid: string;
|
|
191
|
+
appcode: typeof appCode;
|
|
192
|
+
environment: string;
|
|
193
|
+
traceid?: string;
|
|
194
|
+
schemaversion: string;
|
|
195
|
+
}
|
|
196
|
+
export type EventHandlerInput<TCode extends EventSubscriptionCode> = OpenXiangdaCloudEvent<EventTypesForSubscription<TCode>>;
|
|
197
|
+
|
|
198
|
+
export interface LabeledValue {
|
|
199
|
+
label: string;
|
|
200
|
+
value: string;
|
|
201
|
+
description?: string;
|
|
202
|
+
color?: string;
|
|
203
|
+
}
|
|
204
|
+
export interface ResourceReferenceValue extends LabeledValue {
|
|
205
|
+
resourceCode: string;
|
|
206
|
+
snapshot?: Record<string, unknown>;
|
|
207
|
+
}
|
|
208
|
+
export interface DepartmentReferenceValue extends LabeledValue {
|
|
209
|
+
fullPath?: string;
|
|
210
|
+
path?: LabeledValue[];
|
|
211
|
+
parent?: LabeledValue;
|
|
212
|
+
}
|
|
213
|
+
export interface UserReferenceValue extends LabeledValue {
|
|
214
|
+
avatarUrl?: string;
|
|
215
|
+
employeeNo?: string;
|
|
216
|
+
title?: string;
|
|
217
|
+
mobile?: string;
|
|
218
|
+
email?: string;
|
|
219
|
+
departments?: DepartmentReferenceValue[];
|
|
220
|
+
}
|
|
221
|
+
export interface DateRangeValue { start: string; end: string; }
|
|
222
|
+
export type CascadePathValue = LabeledValue[];
|
|
223
|
+
export interface DataFileRef {
|
|
224
|
+
schemaVersion: 'openxiangda.data-file-ref/v2';
|
|
225
|
+
id: string;
|
|
226
|
+
name: string;
|
|
227
|
+
size: number;
|
|
228
|
+
contentType: string;
|
|
229
|
+
}
|
|
230
|
+
export interface DataImageRef extends DataFileRef {
|
|
231
|
+
width: number;
|
|
232
|
+
height: number;
|
|
233
|
+
thumbnailUrl: string;
|
|
234
|
+
previewUrl: string;
|
|
235
|
+
}
|
|
236
|
+
export interface StableSignatureValue {
|
|
237
|
+
file: Omit<DataFileRef, 'schemaVersion'>;
|
|
238
|
+
signer?: UserReferenceValue;
|
|
239
|
+
signedAt: string;
|
|
240
|
+
points?: Array<{ x: number; y: number; t: number }>;
|
|
241
|
+
hash: string;
|
|
242
|
+
}
|
|
243
|
+
export interface StableAddressValue {
|
|
244
|
+
country?: LabeledValue;
|
|
245
|
+
province?: LabeledValue;
|
|
246
|
+
city?: LabeledValue;
|
|
247
|
+
district?: LabeledValue;
|
|
248
|
+
street?: LabeledValue;
|
|
249
|
+
detail?: string;
|
|
250
|
+
fullAddress?: string;
|
|
251
|
+
}
|
|
252
|
+
export interface StableLocationSnapshot {
|
|
253
|
+
address?: string;
|
|
254
|
+
name?: string;
|
|
255
|
+
province?: string;
|
|
256
|
+
city?: string;
|
|
257
|
+
district?: string;
|
|
258
|
+
accuracy?: number;
|
|
259
|
+
capturedAt?: string;
|
|
260
|
+
}
|
|
261
|
+
export type StableLocationValue = StableLocationSnapshot & {
|
|
262
|
+
source: 'browser' | 'dingTalk';
|
|
263
|
+
longitude: number;
|
|
264
|
+
latitude: number;
|
|
265
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './generated.js';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2022",
|
|
4
|
+
"module": "NodeNext",
|
|
5
|
+
"moduleResolution": "NodeNext",
|
|
6
|
+
"strict": true,
|
|
7
|
+
"noUncheckedIndexedAccess": true,
|
|
8
|
+
"exactOptionalPropertyTypes": true,
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
"experimentalDecorators": true,
|
|
11
|
+
"emitDecoratorMetadata": true
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand } from "../../base.js";
|
|
2
|
-
export default class AppCreate extends OpenXiangdaCommand {
|
|
3
|
-
static summary: string;
|
|
4
|
-
static args: {
|
|
5
|
-
directory: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
6
|
-
};
|
|
7
|
-
static flags: {
|
|
8
|
-
"app-code": import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
9
|
-
name: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
|
-
install: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
11
|
-
"local-sdk": import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
12
|
-
};
|
|
13
|
-
run(): Promise<import("openxiangda-contracts").DevkitResult<unknown>>;
|
|
14
|
-
}
|
|
15
|
-
//# sourceMappingURL=create.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/commands/app/create.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,kBAAkB;IACvD,MAAM,CAAC,OAAO,SAA+B;IAC7C,MAAM,CAAC,IAAI;;MAAkD;IAC7D,MAAM,CAAC,KAAK;;;;;MAOV;IAEI,GAAG;CA0BV"}
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { Args, Flags } from "@oclif/core";
|
|
2
|
-
import { createWorkspace } from "create-openxiangda";
|
|
3
|
-
import { OpenXiangdaCommand } from "../../base.js";
|
|
4
|
-
export default class AppCreate extends OpenXiangdaCommand {
|
|
5
|
-
static summary = "从官方模板创建 React + NestJS 应用";
|
|
6
|
-
static args = { directory: Args.string({ required: true }) };
|
|
7
|
-
static flags = {
|
|
8
|
-
"app-code": Flags.string({ required: true, summary: "稳定应用代码" }),
|
|
9
|
-
name: Flags.string({ required: true, summary: "应用名称" }),
|
|
10
|
-
install: Flags.boolean({ summary: "创建后安装依赖" }),
|
|
11
|
-
"local-sdk": Flags.string({
|
|
12
|
-
summary: "使用本地 OpenXiangda 2.0 源码包,不经过 npm 发布",
|
|
13
|
-
}),
|
|
14
|
-
};
|
|
15
|
-
async run() {
|
|
16
|
-
const { args, flags } = await this.parse(AppCreate);
|
|
17
|
-
const data = await createWorkspace({
|
|
18
|
-
directory: args.directory,
|
|
19
|
-
appCode: flags["app-code"],
|
|
20
|
-
name: flags.name,
|
|
21
|
-
install: flags.install,
|
|
22
|
-
...(flags["local-sdk"]
|
|
23
|
-
? { localSdkRoot: flags["local-sdk"] }
|
|
24
|
-
: {}),
|
|
25
|
-
});
|
|
26
|
-
return this.present({
|
|
27
|
-
ok: true,
|
|
28
|
-
operation: "app.create",
|
|
29
|
-
workspace: { appCode: data.appCode, name: data.name, root: data.root },
|
|
30
|
-
data,
|
|
31
|
-
diagnostics: [],
|
|
32
|
-
nextActions: [
|
|
33
|
-
{
|
|
34
|
-
code: "check",
|
|
35
|
-
label: "检查应用",
|
|
36
|
-
command: `cd ${data.root} && openxiangda check`,
|
|
37
|
-
},
|
|
38
|
-
],
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
//# sourceMappingURL=create.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../../src/commands/app/create.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,E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,CAAC;QACH,OAAO,IAAI,CAAC,OAAO,CAAC;YAClB,EAAE,EAAE,IAAI;YACR,SAAS,EAAE,YAAY;YACvB,SAAS,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE;YACtE,IAAI;YACJ,WAAW,EAAE,EAAE;YACf,WAAW,EAAE;gBACX;oBACE,IAAI,EAAE,OAAO;oBACb,KAAK,EAAE,MAAM;oBACb,OAAO,EAAE,MAAM,IAAI,CAAC,IAAI,uBAAuB;iBAChD;aACF;SACF,CAAC,CAAC;IACL,CAAC"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand } from '../../base.js';
|
|
2
|
-
export default class AppInfo extends OpenXiangdaCommand {
|
|
3
|
-
static summary: string;
|
|
4
|
-
static flags: {
|
|
5
|
-
cwd: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
6
|
-
};
|
|
7
|
-
run(): Promise<import("openxiangda-contracts").DevkitResult<unknown>>;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=info.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"info.d.ts","sourceRoot":"","sources":["../../../src/commands/app/info.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAkB,MAAM,eAAe,CAAC;AAEnE,MAAM,CAAC,OAAO,OAAO,OAAQ,SAAQ,kBAAkB;IACrD,MAAM,CAAC,OAAO,SAAqB;IACnC,MAAM,CAAC,KAAK;;MAAkB;IACxB,GAAG;CAIV"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand, workspaceFlags } from '../../base.js';
|
|
2
|
-
export default class AppInfo extends OpenXiangdaCommand {
|
|
3
|
-
static summary = '读取 2.0 应用工作区上下文';
|
|
4
|
-
static flags = workspaceFlags;
|
|
5
|
-
async run() {
|
|
6
|
-
const { flags } = await this.parse(AppInfo);
|
|
7
|
-
return this.present(await this.services.workspaceContext(flags.cwd));
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=info.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"info.js","sourceRoot":"","sources":["../../../src/commands/app/info.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAEnE,MAAM,CAAC,OAAO,OAAO,OAAQ,SAAQ,kBAAkB;IACrD,MAAM,CAAC,OAAO,GAAG,iBAAiB,CAAC;IACnC,MAAM,CAAC,KAAK,GAAG,cAAc,CAAC;IAC9B,KAAK,CAAC,GAAG;QACP,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC5C,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,IAAI,CAAC,QAAQ,CAAC,gBAAgB,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;IACvE,CAAC"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand } from '../../base.js';
|
|
2
|
-
export default class AppLink extends OpenXiangdaCommand {
|
|
3
|
-
static summary: string;
|
|
4
|
-
static flags: {
|
|
5
|
-
'base-url': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
6
|
-
cwd: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
7
|
-
};
|
|
8
|
-
run(): Promise<import("openxiangda-contracts").DevkitResult<unknown>>;
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=link.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"link.d.ts","sourceRoot":"","sources":["../../../src/commands/app/link.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,kBAAkB,EAAkB,MAAM,eAAe,CAAC;AAEnE,MAAM,CAAC,OAAO,OAAO,OAAQ,SAAQ,kBAAkB;IACrD,MAAM,CAAC,OAAO,SAAiB;IAC/B,MAAM,CAAC,KAAK;;;MAGV;IAEI,GAAG;CAQV"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { Flags } from '@oclif/core';
|
|
2
|
-
import { OpenXiangdaCommand, workspaceFlags } from '../../base.js';
|
|
3
|
-
export default class AppLink extends OpenXiangdaCommand {
|
|
4
|
-
static summary = '绑定 2.0 平台地址';
|
|
5
|
-
static flags = {
|
|
6
|
-
...workspaceFlags,
|
|
7
|
-
'base-url': Flags.string({ required: true }),
|
|
8
|
-
};
|
|
9
|
-
async run() {
|
|
10
|
-
const { flags } = await this.parse(AppLink);
|
|
11
|
-
return this.present(await this.services.linkApplication(flags.cwd, {
|
|
12
|
-
baseUrl: flags['base-url'],
|
|
13
|
-
}));
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
//# sourceMappingURL=link.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"link.js","sourceRoot":"","sources":["../../../src/commands/app/link.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAEnE,MAAM,CAAC,OAAO,OAAO,OAAQ,SAAQ,kBAAkB;IACrD,MAAM,CAAC,OAAO,GAAG,aAAa,CAAC;IAC/B,MAAM,CAAC,KAAK,GAAG;QACb,GAAG,cAAc;QACjB,UAAU,EAAE,KAAK,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;KAC7C,CAAC;IAEF,KAAK,CAAC,GAAG;QACP,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC5C,OAAO,IAAI,CAAC,OAAO,CACjB,MAAM,IAAI,CAAC,QAAQ,CAAC,eAAe,CAAC,KAAK,CAAC,GAAG,EAAE;YAC7C,OAAO,EAAE,KAAK,CAAC,UAAU,CAAC;SAC3B,CAAC,CACH,CAAC;IACJ,CAAC"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand } from "../../base.js";
|
|
2
|
-
export default class AppProvision extends OpenXiangdaCommand {
|
|
3
|
-
static summary: string;
|
|
4
|
-
static flags: {
|
|
5
|
-
cwd: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
6
|
-
};
|
|
7
|
-
run(): Promise<import("openxiangda-contracts").DevkitResult<unknown>>;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=provision.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"provision.d.ts","sourceRoot":"","sources":["../../../src/commands/app/provision.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAkB,MAAM,eAAe,CAAC;AAEnE,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,kBAAkB;IAC1D,MAAM,CAAC,OAAO,SAAsB;IACpC,MAAM,CAAC,KAAK;;MAAkB;IAExB,GAAG;CAIV"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand, workspaceFlags } from "../../base.js";
|
|
2
|
-
export default class AppProvision extends OpenXiangdaCommand {
|
|
3
|
-
static summary = "在平台幂等创建 2.0 应用身份";
|
|
4
|
-
static flags = workspaceFlags;
|
|
5
|
-
async run() {
|
|
6
|
-
const { flags } = await this.parse(AppProvision);
|
|
7
|
-
return this.present(await this.services.provisionApplication(flags.cwd));
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=provision.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"provision.js","sourceRoot":"","sources":["../../../src/commands/app/provision.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAEnE,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,kBAAkB;IAC1D,MAAM,CAAC,OAAO,GAAG,kBAAkB,CAAC;IACpC,MAAM,CAAC,KAAK,GAAG,cAAc,CAAC;IAE9B,KAAK,CAAC,GAAG;QACP,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,IAAI,CAAC,QAAQ,CAAC,oBAAoB,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;IAC3E,CAAC"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { OpenXiangdaCommand } from "../../base.js";
|
|
2
|
-
export default class AuthLogin extends OpenXiangdaCommand {
|
|
3
|
-
static summary: string;
|
|
4
|
-
static flags: {
|
|
5
|
-
"base-url": import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
6
|
-
"no-open": import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
7
|
-
};
|
|
8
|
-
run(): Promise<import("openxiangda-contracts").DevkitResult<unknown>>;
|
|
9
|
-
private openBrowser;
|
|
10
|
-
}
|
|
11
|
-
//# sourceMappingURL=login.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"login.d.ts","sourceRoot":"","sources":["../../../src/commands/auth/login.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,kBAAkB;IACvD,MAAM,CAAC,OAAO,SAAiC;IAC/C,MAAM,CAAC,KAAK;;;MASV;IAEI,GAAG;IAmBT,OAAO,CAAC,WAAW;CAkBpB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version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