Index
extends BaseController
in package
控制器基础类 不要单独继承此类使用 必须使用ApiController或AdminController
Table of Contents
Properties
- $action : mixed
- 操作
- $class_name : mixed
- 当前访问的类名
- $j_class_name : mixed
- 继承类名
- $login_tag : mixed
- $shop_id : mixed
- $store_id : mixed
- $user : mixed
- $user_id : mixed
- $user_tag : mixed
- $app : App
- 应用实例
- $batchValidate : bool
- 是否批量验证
- $field : mixed
- $input : mixed
- $middleware : array<string|int, mixed>
- 控制器中间件
- $name : mixed
- $request : Request
- Request实例
- $table : mixed
Methods
- __construct() : mixed
- 构造方法
- get_admin_phone() : mixed
- 登录者手机号
- get_admin_shop_id() : mixed
- 当前的连锁店ID
- get_admin_store_id() : mixed
- 当前的门店ID
- get_admin_store_ids() : mixed
- 取登录后用户下的门店ID
- get_admin_stores() : mixed
- 取登录后用户下的门店信息
- index() : mixed
- logout() : mixed
- 退出
- _add() : mixed
- _cross_origin() : mixed
- _del() : mixed
- _edit() : mixed
- _get_user() : mixed
- _init_admin() : mixed
- _init_api() : mixed
- _init_shop() : mixed
- 连锁店
- _init_store() : mixed
- 门店
- _list() : mixed
- _pager() : mixed
- _sort() : mixed
- _status() : mixed
- _upload() : mixed
- 上传 ?is_full=1&&private=1
- _upload_delete() : mixed
- before_insert() : mixed
- checker_signature() : mixed
- init() : mixed
- validate() : array<string|int, mixed>|string|true
- 验证数据
Properties
$action
操作
public
mixed
$action
= []
$class_name
当前访问的类名
public
mixed
$class_name
$j_class_name
继承类名
public
mixed
$j_class_name
$login_tag
public
mixed
$login_tag
= ''
$shop_id
public
mixed
$shop_id
$store_id
public
mixed
$store_id
$user
public
mixed
$user
= []
$user_id
public
mixed
$user_id
= ''
$user_tag
public
mixed
$user_tag
= 'default'
$app
应用实例
protected
App
$app
$batchValidate
是否批量验证
protected
bool
$batchValidate
= false
$field
protected
mixed
$field
= []
$input
protected
mixed
$input
= []
$middleware
控制器中间件
protected
array<string|int, mixed>
$middleware
= []
$name
protected
mixed
$name
$request
Request实例
protected
Request
$request
$table
protected
mixed
$table
Methods
__construct()
构造方法
public
__construct(App $app) : mixed
Parameters
- $app : App
-
应用对象
Tags
get_admin_phone()
登录者手机号
public
get_admin_phone() : mixed
get_admin_shop_id()
当前的连锁店ID
public
get_admin_shop_id() : mixed
get_admin_store_id()
当前的门店ID
public
get_admin_store_id() : mixed
get_admin_store_ids()
取登录后用户下的门店ID
public
get_admin_store_ids() : mixed
get_admin_stores()
取登录后用户下的门店信息
public
get_admin_stores() : mixed
index()
public
index() : mixed
logout()
退出
public
logout() : mixed
_add()
protected
_add([mixed $validate_class = '' ]) : mixed
Parameters
- $validate_class : mixed = ''
_cross_origin()
protected
_cross_origin() : mixed
_del()
protected
_del([mixed $where = [] ]) : mixed
Parameters
- $where : mixed = []
_edit()
protected
_edit([mixed $validate_class = '' ]) : mixed
Parameters
- $validate_class : mixed = ''
_get_user()
protected
_get_user(mixed $id) : mixed
Parameters
- $id : mixed
_init_admin()
protected
_init_admin() : mixed
_init_api()
protected
_init_api() : mixed
_init_shop()
连锁店
protected
_init_shop() : mixed
_init_store()
门店
protected
_init_store() : mixed
_list()
protected
_list([mixed $where = [] ][, mixed $limit = null ]) : mixed
Parameters
- $where : mixed = []
- $limit : mixed = null
_pager()
protected
_pager([mixed $where = [] ]) : mixed
Parameters
- $where : mixed = []
_sort()
protected
_sort() : mixed
_status()
protected
_status() : mixed
_upload()
上传 ?is_full=1&&private=1
protected
_upload() : mixed
_upload_delete()
protected
_upload_delete() : mixed
before_insert()
protected
before_insert(mixed &$data) : mixed
Parameters
- $data : mixed
checker_signature()
protected
checker_signature() : mixed
init()
protected
init() : mixed
validate()
验证数据
protected
validate(array<string|int, mixed> $data, string|array<string|int, mixed> $validate[, array<string|int, mixed> $message = [] ][, bool $batch = false ]) : array<string|int, mixed>|string|true
Parameters
- $data : array<string|int, mixed>
-
数据
- $validate : string|array<string|int, mixed>
-
验证器名或者验证规则数组
- $message : array<string|int, mixed> = []
-
提示信息
- $batch : bool = false
-
是否批量验证