现在我正处于从BOLT CM 3.2.2迁移到3.6.3 ver的过程中。 还有一件让我很烦的事情-本地扩展。 我曾经运行我自己的本地扩展程序,它对网站上的所有cron,curl和其他脚本操作都做出了响应……我不能将其转换为包,所以我决定将其从以下位置移出
:extensions/local/name/extname
到
extensions/vendor/name/extname
通过这篇文章:https://github.com/bolt/bolt/issues/6955#issuecomment-328898285
我还编辑了扩展名composer.json文件 和extensions / composer.json文件
现在http://sitename/bolt/extensions 我有错误:
raxta/main — [INVALID] — [DISABLED]
not installed yet
我的扩展名composer.json文件
{
"name": "raxta/main",
"description": "Добавляет личный кабинет для доступа к материалам",
"type": "bolt-extension",
"require": {
"bolt/bolt": "^3.0"
},
"require-dev": {
"phpunit/phpunit": "^4.7"
},
"authors": [
{
"name": "Raxta",
"email": "name@email.com"
}
],
"minimum-stability": "dev",
"prefer-stable": true,
"autoload": {
"psr-4": {
"Bolt\\Extension\\raxta\\main\\": "src/"
}
},
"extra": {
"bolt-assets": "web",
"bolt-class": "Bolt\\Extension\\raxta\\main\\MainExtension"
}
}
扩展composer.json文件的一部分:
"require": {
"bolt/boltforms": "^3.1",
"bolt/robots": "^1.0",
"toog/customfields": "^1.1",
"wikimedia/composer-merge-plugin": "^1.4",
"raxta/main": "^1.0"
},
目录列表 供应商/ raxta /
`-- main
|-- LICENSE
|-- README.md
|-- composer.json
|-- config
| `-- config.yml.dist
|-- src
| `-- MainExtension.php
`-- templates
|-- analytic.html.twig
|-- dash.html.twig
|-- docs.html.twig
|-- docsCat.html.twig
|-- document.html.twig
|-- header.html.twig
|-- list.html.twig
|-- lkaccess.html.twig
|-- login.html.twig
|-- main.html.twig
|-- plan.html.twig
|-- profile.html.twig
|-- report.html.twig
|-- video.html.twig
|-- videoCat.html.twig
`-- videoCats.html.twig
我应该检查什么?我可能需要其他一些调整吗?
EDIT1: 如果我添加到extensions / autoload.json
"raxta/main": {
"name": "raxta/main",
"path": "vendor/raxta/main",
"webPath": "extensions/vendor/raxta/main",
"class": "Bolt\\Extension\\raxta\\main\\MainExtension",
"constraint": "^3.0",
"valid": true
},
bolt \ extension页面中将出现错误,例如:
В расширении raxta/main пропущено, так как в нём есть некорректный класс 'Bolt\Extension\Raxta\Main\MainExtension'
Translation: In extension raxta/main skipped, because it consist not a correct class 'Bolt\Extension\Raxta\Main\MainExtension'