作者 lyh

gx

@@ -40,6 +40,7 @@ class Kernel extends ConsoleKernel @@ -40,6 +40,7 @@ class Kernel extends ConsoleKernel
40 $schedule->command('update_seo_tdk_crontab')->dailyAt('00:00')->withoutOverlapping(1); //更新上线项目TDK 40 $schedule->command('update_seo_tdk_crontab')->dailyAt('00:00')->withoutOverlapping(1); //更新上线项目TDK
41 $schedule->command('website_data')->dailyAt('01:00')->withoutOverlapping(1); // 向AICC推送数据 41 $schedule->command('website_data')->dailyAt('01:00')->withoutOverlapping(1); // 向AICC推送数据
42 $schedule->command('project_file_pdf')->dailyAt('00:00')->withoutOverlapping(1); // 网站项目数据,生成PDF文件 42 $schedule->command('project_file_pdf')->dailyAt('00:00')->withoutOverlapping(1); // 网站项目数据,生成PDF文件
  43 + $schedule->command('sync_manager')->dailyAt('01:00')->withoutOverlapping(1); //TODO::手机号码同步 每天执行一次
43 } 44 }
44 45
45 /** 46 /**
@@ -709,7 +709,7 @@ class BTemplateLogic extends BaseLogic @@ -709,7 +709,7 @@ class BTemplateLogic extends BaseLogic
709 $moduleModel = new CustomModule(); 709 $moduleModel = new CustomModule();
710 $moduleList = $moduleModel->list(['status'=>0]); 710 $moduleList = $moduleModel->list(['status'=>0]);
711 foreach ($moduleList as $v){ 711 foreach ($moduleList as $v){
712 - $moduleCategory = $this->getCategoryList((new CustomModuleCategory()),0,['id','name','pid']); 712 + $moduleCategory = $this->getCategoryModuleList((new CustomModuleCategory()),$v['id'],0,['id','name','pid']);
713 $categoryList = [["id"=>"all", "name"=>"全部"], ["id"=>"new", "name"=>"最新"]]; 713 $categoryList = [["id"=>"all", "name"=>"全部"], ["id"=>"new", "name"=>"最新"]];
714 foreach ($moduleCategory as $values){ 714 foreach ($moduleCategory as $values){
715 $categoryList[] = $values; 715 $categoryList[] = $values;
@@ -782,6 +782,26 @@ class BTemplateLogic extends BaseLogic @@ -782,6 +782,26 @@ class BTemplateLogic extends BaseLogic
782 } 782 }
783 783
784 /** 784 /**
  785 + * @remark :获取1级+2级
  786 + * @name :getCategoryList
  787 + * @author :lyh
  788 + * @method :post
  789 + * @time :2023/12/20 10:26
  790 + */
  791 + public function getCategoryModuleList($categoryModel,$module_id,$status = 0,$filed = ['*']){
  792 + $data = array();
  793 + $list = $categoryModel->list(['pid'=>0, 'module_id'=>$module_id , 'status'=>$status],['sort','id'],$filed);
  794 + foreach ($list as $v){
  795 + $data[] = $v;
  796 + $son_list = $categoryModel->list(['pid'=>$v['id'],'module_id'=>$module_id,'status'=>$status],['sort','id'],$filed);
  797 + foreach ($son_list as $v1){
  798 + $data[] = $v1;
  799 + }
  800 + }
  801 + return $this->success($data);
  802 + }
  803 +
  804 + /**
785 * @remark :保存html 805 * @remark :保存html
786 * @name :savePublicTemplateHtml 806 * @name :savePublicTemplateHtml
787 * @author :lyh 807 * @author :lyh