|
...
|
...
|
@@ -10,6 +10,7 @@ |
|
|
|
namespace App\Console\Commands\Test;
|
|
|
|
|
|
|
|
use App\Models\Project\Project;
|
|
|
|
use App\Models\Template\BTemplate;
|
|
|
|
use App\Services\ProjectServer;
|
|
|
|
use Illuminate\Console\Command;
|
|
|
|
use Illuminate\Support\Facades\DB;
|
|
...
|
...
|
@@ -38,13 +39,29 @@ class EditVideoMp4 extends Command |
|
|
|
foreach ($list as $v){
|
|
|
|
echo date('Y-m-d H:i:s') . 'project_id:'.$v['id'] . PHP_EOL;
|
|
|
|
ProjectServer::useProject($v['id']);
|
|
|
|
$this->copyTable();
|
|
|
|
$this->getHtml();
|
|
|
|
DB::disconnect('custom_mysql');
|
|
|
|
}
|
|
|
|
echo date('Y-m-d H:i:s') . 'end' . PHP_EOL;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @remark :获取需要替换的html
|
|
|
|
* @name :getHtml
|
|
|
|
* @author :lyh
|
|
|
|
* @method :post
|
|
|
|
* @time :2024/4/16 10:17
|
|
|
|
*/
|
|
|
|
public function getHtml(){
|
|
|
|
$templateModel = new BTemplate();
|
|
|
|
$list = $templateModel->list();
|
|
|
|
foreach ($list as $k1 => $v1){
|
|
|
|
$this->getVideoSrc($v1['main_html']);
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @remark :获取video的src
|
|
|
|
* @name :getVideoSrc
|
|
|
|
* @author :lyh
|
|
...
|
...
|
@@ -60,6 +77,7 @@ class EditVideoMp4 extends Command |
|
|
|
foreach ($srcLinks as $link) {
|
|
|
|
$videoArr[] = $link;
|
|
|
|
}
|
|
|
|
dd($videoArr);
|
|
|
|
return $videoArr;
|
|
|
|
}
|
|
|
|
|
...
|
...
|
|