首页 > 解决方案 > 在 WCMS/catalog (hybris) 上看不到 mystore 目录

问题描述

我创建了 b2b 商店。我将 mystoreinitialdata/impex 商店名称更改为我的商店名称。

# -----------------------------------------------------------------------
# [y] hybris Platform
#
# Copyright (c) 2018 SAP SE or an SAP affiliate company.  All rights reserved.
#
# This software is the confidential and proprietary information of SAP
# ("Confidential Information"). You shall not disclose such Confidential
# Information and shall use it only in accordance with the terms of the
# license agreement you entered into with SAP.
# -----------------------------------------------------------------------
# ImpEx for Points of Service

# Macros / Replacement Parameter definitions
$storeUid=mystore
$productCatalog=mystoreProductCatalog

$catalogVersion=catalogversion(catalog(id[default=$productCatalog]),version[default='Staged'])[unique=true,default=$productCatalog:Staged]
$storeImage=storeImage(qualifier, $catalogVersion)

INSERT_UPDATE OpeningSchedule;code[unique=true];

INSERT_UPDATE WeekdayOpeningDay;openingSchedule(code)[unique=true];dayOfWeek(code)[unique=true];openingTime[dateformat=hh:mm];closingTime[dateformat=hh:mm];

INSERT_UPDATE SpecialOpeningDay;openingSchedule(code)[unique=true];date[unique=true,dateformat=dd.MM.yyyy];closed;openingTime[dateformat=hh:mm];closingTime[dateformat=hh:mm]

INSERT_UPDATE Address;&addrID;streetname;streetnumber;postalcode[unique=true];town[unique=true];country(isocode);region(isocode);phone1;owner(PointOfService.name)[unique=true]

INSERT_UPDATE StoreLocatorFeature;code[unique=true]

INSERT_UPDATE PointOfService;name[unique=true];type(code);address(&addrID);latitude;longitude;geocodeTimestamp[dateformat=dd-MM-yyyy];$storeImage;openingSchedule(code);basestore(uid)[default=$storeUid];features(code)

UPDATE PointOfService;name[unique=true];features(code);

INSERT_UPDATE PoS2WarehouseRel;source(name)[unique=true];target(code)[unique=true]

像那样的影响。

然后我让蚂蚁初始化,当我去backoffice/catalog/catalogs

我没有看到我的商店。(即mystore

我像以前一样看到默认的服装、电动工具等。

我该怎么办,java方面的事情?

这是内容目录/catalogimpex

# -----------------------------------------------------------------------
# [y] hybris Platform
#
# Copyright (c) 2018 SAP SE or an SAP affiliate company.  All rights reserved.
#
# This software is the confidential and proprietary information of SAP
# ("Confidential Information"). You shall not disclose such Confidential
# Information and shall use it only in accordance with the terms of the
# license agreement you entered into with SAP.
# -----------------------------------------------------------------------
#
# Import the Content Catalog
#
$contentCatalog=mystoreContentCatalog
$languages=ja,en,de,zh

# Content catalog for CMS contents
INSERT_UPDATE ContentCatalog;id[unique=true]
;$contentCatalog

# Catalog versions for content catalogs
INSERT_UPDATE CatalogVersion;catalog(id)[unique=true];version[unique=true];active;languages(isoCode)
;$contentCatalog;Staged;false;$languages
;$contentCatalog;Online;true;$languages

标签: hybris

解决方案


您发送的 impex 实际上不会更改单个项目。Impex 使用一个标头来定义操作(INSERT、INSERT_UPDATE、UPDATE、REMOVE)、要更改的数据类型以及要更改的属性。在接下来的行中,需要有一行或多行 csv 数据。

考虑这个例子:

UPDATE PointOfService;name[unique=true];features(code);
;myPointOfService;feature1,feature2;

此 impex 脚本更改由其名称 (myPointOfService) 标识的服务点,并将属性要素设置为由要素代码 feature1 和 feature2 标识的两个要素。第一行是标题,第二行是数据。由于您的脚本仅包含标题,因此不会有任何变化。

如果要创建目录,请考虑更改以下文件:

/mystoreinitialdata/resources/mystoreinitialdata/import/coredata/contentCatalogs/catalogName/catalog.impex
/mystoreinitialdata/resources/mystoreinitialdata/import/coredata/productCatalogs/catalogName/catalog.impex

推荐阅读