from server 30.01.23
This commit is contained in:
parent
dacdc1a9f9
commit
112c317b0e
|
|
@ -234,12 +234,14 @@ class Post extends Model
|
|||
|
||||
// \Log::info($fields->category_groups->value);
|
||||
// \Log::info($fields->category_groupsq->value);
|
||||
|
||||
|
||||
if (isset($this->awtor)) {
|
||||
if ($this->awtor->type == 'other') {
|
||||
if ($this->awtor->type == 'other' && $context == "create") {
|
||||
$fields->author_name->value = '';
|
||||
$fields->author_name->readOnly = false;
|
||||
} elseif (isset($fields->author_name)) {
|
||||
} elseif ($this->awtor->type == 'other' && $context == "update") {
|
||||
$fields->author_name->readOnly = false;
|
||||
}elseif (isset($fields->author_name)) {
|
||||
$fields->author_name->value = $this->awtor->name;
|
||||
$fields->author_name->readOnly = true;
|
||||
}
|
||||
|
|
@ -277,8 +279,8 @@ class Post extends Model
|
|||
$fields->categories->value = null;
|
||||
}
|
||||
|
||||
\Log::info($fields->category_groups->value);
|
||||
\Log::info($this->category_groups);
|
||||
//\Log::info($fields->category_groups->value);
|
||||
// \Log::info($this->category_groups);
|
||||
|
||||
if($this->category_groups->where('type', 'news')->count()){
|
||||
$fields->type_post->hidden = false;
|
||||
|
|
|
|||
|
|
@ -59,3 +59,8 @@ columns:
|
|||
sortable: false
|
||||
select: name
|
||||
relation: awtor
|
||||
author_name:
|
||||
label: 'Awtor Ady'
|
||||
type: text
|
||||
searchable: true
|
||||
sortable: true
|
||||
|
|
|
|||
Loading…
Reference in New Issue