正在显示
11 个修改的文件
包含
21 行增加
和
20 行删除
| @@ -61,6 +61,7 @@ class AyrReleaseController extends BaseController | @@ -61,6 +61,7 @@ class AyrReleaseController extends BaseController | ||
| 61 | 'post'=>$this->param['content'], | 61 | 'post'=>$this->param['content'], |
| 62 | 'platforms'=>$this->param['platforms'], | 62 | 'platforms'=>$this->param['platforms'], |
| 63 | 'mediaUrls'=>$this->param['mediaUrls'],//参数处理 | 63 | 'mediaUrls'=>$this->param['mediaUrls'],//参数处理 |
| 64 | + 'idempotencyKey'=>$this->param['idempotencyKey'],//时间(如是过去时间,立即发布) | ||
| 64 | ]; | 65 | ]; |
| 65 | //发送请求注册社交用户 | 66 | //发送请求注册社交用户 |
| 66 | $res = $ayrShare->post_send_msg($param,$share_info['profile_key']); | 67 | $res = $ayrShare->post_send_msg($param,$share_info['profile_key']); |
| @@ -8,7 +8,8 @@ use App\Models\User\User; | @@ -8,7 +8,8 @@ use App\Models\User\User; | ||
| 8 | class Blog extends Base | 8 | class Blog extends Base |
| 9 | { | 9 | { |
| 10 | protected $table = 'gl_blog'; | 10 | protected $table = 'gl_blog'; |
| 11 | - | 11 | + //连接数据库 |
| 12 | + protected $connection = 'custom_mysql'; | ||
| 12 | public function user(){ | 13 | public function user(){ |
| 13 | return $this->hasMany(User::class,'operator_id','id'); | 14 | return $this->hasMany(User::class,'operator_id','id'); |
| 14 | } | 15 | } |
| @@ -7,4 +7,7 @@ use App\Models\Base; | @@ -7,4 +7,7 @@ use App\Models\Base; | ||
| 7 | class BlogCategory extends Base | 7 | class BlogCategory extends Base |
| 8 | { | 8 | { |
| 9 | protected $table = 'gl_blog_category'; | 9 | protected $table = 'gl_blog_category'; |
| 10 | + //连接数据库 | ||
| 11 | + protected $connection = 'custom_mysql'; | ||
| 12 | + | ||
| 10 | } | 13 | } |
| @@ -8,20 +8,6 @@ class Image extends Base | @@ -8,20 +8,6 @@ class Image extends Base | ||
| 8 | { | 8 | { |
| 9 | protected $table = 'gl_image'; | 9 | protected $table = 'gl_image'; |
| 10 | 10 | ||
| 11 | - public $timestamps = true; | ||
| 12 | - | ||
| 13 | - /** | ||
| 14 | - * @param $hash | ||
| 15 | - * @name :(获取图片详情)image_read | ||
| 16 | - * @author :lyh | ||
| 17 | - * @method :post | ||
| 18 | - * @time :2023/5/4 11:50 | ||
| 19 | - */ | ||
| 20 | - public function image_read($hash){ | ||
| 21 | - $info = $this->read(['hash'=>$hash]); | ||
| 22 | - if(empty($info)){ | ||
| 23 | - return false; | ||
| 24 | - } | ||
| 25 | - return $info; | ||
| 26 | - } | 11 | + //连接数据库 |
| 12 | + protected $connection = 'custom_mysql'; | ||
| 27 | } | 13 | } |
| @@ -9,4 +9,6 @@ class Mail extends Base | @@ -9,4 +9,6 @@ class Mail extends Base | ||
| 9 | protected $table = 'gl_mail'; | 9 | protected $table = 'gl_mail'; |
| 10 | //自动维护create_at创建时间 updated_at修改时间 | 10 | //自动维护create_at创建时间 updated_at修改时间 |
| 11 | public $timestamps = true; | 11 | public $timestamps = true; |
| 12 | + //连接数据库 | ||
| 13 | + protected $connection = 'custom_mysql'; | ||
| 12 | } | 14 | } |
| @@ -9,4 +9,6 @@ class MailUser extends Base | @@ -9,4 +9,6 @@ class MailUser extends Base | ||
| 9 | protected $table = 'gl_mail_user'; | 9 | protected $table = 'gl_mail_user'; |
| 10 | //自动维护create_at创建时间 updated_at修改时间 | 10 | //自动维护create_at创建时间 updated_at修改时间 |
| 11 | public $timestamps = true; | 11 | public $timestamps = true; |
| 12 | + //连接数据库 | ||
| 13 | + protected $connection = 'custom_mysql'; | ||
| 12 | } | 14 | } |
| @@ -7,6 +7,6 @@ use App\Models\Base; | @@ -7,6 +7,6 @@ use App\Models\Base; | ||
| 7 | class NewsCategory extends Base | 7 | class NewsCategory extends Base |
| 8 | { | 8 | { |
| 9 | protected $table = 'gl_news_category'; | 9 | protected $table = 'gl_news_category'; |
| 10 | - //数据库配置 | ||
| 11 | - protected $connection = ''; | 10 | + //连接数据库 |
| 11 | + protected $connection = 'custom_mysql'; | ||
| 12 | } | 12 | } |
| @@ -253,5 +253,5 @@ Route::group([], function () { | @@ -253,5 +253,5 @@ Route::group([], function () { | ||
| 253 | // Route::any('/', [\App\Http\Controllers\Bside\ComController::class, 'get_country'])->name('get_country'); | 253 | // Route::any('/', [\App\Http\Controllers\Bside\ComController::class, 'get_country'])->name('get_country'); |
| 254 | Route::get('/file/download', [\App\Http\Controllers\Bside\FileController::class, 'download'])->name('file_download'); | 254 | Route::get('/file/download', [\App\Http\Controllers\Bside\FileController::class, 'download'])->name('file_download'); |
| 255 | Route::any('/image/{hash}/{type?}/{w?}/{h?}', [\App\Http\Controllers\file\ImageController::class,'index'])->name('image_show'); | 255 | Route::any('/image/{hash}/{type?}/{w?}/{h?}', [\App\Http\Controllers\file\ImageController::class,'index'])->name('image_show'); |
| 256 | - Route::any('/file_hash/{hash}/{type?}/', [\App\Http\Controllers\file\FileController::class,'index'])->name('file_show'); | 256 | + Route::any('/file_hash/{hash}/', [\App\Http\Controllers\file\FileController::class,'index'])->name('file_show'); |
| 257 | }); | 257 | }); |
-
请 注册 或 登录 后发表评论