CategoryItem
class CategoryItem extends Node
Class CategoryItem
Traits
Constants
CREATED_AT |
column nam of created at |
UPDATED_AT |
column nam of updated at |
DELETED_AT |
column nam of deleted at |
Properties
static protected Keygen | $keyGenerator | from DynamicModel | |
static protected ConnectionResolverInterface | $resolver | The connection resolver instance. | from DynamicModel |
static protected array | $macros | The registered macros. | from DynamicModel |
protected array | $proxyOptions | from DynamicModel | |
protected bool | $dynamic | from DynamicModel | |
protected array | $dynamicAttributes | dynamic mode 애서 사용될 attributes | from DynamicModel |
protected NodeInterface | $parent | from Node | |
protected Collection | $children | children collection of model | from Node |
Collection | $ancestors | Collection$ancestors | from Node |
Collection | $descendants | Collection$descendants | from Node |
protected string | $table | The table associated with the model. | |
bool | $timestamps | Indicates if the model should be timestamped. | |
protected string | $closureTable | The pivot table associated with the model. | |
protected array | $fillable | The attributes that are mass assignable. | |
static protected string | $aggregator | The class name of aggregator |
Methods
$args 로 넘어온 데이터와 $columns 를 비교해서 $args 값을 거른다.
Resolve a connection instance.
Get the connection resolver instance.
Set the connection resolver instance.
Illuminate Model 의 newBaseQueryBuilder 변경 VirtualConnection 을 통해 DynamicQuery 를 사용하도록 처리
Handle dynamic method calls into the model.
Return the child node items or empty array
Get the pivot table for model's hierarchy
Get the ancestor key name of pivot table
Get the descendant key name of pivot table
Get the depth key name of pivot table
Get the parent key name for model
Get the aggregator model name for model
Get the aggregator key name for model
Alias aggregator
Get the order key name for model
Set the aggregator model name for model
Details
in DynamicModel at line 103
array
filter(array $args, array $columns = array())
$args 로 넘어온 데이터와 $columns 를 비교해서 $args 값을 거른다.
처리중인 $columns 와 같은 이름을 데이터만 리턴됨 이 처리는 dynamic 을 통해 proxy 를 처리 할 경우에 대해서 동작됨
in DynamicModel at line 124
private array
schema()
get table schema
in DynamicModel at line 135
void
fill(array $attributes)
fill
in DynamicModel at line 150
Keygen
getKeyGen()
get key generator
in DynamicModel at line 164
static void
setKeyGen(Keygen $keyGenerator)
Set key generator
in DynamicModel at line 175
static Connection
resolveConnection(string|null $connection = null)
Resolve a connection instance.
in DynamicModel at line 185
static ConnectionResolverInterface
getConnectionResolver()
Get the connection resolver instance.
in DynamicModel at line 196
static void
setConnectionResolver(ConnectionResolverInterface $resolver)
Set the connection resolver instance.
in DynamicModel at line 206
static void
unsetConnectionResolver()
Unset the connection resolver for models.
in DynamicModel at line 217
$this
setDynamic(bool $use)
dynamic query 사용하도록 설정
in DynamicModel at line 228
$this
setProxyOptions(array $options)
proxy option 설정
in DynamicModel at line 239
array
getProxyOptions()
get proxy option
in DynamicModel at line 249
array
getDynamicAttributes()
get dynamic attributes
in DynamicModel at line 261
Builder|DynamicModel
newEloquentBuilder(DynamicQuery $query)
Create a new Eloquent query builder for the model.
Xpressengine\Database\Eloquent\Builder 울 사용하도록 변경
in DynamicModel at line 272
protected DynamicQuery
newBaseQueryBuilder()
Illuminate Model 의 newBaseQueryBuilder 변경 VirtualConnection 을 통해 DynamicQuery 를 사용하도록 처리
in DynamicModel at line 291
protected bool
performInsert(Builder $query, array $options = array())
in DynamicModel at line 305
bool
save(array $options = array())
Save the model to the database.
in DynamicModel at line 321
static void
macro(string $name, callable $macro)
Register a custom macro.
in DynamicModel at line 332
static bool
hasMacro(string $name)
Checks if macro is registered.
in DynamicModel at line 343
mixed
callMacro(string $name, array $parameters = array())
call macro
in DynamicModel at line 359
mixed
getMacroValue(string $name)
get macro value
in DynamicModel at line 376
mixed
__call(string $method, array $parameters)
Handle dynamic method calls into the model.
in DynamicModel at line 391
mixed
__get(string $key)
Dynamically retrieve attributes on the model.
in TreeMakerTrait at line 31
protected Tree
makeTree(array $nodes = array())
Make Tree instance
in Node at line 56
BelongsTo
aggregator()
Aggregator relationship
in Node at line 67
BelongsToMany
ancestors(bool $without = true)
Ancestors relationship
in Node at line 90
BelongsToMany
descendants(bool $without = true)
Descendants relationship
in Node at line 111
string|int
getNodeIdentifier()
Get the unique identifier for the node
in Node at line 121
string
getNodeIdentifierName()
Get the unique identifier name for the node
in Node at line 131
string|int
getParentNodeIdentifier()
Get the parent identifier for the node
in Node at line 158
void
setParent(NodeInterface $node)
Set parent node
at line 84
Collection
getChildren()
Return the child node items or empty array
in Node at line 183
void
setChildren(NodeInterface[] $children = array())
Set child nodes
in Node at line 194
void
addChild(NodeInterface $node)
Add child node
in Node at line 204
bool
hasChild()
Check having child and return the boolean result.
in Node at line 214
protected Collection
children()
Returns children collection
in Node at line 229
Tree
getDescendantTree(bool $withSelf = false)
Get a descendant tree collection of model
in Node at line 244
int
getDescendantCount()
Returns a number of descendants
in Node at line 261
int
getDepth()
Get the depth value of model
in Node at line 271
Collection
getBreadcrumbs()
get breadcrumbs
in Node at line 295
Builder
scopeRoots(Builder $query)
Scope for get node items of root
in Node at line 307
Builder
scopeProgenitors(Builder $query, Aggregator $aggregator)
Scope for get node items of progenitor
at line 109
string
getClosureTable()
Get the pivot table for model's hierarchy
at line 119
string
getAncestorName()
Get the ancestor key name of pivot table
at line 129
string
getDescendantName()
Get the descendant key name of pivot table
at line 139
string
getDepthName()
Get the depth key name of pivot table
at line 149
string
getParentIdName()
Get the parent key name for model
at line 169
string
getAggregatorModel()
Get the aggregator model name for model
at line 179
string
getAggregatorKeyName()
Get the aggregator key name for model
at line 74
BelongsTo
category()
Alias aggregator
at line 159
string
getOrderKeyName()
Get the order key name for model
at line 190
static void
setAggregatorModel(string $model)
Set the aggregator model name for model