首页 > 解决方案 > Shopware 从 6.2.2 更新到 6.2.3 后出错

问题描述

我有一个带有shopware/development,shopware/platform和其中的 monorepo custom/plugins。应用程序在 Docker 上运行,并将当前版本显示为v9999999 Developer Version. 删除了产品、属性和类别等演示数据并导入了新集。

我试图更新shopware/platform. 我的步骤:

  1. 下载代码表格https://github.com/shopware/platform/releases/tag/v6.2.3
  2. 将其复制到“平台”文件夹
  3. 在容器中运行命令muenkel_app_server_1
composer install
bin/console database:migrate --all
bin/console theme:refresh
bin/console cache:clear

前台展示

Notice: Undefined index: structs
in platform/src/Core/Framework/DataAbstractionLayer/FieldSerializer/ListingPriceFieldSerializer.php (line 30)
     
      return new ListingPriceCollection();        
    }  
       
    $value = json_decode((string) $value, true);  
      
    return new ListingPriceCollection(unserialize($value['structs']));    
  }
}

后端不加载产品列表

38 b67864 POST xhr 500 http://muenkel.local.de/api/v2/search/product

我在更新过程中错过了什么?

标签: shopware

解决方案


我还没有弄清楚原因是什么,但一个临时的解决方法是在第 30 行添加这个ListingPriceFieldSerializer.php

if (!isset($value['structs'])) {
    $value['structs'] = 'a:0:{}';
}

更新; 它已在 6.3.0.0 版本中修复,请参阅此处的提交;https://github.com/shopware/platform/commit/20a4e656d9dcf54ff2180d1e28baac1495b30173


推荐阅读