feat: 业务提供项编辑弹窗支持区块点选联动
This commit is contained in:
1 parent
a3730ee8fc
commit
64b6f5c27c
8 files changed
+216
-34
No files matched your search
@@ -189,6 +189,16 @@ test("业务编辑弹窗预览列表与详情详情同一份内容", async ({ pa
|
||||
await expect(editor.locator(".service-offering-editor__view")).toContainText("详情内容");
|
||||
await expect(page.getByText("正在核对详情展示")).toBeVisible();
|
||||
|
||||
await preview.locator(".food-detail .hero-copy").click();
|
||||
await expect(preview).toHaveAttribute(
|
||||
"data-active-target",
|
||||
"acheng-campus-food.detail.dishDetail",
|
||||
);
|
||||
await expect(page.getByText("餐品与服务详情对应字段", { exact: true })).toBeVisible();
|
||||
await expect(
|
||||
editor.locator('[data-presentation-binding="offering.config.details.background"]'),
|
||||
).toHaveClass(/is-preview-active/);
|
||||
|
||||
await page.getByLabel("餐品介绍").fill("弹窗编辑后的餐品介绍");
|
||||
await expect(preview.locator(".food-detail .body")).toContainText("弹窗编辑后的餐品介绍");
|
||||
|
||||
@@ -197,6 +207,25 @@ test("业务编辑弹窗预览列表与详情详情同一份内容", async ({ pa
|
||||
await expect(preview).toHaveAttribute("data-active-target", "acheng-campus-food.offerings.item");
|
||||
await expect(page.getByText("正在核对列表展示")).toBeVisible();
|
||||
|
||||
await preview.locator(".offering-card .dish-name").click();
|
||||
await expect(page.getByText("业务卡片对应字段", { exact: true })).toBeVisible();
|
||||
await expect(editor.locator('[data-presentation-binding="offering.name"]')).toHaveClass(
|
||||
/is-preview-active/,
|
||||
);
|
||||
await expect(
|
||||
editor.locator('[data-presentation-binding="offering.config.details.background"]'),
|
||||
).toHaveCount(0);
|
||||
|
||||
await preview.locator(".menu-head").click();
|
||||
await expect(preview).toHaveAttribute("data-active-target", "acheng-campus-food.offerings.menu");
|
||||
await expect(page.getByText("「菜单页说明」属于页面通用内容", { exact: true })).toBeVisible();
|
||||
await expect(editor.locator('[data-presentation-binding="offering.name"]')).not.toHaveClass(
|
||||
/is-preview-active/,
|
||||
);
|
||||
await expect(editor.getByText("详情主图", { exact: true })).toHaveCount(0);
|
||||
|
||||
await preview.locator(".offering-card .dish-name").click();
|
||||
await expect(page.getByText("业务卡片对应字段", { exact: true })).toBeVisible();
|
||||
await page.getByLabel("名称", { exact: true }).fill("列表实时预览餐品");
|
||||
await expect(preview.locator(".offering-card")).toContainText("列表实时预览餐品");
|
||||
|
||||
|
||||
Reference in new issue
Block a user