瀏覽代碼

接口出入参全面改为驼峰命名,放弃与 PHP 逐字段对齐口径

出参:
- application.yml 移除 jackson SNAKE_CASE 全局策略,输出统一驼峰
- 119 处 @JsonProperty 钉死值转驼峰(含 OrderGoods 全限定名注解)
- 226 处 Map/JsonNode 手拼字段名转驼峰(含统计、订单、评论、页面装修、导出等)
- goodsRanking SQL 输出别名及 order by 同步转驼峰
- UserLiteSerializer 内部 SNAKE_CASE mapper 改全局驼峰,修复订单 user 子对象残留
入参:
- Params 工具方法调用的 key 参数 48 处转驼峰(category_id→categoryId 等)
- Params.merge 自动解包前端 {form:{...}} 包裹并以 form 字段为准(修复表单提交丢失)
- RechargeService firstInt 兼容参数去重
验证:
- 新增 tools/smoke_camel.py:17 个读接口出参零 snake key + 驼峰入参写链路全通过
- form 包裹 add/edit/delete 全链路验证通过
- 新增迁移脚本 migrate_camel_java / migrate_camel_params / fix_camel_break / migrate_camel_front 备查
tanlie 1 天之前
父節點
當前提交
2a66a0b35b
共有 90 個文件被更改,包括 684 次插入 和 382 次删除
  1. 24 0
      tools/fix_camel_break.py
  2. 73 0
      tools/migrate_camel_front.py
  3. 77 0
      tools/migrate_camel_java.py
  4. 42 0
      tools/migrate_camel_params.py
  5. 79 0
      tools/smoke_camel.py
  6. 4 4
      yoshop-java/src/main/java/cn/yoshop/common/entity/Article.java
  7. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/ArticleCategory.java
  8. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Category.java
  9. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Comment.java
  10. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/CommentImage.java
  11. 5 5
      yoshop-java/src/main/java/cn/yoshop/common/entity/Coupon.java
  12. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Delivery.java
  13. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/DeliveryRule.java
  14. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Express.java
  15. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/entity/Goods.java
  16. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsImage.java
  17. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsService.java
  18. 4 4
      yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsSku.java
  19. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsSpecRel.java
  20. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Help.java
  21. 9 9
      yoshop-java/src/main/java/cn/yoshop/common/entity/Order.java
  22. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderAddress.java
  23. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderDelivery.java
  24. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderDeliveryGoods.java
  25. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderExport.java
  26. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderGoods.java
  27. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderRefund.java
  28. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderRefundAddress.java
  29. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/OrderRefundImage.java
  30. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/PageEntity.java
  31. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Payment.java
  32. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/PaymentTemplate.java
  33. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/PaymentTrade.java
  34. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/entity/Printer.java
  35. 4 4
      yoshop-java/src/main/java/cn/yoshop/common/entity/RechargeOrder.java
  36. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/RechargeOrderPlan.java
  37. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/RechargePlan.java
  38. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/Spec.java
  39. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/SpecValue.java
  40. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/Store.java
  41. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreAddress.java
  42. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreMenuApi.java
  43. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreRole.java
  44. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreRoleMenu.java
  45. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreSetting.java
  46. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreUser.java
  47. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/StoreUserRole.java
  48. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/UploadFile.java
  49. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/UploadGroup.java
  50. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/entity/User.java
  51. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/UserBalanceLog.java
  52. 5 5
      yoshop-java/src/main/java/cn/yoshop/common/entity/UserCoupon.java
  53. 2 2
      yoshop-java/src/main/java/cn/yoshop/common/entity/UserGrade.java
  54. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/UserGradeLog.java
  55. 1 1
      yoshop-java/src/main/java/cn/yoshop/common/entity/UserPointsLog.java
  56. 3 3
      yoshop-java/src/main/java/cn/yoshop/common/mapper/OrderGoodsMapper.java
  57. 13 2
      yoshop-java/src/main/java/cn/yoshop/common/util/Params.java
  58. 3 6
      yoshop-java/src/main/java/cn/yoshop/common/util/UserLiteSerializer.java
  59. 2 2
      yoshop-java/src/main/java/cn/yoshop/store/controller/CategoryController.java
  60. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/ContentArticleCategoryController.java
  61. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/ContentArticleController.java
  62. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/ContentHelpController.java
  63. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/GoodsController.java
  64. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/PageController.java
  65. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/StoreAddressController.java
  66. 2 2
      yoshop-java/src/main/java/cn/yoshop/store/controller/StoreRoleController.java
  67. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/StoreUserController.java
  68. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/controller/UserController.java
  69. 4 4
      yoshop-java/src/main/java/cn/yoshop/store/service/CategoryService.java
  70. 4 4
      yoshop-java/src/main/java/cn/yoshop/store/service/ClientSettingService.java
  71. 11 11
      yoshop-java/src/main/java/cn/yoshop/store/service/CommentService.java
  72. 12 12
      yoshop-java/src/main/java/cn/yoshop/store/service/ContentService.java
  73. 4 4
      yoshop-java/src/main/java/cn/yoshop/store/service/FilesService.java
  74. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/service/GoodsServiceItemService.java
  75. 58 58
      yoshop-java/src/main/java/cn/yoshop/store/service/GoodsWriteService.java
  76. 18 18
      yoshop-java/src/main/java/cn/yoshop/store/service/MarketingService.java
  77. 1 1
      yoshop-java/src/main/java/cn/yoshop/store/service/MemberWriteService.java
  78. 56 56
      yoshop-java/src/main/java/cn/yoshop/store/service/OrderExportService.java
  79. 4 4
      yoshop-java/src/main/java/cn/yoshop/store/service/OrderRefundService.java
  80. 2 2
      yoshop-java/src/main/java/cn/yoshop/store/service/OrderService.java
  81. 8 8
      yoshop-java/src/main/java/cn/yoshop/store/service/PageDesignService.java
  82. 12 12
      yoshop-java/src/main/java/cn/yoshop/store/service/PaymentSettingService.java
  83. 15 15
      yoshop-java/src/main/java/cn/yoshop/store/service/PermissionService.java
  84. 3 3
      yoshop-java/src/main/java/cn/yoshop/store/service/RechargeService.java
  85. 10 10
      yoshop-java/src/main/java/cn/yoshop/store/service/SettingService.java
  86. 7 7
      yoshop-java/src/main/java/cn/yoshop/store/service/StatisticsService.java
  87. 4 4
      yoshop-java/src/main/java/cn/yoshop/store/service/StoreGoodsService.java
  88. 7 7
      yoshop-java/src/main/java/cn/yoshop/store/service/StoreInfoService.java
  89. 8 8
      yoshop-java/src/main/java/cn/yoshop/store/service/StoreUserService.java
  90. 0 1
      yoshop-java/src/main/resources/application.yml

+ 24 - 0
tools/fix_camel_break.py

@@ -0,0 +1,24 @@
+# -*- coding: utf-8 -*-
+"""修复 migrate_camel_java.py 第二轮造成的损坏:
+put("x", y) 被写成了 put("x"), y。
+特征:.put( / .putIfAbsent( / .getOrDefault( 后的 "key") 后紧跟 `, `,
+而这些方法必然带第二参数,正常代码不存在 `"key"), ` 形态,可安全还原。
+"""
+import re
+from pathlib import Path
+from _root import ROOT
+
+SRC = ROOT / "yoshop-java" / "src" / "main" / "java"
+BAD = re.compile(r'\.(put|putIfAbsent|getOrDefault)\("([A-Za-z0-9]+)"\), ')
+
+fixed = []
+for f in sorted(SRC.rglob("*.java")):
+    text = f.read_text(encoding="utf-8")
+    new = BAD.sub(r'.\1("\2", ', text)
+    if new != text:
+        f.write_text(new, encoding="utf-8")
+        fixed.append(str(f.relative_to(SRC)))
+
+print("修复 %d 个文件" % len(fixed))
+for n in fixed:
+    print("  ", n)

+ 73 - 0
tools/migrate_camel_front.py

@@ -0,0 +1,73 @@
+# -*- coding: utf-8 -*-
+"""前端驼峰迁移:src 下 .vue/.js 的全小写 snake_case 标识符 -> 驼峰。
+.vue 只处理 <template> 与 <script>,跳过 <style>。
+排除清单:证书文件名、路由枚举值、CSS 类名、import 路径、第三方 SDK 字段、
+前端框架自身配置 key、localStorage key、短信场景枚举值 —— 这些不是接口字段。
+"""
+import re
+from pathlib import Path
+
+ROOT = Path(r"F:\shop\yoshop2.0-store")
+SRC = ROOT / "src"
+
+EXCLUDE = {
+    # 微信支付证书文件名(文案)
+    "apiclient_cert", "apiclient_key",
+    # 商品列表 listType 枚举值(路由 query,前后端约定值)
+    "on_sale", "off_sale", "sold_out",
+    # CSS 类名片段
+    "text_right",
+    # import 路径(文件名)
+    "lazy_use",
+    # 第三方(云存储/短信/支付)固定字段
+    "access_key", "access_key_id", "access_key_secret",
+    "secret_id", "secret_key", "pub_key",
+    # 前端框架自身配置 / localStorage key(与后端接口无关)
+    "multi_tab", "fixed_header", "fixed_sidebar", "sidebar_type",
+    "nav_theme", "content_width", "auto_hide_header",
+    "app_language", "app_theme", "is_mobile",
+    "region_tree", "order_export_form",
+    # 短信场景枚举值
+    "order_pay",
+}
+
+SNAKE = re.compile(r'\b([a-z]+(_[a-z0-9]+)+)\b')
+
+
+def to_camel(s):
+    return re.sub(r'_([a-z0-9])', lambda m: m.group(1).upper(), s)
+
+
+def convert_vue(text):
+    """按 <template>/<script>/<style> 分段,只处理前两者。"""
+    parts = re.split(r'(<style[^>]*>[\s\S]*?</style>)', text)
+    out = []
+    for p in parts:
+        if p.startswith("<style"):
+            out.append(p)
+        else:
+            out.append(SNAKE.sub(snake_repl, p))
+    return "".join(out)
+
+
+def snake_repl(m):
+    t = m.group(1)
+    if t in EXCLUDE:
+        return t
+    return to_camel(t)
+
+
+changed = []
+total = 0
+for f in sorted(list(SRC.rglob("*.vue")) + list(SRC.rglob("*.js"))):
+    text = f.read_text(encoding="utf-8", errors="replace")
+    new = convert_vue(text) if f.suffix == ".vue" else SNAKE.sub(snake_repl, text)
+    if new != text:
+        n = sum(1 for a, b in zip(text.split("\n"), new.split("\n")) if a != b)
+        total += len(SNAKE.findall(re.sub(r'|'.join(map(lambda e: re.escape(e), EXCLUDE)), '', new)))
+        f.write_text(new, encoding="utf-8", newline="")
+        changed.append((str(f.relative_to(ROOT)), n))
+
+print("改动 %d 个文件" % len(changed))
+for name, n in sorted(changed, key=lambda x: -x[1])[:20]:
+    print("  %-64s ~%d 行" % (name, n))

+ 77 - 0
tools/migrate_camel_java.py

@@ -0,0 +1,77 @@
+# -*- coding: utf-8 -*-
+"""Java 侧驼峰迁移:
+1. application.yml 移除 jackson.property-naming-strategy: SNAKE_CASE
+2. @JsonProperty("snake_case") -> @JsonProperty("camelCase")
+3. Map 出入参 key(.put/.get/.remove/.has/.containsKey)snake -> camel
+   排除 Redis 登录态内部存储(LoginInfo / RedisTokenStore),那是自造 key,与 API 无关
+4. @Select SQL 里 `as snake_alias` 输出别名 -> camel
+注意:绝不动 MyBatis 条件列名(eq/orderBy 等),那才是数据库字段。
+"""
+import re
+from pathlib import Path
+from _root import ROOT
+
+SRC = ROOT / "yoshop-java" / "src" / "main" / "java"
+YML = ROOT / "yoshop-java" / "src" / "main" / "resources" / "application.yml"
+
+# Redis 登录态内部存储 key 不转(自造 JSON,与 API 出入参无关)
+EXCLUDE_FILES = {
+    SRC / "cn" / "yoshop" / "common" / "auth" / "LoginInfo.java",
+    SRC / "cn" / "yoshop" / "common" / "auth" / "RedisTokenStore.java",
+}
+
+SNAKE = re.compile(r'^[a-z]+(_[a-z0-9]+)+$')
+
+
+def to_camel(s: str) -> str:
+    return re.sub(r'_([a-z0-9])', lambda m: m.group(1).upper(), s)
+
+
+# 方法名 -> 是否处理。只处理 Map/JsonNode 的 key 读写,不碰数据库列名。
+KEY_METHODS = ("put", "putIfAbsent", "get", "remove", "has", "containsKey", "getOrDefault")
+CALL = re.compile(r'\.(' + "|".join(KEY_METHODS) + r')\("([a-z0-9_]+)"(?=[,)])')
+JP = re.compile(r'@JsonProperty\("([a-z0-9_]+)"\)')
+SQL_AS = re.compile(r'\bas ([a-z]+(_[a-z0-9]+)+)\b')
+
+changed_files = []
+total = {"jp": 0, "call": 0, "sql": 0}
+
+for f in sorted(SRC.rglob("*.java")):
+    text = f.read_text(encoding="utf-8")
+    orig = text
+
+    def jp_repl(m):
+        total["jp"] += 1
+        return '@JsonProperty("%s")' % to_camel(m.group(1))
+
+    def call_repl(m):
+        key = m.group(2)
+        if not SNAKE.match(key):
+            return m.group(0)
+        total["call"] += 1
+        return '.%s("%s")' % (m.group(1), to_camel(key))
+
+    def sql_repl(m):
+        total["sql"] += 1
+        return 'as %s' % to_camel(m.group(1))
+
+    text = JP.sub(jp_repl, text)
+    if f not in EXCLUDE_FILES:
+        text = CALL.sub(call_repl, text)
+        text = SQL_AS.sub(sql_repl, text)
+
+    if text != orig:
+        f.write_text(text, encoding="utf-8")
+        changed_files.append(str(f.relative_to(SRC)))
+
+# application.yml:移除全局 SNAKE_CASE
+yml_text = YML.read_text(encoding="utf-8")
+new_yml = re.sub(r'\n[ \t]*property-naming-strategy:.*', '', yml_text)
+if new_yml != yml_text:
+    YML.write_text(new_yml, encoding="utf-8")
+    print("application.yml: 已移除 property-naming-strategy: SNAKE_CASE")
+
+print("改动文件 %d 个;@JsonProperty %d 处、Map key %d 处、SQL 别名 %d 处"
+      % (len(changed_files), total["jp"], total["call"], total["sql"]))
+for n in changed_files:
+    print("  ", n)

+ 42 - 0
tools/migrate_camel_params.py

@@ -0,0 +1,42 @@
+# -*- coding: utf-8 -*-
+"""驼峰迁移补充:Params/本地工具方法的 key 字符串参数转驼峰。
+覆盖形如 Params.intOrNull(data, "category_id")、firstInt(params, "user_id", "userId") 的调用。
+第一参数限定 params/form/data/body/all/values/query/request 等变量名,避免误伤。
+"""
+import re
+from pathlib import Path
+from _root import ROOT
+
+SRC = ROOT / "yoshop-java" / "src" / "main" / "java"
+SNAKE = re.compile(r'^[a-z]+(_[a-z0-9]+)+$')
+
+CALL = re.compile(
+    r'((?:\w+\.)?\w+\((?:params|form|data|body|all|values|query|request|order|\w*Map),\s*")([a-z0-9_]+)(")')
+
+
+def to_camel(s):
+    return re.sub(r'_([a-z0-9])', lambda m: m.group(1).upper(), s)
+
+
+changed = []
+n = 0
+for f in sorted(SRC.rglob("*.java")):
+    text = f.read_text(encoding="utf-8")
+    orig = text
+
+    def repl(m):
+        global n
+        key = m.group(2)
+        if not SNAKE.match(key):
+            return m.group(0)
+        n += 1
+        return m.group(1) + to_camel(key) + m.group(3)
+
+    text = CALL.sub(repl, text)
+    if text != orig:
+        f.write_text(text, encoding="utf-8")
+        changed.append(str(f.relative_to(SRC)))
+
+print("改动 %d 个文件、%d 处" % (len(changed), n))
+for c in changed:
+    print("  ", c)

+ 79 - 0
tools/smoke_camel.py

@@ -0,0 +1,79 @@
+# -*- coding: utf-8 -*-
+"""驼峰改造冒烟:核心读接口出参不得出现 snake_case key;写接口用驼峰入参。"""
+import re
+import sys
+
+sys.path.insert(0, "tools")
+from test_redis_auth import login, S, BASE, Redis, PREFIX
+
+
+def check_snake(obj, path="$"):
+    hits = []
+    if isinstance(obj, dict):
+        for k, v in obj.items():
+            if re.match(r'^[a-z]+(_[a-z0-9]+)+$', k):
+                hits.append("%s.%s" % (path, k))
+            hits += check_snake(v, path + "." + k)
+    elif isinstance(obj, list):
+        for i, v in enumerate(obj[:3]):
+            hits += check_snake(v, "%s[%d]" % (path, i))
+    return hits
+
+
+tok = login("redistest_admin", "123456")["data"]["token"]
+H = {"Access-Token": tok}
+
+
+def get(p):
+    return S.get(BASE + p, headers=H, timeout=30).json()
+
+
+def post(p, b):
+    return S.post(BASE + p, headers=H, json=b, timeout=30).json()
+
+
+fails = []
+CASES = [
+    "/store/goods/list?page=1&pageSize=5",
+    "/store/order/list?dataType=order&page=1&pageSize=5",
+    "/store/order/list?dataType=delivery&page=1&pageSize=5",
+    "/store/order/list?dataType=receipt&page=1&pageSize=5",
+    "/store/order/list?dataType=complete&page=1&pageSize=5",
+    "/store/store.user/list?page=1",
+    "/store/files/list?page=1",
+    "/store/goods.comment/list?page=1",
+    "/store/market.coupon/list?page=1",
+    "/store/page/list",
+    "/store/setting/detail",
+    "/store/statistics.data/data",
+    "/store/statistics.data/survey",
+    "/store/category/list",
+    "/store/client.h5.setting/detail?key=basic",
+    "/store/client.wxapp.setting/detail?key=basic",
+]
+# goods/detail 用列表里真实存在的商品 ID(10001/10002 已软删)
+first = get("/store/goods/list?page=1&pageSize=1")
+lst = first.get("data", {}).get("list", {})
+real_gid = (lst.get("data") or [{}])[0].get("goodsId") if isinstance(lst, dict) else None
+if real_gid:
+    CASES.insert(1, "/store/goods/detail?goodsId=%s" % real_gid)
+
+for p in CASES:
+    r = get(p)
+    hits = check_snake(r)
+    tag = "ok" if (r.get("status") == 200 and not hits) else "FAIL"
+    print("[%s] %-46s status=%s snake=%s" % (tag, p, r.get("status"), hits[:4] if hits else "无"))
+    if tag == "FAIL":
+        fails.append(p)
+
+# 写接口:驼峰入参
+r5 = post("/store/category/add", {"form": {"name": "冒烟分类", "parentId": 0, "sort": 99, "imageId": 0}})
+print("[--] category.add(驼峰入参):", r5["status"], r5["message"])
+if r5["status"] != 200:
+    fails.append("category.add")
+
+with Redis() as rd:
+    rd("DEL", PREFIX + tok)
+
+print("\n冒烟结果:", "全部通过" if not fails else "FAIL: %s" % fails)
+sys.exit(1 if fails else 0)

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/common/entity/Article.java

@@ -51,12 +51,12 @@ public class Article {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }
@@ -68,13 +68,13 @@ public class Article {
     private ArticleCategory category;
 
     /** 封面图地址:PHP 关联 image 时 bind(['image_url' => 'preview_url']) */
-    @JsonProperty("image_url")
+    @JsonProperty("imageUrl")
     public String getImageUrl() {
         return image == null ? null : image.getPreviewUrl();
     }
 
     /** 展示的浏览次数 = 虚拟 + 实际(PHP $append) */
-    @JsonProperty("show_views")
+    @JsonProperty("showViews")
     public int getShowViews() {
         int virtual = virtualViews == null ? 0 : virtualViews;
         int actual = actualViews == null ? 0 : actualViews;

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/ArticleCategory.java

@@ -32,12 +32,12 @@ public class ArticleCategory {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Category.java

@@ -37,12 +37,12 @@ public class Category {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Comment.java

@@ -48,12 +48,12 @@ public class Comment {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/CommentImage.java

@@ -30,7 +30,7 @@ public class CommentImage {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 5 - 5
yoshop-java/src/main/java/cn/yoshop/common/entity/Coupon.java

@@ -59,12 +59,12 @@ public class Coupon {
     @JsonIgnore
     private Integer endTime; // 固定时间-结束时间
 
-    @JsonProperty("start_time")
+    @JsonProperty("startTime")
     public String getStartTimeText() {
         return dayOrNull(startTime);
     }
 
-    @JsonProperty("end_time")
+    @JsonProperty("endTime")
     public String getEndTimeText() {
         return dayOrNull(endTime);
     }
@@ -96,18 +96,18 @@ public class Coupon {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }
 
     /** 适用范围配置:库内 json 字符串,出参为数组/对象;为空时对齐 PHP 输出空数组 */
-    @JsonProperty("apply_range_config")
+    @JsonProperty("applyRangeConfig")
     public Object getApplyRangeConfigJson() {
         Object config = cn.yoshop.common.util.PhpStr.jsonDecodeArray(normalizeLegacyConfig(applyRangeConfig));
         return config == null ? java.util.List.of() : config;

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Delivery.java

@@ -41,12 +41,12 @@ public class Delivery {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/DeliveryRule.java

@@ -37,7 +37,7 @@ public class DeliveryRule {
     @JsonIgnore
     private String regionText;
 
-    @JsonProperty("region_text")
+    @JsonProperty("regionText")
     public Object getRegionTextJson() {
         return cn.yoshop.common.util.PhpStr.jsonDecodeArray(regionText);
     }
@@ -59,7 +59,7 @@ public class DeliveryRule {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Express.java

@@ -38,12 +38,12 @@ public class Express {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/entity/Goods.java

@@ -101,7 +101,7 @@ public class Goods {
     @JsonIgnore
     private String aloneGradeEquity;
 
-    @JsonProperty("alone_grade_equity")
+    @JsonProperty("aloneGradeEquity")
     public Object getAloneGradeEquityJson() {
         return cn.yoshop.common.util.PhpStr.jsonDecodeArray(aloneGradeEquity);
     }
@@ -201,12 +201,12 @@ public class Goods {
     @TableField(exist = false)
     private UploadFile videoCover;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsImage.java

@@ -34,7 +34,7 @@ public class GoodsImage {
     @TableField(exist = false)
     private UploadFile file;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsService.java

@@ -40,12 +40,12 @@ public class GoodsService {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsSku.java

@@ -51,7 +51,7 @@ public class GoodsSku {
     @com.fasterxml.jackson.annotation.JsonIgnore
     private String goodsProps;
 
-    @JsonProperty("goods_props")
+    @JsonProperty("goodsProps")
     public Object getGoodsPropsJson() {
         return cn.yoshop.common.util.PhpStr.jsonDecodeArray(goodsProps);
     }
@@ -60,7 +60,7 @@ public class GoodsSku {
     @com.fasterxml.jackson.annotation.JsonIgnore
     private String specValueIds;
 
-    @JsonProperty("spec_value_ids")
+    @JsonProperty("specValueIds")
     public Object getSpecValueIdsJson() {
         return cn.yoshop.common.util.PhpStr.jsonDecodeArray(specValueIds);
     }
@@ -75,12 +75,12 @@ public class GoodsSku {
     @TableField(exist = false)
     private UploadFile image;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/GoodsSpecRel.java

@@ -29,7 +29,7 @@ public class GoodsSpecRel {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return cn.yoshop.common.util.TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Help.java

@@ -36,12 +36,12 @@ public class Help {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 9 - 9
yoshop-java/src/main/java/cn/yoshop/common/entity/Order.java

@@ -153,7 +153,7 @@ public class Order {
 
     // ---------------------------------------------------------------- 出参组装
 
-    @JsonProperty("order_price")
+    @JsonProperty("orderPrice")
     public String getOrderPriceText() {
         if (orderPrice != null && orderPrice.compareTo(BigDecimal.ZERO) != 0) {
             return orderPrice.toPlainString();
@@ -164,7 +164,7 @@ public class Order {
         return total.subtract(coupon).add(diff).toPlainString();
     }
 
-    @JsonProperty("update_price")
+    @JsonProperty("updatePrice")
     public Map<String, String> getUpdatePriceVo() {
         BigDecimal v = updatePrice == null ? BigDecimal.ZERO : updatePrice;
         return Map.of(
@@ -172,22 +172,22 @@ public class Order {
                 "value", String.format(java.util.Locale.US, "%.2f", v.abs()));
     }
 
-    @JsonProperty("pay_time")
+    @JsonProperty("payTime")
     public String getPayTimeText() {
         return TimeUtil.formatOrBlank(payTime);
     }
 
-    @JsonProperty("delivery_time")
+    @JsonProperty("deliveryTime")
     public String getDeliveryTimeText() {
         return TimeUtil.formatOrBlank(deliveryTime);
     }
 
-    @JsonProperty("receipt_time")
+    @JsonProperty("receiptTime")
     public String getReceiptTimeText() {
         return TimeUtil.formatOrBlank(receiptTime);
     }
 
-    @JsonProperty("order_source_data")
+    @JsonProperty("orderSourceData")
     public List<Object> getOrderSourceDataList() {
         if (orderSourceData == null || orderSourceData.isBlank()) {
             return Collections.emptyList();
@@ -196,7 +196,7 @@ public class Order {
         return parsed instanceof List ? castList(parsed) : Collections.emptyList();
     }
 
-    @JsonProperty("state_text")
+    @JsonProperty("stateText")
     public String getStateText() {
         // 对齐 PHP getStateTextAttr:非进行中直接返回状态名
         if (orderStatus != null && orderStatus != 10) {
@@ -219,12 +219,12 @@ public class Order {
         return "已完成";
     }
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderAddress.java

@@ -40,7 +40,7 @@ public class OrderAddress {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderDelivery.java

@@ -39,7 +39,7 @@ public class OrderDelivery {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderDeliveryGoods.java

@@ -34,7 +34,7 @@ public class OrderDeliveryGoods {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderExport.java

@@ -46,17 +46,17 @@ public class OrderExport {
     @TableField(exist = false)
     private String downloadUrl;
 
-    @JsonProperty("start_time")
+    @JsonProperty("startTime")
     public String getStartTimeText() {
         return date(startTime);
     }
 
-    @JsonProperty("end_time")
+    @JsonProperty("endTime")
     public String getEndTimeText() {
         return date(endTime);
     }
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderGoods.java

@@ -42,7 +42,7 @@ public class OrderGoods {
     @JsonIgnore
     private String goodsProps; // SKU的规格属性(json格式)
 
-    @JsonProperty("goods_props")
+    @JsonProperty("goodsProps")
     public Object getGoodsPropsJson() {
         return goodsProps == null || goodsProps.isBlank() ? null : PhpStr.jsonDecodeArray(goodsProps);
     }
@@ -107,7 +107,7 @@ public class OrderGoods {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
@@ -118,7 +118,7 @@ public class OrderGoods {
     private UploadFile image;
 
     /** 商品封面图(image.preview_url) */
-    @com.fasterxml.jackson.annotation.JsonProperty("goods_image")
+    @com.fasterxml.jackson.annotation.JsonProperty("goodsImage")
     public String getGoodsImage() {
         return image == null ? null : image.getPreviewUrl();
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderRefund.java

@@ -45,7 +45,7 @@ public class OrderRefund {
     @JsonIgnore
     private Integer sendTime; // 用户发货时间
 
-    @JsonProperty("send_time")
+    @JsonProperty("sendTime")
     public String getSendTimeText() {
         // 对齐 PHP getSendTimeAttr → format_time():0 输出空串
         return TimeUtil.formatOrBlank(sendTime);
@@ -67,12 +67,12 @@ public class OrderRefund {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderRefundAddress.java

@@ -37,7 +37,7 @@ public class OrderRefundAddress {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/OrderRefundImage.java

@@ -28,7 +28,7 @@ public class OrderRefundImage {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/PageEntity.java

@@ -38,12 +38,12 @@ public class PageEntity {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Payment.java

@@ -48,12 +48,12 @@ public class Payment {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/PaymentTemplate.java

@@ -53,12 +53,12 @@ public class PaymentTemplate {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/PaymentTrade.java

@@ -46,12 +46,12 @@ public class PaymentTrade {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/entity/Printer.java

@@ -27,7 +27,7 @@ public class Printer {
     @JsonIgnore
     private String printerConfig;
 
-    @JsonProperty("printer_config")
+    @JsonProperty("printerConfig")
     public Object getPrinterConfigJson() {
         return cn.yoshop.common.util.PhpStr.jsonDecodeArray(printerConfig);
     }
@@ -47,12 +47,12 @@ public class Printer {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/common/entity/RechargeOrder.java

@@ -60,17 +60,17 @@ public class RechargeOrder {
     private Integer updateTime;
 
     /** PHP getPayTimeAttr:format_time,0 → 空串 */
-    @JsonProperty("pay_time")
+    @JsonProperty("payTime")
     public String getPayTimeText() {
         return TimeUtil.formatOrBlank(payTime);
     }
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }
@@ -82,6 +82,6 @@ public class RechargeOrder {
 
     /** 关联套餐快照(PHP with('order_plan'),hasOne,键名驼峰固定) */
     @TableField(exist = false)
-    @JsonProperty("order_plan")
+    @JsonProperty("orderPlan")
     private RechargeOrderPlan orderPlan;
 }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/RechargeOrderPlan.java

@@ -42,12 +42,12 @@ public class RechargeOrderPlan {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/RechargePlan.java

@@ -43,12 +43,12 @@ public class RechargePlan {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/Spec.java

@@ -25,7 +25,7 @@ public class Spec {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return cn.yoshop.common.util.TimeUtil.format(createTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/SpecValue.java

@@ -27,7 +27,7 @@ public class SpecValue {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return cn.yoshop.common.util.TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/Store.java

@@ -54,12 +54,12 @@ public class Store {
     @JsonProperty("logoImage")
     private UploadFile logoImage;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreAddress.java

@@ -47,12 +47,12 @@ public class StoreAddress {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreMenuApi.java

@@ -25,7 +25,7 @@ public class StoreMenuApi {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreRole.java

@@ -56,12 +56,12 @@ public class StoreRole {
     @TableField(exist = false)
     private List<StoreRole> children;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreRoleMenu.java

@@ -27,7 +27,7 @@ public class StoreRoleMenu {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreSetting.java

@@ -33,12 +33,12 @@ public class StoreSetting {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreUser.java

@@ -46,12 +46,12 @@ public class StoreUser {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/StoreUserRole.java

@@ -27,7 +27,7 @@ public class StoreUserRole {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/UploadFile.java

@@ -84,12 +84,12 @@ public class UploadFile {
         return getExternalUrl();
     }
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/UploadGroup.java

@@ -37,12 +37,12 @@ public class UploadGroup {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/entity/User.java

@@ -85,7 +85,7 @@ public class User {
     @TableField(exist = false)
     private UserGrade grade;
 
-    @JsonProperty("avatar_url")
+    @JsonProperty("avatarUrl")
     public String getAvatarUrl() {
         return avatar == null ? null : avatar.getPreviewUrl();
     }
@@ -102,12 +102,12 @@ public class User {
         };
     }
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/UserBalanceLog.java

@@ -40,7 +40,7 @@ public class UserBalanceLog {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 5 - 5
yoshop-java/src/main/java/cn/yoshop/common/entity/UserCoupon.java

@@ -63,12 +63,12 @@ public class UserCoupon {
     private Integer endTime;
 
     /** PHP getStartTimeAttr 无空值判断:date('Y/m/d', 0) → 1970/01/01 */
-    @JsonProperty("start_time")
+    @JsonProperty("startTime")
     public String getStartTimeText() {
         return day(startTime);
     }
 
-    @JsonProperty("end_time")
+    @JsonProperty("endTime")
     public String getEndTimeText() {
         return day(endTime);
     }
@@ -95,17 +95,17 @@ public class UserCoupon {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }
 
-    @JsonProperty("apply_range_config")
+    @JsonProperty("applyRangeConfig")
     public Object getApplyRangeConfigJson() {
         Object config = cn.yoshop.common.util.PhpStr.jsonDecodeArray(Coupon.normalizeLegacyConfig(applyRangeConfig));
         return config == null ? java.util.List.of() : config;

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/common/entity/UserGrade.java

@@ -55,12 +55,12 @@ public class UserGrade {
     @JsonIgnore
     private Integer updateTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }
 
-    @JsonProperty("update_time")
+    @JsonProperty("updateTime")
     public String getUpdateTimeText() {
         return TimeUtil.format(updateTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/UserGradeLog.java

@@ -33,7 +33,7 @@ public class UserGradeLog {
     @JsonIgnore
     private Integer createTime;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/common/entity/UserPointsLog.java

@@ -39,7 +39,7 @@ public class UserPointsLog {
     @com.fasterxml.jackson.databind.annotation.JsonSerialize(using = cn.yoshop.common.util.UserLiteSerializer.class)
     private User user;
 
-    @JsonProperty("create_time")
+    @JsonProperty("createTime")
     public String getCreateTimeText() {
         return TimeUtil.format(createTime);
     }

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/common/mapper/OrderGoodsMapper.java

@@ -15,13 +15,13 @@ public interface OrderGoodsMapper extends BaseMapper<OrderGoods> {
      * 商品销售榜(PHP GoodsRanking::getGoodsRanking):
      * 已付款且未取消订单,按 goods_id 聚合销售额倒序取前 10。
      */
-    @Select("select o_goods.goods_id as goods_id, max(o_goods.goods_name) as goods_name,"
-            + " sum(o_goods.total_pay_price) as sales_volume, sum(o_goods.total_num) as total_sales_num"
+    @Select("select o_goods.goods_id as goodsId, max(o_goods.goods_name) as goodsName,"
+            + " sum(o_goods.total_pay_price) as salesVolume, sum(o_goods.total_num) as totalSalesNum"
             + " from yoshop_order_goods o_goods"
             + " join yoshop_order `order` on `order`.order_id = o_goods.order_id"
             + " where `order`.pay_status = 20 and `order`.order_status <> 20"
             + " group by o_goods.goods_id"
-            + " order by sales_volume desc"
+            + " order by salesVolume desc"
             + " limit 10")
     List<Map<String, Object>> goodsRanking();
 }

+ 13 - 2
yoshop-java/src/main/java/cn/yoshop/common/util/Params.java

@@ -15,7 +15,12 @@ public final class Params {
     private Params() {
     }
 
-    /** 合并 query/form 参数与 JSON body(body 优先) */
+    /**
+     * 合并 query/form 参数与 JSON body(body 优先)。
+     * 前端表单统一以 {@code {form: {...}}} 包裹提交,这里自动解包并以 form 字段为准;
+     * 平铺提交同样兼容。
+     */
+    @SuppressWarnings("unchecked")
     public static Map<String, Object> merge(Map<String, Object> body, HttpServletRequest request) {
         Map<String, Object> map = new LinkedHashMap<>();
         if (request != null) {
@@ -26,7 +31,13 @@ public final class Params {
             });
         }
         if (body != null) {
-            map.putAll(body);
+            Map<String, Object> merged = new LinkedHashMap<>(body);
+            Object form = body.get("form");
+            if (form instanceof Map) {
+                merged.remove("form");
+                merged.putAll((Map<String, Object>) form);
+            }
+            map.putAll(merged);
         }
         return map;
     }

+ 3 - 6
yoshop-java/src/main/java/cn/yoshop/common/util/UserLiteSerializer.java

@@ -5,7 +5,6 @@ import com.fasterxml.jackson.annotation.JsonInclude;
 import com.fasterxml.jackson.core.JsonGenerator;
 import com.fasterxml.jackson.databind.JsonNode;
 import com.fasterxml.jackson.databind.ObjectMapper;
-import com.fasterxml.jackson.databind.PropertyNamingStrategies;
 import com.fasterxml.jackson.databind.SerializerProvider;
 import com.fasterxml.jackson.databind.JsonSerializer;
 import com.fasterxml.jackson.databind.node.ObjectNode;
@@ -13,16 +12,14 @@ import com.fasterxml.jackson.databind.node.ObjectNode;
 import java.io.IOException;
 
 /**
- * 关联会员的精简序列化:对齐 PHP 只 with(['user.avatar']) 的场景。
+ * 关联会员的精简序列化:订单、积分/余额流水里的 user 只加载了 avatar,
+ * 输出时剔除 grade 键(PHP 端只有显式 with('grade') 才会出现该键)。
  *
- * <p>PHP 端只有显式 with('grade') 的查询才会出现 grade 键(值为 null 或对象);
- * 订单、积分/余额流水里的 user 只加载了 avatar,因此没有 grade 键。
- * 这里复用与全局一致的 SNAKE_CASE 规则序列化后剔除 grade,保证出参与 PHP 一致。
+ * <p>序列化用全局驼峰规则,与其它实体输出保持一致。
  */
 public class UserLiteSerializer extends JsonSerializer<User> {
 
     private static final ObjectMapper MAPPER = new ObjectMapper()
-            .setPropertyNamingStrategy(PropertyNamingStrategies.SNAKE_CASE)
             .setSerializationInclusion(JsonInclude.Include.ALWAYS);
 
     @Override

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/store/controller/CategoryController.java

@@ -42,7 +42,7 @@ public class CategoryController {
     @RequestMapping(value = "/edit", method = {RequestMethod.GET, RequestMethod.POST})
     public R<Void> edit(@RequestBody(required = false) Map<String, Object> body, HttpServletRequest request) {
         Map<String, Object> data = Params.merge(body, request);
-        Integer categoryId = Params.intOrNull(data, "category_id");
+        Integer categoryId = Params.intOrNull(data, "categoryId");
         if (categoryId == null) {
             categoryId = Params.intOrNull(data, "id");
         }
@@ -56,7 +56,7 @@ public class CategoryController {
     @RequestMapping(value = "/delete", method = {RequestMethod.GET, RequestMethod.POST})
     public R<Void> delete(@RequestBody(required = false) Map<String, Object> body, HttpServletRequest request) {
         Map<String, Object> data = Params.merge(body, request);
-        Integer categoryId = Params.intOrNull(data, "category_id");
+        Integer categoryId = Params.intOrNull(data, "categoryId");
         if (categoryId == null) {
             return R.fail("参数错误:categoryId");
         }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/ContentArticleCategoryController.java

@@ -58,6 +58,6 @@ public class ContentArticleCategoryController {
 
     private Integer categoryId(Map<String, Object> params) {
         Integer id = Params.intOrNull(params, "categoryId");
-        return id != null ? id : Params.intOrNull(params, "category_id");
+        return id != null ? id : Params.intOrNull(params, "categoryId");
     }
 }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/ContentArticleController.java

@@ -73,6 +73,6 @@ public class ContentArticleController {
 
     private Integer articleId(Map<String, Object> params) {
         Integer id = Params.intOrNull(params, "articleId");
-        return id != null ? id : Params.intOrNull(params, "article_id");
+        return id != null ? id : Params.intOrNull(params, "articleId");
     }
 }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/ContentHelpController.java

@@ -55,7 +55,7 @@ public class ContentHelpController {
         Map<String, Object> all = Params.merge(body, request);
         Integer helpId = Params.intOrNull(all, "helpId");
         if (helpId == null) {
-            helpId = Params.intOrNull(all, "help_id");
+            helpId = Params.intOrNull(all, "helpId");
         }
         if (helpId == null) {
             return R.fail("参数错误:helpId");

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/GoodsController.java

@@ -70,7 +70,7 @@ public class GoodsController {
     @RequestMapping(value = "/add", method = {RequestMethod.GET, RequestMethod.POST})
     public R<Void> add(@RequestBody(required = false) Map<String, Object> body) {
         Map<String, Object> form = Params.form(body);
-        if (form.isEmpty() || String.valueOf(form.get("goods_name")).isBlank()) {
+        if (form.isEmpty() || String.valueOf(form.get("goodsName")).isBlank()) {
             throw new cn.yoshop.common.exception.BizException("很抱歉,商品名称不能为空");
         }
         goodsWriteService.add(form);

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/PageController.java

@@ -94,6 +94,6 @@ public class PageController {
 
     private Integer pageId(Map<String, Object> params) {
         Integer id = Params.intOrNull(params, "pageId");
-        return id != null ? id : Params.intOrNull(params, "page_id");
+        return id != null ? id : Params.intOrNull(params, "pageId");
     }
 }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/StoreAddressController.java

@@ -66,6 +66,6 @@ public class StoreAddressController {
 
     private Integer addressId(Map<String, Object> params) {
         Integer id = Params.intOrNull(params, "addressId");
-        return id != null ? id : Params.intOrNull(params, "address_id");
+        return id != null ? id : Params.intOrNull(params, "addressId");
     }
 }

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/store/controller/StoreRoleController.java

@@ -42,7 +42,7 @@ public class StoreRoleController {
         Map<String, Object> all = Params.merge(body, request);
         Integer roleId = Params.intOrNull(all, "roleId");
         if (roleId == null) {
-            roleId = Params.intOrNull(all, "role_id");
+            roleId = Params.intOrNull(all, "roleId");
         }
         if (roleId == null) {
             return R.fail("参数错误:roleId");
@@ -56,7 +56,7 @@ public class StoreRoleController {
         Map<String, Object> all = Params.merge(body, request);
         Integer roleId = Params.intOrNull(all, "roleId");
         if (roleId == null) {
-            roleId = Params.intOrNull(all, "role_id");
+            roleId = Params.intOrNull(all, "roleId");
         }
         if (roleId == null) {
             return R.fail("参数错误:roleId");

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/StoreUserController.java

@@ -90,7 +90,7 @@ public class StoreUserController {
 
     private Integer userId(Map<String, Object> params) {
         Integer id = Params.intOrNull(params, "userId");
-        return id != null ? id : Params.intOrNull(params, "store_user_id");
+        return id != null ? id : Params.intOrNull(params, "storeUserId");
     }
 
     /** auth.mode=off 时拦截器不注入登录信息,双跑期默认取超管,便于前端直接查看 */

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/controller/UserController.java

@@ -53,7 +53,7 @@ public class UserController {
             return R.fail("参数错误:userId");
         }
         LoginInfo info = (LoginInfo) request.getAttribute("loginInfo");
-        Object userName = info == null || info.getUser() == null ? null : info.getUser().get("user_name");
+        Object userName = info == null || info.getUser() == null ? null : info.getUser().get("userName");
         memberWriteService.recharge(userId, target, Params.form(body),
                 userName == null ? "" : String.valueOf(userName),
                 info == null ? 0 : (int) info.getStoreId());

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/store/service/CategoryService.java

@@ -75,11 +75,11 @@ public class CategoryService {
         if (category == null) {
             throw new BizException("很抱歉,分类信息不存在");
         }
-        Integer parentId = intOrNull(data.get("parent_id"));
+        Integer parentId = intOrNull(data.get("parentId"));
         if (parentId != null && parentId > 0 && isDescendant(categoryId, parentId)) {
             throw new BizException("上级分类不允许设置为当前子分类");
         }
-        if (!data.containsKey("image_id")) {
+        if (!data.containsKey("imageId")) {
             category.setImageId(0);
         }
         apply(category, data);
@@ -121,11 +121,11 @@ public class CategoryService {
         if (data.get("name") != null) {
             category.setName(String.valueOf(data.get("name")));
         }
-        Integer parentId = intOrNull(data.get("parent_id"));
+        Integer parentId = intOrNull(data.get("parentId"));
         if (parentId != null) {
             category.setParentId(parentId);
         }
-        Integer imageId = intOrNull(data.get("image_id"));
+        Integer imageId = intOrNull(data.get("imageId"));
         if (imageId != null) {
             category.setImageId(imageId);
         }

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/store/service/ClientSettingService.java

@@ -138,8 +138,8 @@ public class ClientSettingService {
         }
         Map<String, Object> picked = new LinkedHashMap<>();
         picked.put("enabled", values.getOrDefault("enabled", true));
-        picked.put("app_id", values.getOrDefault("app_id", ""));
-        picked.put("app_secret", values.getOrDefault("app_secret", ""));
+        picked.put("appId", values.getOrDefault("appId", ""));
+        picked.put("appSecret", values.getOrDefault("appSecret", ""));
         picked.put("enableShipping", false);
 
         int now = (int) (System.currentTimeMillis() / 1000);
@@ -165,8 +165,8 @@ public class ClientSettingService {
     private Map<String, Object> wxappDefaults() {
         Map<String, Object> values = new LinkedHashMap<>();
         values.put("enabled", true);
-        values.put("app_id", "");
-        values.put("app_secret", "");
+        values.put("appId", "");
+        values.put("appSecret", "");
         values.put("enableShipping", false);
         Map<String, Object> item = new LinkedHashMap<>();
         item.put("key", "basic");

+ 11 - 11
yoshop-java/src/main/java/cn/yoshop/store/service/CommentService.java

@@ -188,10 +188,10 @@ public class CommentService {
             return null;
         }
         Map<String, Object> vo = new LinkedHashMap<>();
-        vo.put("user_id", user.getUserId());
-        vo.put("nick_name", user.getNickName());
-        vo.put("avatar_id", user.getAvatarId());
-        vo.put("avatar_url", user.getAvatarUrl());
+        vo.put("userId", user.getUserId());
+        vo.put("nickName", user.getNickName());
+        vo.put("avatarId", user.getAvatarId());
+        vo.put("avatarUrl", user.getAvatarUrl());
         vo.put("avatar", user.getAvatar());
         return vo;
     }
@@ -202,14 +202,14 @@ public class CommentService {
             return null;
         }
         Map<String, Object> vo = new LinkedHashMap<>();
-        vo.put("order_goods_id", goods.getOrderGoodsId());
-        vo.put("goods_id", goods.getGoodsId());
-        vo.put("goods_name", goods.getGoodsName());
-        vo.put("image_id", goods.getImageId());
-        vo.put("goods_props", goods.getGoodsProps() == null || goods.getGoodsProps().isBlank()
+        vo.put("orderGoodsId", goods.getOrderGoodsId());
+        vo.put("goodsId", goods.getGoodsId());
+        vo.put("goodsName", goods.getGoodsName());
+        vo.put("imageId", goods.getImageId());
+        vo.put("goodsProps", goods.getGoodsProps() == null || goods.getGoodsProps().isBlank()
                 ? null : PhpStr.jsonDecodeArray(goods.getGoodsProps()));
-        vo.put("order_id", goods.getOrderId());
-        vo.put("goods_image", goods.getImage() == null ? null : goods.getImage().getPreviewUrl());
+        vo.put("orderId", goods.getOrderId());
+        vo.put("goodsImage", goods.getImage() == null ? null : goods.getImage().getPreviewUrl());
         vo.put("image", goods.getImage());
         return vo;
     }

+ 12 - 12
yoshop-java/src/main/java/cn/yoshop/store/service/ContentService.java

@@ -221,8 +221,8 @@ public class ContentService {
 
     @Transactional
     public void articleAdd(Map<String, Object> data, int storeId) {
-        if (data.get("image_id") == null || String.valueOf(data.get("image_id")).isEmpty()
-                || "0".equals(String.valueOf(data.get("image_id")))) {
+        if (data.get("imageId") == null || String.valueOf(data.get("imageId")).isEmpty()
+                || "0".equals(String.valueOf(data.get("imageId")))) {
             throw new BizException("请上传封面图");
         }
         if (data.get("content") == null || String.valueOf(data.get("content")).isEmpty()) {
@@ -245,8 +245,8 @@ public class ContentService {
         if (article == null) {
             throw new BizException("很抱歉,文章不存在");
         }
-        if (data.get("image_id") == null || String.valueOf(data.get("image_id")).isEmpty()
-                || "0".equals(String.valueOf(data.get("image_id")))) {
+        if (data.get("imageId") == null || String.valueOf(data.get("imageId")).isEmpty()
+                || "0".equals(String.valueOf(data.get("imageId")))) {
             throw new BizException("请上传封面图");
         }
         if (data.get("content") == null || String.valueOf(data.get("content")).isEmpty()) {
@@ -272,14 +272,14 @@ public class ContentService {
         if (data.containsKey("title")) {
             article.setTitle(Params.strOrNull(data, "title"));
         }
-        if (data.containsKey("show_type")) {
-            article.setShowType(Params.intVal(data, "show_type", 10));
+        if (data.containsKey("showType")) {
+            article.setShowType(Params.intVal(data, "showType", 10));
         }
-        if (data.containsKey("category_id")) {
-            article.setCategoryId(Params.intVal(data, "category_id", 0));
+        if (data.containsKey("categoryId")) {
+            article.setCategoryId(Params.intVal(data, "categoryId", 0));
         }
-        if (data.containsKey("image_id")) {
-            article.setImageId(Params.intVal(data, "image_id", 0));
+        if (data.containsKey("imageId")) {
+            article.setImageId(Params.intVal(data, "imageId", 0));
         }
         if (data.containsKey("content")) {
             article.setContent(Params.strOrNull(data, "content"));
@@ -290,8 +290,8 @@ public class ContentService {
         if (data.containsKey("status")) {
             article.setStatus(Params.intVal(data, "status", 1));
         }
-        if (data.containsKey("virtual_views")) {
-            article.setVirtualViews(Params.intVal(data, "virtual_views", 0));
+        if (data.containsKey("virtualViews")) {
+            article.setVirtualViews(Params.intVal(data, "virtualViews", 0));
         }
     }
 }

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/store/service/FilesService.java

@@ -122,12 +122,12 @@ public class FilesService {
         if (file == null) {
             throw new BizException("很抱歉,文件不存在");
         }
-        if (data.get("file_name") != null) {
-            file.setFileName(String.valueOf(data.get("file_name")));
+        if (data.get("fileName") != null) {
+            file.setFileName(String.valueOf(data.get("fileName")));
         }
         Integer groupId = Params.argInt(data, "groupId");
         if (groupId == null) {
-            groupId = Params.argInt(data, "group_id");
+            groupId = Params.argInt(data, "groupId");
         }
         if (groupId != null) {
             file.setGroupId(groupId);
@@ -172,7 +172,7 @@ public class FilesService {
         if (data.get("name") != null) {
             group.setName(String.valueOf(data.get("name")));
         }
-        Integer parentId = Params.intOrNull(data, "parent_id");
+        Integer parentId = Params.intOrNull(data, "parentId");
         if (parentId != null) {
             group.setParentId(parentId);
         }

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/service/GoodsServiceItemService.java

@@ -85,7 +85,7 @@ public class GoodsServiceItemService {
         if (data.get("summary") != null) {
             item.setSummary(String.valueOf(data.get("summary")));
         }
-        Integer isDefault = intOrNull(data.get("is_default"));
+        Integer isDefault = intOrNull(data.get("isDefault"));
         if (isDefault != null) {
             item.setIsDefault(isDefault);
         }

+ 58 - 58
yoshop-java/src/main/java/cn/yoshop/store/service/GoodsWriteService.java

@@ -61,7 +61,7 @@ public class GoodsWriteService {
         insertImageRel(goodsId, intList(data.get("imagesIds")));
         insertServiceRel(goodsId, intList(data.get("serviceIds")));
         insertSpecRel(goodsId, castList(data.get("newSpecList")));
-        insertSkuList(goodsId, intVal(data.get("spec_type"), 0), castList(data.get("newSkuList")));
+        insertSkuList(goodsId, intVal(data.get("specType"), 0), castList(data.get("newSkuList")));
     }
 
     @Transactional
@@ -80,59 +80,59 @@ public class GoodsWriteService {
         goodsSpecRelMapper.delete(Wrappers.<GoodsSpecRel>lambdaQuery().eq(GoodsSpecRel::getGoodsId, goodsId));
         insertSpecRel(goodsId, castList(data.get("newSpecList")));
         goodsSkuMapper.delete(Wrappers.<GoodsSku>lambdaQuery().eq(GoodsSku::getGoodsId, goodsId));
-        insertSkuList(goodsId, intVal(data.get("spec_type"), 0), castList(data.get("newSkuList")));
+        insertSkuList(goodsId, intVal(data.get("specType"), 0), castList(data.get("newSkuList")));
     }
 
     // ------------------------------------------------------------------ 商品主体
 
     private Goods buildGoods(Map<String, Object> data, Integer goodsId) {
         int now = (int) (System.currentTimeMillis() / 1000);
-        int specType = intVal(data.get("spec_type"), 0);
+        int specType = intVal(data.get("specType"), 0);
 
         Goods g = new Goods();
         if (goodsId != null) {
             g.setGoodsId(goodsId);
         }
-        g.setGoodsType(intVal(data.get("goods_type"), 10));
-        g.setGoodsName(str(data.get("goods_name"), ""));
-        g.setGoodsNo(str(data.get("goods_no"), ""));
-        g.setVideoId(intVal(data.get("video_id"), 0));
-        g.setVideoCoverId(intVal(data.get("video_cover_id"), 0));
-        g.setSellingPoint(str(data.get("selling_point"), ""));
+        g.setGoodsType(intVal(data.get("goodsType"), 10));
+        g.setGoodsName(str(data.get("goodsName"), ""));
+        g.setGoodsNo(str(data.get("goodsNo"), ""));
+        g.setVideoId(intVal(data.get("videoId"), 0));
+        g.setVideoCoverId(intVal(data.get("videoCoverId"), 0));
+        g.setSellingPoint(str(data.get("sellingPoint"), ""));
         g.setSpecType(specType);
-        g.setDeductStockType(intVal(data.get("deduct_stock_type"), 20));
-        g.setIsRestrict(intVal(data.get("is_restrict"), 0));
-        g.setRestrictTotal(intVal(data.get("restrict_total"), 0));
-        g.setRestrictSingle(intVal(data.get("restrict_single"), 0));
+        g.setDeductStockType(intVal(data.get("deductStockType"), 20));
+        g.setIsRestrict(intVal(data.get("isRestrict"), 0));
+        g.setRestrictTotal(intVal(data.get("restrictTotal"), 0));
+        g.setRestrictSingle(intVal(data.get("restrictSingle"), 0));
         g.setContent(str(data.get("content"), ""));
-        g.setSalesInitial(intVal(data.get("sales_initial"), 0));
-        g.setDeliveryId(intVal(data.get("delivery_id"), 0));
-        g.setIsPointsGift(intVal(data.get("is_points_gift"), 1));
-        g.setIsPointsDiscount(intVal(data.get("is_points_discount"), 1));
-        g.setIsAlonePointsDiscount(intVal(data.get("is_alone_points_discount"), 0));
-        g.setPointsDiscountConfig(str(data.get("points_discount_config"), ""));
-        g.setIsIndDeliveryType(intVal(data.get("is_ind_delivery_type"), 0));
+        g.setSalesInitial(intVal(data.get("salesInitial"), 0));
+        g.setDeliveryId(intVal(data.get("deliveryId"), 0));
+        g.setIsPointsGift(intVal(data.get("isPointsGift"), 1));
+        g.setIsPointsDiscount(intVal(data.get("isPointsDiscount"), 1));
+        g.setIsAlonePointsDiscount(intVal(data.get("isAlonePointsDiscount"), 0));
+        g.setPointsDiscountConfig(str(data.get("pointsDiscountConfig"), ""));
+        g.setIsIndDeliveryType(intVal(data.get("isIndDeliveryType"), 0));
         g.setStatus(intVal(data.get("status"), 10));
         g.setSort(intVal(data.get("sort"), 0));
         g.setIsDelete(0);
-        g.setStoreId(intVal(data.get("store_id"), STORE_ID));
+        g.setStoreId(intVal(data.get("storeId"), STORE_ID));
         g.setUpdateTime(now);
         if (goodsId == null) {
             g.setSalesActual(0);
             g.setCreateTime(now);
         }
         // 配送方式:库内为 json 字符串
-        List<Integer> deliveryType = intList(data.get("delivery_type"));
+        List<Integer> deliveryType = intList(data.get("deliveryType"));
         g.setDeliveryType(deliveryType);
         // 会员折扣
-        int isEnableGrade = intVal(data.get("is_enable_grade"), 1);
-        int isAloneGrade = intVal(data.get("is_alone_grade"), 0);
+        int isEnableGrade = intVal(data.get("isEnableGrade"), 1);
+        int isAloneGrade = intVal(data.get("isAloneGrade"), 0);
         if (isEnableGrade == 0) {
             isAloneGrade = 0;
         }
         g.setIsEnableGrade(isEnableGrade);
         g.setIsAloneGrade(isAloneGrade);
-        g.setAloneGradeEquity(buildAloneGradeEquity(data.get("alone_grade_equity"), isAloneGrade));
+        g.setAloneGradeEquity(buildAloneGradeEquity(data.get("aloneGradeEquity"), isAloneGrade));
 
         // 价格与库存区间
         if (specType == 20) {
@@ -145,13 +145,13 @@ public class GoodsWriteService {
             g.setLinePriceMin(linePrices[0]);
             g.setLinePriceMax(linePrices[1]);
         } else if (specType == 10) {
-            BigDecimal goodsPrice = decimal(data.get("goods_price"));
-            BigDecimal linePrice = decimal(data.get("line_price"));
+            BigDecimal goodsPrice = decimal(data.get("goodsPrice"));
+            BigDecimal linePrice = decimal(data.get("linePrice"));
             g.setGoodsPriceMin(goodsPrice);
             g.setGoodsPriceMax(goodsPrice);
             g.setLinePriceMin(linePrice);
             g.setLinePriceMax(linePrice);
-            g.setStockTotal(intVal(data.get("stock_num"), 0));
+            g.setStockTotal(intVal(data.get("stockNum"), 0));
         }
 
         // 规格与 sku 数据生成(写入 spec / spec_value 表并回填 ID)
@@ -164,10 +164,10 @@ public class GoodsWriteService {
             data.put("newSkuList", getNewSkuList(newSpecList, skuList));
         } else if (specType == 10) {
             Map<String, Object> skuItem = new LinkedHashMap<>();
-            skuItem.put("goods_price", data.get("goods_price"));
-            skuItem.put("line_price", data.get("line_price"));
-            skuItem.put("stock_num", data.get("stock_num"));
-            skuItem.put("goods_weight", data.get("goods_weight"));
+            skuItem.put("goodsPrice", data.get("goodsPrice"));
+            skuItem.put("linePrice", data.get("linePrice"));
+            skuItem.put("stockNum", data.get("stockNum"));
+            skuItem.put("goodsWeight", data.get("goodsWeight"));
             data.put("newSkuList", List.of(skuItem));
         } else {
             data.put("newSpecList", List.of());
@@ -195,7 +195,7 @@ public class GoodsWriteService {
     private void checkSpecData(List<Map<String, Object>> specList) {
         List<String> names = new ArrayList<>();
         for (Map<String, Object> item : specList) {
-            names.add(str(item.get("spec_name"), ""));
+            names.add(str(item.get("specName"), ""));
         }
         if (names.size() != names.stream().distinct().count()) {
             throw new BizException("很抱歉,不能存在重复的规格组");
@@ -203,7 +203,7 @@ public class GoodsWriteService {
         for (Map<String, Object> item : specList) {
             List<String> values = new ArrayList<>();
             for (Map<String, Object> value : castList(item.get("valueList"))) {
-                values.add(str(value.get("spec_value"), ""));
+                values.add(str(value.get("specValue"), ""));
             }
             if (values.size() != values.stream().distinct().count()) {
                 throw new BizException("很抱歉,不能存在重复的规格值");
@@ -216,7 +216,7 @@ public class GoodsWriteService {
         int now = (int) (System.currentTimeMillis() / 1000);
         List<Map<String, Object>> result = new ArrayList<>();
         for (Map<String, Object> item : specList) {
-            String specName = str(item.get("spec_name"), "");
+            String specName = str(item.get("specName"), "");
             Spec spec = specMapper.selectOne(Wrappers.<Spec>lambdaQuery()
                     .eq(Spec::getSpecName, specName)
                     .eq(Spec::getStoreId, storeId)
@@ -229,7 +229,7 @@ public class GoodsWriteService {
                 specMapper.insert(spec);
             }
             Map<String, Object> group = new LinkedHashMap<>(item);
-            group.put("spec_id", spec.getSpecId());
+            group.put("specId", spec.getSpecId());
             group.put("valueList", getNewValueList(spec.getSpecId(), castList(item.get("valueList")), storeId));
             result.add(group);
         }
@@ -240,7 +240,7 @@ public class GoodsWriteService {
         int now = (int) (System.currentTimeMillis() / 1000);
         List<Map<String, Object>> result = new ArrayList<>();
         for (Map<String, Object> item : valueList) {
-            String value = str(item.get("spec_value"), "");
+            String value = str(item.get("specValue"), "");
             SpecValue specValue = specValueMapper.selectOne(Wrappers.<SpecValue>lambdaQuery()
                     .eq(SpecValue::getSpecId, specId)
                     .eq(SpecValue::getSpecValue, value)
@@ -255,7 +255,7 @@ public class GoodsWriteService {
                 specValueMapper.insert(specValue);
             }
             Map<String, Object> valueItem = new LinkedHashMap<>(item);
-            valueItem.put("spec_value_id", specValue.getSpecValueId());
+            valueItem.put("specValueId", specValue.getSpecValueId());
             result.add(valueItem);
         }
         return result;
@@ -282,14 +282,14 @@ public class GoodsWriteService {
                 if (value == null) {
                     continue;
                 }
-                specValueIds.add(intVal(value.get("spec_value_id"), 0));
+                specValueIds.add(intVal(value.get("specValueId"), 0));
                 Map<String, Object> prop = new LinkedHashMap<>();
                 Map<String, Object> groupInfo = new LinkedHashMap<>();
-                groupInfo.put("name", str(group.get("spec_name"), ""));
-                groupInfo.put("id", intVal(group.get("spec_id"), 0));
+                groupInfo.put("name", str(group.get("specName"), ""));
+                groupInfo.put("id", intVal(group.get("specId"), 0));
                 Map<String, Object> valueInfo = new LinkedHashMap<>();
-                valueInfo.put("name", str(value.get("spec_value"), ""));
-                valueInfo.put("id", intVal(value.get("spec_value_id"), 0));
+                valueInfo.put("name", str(value.get("specValue"), ""));
+                valueInfo.put("id", intVal(value.get("specValueId"), 0));
                 prop.put("group", groupInfo);
                 prop.put("value", valueInfo);
                 goodsProps.add(prop);
@@ -297,7 +297,7 @@ public class GoodsWriteService {
             Map<String, Object> item = new LinkedHashMap<>(sku);
             item.put("specValueIds", specValueIds);
             item.put("goodsProps", goodsProps);
-            item.put("goods_sku_id", String.join("_", specValueIds.stream().map(String::valueOf).toList()));
+            item.put("goodsSkuId", String.join("_", specValueIds.stream().map(String::valueOf).toList()));
             result.add(item);
         }
         return result;
@@ -383,12 +383,12 @@ public class GoodsWriteService {
     private void insertSpecRel(int goodsId, List<Map<String, Object>> specList) {
         int now = (int) (System.currentTimeMillis() / 1000);
         for (Map<String, Object> item : specList) {
-            int specId = intVal(item.get("spec_id"), 0);
+            int specId = intVal(item.get("specId"), 0);
             for (Map<String, Object> value : castList(item.get("valueList"))) {
                 GoodsSpecRel rel = new GoodsSpecRel();
                 rel.setGoodsId(goodsId);
                 rel.setSpecId(specId);
-                rel.setSpecValueId(intVal(value.get("spec_value_id"), 0));
+                rel.setSpecValueId(intVal(value.get("specValueId"), 0));
                 rel.setStoreId(STORE_ID);
                 rel.setCreateTime(now);
                 goodsSpecRelMapper.insert(rel);
@@ -405,10 +405,10 @@ public class GoodsWriteService {
             sku.setGoodsSkuId("0");
             sku.setImageId(0);
             sku.setGoodsSkuNo("");
-            sku.setGoodsPrice(decimal(item.get("goods_price")));
-            sku.setLinePrice(decimal(item.get("line_price")));
-            sku.setStockNum(intVal(item.get("stock_num"), 0));
-            sku.setGoodsWeight(doubleVal(item.get("goods_weight")));
+            sku.setGoodsPrice(decimal(item.get("goodsPrice")));
+            sku.setLinePrice(decimal(item.get("linePrice")));
+            sku.setStockNum(intVal(item.get("stockNum"), 0));
+            sku.setGoodsWeight(doubleVal(item.get("goodsWeight")));
             sku.setGoodsProps("");
             sku.setSpecValueIds("");
             sku.setStoreId(STORE_ID);
@@ -423,16 +423,16 @@ public class GoodsWriteService {
         for (Map<String, Object> item : skuList) {
             GoodsSku sku = new GoodsSku();
             sku.setGoodsId(goodsId);
-            sku.setGoodsSkuId(str(item.get("goods_sku_id"), "0"));
-            sku.setImageId(intVal(item.get("image_id"), 0));
-            sku.setGoodsSkuNo(str(item.get("goods_sku_no"), ""));
+            sku.setGoodsSkuId(str(item.get("goodsSkuId"), "0"));
+            sku.setImageId(intVal(item.get("imageId"), 0));
+            sku.setGoodsSkuNo(str(item.get("goodsSkuNo"), ""));
             // 对齐 PHP:goods_price ?: 0.01,line_price ?: 0
-            BigDecimal goodsPrice = decimal(item.get("goods_price"));
+            BigDecimal goodsPrice = decimal(item.get("goodsPrice"));
             sku.setGoodsPrice(goodsPrice.compareTo(BigDecimal.ZERO) == 0
                     ? new BigDecimal("0.01") : goodsPrice);
-            sku.setLinePrice(decimal(item.get("line_price")));
-            sku.setStockNum(intVal(item.get("stock_num"), 0));
-            sku.setGoodsWeight(doubleVal(item.get("goods_weight")));
+            sku.setLinePrice(decimal(item.get("linePrice")));
+            sku.setStockNum(intVal(item.get("stockNum"), 0));
+            sku.setGoodsWeight(doubleVal(item.get("goodsWeight")));
             sku.setGoodsProps(PhpStr.jsonEncode(item.get("goodsProps")));
             sku.setSpecValueIds(PhpStr.jsonEncode(item.get("specValueIds")));
             sku.setStoreId(STORE_ID);
@@ -445,7 +445,7 @@ public class GoodsWriteService {
     // ------------------------------------------------------------------ 工具
 
     private int stockTotal(List<Map<String, Object>> skuList) {
-        return skuList.stream().mapToInt(item -> intVal(item.get("stock_num"), 0)).sum();
+        return skuList.stream().mapToInt(item -> intVal(item.get("stockNum"), 0)).sum();
     }
 
     /** 价格区间:过滤空/0 值后取 min/max,全空返回 [0, 0] */

+ 18 - 18
yoshop-java/src/main/java/cn/yoshop/store/service/MarketingService.java

@@ -112,28 +112,28 @@ public class MarketingService {
         if (form.containsKey("name")) {
             coupon.setName(Params.str(form, "name", ""));
         }
-        if (form.containsKey("coupon_type")) {
-            coupon.setCouponType(Params.intVal(form, "coupon_type", 10));
+        if (form.containsKey("couponType")) {
+            coupon.setCouponType(Params.intVal(form, "couponType", 10));
         }
-        if (form.containsKey("reduce_price")) {
-            coupon.setReducePrice(decimal(form.get("reduce_price")));
+        if (form.containsKey("reducePrice")) {
+            coupon.setReducePrice(decimal(form.get("reducePrice")));
         }
         if (form.containsKey("discount")) {
             // PHP setDiscountAttr: 出参是 0-10 的折扣率,库内存 0-100
             coupon.setDiscount(decimal(form.get("discount")).multiply(BigDecimal.TEN)
                     .setScale(0, RoundingMode.HALF_UP).intValue());
         }
-        if (form.containsKey("min_price")) {
-            coupon.setMinPrice(decimal(form.get("min_price")));
+        if (form.containsKey("minPrice")) {
+            coupon.setMinPrice(decimal(form.get("minPrice")));
         }
-        if (form.containsKey("expire_day")) {
-            coupon.setExpireDay(Params.intVal(form, "expire_day", 0));
+        if (form.containsKey("expireDay")) {
+            coupon.setExpireDay(Params.intVal(form, "expireDay", 0));
         }
-        if (form.containsKey("apply_range")) {
-            coupon.setApplyRange(Params.intVal(form, "apply_range", 10));
+        if (form.containsKey("applyRange")) {
+            coupon.setApplyRange(Params.intVal(form, "applyRange", 10));
         }
-        if (form.containsKey("total_num")) {
-            coupon.setTotalNum(Params.intVal(form, "total_num", 0));
+        if (form.containsKey("totalNum")) {
+            coupon.setTotalNum(Params.intVal(form, "totalNum", 0));
         }
         if (form.containsKey("status")) {
             coupon.setStatus(Params.intVal(form, "status", 1));
@@ -146,7 +146,7 @@ public class MarketingService {
         }
 
         // 有效期
-        int expireType = Params.intVal(form, "expire_type", 10);
+        int expireType = Params.intVal(form, "expireType", 10);
         coupon.setExpireType(expireType);
         if (expireType == 10) {
             coupon.setStartTime(0);
@@ -166,7 +166,7 @@ public class MarketingService {
         if (applyRange == 10) {
             coupon.setApplyRangeConfig("[]");
         } else {
-            Object config = form.get("apply_range_config");
+            Object config = form.get("applyRangeConfig");
             coupon.setApplyRangeConfig(PhpStr.jsonEncode(config == null ? new ArrayList<>() : config));
         }
     }
@@ -236,14 +236,14 @@ public class MarketingService {
     }
 
     private void applyPlanForm(RechargePlan plan, Map<String, Object> form) {
-        if (form.containsKey("plan_name")) {
-            plan.setPlanName(Params.str(form, "plan_name", ""));
+        if (form.containsKey("planName")) {
+            plan.setPlanName(Params.str(form, "planName", ""));
         }
         if (form.containsKey("money")) {
             plan.setMoney(decimal(form.get("money")));
         }
-        if (form.containsKey("gift_money")) {
-            plan.setGiftMoney(decimal(form.get("gift_money")));
+        if (form.containsKey("giftMoney")) {
+            plan.setGiftMoney(decimal(form.get("giftMoney")));
         }
         if (form.containsKey("sort")) {
             plan.setSort(Params.intVal(form, "sort", 0));

+ 1 - 1
yoshop-java/src/main/java/cn/yoshop/store/service/MemberWriteService.java

@@ -131,7 +131,7 @@ public class MemberWriteService {
     @Transactional
     public void updateGrade(int userId, Map<String, Object> form, int storeId) {
         User user = requireUser(userId);
-        Integer newGradeId = cn.yoshop.common.util.Params.intOrNull(form, "grade_id");
+        Integer newGradeId = cn.yoshop.common.util.Params.intOrNull(form, "gradeId");
         if (newGradeId == null) {
             newGradeId = cn.yoshop.common.util.Params.intOrNull(form, "gradeId");
         }

+ 56 - 56
yoshop-java/src/main/java/cn/yoshop/store/service/OrderExportService.java

@@ -158,36 +158,36 @@ public class OrderExportService {
         Map<String, String> row = new LinkedHashMap<>();
         OrderAddress address = order.getAddress();
         PaymentTrade trade = order.getTrade();
-        row.put("order_id", tab(order.getOrderId()));
-        row.put("order_no", tab(order.getOrderNo()));
-        row.put("goods_detail", goodsDetail(order));
-        row.put("total_price", tab(money(order.getTotalPrice())) + "元");
-        row.put("coupon_money", tab(money(order.getCouponMoney())) + "元");
-        row.put("points_money", tab(money(order.getPointsMoney())) + "元");
+        row.put("orderId", tab(order.getOrderId()));
+        row.put("orderNo", tab(order.getOrderNo()));
+        row.put("goodsDetail", goodsDetail(order));
+        row.put("totalPrice", tab(money(order.getTotalPrice())) + "元");
+        row.put("couponMoney", tab(money(order.getCouponMoney())) + "元");
+        row.put("pointsMoney", tab(money(order.getPointsMoney())) + "元");
         String symbol = order.getUpdatePrice() == null || order.getUpdatePrice().signum() >= 0 ? "+" : "-";
         BigDecimal diff = order.getUpdatePrice() == null ? BigDecimal.ZERO : order.getUpdatePrice().abs();
-        row.put("update_price", symbol + money(diff) + "元");
-        row.put("express_price", tab(money(order.getExpressPrice())) + "元");
-        row.put("pay_price", tab(money(order.getPayPrice())) + "元");
-        row.put("pay_method", payMethodName(order.getPayMethod()));
-        row.put("create_time", tab(TimeUtil.format(order.getCreateTime())));
-        row.put("user_info", tab(order.getUser() == null ? "" : order.getUser().getNickName()));
-        row.put("buyer_remark", tab(order.getBuyerRemark()));
-        row.put("delivery_type", deliveryTypeName(order.getDeliveryType()));
-        row.put("receipt_name", address == null ? "" : tab(address.getName()));
-        row.put("receipt_phone", address == null ? "" : tab(address.getPhone()));
-        row.put("receipt_address", address == null ? "" : fullAddress(address));
-        row.put("pay_status", payStatusName(order.getPayStatus()));
-        row.put("pay_time", TimeUtil.formatOrBlank(order.getPayTime()));
-        row.put("delivery_status", deliveryStatusName(order.getDeliveryStatus()));
-        row.put("delivery_time", TimeUtil.formatOrBlank(order.getDeliveryTime()));
-        row.put("receipt_status", receiptStatusName(order.getReceiptStatus()));
-        row.put("receipt_time", TimeUtil.formatOrBlank(order.getReceiptTime()));
-        row.put("order_status", orderStatusName(order.getOrderStatus()));
-        row.put("is_comment", order.getIsComment() != null && order.getIsComment() != 0 ? "是" : "否");
-        row.put("order_source", orderSourceName(order.getOrderSource()));
-        row.put("out_trade_no", trade == null ? "" : tab(trade.getOutTradeNo()));
-        row.put("trade_no", trade == null ? "" : tab(trade.getTradeNo()));
+        row.put("updatePrice", symbol + money(diff) + "元");
+        row.put("expressPrice", tab(money(order.getExpressPrice())) + "元");
+        row.put("payPrice", tab(money(order.getPayPrice())) + "元");
+        row.put("payMethod", payMethodName(order.getPayMethod()));
+        row.put("createTime", tab(TimeUtil.format(order.getCreateTime())));
+        row.put("userInfo", tab(order.getUser() == null ? "" : order.getUser().getNickName()));
+        row.put("buyerRemark", tab(order.getBuyerRemark()));
+        row.put("deliveryType", deliveryTypeName(order.getDeliveryType()));
+        row.put("receiptName", address == null ? "" : tab(address.getName()));
+        row.put("receiptPhone", address == null ? "" : tab(address.getPhone()));
+        row.put("receiptAddress", address == null ? "" : fullAddress(address));
+        row.put("payStatus", payStatusName(order.getPayStatus()));
+        row.put("payTime", TimeUtil.formatOrBlank(order.getPayTime()));
+        row.put("deliveryStatus", deliveryStatusName(order.getDeliveryStatus()));
+        row.put("deliveryTime", TimeUtil.formatOrBlank(order.getDeliveryTime()));
+        row.put("receiptStatus", receiptStatusName(order.getReceiptStatus()));
+        row.put("receiptTime", TimeUtil.formatOrBlank(order.getReceiptTime()));
+        row.put("orderStatus", orderStatusName(order.getOrderStatus()));
+        row.put("isComment", order.getIsComment() != null && order.getIsComment() != 0 ? "是" : "否");
+        row.put("orderSource", orderSourceName(order.getOrderSource()));
+        row.put("outTradeNo", trade == null ? "" : tab(trade.getOutTradeNo()));
+        row.put("tradeNo", trade == null ? "" : tab(trade.getTradeNo()));
         return row;
     }
 
@@ -244,34 +244,34 @@ public class OrderExportService {
     /** 订单记录字典(PHP Export::dictionary),顺序即 Excel 列顺序 */
     private Map<String, String> dictionary() {
         Map<String, String> map = new LinkedHashMap<>();
-        map.put("order_id", "订单ID");
-        map.put("order_no", "订单号");
-        map.put("goods_detail", "商品信息");
-        map.put("total_price", "商品总额");
-        map.put("coupon_money", "优惠券抵扣金额");
-        map.put("points_money", "积分抵扣金额");
-        map.put("update_price", "后台改价");
-        map.put("express_price", "运费金额");
-        map.put("pay_price", "订单实付款");
-        map.put("pay_method", "支付方式");
-        map.put("create_time", "下单时间");
-        map.put("user_info", "买家信息");
-        map.put("buyer_remark", "买家留言");
-        map.put("delivery_type", "配送方式");
-        map.put("receipt_name", "收货人");
-        map.put("receipt_phone", "联系电话");
-        map.put("receipt_address", "收货地址");
-        map.put("pay_status", "付款状态");
-        map.put("pay_time", "付款时间");
-        map.put("delivery_status", "发货状态");
-        map.put("delivery_time", "发货时间");
-        map.put("receipt_status", "收货状态");
-        map.put("receipt_time", "收货时间");
-        map.put("order_status", "订单状态");
-        map.put("is_comment", "是否已评价");
-        map.put("order_source", "订单来源");
-        map.put("out_trade_no", "第三方支付订单号");
-        map.put("trade_no", "支付流水号");
+        map.put("orderId", "订单ID");
+        map.put("orderNo", "订单号");
+        map.put("goodsDetail", "商品信息");
+        map.put("totalPrice", "商品总额");
+        map.put("couponMoney", "优惠券抵扣金额");
+        map.put("pointsMoney", "积分抵扣金额");
+        map.put("updatePrice", "后台改价");
+        map.put("expressPrice", "运费金额");
+        map.put("payPrice", "订单实付款");
+        map.put("payMethod", "支付方式");
+        map.put("createTime", "下单时间");
+        map.put("userInfo", "买家信息");
+        map.put("buyerRemark", "买家留言");
+        map.put("deliveryType", "配送方式");
+        map.put("receiptName", "收货人");
+        map.put("receiptPhone", "联系电话");
+        map.put("receiptAddress", "收货地址");
+        map.put("payStatus", "付款状态");
+        map.put("payTime", "付款时间");
+        map.put("deliveryStatus", "发货状态");
+        map.put("deliveryTime", "发货时间");
+        map.put("receiptStatus", "收货状态");
+        map.put("receiptTime", "收货时间");
+        map.put("orderStatus", "订单状态");
+        map.put("isComment", "是否已评价");
+        map.put("orderSource", "订单来源");
+        map.put("outTradeNo", "第三方支付订单号");
+        map.put("tradeNo", "支付流水号");
         return map;
     }
 

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/store/service/OrderRefundService.java

@@ -195,10 +195,10 @@ public class OrderRefundService {
     @Transactional
     public void audit(int orderRefundId, Map<String, Object> form) {
         OrderRefund refund = requireRefund(orderRefundId);
-        int auditStatus = Params.intVal(form, "auditStatus", Params.intVal(form, "audit_status", 0));
-        String refuseDesc = Params.str(form, "refuseDesc", Params.str(form, "refuse_desc", ""));
+        int auditStatus = Params.intVal(form, "auditStatus", Params.intVal(form, "auditStatus", 0));
+        String refuseDesc = Params.str(form, "refuseDesc", Params.str(form, "refuseDesc", ""));
         Integer addressId = Params.argInt(form, "addressId") != null
-                ? Params.argInt(form, "addressId") : Params.argInt(form, "address_id");
+                ? Params.argInt(form, "addressId") : Params.argInt(form, "addressId");
 
         if (auditStatus == AUDIT_REJECTED && refuseDesc.isEmpty()) {
             throw new BizException("请输入拒绝原因");
@@ -260,7 +260,7 @@ public class OrderRefundService {
         }
         OrderGoods orderGoods = orderGoodsMapper.selectById(refund.getOrderGoodsId());
         BigDecimal refundMoney = decimal(form.get("refundMoney") != null
-                ? form.get("refundMoney") : form.get("refund_money"));
+                ? form.get("refundMoney") : form.get("refundMoney"));
 
         BigDecimal payPrice = order.getPayPrice() == null ? BigDecimal.ZERO : order.getPayPrice();
         BigDecimal goodsPayPrice = orderGoods == null || orderGoods.getTotalPayPrice() == null

+ 2 - 2
yoshop-java/src/main/java/cn/yoshop/store/service/OrderService.java

@@ -285,7 +285,7 @@ public class OrderService {
         node.remove("delivery");
         if (node.get("user") instanceof ObjectNode user) {
             user.remove("avatar");
-            user.remove("avatar_url");
+            user.remove("avatarUrl");
         }
         return node;
     }
@@ -318,7 +318,7 @@ public class OrderService {
         // 详情只 with('user')、未加载 avatar 关联,PHP 对象里没有 avatar/avatar_url 键
         if (node.get("user") instanceof ObjectNode user) {
             user.remove("avatar");
-            user.remove("avatar_url");
+            user.remove("avatarUrl");
         }
         Map<String, Object> data = new LinkedHashMap<>();
         data.put("detail", node);

+ 8 - 8
yoshop-java/src/main/java/cn/yoshop/store/service/PageDesignService.java

@@ -98,14 +98,14 @@ public class PageDesignService {
             return null;
         }
         Map<String, Object> out = new LinkedHashMap<>();
-        out.put("page_id", page.getPageId());
-        out.put("page_type", page.getPageType());
-        out.put("page_name", page.getPageName());
-        out.put("page_data", mergePageData(page.getPageData()));
-        out.put("store_id", page.getStoreId());
-        out.put("is_delete", page.getIsDelete());
-        out.put("create_time", TimeUtil.format(page.getCreateTime()));
-        out.put("update_time", TimeUtil.format(page.getUpdateTime()));
+        out.put("pageId", page.getPageId());
+        out.put("pageType", page.getPageType());
+        out.put("pageName", page.getPageName());
+        out.put("pageData", mergePageData(page.getPageData()));
+        out.put("storeId", page.getStoreId());
+        out.put("isDelete", page.getIsDelete());
+        out.put("createTime", TimeUtil.format(page.getCreateTime()));
+        out.put("updateTime", TimeUtil.format(page.getUpdateTime()));
         return out;
     }
 

+ 12 - 12
yoshop-java/src/main/java/cn/yoshop/store/service/PaymentSettingService.java

@@ -57,10 +57,10 @@ public class PaymentSettingService {
             Map<String, Object> method = new LinkedHashMap<>();
             method.put("method", row.getMethod());
             method.put("client", row.getClient());
-            method.put("is_must_template", nvl(row.getIsMustTemplate()) != 0);
-            method.put("template_id", nvl(row.getTemplateId()));
-            method.put("is_enable", nvl(row.getIsEnable()) != 0);
-            method.put("is_default", nvl(row.getIsDefault()) != 0);
+            method.put("isMustTemplate", nvl(row.getIsMustTemplate()) != 0);
+            method.put("templateId", nvl(row.getTemplateId()));
+            method.put("isEnable", nvl(row.getIsEnable()) != 0);
+            method.put("isDefault", nvl(row.getIsDefault()) != 0);
             Object others = PhpStr.jsonDecodeArray(row.getOthers());
             method.put("others", others == null ? new ArrayList<>() : others);
 
@@ -113,10 +113,10 @@ public class PaymentSettingService {
                 Payment payment = new Payment();
                 payment.setClient(client);
                 payment.setMethod(str(m.get("method")));
-                payment.setIsMustTemplate(boolInt(m.get("is_must_template")));
-                payment.setTemplateId(intOf(m.get("template_id")));
-                payment.setIsEnable(boolInt(m.get("is_enable")));
-                payment.setIsDefault(boolInt(m.get("is_default")));
+                payment.setIsMustTemplate(boolInt(m.get("isMustTemplate")));
+                payment.setTemplateId(intOf(m.get("templateId")));
+                payment.setIsEnable(boolInt(m.get("isEnable")));
+                payment.setIsDefault(boolInt(m.get("isDefault")));
                 payment.setOthers("[]");
                 payment.setStoreId(storeId);
                 payment.setCreateTime(now);
@@ -147,10 +147,10 @@ public class PaymentSettingService {
             Map<String, Object> item = new LinkedHashMap<>();
             item.put("key", key);
             item.put("method", method);
-            item.put("is_must_template", !"balance".equals(method));
-            item.put("template_id", 0);
-            item.put("is_enable", "balance".equals(method));
-            item.put("is_default", false);
+            item.put("isMustTemplate", !"balance".equals(method));
+            item.put("templateId", 0);
+            item.put("isEnable", "balance".equals(method));
+            item.put("isDefault", false);
             item.put("others", new ArrayList<>());
             methods.put(client + "-" + method, item);
         }

+ 15 - 15
yoshop-java/src/main/java/cn/yoshop/store/service/PermissionService.java

@@ -155,7 +155,7 @@ public class PermissionService {
     /** 新增管理员 */
     @Transactional
     public void addAdmin(Map<String, Object> data, int storeId) {
-        String userName = lower(Params.str(data, "user_name", ""));
+        String userName = lower(Params.str(data, "userName", ""));
         if (userName.isEmpty()) {
             throw new BizException("请输入用户名");
         }
@@ -163,7 +163,7 @@ public class PermissionService {
             throw new BizException("用户名已存在");
         }
         String password = Params.str(data, "password", "");
-        if (!password.equals(Params.str(data, "password_confirm", ""))) {
+        if (!password.equals(Params.str(data, "passwordConfirm", ""))) {
             throw new BizException("确认密码不正确");
         }
         List<Integer> roles = intList(data.get("roles"));
@@ -175,7 +175,7 @@ public class PermissionService {
         StoreUser user = new StoreUser();
         user.setUserName(userName);
         user.setPassword(PasswordUtil.hash(password));
-        user.setRealName(Params.strOrNull(data, "real_name"));
+        user.setRealName(Params.strOrNull(data, "realName"));
         user.setSort(Params.intVal(data, "sort", 0));
         user.setStoreId(storeId);
         user.setIsSuper(0);
@@ -194,13 +194,13 @@ public class PermissionService {
         if (user == null) {
             throw new BizException("很抱歉,管理员信息不存在");
         }
-        String userName = lower(Params.str(data, "user_name", user.getUserName()));
+        String userName = lower(Params.str(data, "userName", user.getUserName()));
         if (!userName.equals(user.getUserName()) && checkUserNameExist(userName)) {
             throw new BizException("用户名已存在");
         }
         String password = Params.str(data, "password", "");
         boolean isSuper = user.getIsSuper() != null && user.getIsSuper() == 1;
-        if (!password.isEmpty() && !password.equals(Params.str(data, "password_confirm", ""))) {
+        if (!password.isEmpty() && !password.equals(Params.str(data, "passwordConfirm", ""))) {
             throw new BizException("确认密码不正确");
         }
         List<Integer> roles = intList(data.get("roles"));
@@ -212,8 +212,8 @@ public class PermissionService {
         if (!password.isEmpty()) {
             user.setPassword(PasswordUtil.hash(password));
         }
-        if (data.containsKey("real_name")) {
-            user.setRealName(Params.strOrNull(data, "real_name"));
+        if (data.containsKey("realName")) {
+            user.setRealName(Params.strOrNull(data, "realName"));
         }
         if (data.containsKey("sort")) {
             user.setSort(Params.intVal(data, "sort", 0));
@@ -252,10 +252,10 @@ public class PermissionService {
             throw new BizException("很抱歉,管理员信息不存在");
         }
         String password = Params.str(data, "password", "");
-        if (!password.isEmpty() && !password.equals(Params.str(data, "password_confirm", ""))) {
+        if (!password.isEmpty() && !password.equals(Params.str(data, "passwordConfirm", ""))) {
             throw new BizException("确认密码不正确");
         }
-        String userName = lower(Params.str(data, "user_name", user.getUserName()));
+        String userName = lower(Params.str(data, "userName", user.getUserName()));
         if (!userName.equals(user.getUserName()) && checkUserNameExist(userName)) {
             throw new BizException("用户名已存在");
         }
@@ -263,8 +263,8 @@ public class PermissionService {
         if (!password.isEmpty()) {
             user.setPassword(PasswordUtil.hash(password));
         }
-        if (data.containsKey("real_name")) {
-            user.setRealName(Params.strOrNull(data, "real_name"));
+        if (data.containsKey("realName")) {
+            user.setRealName(Params.strOrNull(data, "realName"));
         }
         user.setUpdateTime((int) (System.currentTimeMillis() / 1000));
         storeUserMapper.updateById(user);
@@ -318,8 +318,8 @@ public class PermissionService {
         }
         int now = (int) (System.currentTimeMillis() / 1000);
         StoreRole role = new StoreRole();
-        role.setRoleName(Params.str(data, "role_name", ""));
-        role.setParentId(Params.intVal(data, "parent_id", 0));
+        role.setRoleName(Params.str(data, "roleName", ""));
+        role.setParentId(Params.intVal(data, "parentId", 0));
         role.setSort(Params.intVal(data, "sort", 100));
         role.setStoreId(storeId);
         role.setCreateTime(now);
@@ -339,7 +339,7 @@ public class PermissionService {
         if (menus.isEmpty()) {
             throw new BizException("菜单权限不能为空,请重新选择");
         }
-        int parentId = Params.intVal(data, "parent_id", 0);
+        int parentId = Params.intVal(data, "parentId", 0);
         if (parentId > 0) {
             List<Integer> parentIds = new ArrayList<>();
             collectParentIds(storeRoleMapper.selectList(null), parentId, parentIds);
@@ -347,7 +347,7 @@ public class PermissionService {
                 throw new BizException("上级角色不允许设置为当前子角色");
             }
         }
-        role.setRoleName(Params.str(data, "role_name", role.getRoleName()));
+        role.setRoleName(Params.str(data, "roleName", role.getRoleName()));
         role.setParentId(parentId);
         role.setSort(Params.intVal(data, "sort", role.getSort() == null ? 100 : role.getSort()));
         role.setUpdateTime((int) (System.currentTimeMillis() / 1000));

+ 3 - 3
yoshop-java/src/main/java/cn/yoshop/store/service/RechargeService.java

@@ -34,10 +34,10 @@ public class RechargeService {
 
     public PageVO<RechargeOrder> orderList(Map<String, Object> params) {
         int page = Params.intVal(params, "page", 1);
-        Integer userId = firstInt(params, "user_id", "userId");
+        Integer userId = firstInt(params, "userId");
         String search = Params.strOrNull(params, "search");
-        Integer rechargeType = firstInt(params, "recharge_type", "rechargeType");
-        Integer payStatus = firstInt(params, "pay_status", "payStatus");
+        Integer rechargeType = firstInt(params, "rechargeType");
+        Integer payStatus = firstInt(params, "payStatus");
         List<Long> between = MemberService.betweenTime(params.get("betweenTime"));
 
         IPage<RechargeOrder> result = rechargeOrderMapper.selectPageWithUser(new Page<>(page, 15),

+ 10 - 10
yoshop-java/src/main/java/cn/yoshop/store/service/SettingService.java

@@ -196,11 +196,11 @@ public class SettingService {
             DeliveryRule entity = new DeliveryRule();
             entity.setDeliveryId(deliveryId);
             entity.setRegion(PhpStr.jsonEncode(rule.get("region")));
-            entity.setRegionText(PhpStr.jsonEncode(rule.get("region_text")));
+            entity.setRegionText(PhpStr.jsonEncode(rule.get("regionText")));
             entity.setFirst(doubleOf(rule.get("first")));
-            entity.setFirstFee(decimalOf(rule.get("first_fee")));
+            entity.setFirstFee(decimalOf(rule.get("firstFee")));
             entity.setAdditional(doubleOf(rule.get("additional")));
-            entity.setAdditionalFee(decimalOf(rule.get("additional_fee")));
+            entity.setAdditionalFee(decimalOf(rule.get("additionalFee")));
             entity.setStoreId(storeId);
             entity.setCreateTime(now);
             deliveryRuleMapper.insert(entity);
@@ -347,9 +347,9 @@ public class SettingService {
     }
 
     private void applyExpress(Express express, Map<String, Object> params) {
-        express.setExpressName(Params.strOrNull(params, "express_name"));
+        express.setExpressName(Params.strOrNull(params, "expressName"));
         express.setKuaidi100Code(Params.strOrNull(params, "kuaidi100_code"));
-        express.setKdniaoCode(Params.strOrNull(params, "kdniao_code"));
+        express.setKdniaoCode(Params.strOrNull(params, "kdniaoCode"));
         express.setSort(Params.intVal(params, "sort", 100));
     }
 
@@ -365,7 +365,7 @@ public class SettingService {
     public PageVO<Printer> printerList(Map<String, Object> params) {
         int page = Params.intVal(params, "page", 1);
         String search = Params.strOrNull(params, "search");
-        String type = Params.strOrNull(params, "printer_type");
+        String type = Params.strOrNull(params, "printerType");
         Page<Printer> result = printerMapper.selectPage(new Page<>(page, 15),
                 Wrappers.<Printer>lambdaQuery()
                         .eq(Printer::getIsDelete, 0)
@@ -415,11 +415,11 @@ public class SettingService {
     }
 
     private void applyPrinter(Printer printer, Map<String, Object> params) {
-        printer.setPrinterName(Params.strOrNull(params, "printer_name"));
-        printer.setPrinterType(Params.strOrNull(params, "printer_type"));
-        Object config = params.get("printer_config");
+        printer.setPrinterName(Params.strOrNull(params, "printerName"));
+        printer.setPrinterType(Params.strOrNull(params, "printerType"));
+        Object config = params.get("printerConfig");
         printer.setPrinterConfig(config == null ? "[]" : PhpStr.jsonEncode(config));
-        printer.setPrintTimes(Params.intVal(params, "print_times", 1));
+        printer.setPrintTimes(Params.intVal(params, "printTimes", 1));
         printer.setSort(Params.intVal(params, "sort", 100));
     }
 

+ 7 - 7
yoshop-java/src/main/java/cn/yoshop/store/service/StatisticsService.java

@@ -156,10 +156,10 @@ public class StatisticsService {
         List<Map<String, Object>> out = new ArrayList<>();
         for (Map<String, Object> row : rows) {
             Map<String, Object> item = new LinkedHashMap<>();
-            item.put("goods_id", row.get("goods_id"));
-            item.put("goods_name", row.get("goods_name"));
-            item.put("sales_volume", plain(row.get("sales_volume")));
-            item.put("total_sales_num", plain(row.get("total_sales_num")));
+            item.put("goodsId", row.get("goodsId"));
+            item.put("goodsName", row.get("goodsName"));
+            item.put("salesVolume", plain(row.get("salesVolume")));
+            item.put("totalSalesNum", plain(row.get("totalSalesNum")));
             out.add(item);
         }
         return out;
@@ -175,9 +175,9 @@ public class StatisticsService {
         List<Map<String, Object>> out = new ArrayList<>();
         for (User user : users) {
             Map<String, Object> item = new LinkedHashMap<>();
-            item.put("user_id", user.getUserId());
-            item.put("nick_name", user.getNickName());
-            item.put("expend_money", number2(user.getExpendMoney()));
+            item.put("userId", user.getUserId());
+            item.put("nickName", user.getNickName());
+            item.put("expendMoney", number2(user.getExpendMoney()));
             out.add(item);
         }
         return out;

+ 4 - 4
yoshop-java/src/main/java/cn/yoshop/store/service/StoreGoodsService.java

@@ -248,8 +248,8 @@ public class StoreGoodsService {
             }
             Spec spec = specMap.get(rel.getSpecId());
             Map<String, Object> group = new java.util.LinkedHashMap<>();
-            group.put("spec_id", spec == null ? rel.getSpecId() : spec.getSpecId());
-            group.put("spec_name", spec == null ? "" : spec.getSpecName());
+            group.put("specId", spec == null ? rel.getSpecId() : spec.getSpecId());
+            group.put("specName", spec == null ? "" : spec.getSpecName());
             group.put("key", groupIndex.size());
             group.put("valueList", new java.util.ArrayList<Map<String, Object>>());
             groupIndex.put(rel.getSpecId(), group);
@@ -267,8 +267,8 @@ public class StoreGoodsService {
             Map<String, Object> item = new java.util.LinkedHashMap<>();
             item.put("key", valueList.size());
             item.put("groupKey", group.get("key"));
-            item.put("spec_value_id", value == null ? rel.getSpecValueId() : value.getSpecValueId());
-            item.put("spec_value", value == null ? "" : value.getSpecValue());
+            item.put("specValueId", value == null ? rel.getSpecValueId() : value.getSpecValueId());
+            item.put("specValue", value == null ? "" : value.getSpecValue());
             valueList.add(item);
         }
         return specList;

+ 7 - 7
yoshop-java/src/main/java/cn/yoshop/store/service/StoreInfoService.java

@@ -39,23 +39,23 @@ public class StoreInfoService {
         if (store == null) {
             throw new BizException("很抱歉,商城信息不存在");
         }
-        if (!data.containsKey("logo_image_id")) {
+        if (!data.containsKey("logoImageId")) {
             store.setLogoImageId(0);
         }
-        if (data.get("store_name") != null) {
-            store.setStoreName(String.valueOf(data.get("store_name")));
+        if (data.get("storeName") != null) {
+            store.setStoreName(String.valueOf(data.get("storeName")));
         }
         if (data.get("describe") != null) {
             store.setDescribe(String.valueOf(data.get("describe")));
         }
-        if (data.get("logo_image_id") != null && !String.valueOf(data.get("logo_image_id")).isEmpty()) {
-            store.setLogoImageId((int) Double.parseDouble(String.valueOf(data.get("logo_image_id"))));
+        if (data.get("logoImageId") != null && !String.valueOf(data.get("logoImageId")).isEmpty()) {
+            store.setLogoImageId((int) Double.parseDouble(String.valueOf(data.get("logoImageId"))));
         }
         if (data.get("remark") != null) {
             store.setRemark(String.valueOf(data.get("remark")));
         }
-        if (data.get("custom_domain") != null) {
-            store.setCustomDomain(String.valueOf(data.get("custom_domain")));
+        if (data.get("customDomain") != null) {
+            store.setCustomDomain(String.valueOf(data.get("customDomain")));
         }
         if (data.get("sort") != null && !String.valueOf(data.get("sort")).isEmpty()) {
             store.setSort((int) Double.parseDouble(String.valueOf(data.get("sort"))));

+ 8 - 8
yoshop-java/src/main/java/cn/yoshop/store/service/StoreUserService.java

@@ -160,16 +160,16 @@ public class StoreUserService {
     /** 写入缓存 user 节点的字段集合与 PHP 模型 toArray() 保持一致 */
     private Map<String, Object> toCacheUser(StoreUser user) {
         Map<String, Object> m = new LinkedHashMap<>();
-        m.put("store_user_id", user.getStoreUserId());
-        m.put("user_name", user.getUserName());
+        m.put("storeUserId", user.getStoreUserId());
+        m.put("userName", user.getUserName());
         m.put("password", user.getPassword());
-        m.put("real_name", user.getRealName());
-        m.put("is_super", user.getIsSuper());
-        m.put("is_delete", user.getIsDelete());
+        m.put("realName", user.getRealName());
+        m.put("isSuper", user.getIsSuper());
+        m.put("isDelete", user.getIsDelete());
         m.put("sort", user.getSort());
-        m.put("store_id", user.getStoreId());
-        m.put("create_time", user.getCreateTime());
-        m.put("update_time", user.getUpdateTime());
+        m.put("storeId", user.getStoreId());
+        m.put("createTime", user.getCreateTime());
+        m.put("updateTime", user.getUpdateTime());
         return m;
     }
 }

+ 0 - 1
yoshop-java/src/main/resources/application.yml

@@ -23,7 +23,6 @@ spring:
     date-format: yyyy-MM-dd HH:mm:ss
     time-zone: Asia/Shanghai
     # PHP 出参全部是 snake_case(goods_id / per_page ...),全局统一
-    property-naming-strategy: SNAKE_CASE
     mapper:
       # 使用 @JsonView 区分列表/详情:未标注视图的字段默认参与序列化(否则会输出 {})
       default-view-inclusion: true