0

我尝试使用以下命令安装 sylius 项目:

composer create-project -s dev sylius/sylius-standard

但总是有同样的错误:

  [InvalidArgumentException]                                       
  The class sylius.model.promotion_subject.class does not exists.

Script Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache
handling the post-update-cmd event terminated with an exception

  [RuntimeException]                                                         
  An error occurred when executing the "'cache:clear --no-warmup'" command. 

在 SyliusPromotionBundle 中,我注意到:

       $interfaces = array(
        'Sylius\Bundle\PromotionsBundle\Model\PromotionInterface'        =>     'sylius.model.promotion.class',
        'Sylius\Bundle\PromotionsBundle\Model\CouponInterface'           => 'sylius.model.promotion_coupon.class',
        'Sylius\Bundle\PromotionsBundle\Model\RuleInterface'             => 'sylius.model.promotion_rule.class',
        'Sylius\Bundle\PromotionsBundle\Model\ActionInterface'           => 'sylius.model.promotion_action.class',
        'Sylius\Bundle\PromotionsBundle\Model\PromotionSubjectInterface' => 'sylius.model.promotion_subject.class',
    );

所以,我尝试直接在 app/parameters.yml 中添加:

sylius.model.promotion_subject.class: "Sylius\Bundle\PromotionsBundle\Model\PromotionSubjectInterface"

它似乎有效,但我觉得这是一个丑陋的解决方案......

现在: app/console sylius:install 导致:

  [InvalidArgumentException]                                                   
  There are no commands defined in the "doctrine:phpcr:repository" namespace.

有没有其他人遇到过同样的问题?

4

1 回答 1

0

我发现奇怪的是我们必须做一些文档中没有提到的操作。我今天再次尝试从头安装 sylius 项目,一切似乎都很好。正如 sylius 网站上提到的:“Sylius 处于预 alpha 开发阶段。” 我猜球队做出了一些改变。蒂蒙,我希望你今天的安装能成功……最好的问候。

于 2014-03-17T08:31:02.040 回答