mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
lnbits paid articles added
This commit is contained in:
@@ -41,8 +41,8 @@ class NewsArticleForm extends Component
|
|||||||
'libraryItem.type' => 'required',
|
'libraryItem.type' => 'required',
|
||||||
'libraryItem.language_code' => 'required',
|
'libraryItem.language_code' => 'required',
|
||||||
'libraryItem.value' => 'required',
|
'libraryItem.value' => 'required',
|
||||||
'libraryItem.value_to_be_paid' => [Rule::requiredIf(!$this->libraryItem->sats), 'string',],
|
'libraryItem.value_to_be_paid' => [Rule::requiredIf($this->libraryItem->sats), 'nullable', 'string',],
|
||||||
'libraryItem.sats' => [Rule::requiredIf(!$this->libraryItem->sats), 'numeric',],
|
'libraryItem.sats' => [Rule::requiredIf($this->libraryItem->sats), 'nullable', 'numeric',],
|
||||||
'libraryItem.subtitle' => 'string|nullable',
|
'libraryItem.subtitle' => 'string|nullable',
|
||||||
'libraryItem.excerpt' => 'required',
|
'libraryItem.excerpt' => 'required',
|
||||||
'libraryItem.main_image_caption' => 'string|nullable',
|
'libraryItem.main_image_caption' => 'string|nullable',
|
||||||
@@ -66,9 +66,7 @@ class NewsArticleForm extends Component
|
|||||||
'sats' => $this->paid ? 21 : null,
|
'sats' => $this->paid ? 21 : null,
|
||||||
'news' => true,
|
'news' => true,
|
||||||
'language_code' => 'de',
|
'language_code' => 'de',
|
||||||
'approved' => auth()
|
'approved' => false,
|
||||||
->user()
|
|
||||||
->hasRole('news-editor'),
|
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
if (!$this->fromUrl) {
|
if (!$this->fromUrl) {
|
||||||
|
|||||||
Reference in New Issue
Block a user