同步草稿箱避免重复执行
This commit is contained in:
@@ -1022,6 +1022,13 @@ class Aiarticle extends Base
|
||||
return json_encode(['status' => 2, 'msg' => 'Please select an article']);
|
||||
}
|
||||
|
||||
//判断草稿箱是否上传
|
||||
$oMaterial = new Material;
|
||||
$aLog = json_decode($oMaterial->getWechatLog(['article_id' => $iArticleId,'type' => 2,'status' =>1]),true);
|
||||
if(!empty($aLog['data'])){
|
||||
return json_encode(['status' => 1,'msg' => 'Already uploaded to draft box','data' => []]);
|
||||
}
|
||||
|
||||
//判断文章类型
|
||||
$article_type = empty($aParam['article_type']) ? 'news' : $aParam['article_type'];
|
||||
if(!in_array($article_type, ['news','newspic'])){
|
||||
|
||||
Reference in New Issue
Block a user