2023-09-18 09:11:13 +08:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace app\adminapi\controller\finance;
|
|
|
|
|
|
|
|
use app\adminapi\controller\BaseAdminController;
|
|
|
|
use app\adminapi\lists\finance\AccountLogLists;
|
|
|
|
use app\common\enum\user\AccountLogEnum;
|
2023-11-15 17:32:00 +08:00
|
|
|
use think\response\Json;
|
2023-09-18 09:11:13 +08:00
|
|
|
|
|
|
|
/***
|
|
|
|
* 账户流水控制器
|
|
|
|
* Class AccountLogController
|
|
|
|
* @package app\adminapi\controller
|
|
|
|
*/
|
|
|
|
class AccountLogController extends BaseAdminController
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @notes 账户流水明细
|
|
|
|
* @return \think\response\Json
|
|
|
|
* @author 段誉
|
|
|
|
* @date 2023/2/24 15:25
|
|
|
|
*/
|
|
|
|
public function lists()
|
|
|
|
{
|
|
|
|
return $this->dataLists(new AccountLogLists());
|
|
|
|
}
|
|
|
|
|
2023-11-15 17:32:00 +08:00
|
|
|
public function taskLists(): Json
|
|
|
|
{
|
2023-11-20 10:14:59 +08:00
|
|
|
$params = $this->request->get(['company_id', 'change_type', 'user_info', 'type', 'start_time', 'end_time']);
|
2023-11-20 10:40:17 +08:00
|
|
|
halt($params);
|
2023-11-17 16:06:34 +08:00
|
|
|
$result = curl_post(env('project.worker_domain').'/middleapi/account_log/lists',$params,$this->reqHeader);
|
2023-11-15 17:32:00 +08:00
|
|
|
if($result['code'] == 0){
|
|
|
|
return $this->fail($result['msg']);
|
|
|
|
}
|
|
|
|
return json($result);
|
|
|
|
}
|
|
|
|
|
2023-09-18 09:11:13 +08:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @notes 用户余额变动类型
|
|
|
|
* @return \think\response\Json
|
|
|
|
* @author 段誉
|
|
|
|
* @date 2023/2/24 15:25
|
|
|
|
*/
|
|
|
|
public function getUmChangeType()
|
|
|
|
{
|
|
|
|
return $this->data(AccountLogEnum::getUserMoneyChangeTypeDesc());
|
|
|
|
}
|
|
|
|
|
2023-11-15 17:32:00 +08:00
|
|
|
public function getTaskUmChangeType(): Json
|
|
|
|
{
|
|
|
|
$params = $this->request->get();
|
2023-11-17 16:06:34 +08:00
|
|
|
$result = curl_post(env('project.worker_domain').'/middleapi/account_log/getUmChangeType',$params,$this->reqHeader);
|
2023-11-15 17:32:00 +08:00
|
|
|
if($result['code'] == 0){
|
|
|
|
return $this->fail($result['msg']);
|
|
|
|
}
|
|
|
|
return json($result);
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getTaskCompanyUserList(): Json
|
|
|
|
{
|
|
|
|
$params = $this->request->get(['company_id']);
|
2023-11-17 16:06:34 +08:00
|
|
|
$result = curl_post(env('project.worker_domain').'/middleapi/account_log/getCompanyUserList',$params,$this->reqHeader);
|
2023-11-15 17:32:00 +08:00
|
|
|
if($result['code'] == 0){
|
|
|
|
return $this->fail($result['msg']);
|
|
|
|
}
|
|
|
|
return json($result);
|
|
|
|
}
|
|
|
|
|
2023-09-18 09:11:13 +08:00
|
|
|
|
|
|
|
}
|