Documentation

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

$batchValidate

是否批量验证

protected bool $batchValidate = false

$middleware

控制器中间件

protected array<string|int, mixed> $middleware = []

Methods

__construct()

构造方法

public __construct(App $app) : mixed
Parameters
$app : App

应用对象

Tags
access

public

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

_add()

protected _add([mixed $validate_class = '' ]) : mixed
Parameters
$validate_class : 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

_list()

protected _list([mixed $where = [] ][, mixed $limit = null ]) : mixed
Parameters
$where : mixed = []
$limit : mixed = null

_pager()

protected _pager([mixed $where = [] ]) : mixed
Parameters
$where : mixed = []

_upload()

上传 ?is_full=1&&private=1

protected _upload() : mixed

before_insert()

protected before_insert(mixed &$data) : mixed
Parameters
$data : 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

是否批量验证

Tags
access

protected

throws
ValidateException
Return values
array<string|int, mixed>|string|true
Loading…
On this page

Search results