idealley/cloudcms-laravel
Composer 安装命令:
composer require idealley/cloudcms-laravel
包简介
Package wrapping the cloudcms php sdk for laravel
README 文档
README
Here is the PhP agnostic SDK
Every thing is still very experimental and subject to CHANGE
How to install:
composer require idealley/cloudcms-laravel
Publish the config with the command
php artisan vendor:publish
This will let you change few settings in the app/config folder.
How to use
CC is a Laravel Facade.
to use it add use CC; at the top of your file.
You can get a children of a node like this (think category or list of blogs)
$catnode = 'o:9a8195e6286a4f7b40ae';
$nodes = CC::nodes()
->listChildren($catnode)
->addParams(['full' => 'true'])
->get();
Or a single node (for now we are getting it from a special slug field) like this:
$node = CC::nodes()
->find($slug)
->addParams(['full' => 'true'])
->get();
You can chain paramas
$node = CC::nodes()
->find($slug)
->addParams(['full' => 'true'])
->addParams(['metadata' => 'true'])
->get();
or pass them in a single array
->addParams(['full' => 'true', 'metadata' => 'true'])
You can get an image like this
$path = 'Samples/Catalog/Products/';
$img = CC::nodes()
->getImage($node['rows'][0]['_qname'])
->addParams(['name' => $node['rows'][0]['_features']['f:filename']['filename']])
->addParams(['size' => '400'])
->set();
There are many more methods you can use, check 'Node' class in the cloudcms-sdk to find everything that is available. Each method is documented with working query examples.
You can chain any params as per the documentation
Do not forget to add these values in your .env file
CC_CLIENT_KEY=
CC_CLIENT_SECRET=
CC_USERNAME=
CC_PASSWORD=
CC_CLIENT_KEY=
CC_TOKEN_STORAGE_PATH=/storage/token
CC_DEPLOYMENT_URL=
idealley/cloudcms-laravel 适用场景与选型建议
idealley/cloudcms-laravel 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 52 次下载、GitHub Stars 达 1, 最近一次更新时间为 2016 年 05 月 19 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 idealley/cloudcms-laravel 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 idealley/cloudcms-laravel 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 52
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-05-19