adding some to the docblocks for Laravel models
This commit is contained in:
parent
6c15670077
commit
7da1325b1f
@ -25,7 +25,6 @@
|
|||||||
[
|
[
|
||||||
"dlig"
|
"dlig"
|
||||||
],
|
],
|
||||||
"font_size": 9,
|
|
||||||
"git_diff_target": "head",
|
"git_diff_target": "head",
|
||||||
"hardware_acceleration": "opengl",
|
"hardware_acceleration": "opengl",
|
||||||
"highlight_modified_tabs": true,
|
"highlight_modified_tabs": true,
|
||||||
@ -44,4 +43,6 @@
|
|||||||
"show_line_endings": true,
|
"show_line_endings": true,
|
||||||
"theme": "Material-Theme.sublime-theme",
|
"theme": "Material-Theme.sublime-theme",
|
||||||
"translate_tabs_to_spaces": true,
|
"translate_tabs_to_spaces": true,
|
||||||
|
/*"font_size": 9,*/
|
||||||
|
/*"font_size": 11,*/
|
||||||
}
|
}
|
||||||
|
@ -44,7 +44,7 @@ protected \$touches = [];
|
|||||||
/** @var array<int,string> */
|
/** @var array<int,string> */
|
||||||
protected \$dispatchesEvents = [];
|
protected \$dispatchesEvents = [];
|
||||||
|
|
||||||
/*
|
/**
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Class Constants
|
| Class Constants
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
@ -53,7 +53,7 @@ protected \$dispatchesEvents = [];
|
|||||||
|
|
||||||
//
|
//
|
||||||
|
|
||||||
/*
|
/**
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Custom/Private Methods
|
| Custom/Private Methods
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
@ -63,18 +63,20 @@ protected \$dispatchesEvents = [];
|
|||||||
/**
|
/**
|
||||||
* Get the prunable model query.
|
* Get the prunable model query.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Database\Eloquent\Builder
|
* @return \Illuminate\Database\Eloquent\Builder
|
||||||
*/
|
*/
|
||||||
public function prunable(): Builder
|
public function prunable(): Builder
|
||||||
{
|
{
|
||||||
//return static::where('created_at', '<=', now()->subMonth());
|
return static::where('deleted_at', '<=', now()->subMonth());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Prepare the model for pruning.
|
* Prepare the model for pruning.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return void
|
* @return void
|
||||||
@ -87,6 +89,7 @@ protected function pruning(): void
|
|||||||
/**
|
/**
|
||||||
* Get the value used to index the model.
|
* Get the value used to index the model.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return mixed
|
* @return mixed
|
||||||
@ -99,6 +102,7 @@ public function getScoutKey()
|
|||||||
/**
|
/**
|
||||||
* Get the key name used to index the model.
|
* Get the key name used to index the model.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return string
|
* @return string
|
||||||
@ -111,6 +115,7 @@ public function getScoutKeyName(): string
|
|||||||
/**
|
/**
|
||||||
* Get the name of the index associated with the model.
|
* Get the name of the index associated with the model.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return string
|
* @return string
|
||||||
@ -123,6 +128,7 @@ public function searchableAs(): string
|
|||||||
/**
|
/**
|
||||||
* Get the indexable data array for the model.
|
* Get the indexable data array for the model.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return array
|
* @return array
|
||||||
@ -136,7 +142,7 @@ public function toSearchableArray(): array
|
|||||||
return \$payload;
|
return \$payload;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/**
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Accessors
|
| Accessors
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
@ -146,6 +152,7 @@ public function toSearchableArray(): array
|
|||||||
/**
|
/**
|
||||||
* An accessor.
|
* An accessor.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Database\Eloquent\Casts\Attribute
|
* @return \Illuminate\Database\Eloquent\Casts\Attribute
|
||||||
@ -158,7 +165,7 @@ protected function attrName(): Attribute
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/**
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Mutators
|
| Mutators
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
@ -167,7 +174,7 @@ protected function attrName(): Attribute
|
|||||||
|
|
||||||
//
|
//
|
||||||
|
|
||||||
/*
|
/**
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Scopes
|
| Scopes
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
@ -176,7 +183,7 @@ protected function attrName(): Attribute
|
|||||||
|
|
||||||
//
|
//
|
||||||
|
|
||||||
/*
|
/**
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Relationships
|
| Relationships
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
@ -186,6 +193,7 @@ protected function attrName(): Attribute
|
|||||||
/**
|
/**
|
||||||
* Something relationship.
|
* Something relationship.
|
||||||
*
|
*
|
||||||
|
* @package App\Models\Class
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
|
Loading…
x
Reference in New Issue
Block a user