oversized = new java.util.ArrayList<>();
for (long i = 1; i <= JdProductQueryService.MAX_EXPORT_IDS + 1; i++) {
oversized.add(i);
}
- BusinessException over = assertThrows(BusinessException.class, () -> service.exportCsv(oversized));
+ BusinessException over = assertThrows(BusinessException.class, () -> service.exportCsv(oversized, null));
assertTrue(over.getMessage().contains("1000"), "超限文案必须点名上限 1000");
}
@@ -1037,7 +1049,7 @@ class AdminJdProductControllerTest {
image.setHeight(800);
when(imageMapper.selectList(any())).thenReturn(List.of(image));
- JdProductDetailVo vo = service.detail(11L, null);
+ JdProductDetailVo vo = service.detail(11L, null, null);
assertEquals(2, vo.getAttrGroups().size(), "tabs 数组逐个映射成 attrGroups(groupName=tab 字段)");
assertEquals("商品基本信息", vo.getAttrGroups().get(0).getGroupName());
@@ -1066,7 +1078,7 @@ class AdminJdProductControllerTest {
JdProductEntity broken = productEntity(11L);
broken.setAttrJson("{\"tabs\": [broken");
when(mapper.selectById(11L)).thenReturn(broken);
- JdProductDetailVo brokenVo = service.detail(11L, null);
+ JdProductDetailVo brokenVo = service.detail(11L, null, null);
assertTrue(brokenVo.getAttrGroups().isEmpty(), "解析异常落空 attrGroups,不抛 500(AC-7)");
assertEquals("{\"tabs\": [broken", brokenVo.getAttrJsonRaw(), "原文进 attrJsonRaw 兜底展示");
@@ -1074,7 +1086,7 @@ class AdminJdProductControllerTest {
JdProductEntity foreign = productEntity(11L);
foreign.setAttrJson("{\"attrs\":[{\"key\":\"x\",\"value\":\"y\"}]}");
when(mapper.selectById(11L)).thenReturn(foreign);
- JdProductDetailVo foreignVo = service.detail(11L, null);
+ JdProductDetailVo foreignVo = service.detail(11L, null, null);
assertTrue(foreignVo.getAttrGroups().isEmpty(), "非契约形状落空 attrGroups");
assertEquals("{\"attrs\":[{\"key\":\"x\",\"value\":\"y\"}]}", foreignVo.getAttrJsonRaw(),
"未识别属性不丢弃:原文兜底透出(AC-7)");
@@ -1083,7 +1095,7 @@ class AdminJdProductControllerTest {
JdProductEntity blank = productEntity(11L);
blank.setAttrJson(null);
when(mapper.selectById(11L)).thenReturn(blank);
- JdProductDetailVo blankVo = service.detail(11L, null);
+ JdProductDetailVo blankVo = service.detail(11L, null, null);
assertTrue(blankVo.getAttrGroups().isEmpty());
assertNull(blankVo.getAttrJsonRaw());
}
@@ -1112,7 +1124,7 @@ class AdminJdProductControllerTest {
brokenJson.setSaleAttrsJson("[{\"name\":");
when(skuMapper.selectList(any())).thenReturn(List.of(first, brokenJson));
- JdProductDetailVo vo = service.detail(11L, null);
+ JdProductDetailVo vo = service.detail(11L, null, null);
assertEquals(2, vo.getSkus().size(), "京麦那 12 行矩阵按入库行下发(抽屉渲染的唯一来源)");
JdProductDetailVo.SkuVo sku = vo.getSkus().get(0);
@@ -1137,14 +1149,14 @@ class AdminJdProductControllerTest {
JdProductEntity row = productEntity(11L);
row.setCompanyId(6L);
when(mapper.selectById(11L)).thenReturn(row);
- assertNotNull(service.detail(11L, null));
+ assertNotNull(service.detail(11L, null, null));
// 行不存在 ⇒ 按「商品不存在」拒绝。
when(mapper.selectById(11L)).thenReturn(null);
- BusinessException ex = assertThrows(BusinessException.class, () -> service.detail(11L, null));
+ BusinessException ex = assertThrows(BusinessException.class, () -> service.detail(11L, null, null));
assertTrue(ex.getMessage().contains("商品不存在"));
// id 非法同样拒绝。
- assertThrows(BusinessException.class, () -> service.detail(0L, null));
+ assertThrows(BusinessException.class, () -> service.detail(0L, null, null));
}
@Test
@@ -1158,9 +1170,9 @@ class AdminJdProductControllerTest {
JdProductEntity categorized = productEntity(1L);
JdProductEntity missing = productEntity(2L);
when(mapper.countProducts(any(), any(), any(), any(), any(), any(), any(), any(),
- any(), any(), any(), any())).thenReturn(2L);
+ any(), any(), any(), any(), isNull())).thenReturn(2L);
when(mapper.selectProductPage(any(), any(), any(), any(), any(), any(), any(), any(),
- any(), any(), any(), any(), anyLong(), anyInt())).thenReturn(List.of(categorized, missing));
+ any(), any(), any(), any(), isNull(), anyLong(), anyInt())).thenReturn(List.of(categorized, missing));
when(assignMapper.selectList(any())).thenReturn(List.of(
assign(1L, GROUP_ID, 3L), assign(2L, GROUP_ID, 99L)));
JdProductGroupEntity category = new JdProductGroupEntity();
@@ -1169,7 +1181,7 @@ class AdminJdProductControllerTest {
when(categoryMapper.selectBatchIds(any())).thenReturn(List.of(category));
JdProductPageVo vo = service.page(1L, 20L, null, null, null, null, null, null, null, null,
- null, null, null, GROUP_ID);
+ null, null, null, GROUP_ID, null);
assertEquals(3L, vo.getItems().get(0).getGroupId(), "分类 id 取本组归属行");
assertEquals("秋冬款", vo.getItems().get(0).getGroupName(), "行集归属一次取齐分类名(无逐行查询)");
@@ -1185,12 +1197,12 @@ class AdminJdProductControllerTest {
JdProductQueryService service = queryService(mapper, mock(JdProductImageMapper.class),
mock(JdProductSkuMapper.class), mock(JdProductGroupMapper.class), assignMapper);
when(mapper.countProducts(any(), any(), any(), any(), any(), any(), any(), any(),
- any(), any(), any(), any())).thenReturn(1L);
+ any(), any(), any(), any(), isNull())).thenReturn(1L);
when(mapper.selectProductPage(any(), any(), any(), any(), any(), any(), any(), any(),
- any(), any(), any(), any(), anyLong(), anyInt())).thenReturn(List.of(productEntity(1L)));
+ any(), any(), any(), any(), isNull(), anyLong(), anyInt())).thenReturn(List.of(productEntity(1L)));
JdProductPageVo vo = service.page(1L, 20L, null, null, null, null, null, null, null, null,
- null, null, null, null);
+ null, null, null, null, null);
assertNull(vo.getItems().get(0).getGroupId(), "不属于任何分组的账号:分类列一律空(未分类)");
assertNull(vo.getItems().get(0).getGroupName());
@@ -1208,7 +1220,7 @@ class AdminJdProductControllerTest {
// 本组(10)没归类:detail 的 selectOne 回 null ⇒ 分类字段空。
when(assignMapper.selectOne(any())).thenReturn(null);
- JdProductDetailVo untouched = service.detail(11L, GROUP_ID);
+ JdProductDetailVo untouched = service.detail(11L, GROUP_ID, null);
assertNull(untouched.getGroupId(), "本组没归类=未分类,不拿别组的归属顶上");
assertNull(untouched.getGroupName());
@@ -1218,7 +1230,7 @@ class AdminJdProductControllerTest {
category.setId(3L);
category.setName("秋冬款");
when(categoryMapper.selectBatchIds(any())).thenReturn(List.of(category));
- JdProductDetailVo categorized = service.detail(11L, GROUP_ID);
+ JdProductDetailVo categorized = service.detail(11L, GROUP_ID, null);
assertEquals(3L, categorized.getGroupId());
assertEquals("秋冬款", categorized.getGroupName());
}
diff --git a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/mapper/JdProductMapperSqlTest.java b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/mapper/JdProductMapperSqlTest.java
index 0d269d525..61a3302d0 100644
--- a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/mapper/JdProductMapperSqlTest.java
+++ b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/mapper/JdProductMapperSqlTest.java
@@ -113,6 +113,24 @@ class JdProductMapperSqlTest {
assertTrue(sql.endsWith("ORDER BY p.shop_name LIMIT ?"), () -> "必须按店名升序+LIMIT 收尾: " + sql);
}
+ /**
+ * 公司隔离(2026-11-23 客户口径「公司与公司之间不能互看」):四条读路径(列表/总数/
+ * 类目下拉/店铺候选)都必须能把 companyId 下推成 {@code p.company_id = ?};平台超管
+ * (companyId 空)不得出现该谓词。漏一条=那条路径跨公司可见,且不会报错。
+ */
+ @Test
+ void 公司隔离谓词必须下推SQL() throws Exception {
+ for (String id : java.util.List.of("countProducts", "selectProductPage",
+ "selectProductCategories", "selectDistinctShopNames")) {
+ String sql = render(id, Map.of("companyId", 5L, "offset", 0L, "limit", 20));
+ assertTrue(sql.contains("p.company_id = ?"),
+ () -> id + " 少了公司隔离谓词(该路径会跨公司返回): " + sql);
+ }
+ String bare = render("countProducts", Map.of("offset", 0L, "limit", 20));
+ assertFalse(bare.contains("company_id"),
+ () -> "平台超管(companyId 空)不得被钉死在某公司: " + bare);
+ }
+
private static String render(String id) throws Exception {
return render(id, Map.of("companyId", 1L, "taskId", 34956L));
}
diff --git a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdCategoryScopeServiceTest.java b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdCategoryScopeServiceTest.java
index db29192d1..535a122b1 100644
--- a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdCategoryScopeServiceTest.java
+++ b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdCategoryScopeServiceTest.java
@@ -31,8 +31,9 @@ import static org.mockito.Mockito.when;
*
* 四档矩阵(2026-11-17 起各档可见集最后统一过「只留京东档 platform='jd' 分组」的平台闸):
* 平台超管=全部公司全部组可读可写;公司超管=本公司全部组;
- * 管理员=全部可见组可写(2026-11-23 客户口径「管理人员只有分类权限」,不再要求组长身份);
- * 普通号=与管理员同可见、零可写(能开弹窗看,不能增删改分类、不能归类)。
+ * 管理员=自己带的组可写、成员所属组只读(2026-11-23 客户口径「管理员之间分类不能互看」:
+ * 不再继承上级带的组);普通号=自己带的组+成员所属组+上级组可见、零可写
+ * (「管理员与员工可以互看分类」「普通员工没有权限分类」)。
* 另钉三条收敛语义:不可见组读 403(不做空结果降级)、无分组上下文读回 null(页面照常可用)、
* 写侧在「无可写组 / 多可写组未选 / 该组不可写 / 组行不存在」四种形状下的文案。
* 下拉 label 前缀(2026-11-21 用户口径「这里不是选公司 是选超管/管理员」):平台超管跨多个
@@ -168,75 +169,45 @@ class JdCategoryScopeServiceTest {
* 管理人员普遍不是组长,拿不到分类入口)。可见性边界不变:不可见组仍双拒。
*/
@Test
- void 管理人员_全部可见组可写_含非组长身份所属组的组() {
+ void 管理人员_自己带的组可写_成员所属组只读() {
AdminUserEntity operator = user(USER_ID, COMPANY_ID);
when(adminAuthSupport.currentRole(operator)).thenReturn("admin");
when(dataReadScope.isPlatformSuperAdmin(operator)).thenReturn(false);
when(shopManageGroupMapper.selectLedGroups(USER_ID)).thenReturn(List.of(group(10L, COMPANY_ID, "自己的组")));
when(shopManageGroupMapper.selectLeaderIdsByMemberUserId(USER_ID)).thenReturn(List.of(3L));
- when(shopManageGroupMapper.selectLedGroups(3L)).thenReturn(List.of(group(11L, COMPANY_ID, "上司的组")));
+ when(shopManageGroupMapper.selectLedGroups(3L)).thenReturn(List.of(group(11L, COMPANY_ID, "组长A的组")));
JdCategoryScopeService.JdCategoryScope scope = service.resolve(operator);
assertThat(scope.visibleGroupIds()).containsExactly(10L, 11L);
- assertThat(scope.writableGroupIds()).containsExactly(10L, 11L);
+ // 2026-11-23 客户口径「管理员与管理员之间分类不能互看,同组的可以看、不同组的不能看」:
+ // 分类可写只到自己带的组;作为别组成员时那组只读(归它的组长管)。
+ assertThat(scope.writableGroupIds()).containsExactly(10L);
assertThat(scope.canRead(11L)).isTrue();
- assertThat(scope.canWrite(11L)).isTrue();
- // 不可见组仍双拒:可写放开只到可见集为止,V203 分组隔离不松。
+ assertThat(scope.canWrite(11L)).isFalse();
+ // 不可见组仍双拒:V203 分组隔离不松。
assertThat(scope.canRead(99L)).isFalse();
assertThat(scope.canWrite(99L)).isFalse();
}
- /** 非组长的普通管理人员(只靠成员关系可见组)同样拿到分类可写——客户账号 阿华226655 的形状。 */
+ /** 非组长的管理人员(只靠成员关系可见组):分类可读、不可写——写归该组组长。 */
@Test
- void 管理人员非组长_成员关系可见的组也可写分类() {
+ void 管理人员非组长_成员组可见但不可写() {
AdminUserEntity operator = user(USER_ID, COMPANY_ID);
when(adminAuthSupport.currentRole(operator)).thenReturn("admin");
when(dataReadScope.isPlatformSuperAdmin(operator)).thenReturn(false);
when(shopManageGroupMapper.selectLedGroups(USER_ID)).thenReturn(List.of());
when(shopManageGroupMapper.selectLeaderIdsByMemberUserId(USER_ID)).thenReturn(List.of(3L));
- when(shopManageGroupMapper.selectLedGroups(3L)).thenReturn(List.of(group(11L, COMPANY_ID, "上司的组")));
+ when(shopManageGroupMapper.selectLedGroups(3L)).thenReturn(List.of(group(11L, COMPANY_ID, "组长A的组")));
JdCategoryScopeService.JdCategoryScope scope = service.resolve(operator);
assertThat(scope.visibleGroupIds()).containsExactly(11L);
- assertThat(scope.writableGroupIds()).containsExactly(11L);
- assertThat(scope.groups()).singleElement()
- .satisfies(option -> assertThat(option.isEditable()).isTrue());
- }
-
- @Test
- void 普通号_可见同组长但零可写() {
- AdminUserEntity operator = user(USER_ID, COMPANY_ID);
- when(adminAuthSupport.currentRole(operator)).thenReturn("normal");
- when(dataReadScope.isPlatformSuperAdmin(operator)).thenReturn(false);
- when(shopManageGroupMapper.selectLedGroups(USER_ID)).thenReturn(List.of());
- when(shopManageGroupMapper.selectLeaderIdsByMemberUserId(USER_ID)).thenReturn(List.of(3L));
- when(shopManageGroupMapper.selectLedGroups(3L)).thenReturn(List.of(group(10L, COMPANY_ID, "A组")));
-
- JdCategoryScopeService.JdCategoryScope scope = service.resolve(operator);
-
- assertThat(scope.visibleGroupIds()).containsExactly(10L);
assertThat(scope.writableGroupIds()).isEmpty();
assertThat(scope.groups()).singleElement()
.satisfies(option -> assertThat(option.isEditable()).isFalse());
}
- @Test
- void 不属于任何分组的账号_空作用域不报错() {
- AdminUserEntity operator = user(USER_ID, COMPANY_ID);
- when(adminAuthSupport.currentRole(operator)).thenReturn("normal");
- when(dataReadScope.isPlatformSuperAdmin(operator)).thenReturn(false);
- when(shopManageGroupMapper.selectLedGroups(USER_ID)).thenReturn(List.of());
- when(shopManageGroupMapper.selectLeaderIdsByMemberUserId(USER_ID)).thenReturn(List.of());
-
- JdCategoryScopeService.JdCategoryScope scope = service.resolve(operator);
-
- assertThat(scope.visibleGroupIds()).isEmpty();
- assertThat(scope.defaultGroupId()).isNull();
- assertThat(scope.groups()).isEmpty();
- }
-
/**
* 2026-11-24 客户口径「普通管理员看不到同组管理员的分类」(线上账号 阿华112336 的形状:
* 员工 1366 → 管理员 1365(不带组)→ 公司超管 1353(带组 49)):可见组沿 created_by_id
@@ -332,6 +303,38 @@ class JdCategoryScopeServiceTest {
assertThat(scope.canRead(22L)).isFalse();
}
+ @Test
+ void 普通号_可见同组长但零可写() {
+ AdminUserEntity operator = user(USER_ID, COMPANY_ID);
+ when(adminAuthSupport.currentRole(operator)).thenReturn("normal");
+ when(dataReadScope.isPlatformSuperAdmin(operator)).thenReturn(false);
+ when(shopManageGroupMapper.selectLedGroups(USER_ID)).thenReturn(List.of());
+ when(shopManageGroupMapper.selectLeaderIdsByMemberUserId(USER_ID)).thenReturn(List.of(3L));
+ when(shopManageGroupMapper.selectLedGroups(3L)).thenReturn(List.of(group(10L, COMPANY_ID, "A组")));
+
+ JdCategoryScopeService.JdCategoryScope scope = service.resolve(operator);
+
+ assertThat(scope.visibleGroupIds()).containsExactly(10L);
+ assertThat(scope.writableGroupIds()).isEmpty();
+ assertThat(scope.groups()).singleElement()
+ .satisfies(option -> assertThat(option.isEditable()).isFalse());
+ }
+
+ @Test
+ void 不属于任何分组的账号_空作用域不报错() {
+ AdminUserEntity operator = user(USER_ID, COMPANY_ID);
+ when(adminAuthSupport.currentRole(operator)).thenReturn("normal");
+ when(dataReadScope.isPlatformSuperAdmin(operator)).thenReturn(false);
+ when(shopManageGroupMapper.selectLedGroups(USER_ID)).thenReturn(List.of());
+ when(shopManageGroupMapper.selectLeaderIdsByMemberUserId(USER_ID)).thenReturn(List.of());
+
+ JdCategoryScopeService.JdCategoryScope scope = service.resolve(operator);
+
+ assertThat(scope.visibleGroupIds()).isEmpty();
+ assertThat(scope.defaultGroupId()).isNull();
+ assertThat(scope.groups()).isEmpty();
+ }
+
// ---------------------------------------------------------------- 入参收敛
@Test
diff --git a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdGroupShopServiceTest.java b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdGroupShopServiceTest.java
index 344111e10..6e6fc8c0b 100644
--- a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdGroupShopServiceTest.java
+++ b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdGroupShopServiceTest.java
@@ -202,19 +202,19 @@ class JdGroupShopServiceTest {
@Test
void 可添加候选排除已有名单且limit钳制() {
when(shopMapper.selectList(any())).thenReturn(List.of(shopRow(1L, CATEGORY_ID, "已有店A")));
- when(productMapper.selectDistinctShopNames("旗", List.of("已有店A"), 200))
+ when(productMapper.selectDistinctShopNames("旗", List.of("已有店A"), 200, null))
.thenReturn(List.of("旗舷店"));
assertEquals(List.of("旗舷店"),
- service.availableShops(" 旗 ", CATEGORY_ID, null), "keyword trim 后下推;limit 缺省钳到 200");
+ service.availableShops(" 旗 ", CATEGORY_ID, null, null), "keyword trim 后下推;limit 缺省钳到 200");
// limit 钳制:500 请求 → 200(服务侧钳,mapper 不做第二次换算)。
- service.availableShops(null, CATEGORY_ID, 500);
- verify(productMapper).selectDistinctShopNames(null, List.of("已有店A"), 200);
+ service.availableShops(null, CATEGORY_ID, 500, null);
+ verify(productMapper).selectDistinctShopNames(null, List.of("已有店A"), 200, null);
// 不带排除分类:excludeNames 空清单(不生成 NOT IN);前两轮各查过一次名单表,共两次。
- when(productMapper.selectDistinctShopNames(null, List.of(), 50)).thenReturn(List.of("直接店"));
- assertEquals(List.of("直接店"), service.availableShops(null, null, 50));
+ when(productMapper.selectDistinctShopNames(null, List.of(), 50, null)).thenReturn(List.of("直接店"));
+ assertEquals(List.of("直接店"), service.availableShops(null, null, 50, null));
verify(shopMapper, times(2)).selectList(any());
}
diff --git a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdProductQueryServiceUserPageTest.java b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdProductQueryServiceUserPageTest.java
index 2f7fbaf74..f818d26a2 100644
--- a/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdProductQueryServiceUserPageTest.java
+++ b/backend-java/src/test/java/com/nanri/aiimage/modules/jd/service/JdProductQueryServiceUserPageTest.java
@@ -149,6 +149,44 @@ class JdProductQueryServiceUserPageTest {
verify(jdProductMapper, never()).selectList(any());
}
+ /**
+ * 公司隔离(2026-11-23 客户口径「公司与公司之间不能互看」):详情按行 company_id 校验,
+ * 别公司的行按「商品不存在」拒绝(不 403,不泄露行是否存在);平台超管(null)不限。
+ */
+ @Test
+ void 详情跨公司按商品不存在拒绝_本公司放行() {
+ JdProductEntity row = product(31L);
+ row.setCompanyId(5L);
+ when(jdProductMapper.selectById(31L)).thenReturn(row);
+ when(jdProductImageMapper.selectList(any())).thenReturn(List.of());
+ when(jdProductSkuMapper.selectList(any())).thenReturn(List.of());
+
+ assertThat(service.detail(31L, null, 5L).getId()).as("本公司行正常返回").isEqualTo(31L);
+ assertThat(service.detail(31L, null, null).getId()).as("平台超管不限公司").isEqualTo(31L);
+ org.junit.jupiter.api.Assertions.assertThrows(
+ com.nanri.aiimage.common.exception.BusinessException.class,
+ () -> service.detail(31L, null, 6L),
+ "别公司的行必须按「商品不存在」拒绝(不是 403,不泄露存在性)");
+ }
+
+ /**
+ * 写侧行级公司闸:请求 id 里只要有一行不属于作用域公司就整批拒绝;平台超管(null)不限。
+ * 读侧藏起来的行仍然能删=静默删除,不是隔离——编辑/传图/删除/批量删除/归类都走这一道。
+ */
+ @Test
+ void 写侧行级公司闸_跨公司整批拒绝_本公司与平台超管放行() {
+ JdProductEntity own = product(41L);
+ own.setCompanyId(5L);
+ when(jdProductMapper.selectBatchIds(List.of(41L))).thenReturn(List.of(own));
+
+ service.assertRowsInCompany(List.of(41L), 5L);
+ service.assertRowsInCompany(List.of(41L), null);
+ org.junit.jupiter.api.Assertions.assertThrows(
+ com.nanri.aiimage.common.exception.BusinessException.class,
+ () -> service.assertRowsInCompany(List.of(41L), 6L),
+ "别公司的行必须整批拒绝(静默删掉别家数据比报错更糟)");
+ }
+
@Test
void 详情与列表都带回人工编辑锁_锁行可观测面() {
// 2026-11-23 E2E 窗发现的缺口:V199 人工锁在编辑侧已置 1,但详情/列表 VO 不暴露,
@@ -159,7 +197,7 @@ class JdProductQueryServiceUserPageTest {
when(jdProductImageMapper.selectList(any())).thenReturn(List.of());
when(jdProductSkuMapper.selectList(any())).thenReturn(List.of());
- com.nanri.aiimage.modules.jd.model.vo.JdProductDetailVo detail = service.detail(21L, null);
+ com.nanri.aiimage.modules.jd.model.vo.JdProductDetailVo detail = service.detail(21L, null, null);
assertThat(detail.getManualLocked()).as("详情 VO 带回人工锁").isEqualTo(1);
JdProductEntity listRow = product(22L);