feat(cms): 增加网站图标与品牌图标支持

- 在 CmsWebsiteServiceImplHelper 中新增 icon 和 avatar 字段映射
- 使 icon 对应 website_icon 用于前端 favicon 及网站设置
- 使 avatar 对应 website_avatar 作为品牌图标,与 icon 区分用途
- 在 ShopVo 中添加 icon 和 avatar 字段及对应注释说明
- 保持 avatar 键名与前端 SiteInfo.avatar 一致
This commit is contained in:
2026-08-05 23:45:04 +08:00
parent 5f018be7bb
commit b20304da29
2 changed files with 8 additions and 1 deletions

View File

@@ -67,6 +67,10 @@ public class CmsWebsiteServiceImplHelper {
vo.setDescription(website.getComments());
vo.setLogo(website.getWebsiteLogo());
vo.setMpQrCode(website.getWebsiteDarkLogo());
// 网站图标favicon / 应用卡图标):接通 website_icon 列,供前端「网站设置」上传与后台标签页 favicon 使用
vo.setIcon(website.getWebsiteIcon());
// 品牌图标(应用卡 / 分享图标):接通 website_avatar 列,但 ShopVo 键名用 avatar 以对齐前端 SiteInfo.avatar与 icon(favicon) 用途分离
vo.setAvatar(website.getWebsiteAvatar());
vo.setDomain(website.getDomain());
vo.setAdminUrl(website.getAdminUrl());
vo.setApiUrl(website.getApiUrl());

View File

@@ -42,9 +42,12 @@ public class ShopVo implements Serializable {
@Schema(description = "LOGO")
private String logo;
@Schema(description = "图标")
@Schema(description = "图标(favicon/应用卡图标),对应 cms_website.website_icon")
private String icon;
@Schema(description = "品牌图标(应用卡/分享图标),对应 cms_website.website_avatar与 icon 用途分离JSON 键名用 avatar 以对齐前端")
private String avatar;
@Schema(description = "域名")
private String domain;