schema-dsl 1.1.0 → 1.1.2

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.
@@ -17,6 +17,31 @@ module.exports = {
17
17
  'conditional.blocked': 'Account has been blocked',
18
18
  'conditional.notAllowed': 'Registration not allowed',
19
19
 
20
+ // I18nError - General errors (v1.1.1)
21
+ 'error.notFound': '{{#resource}} not found',
22
+ 'error.forbidden': 'Access to {{#resource}} is forbidden',
23
+ 'error.unauthorized': 'Unauthorized, please log in',
24
+ 'error.invalid': 'Invalid {{#field}}',
25
+ 'error.duplicate': '{{#resource}} already exists',
26
+ 'error.conflict': 'Operation conflict: {{#reason}}',
27
+
28
+ // I18nError - Account related (v1.1.1)
29
+ 'account.notFound': 'Account not found',
30
+ 'account.inactive': 'Account is inactive',
31
+ 'account.banned': 'Account has been banned',
32
+ 'account.insufficientBalance': 'Insufficient balance, current: {{#balance}}, required: {{#required}}',
33
+ 'account.insufficientCredits': 'Insufficient credits, current: {{#credits}}, required: {{#required}}',
34
+
35
+ // I18nError - User related (v1.1.1)
36
+ 'user.notFound': 'User not found',
37
+ 'user.notVerified': 'User is not verified',
38
+ 'user.noPermission': 'No admin permission',
39
+
40
+ // I18nError - Order related (v1.1.1)
41
+ 'order.notPaid': 'Order not paid',
42
+ 'order.paymentMissing': 'Payment information missing',
43
+ 'order.addressMissing': 'Shipping address missing',
44
+
20
45
  // Formats
21
46
  'format.email': '{{#label}} must be a valid email address',
22
47
  'format.url': '{{#label}} must be a valid URL',
@@ -17,6 +17,31 @@ module.exports = {
17
17
  'conditional.blocked': '账号已被封禁',
18
18
  'conditional.notAllowed': '不允许注册',
19
19
 
20
+ // I18nError - 通用错误消息 (v1.1.1)
21
+ 'error.notFound': '找不到{{#resource}}',
22
+ 'error.forbidden': '没有权限访问{{#resource}}',
23
+ 'error.unauthorized': '未授权,请先登录',
24
+ 'error.invalid': '{{#field}}无效',
25
+ 'error.duplicate': '{{#resource}}已存在',
26
+ 'error.conflict': '操作冲突: {{#reason}}',
27
+
28
+ // I18nError - 账户相关 (v1.1.1)
29
+ 'account.notFound': '账户不存在',
30
+ 'account.inactive': '账户未激活',
31
+ 'account.banned': '账户已被封禁',
32
+ 'account.insufficientBalance': '余额不足,当前余额{{#balance}},需要{{#required}}',
33
+ 'account.insufficientCredits': '积分不足,当前积分{{#credits}},需要{{#required}}',
34
+
35
+ // I18nError - 用户相关 (v1.1.1)
36
+ 'user.notFound': '用户不存在',
37
+ 'user.notVerified': '用户未验证',
38
+ 'user.noPermission': '没有管理员权限',
39
+
40
+ // I18nError - 订单相关 (v1.1.1)
41
+ 'order.notPaid': '订单未支付',
42
+ 'order.paymentMissing': '缺少支付信息',
43
+ 'order.addressMissing': '缺少收货地址',
44
+
20
45
  // Formats
21
46
  'format.email': '{{#label}}必须是有效的邮箱地址',
22
47
  'format.url': '{{#label}}必须是有效的URL地址',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "schema-dsl",
3
- "version": "1.1.0",
3
+ "version": "1.1.2",
4
4
  "description": "简洁强大的JSON Schema验证库 - DSL语法 + String扩展 + 便捷validate",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",