@ysgroup/contracts 0.1.46 → 0.1.47

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/index.ts +83 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ysgroup/contracts",
3
- "version": "0.1.46",
3
+ "version": "0.1.47",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "types": "src/index.ts",
package/src/index.ts CHANGED
@@ -4,7 +4,7 @@
4
4
  export type AccountType = "STOCK" | "FUTURES" | "CREDIT" | "STOCK_OPTION" | "GOLD" | "INCOME_SWAP" | "FUTURES_OPTION" | "HUGANGTONG" | "NEW3BOARD" | "SHENGANGTONG";
5
5
  export type AppKind = "service" | "link";
6
6
  export type AppStatus = "enabled" | "disabled" | "maintenance";
7
- export type AuthorizationTable = "users" | "teams" | "owners" | "accounts" | "exchange_accounts" | "mount_exchange_accounts" | "bank_cards" | "banks" | "cnaps" | "custodians" | "strategies" | "projects" | "project_owner" | "owner_strategy" | "account_strategy" | "company_employees" | "workstations" | "owner_workstations" | "approval_roles" | "owner_approvals" | "brokers" | "broker_branches" | "servers" | "trading_counters" | "trading_nodes" | "trading_seats" | "counter_suppliers" | "server_rooms" | "file_metas" | "apps";
7
+ export type AuthorizationTable = "users" | "teams" | "owners" | "accounts" | "exchange_accounts" | "mount_exchange_accounts" | "bank_cards" | "banks" | "cnaps" | "custodians" | "strategies" | "projects" | "project_owner" | "owner_strategy" | "account_strategy" | "company_employees" | "workstations" | "owner_workstations" | "approval_roles" | "owner_approvals" | "brokers" | "broker_branches" | "servers" | "trading_counters" | "trading_nodes" | "trading_seats" | "counter_suppliers" | "server_rooms" | "file_metas" | "apps" | "user_app";
8
8
  export type ChangeOp = "upsert" | "delete";
9
9
  export type CounterTier = "low_latency_95" | "low_latency_85" | "low_latency_98" | "apex_99";
10
10
  export type CountryCode = "AD" | "AE" | "AF" | "AG" | "AI" | "AL" | "AM" | "AO" | "AQ" | "AR" | "AS" | "AT" | "AU" | "AW" | "AX" | "AZ" | "BA" | "BB" | "BD" | "BE" | "BF" | "BG" | "BH" | "BI" | "BJ" | "BL" | "BM" | "BN" | "BO" | "BQ" | "BR" | "BS" | "BT" | "BV" | "BW" | "BY" | "BZ" | "CA" | "CC" | "CD" | "CF" | "CG" | "CH" | "CI" | "CK" | "CL" | "CM" | "CN" | "CO" | "CR" | "CU" | "CV" | "CW" | "CX" | "CY" | "CZ" | "DE" | "DJ" | "DK" | "DM" | "DO" | "DZ" | "EC" | "EE" | "EG" | "EH" | "ER" | "ES" | "ET" | "FI" | "FJ" | "FK" | "FM" | "FO" | "FR" | "GA" | "GB" | "GD" | "GE" | "GF" | "GG" | "GH" | "GI" | "GL" | "GM" | "GN" | "GP" | "GQ" | "GR" | "GS" | "GT" | "GU" | "GW" | "GY" | "HK" | "HM" | "HN" | "HR" | "HT" | "HU" | "ID" | "IE" | "IL" | "IM" | "IN" | "IO" | "IQ" | "IR" | "IS" | "IT" | "JE" | "JM" | "JO" | "JP" | "KE" | "KG" | "KH" | "KI" | "KM" | "KN" | "KP" | "KR" | "KW" | "KY" | "KZ" | "LA" | "LB" | "LC" | "LI" | "LK" | "LR" | "LS" | "LT" | "LU" | "LV" | "LY" | "MA" | "MC" | "MD" | "ME" | "MF" | "MG" | "MH" | "MK" | "ML" | "MM" | "MN" | "MO" | "MP" | "MQ" | "MR" | "MS" | "MT" | "MU" | "MV" | "MW" | "MX" | "MY" | "MZ" | "NA" | "NC" | "NE" | "NF" | "NG" | "NI" | "NL" | "NO" | "NP" | "NR" | "NU" | "NZ" | "OM" | "PA" | "PE" | "PF" | "PG" | "PH" | "PK" | "PL" | "PM" | "PN" | "PR" | "PS" | "PT" | "PW" | "PY" | "QA" | "RE" | "RO" | "RS" | "RU" | "RW" | "SA" | "SB" | "SC" | "SD" | "SE" | "SG" | "SH" | "SI" | "SJ" | "SK" | "SL" | "SM" | "SN" | "SO" | "SR" | "SS" | "ST" | "SV" | "SX" | "SY" | "SZ" | "TC" | "TD" | "TF" | "TG" | "TH" | "TJ" | "TK" | "TL" | "TM" | "TN" | "TO" | "TR" | "TT" | "TV" | "TW" | "TZ" | "UA" | "UG" | "UM" | "US" | "UY" | "UZ" | "VA" | "VC" | "VE" | "VG" | "VI" | "VN" | "VU" | "WF" | "WS" | "YE" | "YT" | "ZA" | "ZM" | "ZW";
@@ -485,6 +485,10 @@ export const ENUM_META = {
485
485
  "apps": {
486
486
  "label": "应用表",
487
487
  "sort": 230
488
+ },
489
+ "user_app": {
490
+ "label": "应用用户关系表",
491
+ "sort": 235
488
492
  }
489
493
  },
490
494
  "GatewayMode": {
@@ -4448,6 +4452,12 @@ export const AUTHORIZATION_TABLE_META = {
4448
4452
  "category": "配置",
4449
4453
  "scope_mode": "explicit",
4450
4454
  "description": "只下发选中的应用;应用密钥、授权版本、心跳和运行版本不下发"
4455
+ },
4456
+ "user_app": {
4457
+ "name": "应用用户关系表",
4458
+ "category": "配置",
4459
+ "scope_mode": "derived",
4460
+ "description": "应用表和用户表都已授权后,下发已下发应用与已下发用户之间的准入关系"
4451
4461
  }
4452
4462
  } as const;
4453
4463
  export const DERIVED_FIELD_SPECS = {
@@ -7638,6 +7648,78 @@ export const AUTHORIZATION_FIELD_CATALOG = {
7638
7648
  "system_required": false,
7639
7649
  "blocked_reason": "系统安全字段,禁止进入同步流"
7640
7650
  }
7651
+ ],
7652
+ "user_app": [
7653
+ {
7654
+ "key": "_id",
7655
+ "title": "主键",
7656
+ "kind": "original",
7657
+ "type": "<class 'str'>",
7658
+ "sensitivity": "public",
7659
+ "selectable": true,
7660
+ "system_required": true,
7661
+ "blocked_reason": ""
7662
+ },
7663
+ {
7664
+ "key": "created_at",
7665
+ "title": "创建时间",
7666
+ "kind": "original",
7667
+ "type": "<class 'float'>",
7668
+ "sensitivity": "public",
7669
+ "selectable": true,
7670
+ "system_required": false,
7671
+ "blocked_reason": ""
7672
+ },
7673
+ {
7674
+ "key": "updated_at",
7675
+ "title": "更新时间",
7676
+ "kind": "original",
7677
+ "type": "<class 'float'>",
7678
+ "sensitivity": "public",
7679
+ "selectable": true,
7680
+ "system_required": false,
7681
+ "blocked_reason": ""
7682
+ },
7683
+ {
7684
+ "key": "deleted_at",
7685
+ "title": "软删除时间",
7686
+ "kind": "original",
7687
+ "type": "float | None",
7688
+ "sensitivity": "public",
7689
+ "selectable": false,
7690
+ "system_required": false,
7691
+ "blocked_reason": "系统安全字段,禁止进入同步流"
7692
+ },
7693
+ {
7694
+ "key": "user_id",
7695
+ "title": "用户ID",
7696
+ "kind": "original",
7697
+ "type": "<class 'str'>",
7698
+ "sensitivity": "public",
7699
+ "selectable": true,
7700
+ "system_required": true,
7701
+ "blocked_reason": ""
7702
+ },
7703
+ {
7704
+ "key": "app_id",
7705
+ "title": "应用ID",
7706
+ "kind": "original",
7707
+ "type": "<class 'str'>",
7708
+ "sensitivity": "public",
7709
+ "selectable": true,
7710
+ "system_required": true,
7711
+ "blocked_reason": ""
7712
+ },
7713
+ {
7714
+ "key": "admin",
7715
+ "title": "应用管理员",
7716
+ "kind": "original",
7717
+ "type": "<class 'bool'>",
7718
+ "sensitivity": "public",
7719
+ "selectable": true,
7720
+ "system_required": false,
7721
+ "blocked_reason": ""
7722
+ }
7641
7723
  ]
7642
7724
  } as const;
7643
7725
  export type TableName = keyof typeof TABLES;