GeoPlatform.php
890 字节
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
<?php
/**
* @remark :
* @name :GeoPlatform.php
* @author :lyh
* @method :post
* @time :2025/7/3 11:16
*/
namespace App\Models\Geo;
use App\Models\Base;
use Illuminate\Support\Facades\Cache;
/**
* @remark :geo设置平台类型
* @name :GeoPlatform
* @author :lyh
* @method :post
* @time :2025/7/3 11:16
*/
class GeoPlatform extends Base
{
protected $table = 'gl_geo_platform';
const STATUS_ON = 1;
/**
* @remark :获取平台列表
* @name :getList
* @author :lyh
* @method :post
* @time :2025/7/3 11:18
*/
public function getList(){
// $data = Cache::get('geo_platform');
// if(empty($data)){
$data = $this->list(['status'=>$this::STATUS_ON],'id',['name','en_name','icon','sort'],'asc');
Cache::put('geo_platform',$data,'12 * 3600');
// }
return $data;
}
}