更新
This commit is contained in:
parent
f1546e24e5
commit
1843c105d6
@ -63,7 +63,9 @@ class CompanyController extends BaseAdminController
|
||||
$params['other_contacts'] = json_encode($params['other_contacts']);
|
||||
$params['qualification'] = json_encode($params['qualification']);
|
||||
$params['area_manager']=$this->adminId;
|
||||
$params['responsible_area']=implode(',',$params['responsible_area']);
|
||||
if(isset($params['responsible_area'])){
|
||||
$params['responsible_area']=implode(',',$params['responsible_area']);
|
||||
}
|
||||
$result = CompanyLogic::add($params);
|
||||
if (true === $result) {
|
||||
return $this->success('添加成功', [], 1, 1);
|
||||
@ -83,7 +85,9 @@ class CompanyController extends BaseAdminController
|
||||
$params = (new CompanyValidate())->post()->goCheck('edit');
|
||||
$params['other_contacts'] = json_encode($params['other_contacts']);
|
||||
$params['qualification'] = json_encode($params['qualification']);
|
||||
$params['responsible_area']=implode(',',$params['responsible_area']);
|
||||
if(isset($params['responsible_area'])){
|
||||
$params['responsible_area']=implode(',',$params['responsible_area']);
|
||||
}
|
||||
$result = CompanyLogic::edit($params);
|
||||
if (true === $result) {
|
||||
return $this->success('编辑成功', [], 1, 1);
|
||||
|
@ -12,7 +12,7 @@ class CeshiController extends BaseApiController
|
||||
|
||||
public function index()
|
||||
{
|
||||
$all=TaskSchedulingPlan::whereDay('start_time')->with(['template_info','scheduling'])->select();
|
||||
$all=TaskSchedulingPlan::whereDay('start_time','yesterday')->with(['template_info','scheduling'])->select();
|
||||
foreach($all as $k=>$data){
|
||||
$task_id=explode(',',$data['task_id']);
|
||||
$task_count=Task::where('id','in',$task_id)->field('director_uid')->with('director_info')->select();
|
||||
|
@ -150,6 +150,7 @@ class CompanyLogic extends BaseLogic
|
||||
'area_manager' => $params['area_manager'] ?? 0,
|
||||
'qualification' => $params['qualification'],
|
||||
'level_one' => $params['contract']['party_a'] ?? 0,
|
||||
'responsible_area' => $params['responsible_area'],
|
||||
];
|
||||
|
||||
$defaultAvatar = config('project.default_image.admin_avatar');
|
||||
@ -227,6 +228,7 @@ class CompanyLogic extends BaseLogic
|
||||
$data['id_card']='';
|
||||
}
|
||||
$data['area_manager_name'] = Db::name('admin')->where('id', $data['area_manager'])->value('name');
|
||||
$data['responsible_area'] = explode(',', $data['responsible_area']);
|
||||
$data['contract'] = Contract::where(['party_b' => $data['id']])->with(['party_a_info', 'contractType'])->find();
|
||||
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ class TaskInformationJob
|
||||
//通过这个方法可以检查这个任务已经重试了几次了
|
||||
}
|
||||
$task_id=explode(',',$data['task_id']);
|
||||
$task_count=Task::where('id','in',$task_id)->field('nikename')->select();
|
||||
$task_count=Task::where('id','in',$task_id)->field('director_uid')->with('director_info')->select();
|
||||
if(count($task_count)==count($task_id)){
|
||||
$name_arr=[];
|
||||
foreach ($task_count as $key => $value) {
|
||||
|
@ -1,28 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace app\task;
|
||||
|
||||
use app\common\model\task_scheduling_plan\TaskSchedulingPlan;
|
||||
use app\job\TaskAdd;
|
||||
use app\job\TaskInformationJob;
|
||||
use think\facade\Log;
|
||||
use yunwuxin\cron\Task;
|
||||
class Ceshi extends Task{
|
||||
|
||||
public function configure()
|
||||
{
|
||||
// $this->daily(); //设置任务的周期,每天执行一次,更多的方法可以查看源代码,都有注释
|
||||
$this->everyMinute();
|
||||
}
|
||||
/**
|
||||
* 执行任务
|
||||
* @return mixed
|
||||
*/
|
||||
protected function execute()
|
||||
{
|
||||
Log::error('定时任务执行成功1');
|
||||
|
||||
Log::error('定时任务执行成功2');
|
||||
//...具体的任务执行
|
||||
}
|
||||
}
|
@ -11,8 +11,8 @@ class TaskCron extends Task{
|
||||
|
||||
public function configure()
|
||||
{
|
||||
// $this->daily(); //设置任务的周期,每天执行一次,更多的方法可以查看源代码,都有注释
|
||||
$this->everyMinute();
|
||||
$this->daily(); //设置任务的周期,每天执行一次,更多的方法可以查看源代码,都有注释
|
||||
// $this->everyMinute();
|
||||
}
|
||||
/**
|
||||
* 执行任务
|
||||
@ -20,10 +20,10 @@ class TaskCron extends Task{
|
||||
*/
|
||||
protected function execute()
|
||||
{
|
||||
Log::error('定时任务执行成功1');
|
||||
Log::error('定时任务执行成功'.date('Y-m-d H:i:s'));
|
||||
|
||||
//任务结算
|
||||
$all=TaskSchedulingPlan::whereDay('start_time')->with(['template_info','scheduling'])->select()->toArray();
|
||||
$all=TaskSchedulingPlan::whereDay('start_time','yesterday')->with(['template_info','scheduling'])->select()->toArray();
|
||||
foreach($all as $k=>$v){
|
||||
queue(TaskInformationJob::class,$v);
|
||||
}
|
||||
|
2
vendor/ebaoquan/junziqian_sdk
vendored
2
vendor/ebaoquan/junziqian_sdk
vendored
@ -1 +1 @@
|
||||
Subproject commit 9acc82cd23d807280ddd29df2117e7890094d049
|
||||
Subproject commit 1294ea49ff9ecc4532821f8798304816cbf8dd74
|
Loading…
x
Reference in New Issue
Block a user