1234567891011121314151617181920212223242526272829303132333435363738 |
- <?php
- /**
- * 腾讯云点播类
- * Created by PhpStorm.
- * User: phperstar
- * Date: 2019/10/28
- * Time: 10:29 AM
- */
- namespace HeZuoQiao\Controller\Common;
- use Mall\Framework\Core\ErrorCode;
- use Mall\Framework\Factory;
- use HeZuoQiao\Controller\BaseController;
- use Util\TencentCloud\Vod;
- class Video extends BaseController
- {
- /**
- * 小程序登陆接口
- */
- public function getUploadSign()
- {
- $ConfigData = Factory::config()->get('tencentCloud');
- if(empty($ConfigData)){
- $this->sendOutput('腾讯云配置项错误',ErrorCode::$configEroor);
- }
- $objVod = new Vod($ConfigData['secretId'], $ConfigData['secretKey']);
- $result = $objVod->getUploadSign();
- if ($result->isSuccess()) {
- parent::sendOutput($result->getData());
- } else {
- parent::sendOutput($result->getData(), $result->getErrorCode());
- }
- }
- }
|