|
...
|
...
|
@@ -55,10 +55,10 @@ class ProjectFilePDF extends Command |
|
|
|
|
|
|
|
public function start(): int
|
|
|
|
{
|
|
|
|
# 1 - 未生成
|
|
|
|
# 2 - 已生成
|
|
|
|
# 3 - 其它问题
|
|
|
|
$is_pdf = 1;
|
|
|
|
# 0 - 未生成
|
|
|
|
# 1 - 已生成
|
|
|
|
# 2 - 其它问题
|
|
|
|
$is_pdf = 0;
|
|
|
|
$lists = $this->ProjectAssociation::query()->where('is_pdf', $is_pdf)
|
|
|
|
->where('project_id', '!=', 0)
|
|
|
|
->where('friend_id', '!=', 0)
|
|
...
|
...
|
@@ -90,7 +90,7 @@ class ProjectFilePDF extends Command |
|
|
|
$isRes = $this->DataFile->saveData(compact('project_id', 'user_id', 'friend_id', 'file_path') + ['time' => $this->time]);
|
|
|
|
if (!$isRes) {
|
|
|
|
if ($count == 2) {
|
|
|
|
$lists->is_pdf = 3;
|
|
|
|
$lists->is_pdf = 2;
|
|
|
|
$lists->save();
|
|
|
|
$this->debug_echo('项目文件数据保存失败! - 其他原因 - ' . $key);
|
|
|
|
} else {
|
|
...
|
...
|
@@ -98,7 +98,7 @@ class ProjectFilePDF extends Command |
|
|
|
$this->debug_echo('项目文件数据保存失败! - ' . $key);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$lists->is_pdf = 2;
|
|
|
|
$lists->is_pdf = 1;
|
|
|
|
$lists->save();
|
|
|
|
$this->debug_echo('项目文件数据保存成功!');
|
|
|
|
return 0;
|
...
|
...
|
|