AfterCountController.php
1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?php
/**
* @remark :
* @name :AfterCountController.php
* @author :lyh
* @method :post
* @time :2025/4/8 9:56
*/
namespace App\Http\Controllers\Aside\Optimize;
use App\Enums\Common\Code;
use App\Http\Controllers\Aside\BaseController;
use App\Models\HomeCount\AfterCount;
class AfterCountController extends BaseController
{
/**
* @remark :售后数据统计
* @name :getAfterCount
* @author :lyh
* @method :post
* @time :2025/3/27 17:21
*/
public function getAfterCount(AfterCount $afterCount){
$list = $afterCount->lists($this->map,$this->page,$this->row);
$this->response('success',Code::SUCCESS,$list);
}
/**
* @remark :获取当前售后数据详情
* @name :getAfterCountInfo
* @author :lyh
* @method :post
* @time :2025/4/8 9:56
*/
public function getAfterCountInfo(AfterCount $afterCount){
$this->request->validate([
'id' => 'required',
], [
'id.required' => 'id不能为空',
]);
$info = $afterCount->read($this->map,['id','data']);
$info['data'] = json_decode($info['data'],true);
$this->response('success',Code::SUCCESS,$info);
}
}