Enhance Form Visibility Logic and UI Components

- Updated the `getIsClosedAttribute` method in `Form.php` to include a check for the form's visibility status, ensuring that forms marked as 'closed' are accurately reflected in their state.
- Modified `QuillyEditor.vue` to import additional Quill patches for improved functionality.
- Changed the alert color from yellow to amber in `OpenCompleteForm.vue` for better visual consistency.
- Refactored the form status display in `OpenCompleteForm.vue` and `show.vue` to utilize the new `FormStatusBadges` component, streamlining the UI and improving maintainability.
- Enhanced the `FormEditorNavbar.vue` to include icons for better user experience and clarity.

These changes aim to improve the accuracy of form visibility handling and enhance the overall user interface across various components.
This commit is contained in:
JhumanJ
2025-05-16 19:58:53 +02:00
parent b5517c6fce
commit 1ba7805e35
8 changed files with 170 additions and 110 deletions

View File

@@ -223,7 +223,7 @@ class Form extends Model implements CachableAttributes
public function getIsClosedAttribute()
{
return $this->closes_at && now()->gt($this->closes_at);
return $this->visibility === 'closed' || ($this->closes_at && now()->gt($this->closes_at));
}
public function getFormPendingSubmissionKeyAttribute()