Rename admin to panel
2
.github/dependabot.yml
vendored
@ -9,7 +9,7 @@ updates:
|
||||
update-types: ["version-update:semver-major"]
|
||||
|
||||
- package-ecosystem: "npm"
|
||||
directory: "/admin"
|
||||
directory: "/panel"
|
||||
schedule:
|
||||
interval: "monthly"
|
||||
ignore:
|
||||
|
6
.gitignore
vendored
@ -9,8 +9,8 @@ php_error.log
|
||||
|
||||
/vendor/*
|
||||
|
||||
/admin/accounts/*
|
||||
/admin/avatars/*
|
||||
/admin/logs/*
|
||||
/panel/accounts/*
|
||||
/panel/avatars/*
|
||||
/panel/logs/*
|
||||
|
||||
!.gitkeep
|
||||
|
@ -10,8 +10,8 @@ AddDefaultCharset utf-8
|
||||
|
||||
## Prevent direct access to Formwork folders but allow access to assets
|
||||
RewriteRule ^site/templates/assets/.* - [L]
|
||||
RewriteRule ^admin/(assets|avatars)/.* - [L]
|
||||
RewriteRule ^(admin|backup|cache|formwork|site|vendor)/.* index.php [L,NC]
|
||||
RewriteRule ^panel/(assets|avatars)/.* - [L]
|
||||
RewriteRule ^(panel|backup|cache|formwork|site|vendor)/.* index.php [L,NC]
|
||||
|
||||
## Prevent access to specific files
|
||||
RewriteRule ^(.*)\.(md|yml|json)/?$ index.php [L,NC]
|
||||
|
@ -1,4 +1,4 @@
|
||||
# <img src="admin/assets/images/icon.svg" height="28"> Formwork
|
||||
# <img src="panel/assets/images/icon.svg" height="28"> Formwork
|
||||
|
||||
[![Discord](https://img.shields.io/discord/637658168754831380?color=%235865f2&label=chat&logo=discord&logoColor=%23fff)](https://discord.gg/5Q3BmNY)
|
||||
[![GitHub Release Date](https://img.shields.io/github/release-date/getformwork/formwork.svg)](https://github.com/getformwork/formwork/releases/latest)
|
||||
|
@ -1,265 +0,0 @@
|
||||
admin.backup.backup: Backup
|
||||
admin.backup.error.cannot-download: Cannot download backup. %s.
|
||||
admin.backup.error.cannot-download.invalid-filename: Invalid backup file
|
||||
admin.backup.error.cannot-make: Cannot make backup. %s.
|
||||
admin.backup.ready: Backup ready. Starting download...
|
||||
admin.cache.clear: Clear Cache
|
||||
admin.cache.cleared: Cache cleared
|
||||
admin.dashboard.dashboard: Dashboard
|
||||
admin.dashboard.last-modified-pages: Last Edited Pages
|
||||
admin.dashboard.quick-actions: Quick Actions
|
||||
admin.dashboard.statistics: Statistics
|
||||
admin.dashboard.statistics.unique-visitors: Unique Visitors
|
||||
admin.dashboard.statistics.visits: Visits
|
||||
admin.dashboard.welcome: Welcome
|
||||
admin.drag-to-reorder: Drag to Reorder
|
||||
admin.errors.action.report-to-github: Report an issue to GitHub
|
||||
admin.errors.action.return-to-dashboard: Return to Dashboard
|
||||
admin.errors.error.forbidden.description: You don’t have permission to access this page.
|
||||
admin.errors.error.forbidden.heading: Oops, permission required!
|
||||
admin.errors.error.forbidden.status: Forbidden
|
||||
admin.errors.error.internal-server-error.description: Formwork Admin encountered an error while serving your request. Please check Formwork configuration or the server log for errors.
|
||||
admin.errors.error.internal-server-error.heading: Oops, something went wrong!
|
||||
admin.errors.error.internal-server-error.status: Internal Server Error
|
||||
admin.errors.error.not-found.description: The page does not exist or the request is not valid.
|
||||
admin.errors.error.not-found.heading: Oops, page not found!
|
||||
admin.errors.error.not-found.status: Not Found
|
||||
admin.login.attempt.failed: Login attempt failed! Try again.
|
||||
admin.login.attempt.too-many: Too many login attempts. Please try again in %d minutes.
|
||||
admin.login.logged-out: You have been logged out
|
||||
admin.login.login: Login
|
||||
admin.login.logout: Logout
|
||||
admin.login.password: Password
|
||||
admin.login.suspicious-request-detected: A suspicious request has been detected, and for security reasons you have been logged out. Please log in again.
|
||||
admin.login.username: Username
|
||||
admin.manage: Manage
|
||||
admin.modal.action.cancel: Cancel
|
||||
admin.modal.action.continue: Continue
|
||||
admin.modal.action.delete: Delete
|
||||
admin.modal.action.save: Save
|
||||
admin.modal.action.upload-file: Upload a File
|
||||
admin.modal.images.no-images: There are no images here
|
||||
admin.modal.images.no-images.upload: Please upload some images
|
||||
admin.modal.images.title: Select an Image
|
||||
admin.options.info: Info
|
||||
admin.options.options: Options
|
||||
admin.options.site: Site
|
||||
admin.options.site.advanced: Advanced Options
|
||||
admin.options.site.advanced.aliases: Aliases
|
||||
admin.options.site.advanced.aliases.alias: Alias
|
||||
admin.options.site.advanced.aliases.route: Route
|
||||
admin.options.site.advanced.metadata: HTML Metadata
|
||||
admin.options.site.advanced.metadata.content: Content
|
||||
admin.options.site.advanced.metadata.name: Name
|
||||
admin.options.site.info: Info
|
||||
admin.options.site.info.author: Author
|
||||
admin.options.site.info.description: Description
|
||||
admin.options.site.info.language: Language
|
||||
admin.options.site.info.title: Title
|
||||
admin.options.system: System
|
||||
admin.options.system.admin-panel: Admin Panel
|
||||
admin.options.system.admin-panel.default-color-scheme: Default Color Scheme
|
||||
admin.options.system.admin-panel.default-color-scheme.dark: Dark
|
||||
admin.options.system.admin-panel.default-color-scheme.light: Light
|
||||
admin.options.system.admin-panel.default-language: Default Language
|
||||
admin.options.system.admin-panel.logout-redirects-to: Logout Redirects to
|
||||
admin.options.system.admin-panel.logout-redirects-to.home: Home
|
||||
admin.options.system.admin-panel.logout-redirects-to.login: Login
|
||||
admin.options.system.admin-panel.session-timeout: Session Timeout (min)
|
||||
admin.options.system.backup: Backup
|
||||
admin.options.system.backup.backup-files-to-keep: Backups to keep on the server
|
||||
admin.options.system.cache: Cache
|
||||
admin.options.system.cache.disabled: Disabled
|
||||
admin.options.system.cache.enabled: Enabled
|
||||
admin.options.system.cache.time: Cache Time (sec)
|
||||
admin.options.system.date-and-time: Date and Time
|
||||
admin.options.system.date-and-time.date-format: Date Format
|
||||
admin.options.system.date-and-time.first-weekday: First Weekday
|
||||
admin.options.system.date-and-time.first-weekday.monday: Monday
|
||||
admin.options.system.date-and-time.first-weekday.sunday: Sunday
|
||||
admin.options.system.date-and-time.hour-format: Hour Format
|
||||
admin.options.system.date-and-time.timezone: Timezone
|
||||
admin.options.system.files: Files
|
||||
admin.options.system.files.allowed-extensions: Allowed Extensions
|
||||
admin.options.system.images: Images
|
||||
admin.options.system.images.jpeg-quality: JPEG Quality
|
||||
admin.options.system.images.jpeg-save-progressive: Save JPEG images as progressive
|
||||
admin.options.system.images.jpeg-save-progressive.disabled: Disabled
|
||||
admin.options.system.images.jpeg-save-progressive.enabled: Enabled
|
||||
admin.options.system.images.png-compression-level: PNG Compression Level
|
||||
admin.options.system.images.process-uploads: Process (optimize) uploaded images
|
||||
admin.options.system.images.process-uploads.disabled: Disabled
|
||||
admin.options.system.images.process-uploads.enabled: Enabled
|
||||
admin.options.system.images.webp-quality: WebP Quality
|
||||
admin.options.system.languages: Languages
|
||||
admin.options.system.languages.available-languages: Available Languages
|
||||
admin.options.system.languages.available-languages.no-languages: No Languages
|
||||
admin.options.system.languages.preferred-language: Use Browser Prefered Language
|
||||
admin.options.system.languages.preferred-language.disabled: Disabled
|
||||
admin.options.system.languages.preferred-language.enabled: Enabled
|
||||
admin.options.updated: Options updated
|
||||
admin.options.updates: Updates
|
||||
admin.pages.attributes: Attributes
|
||||
admin.pages.change-slug: Edit Slug
|
||||
admin.pages.change-slug.generate: Generate From Title
|
||||
admin.pages.changes.continue: Continue without Saving
|
||||
admin.pages.changes.detected: Changes Detected
|
||||
admin.pages.changes.detected.prompt: You have some changes that have not been saved. Are you sure you want to leave this page?
|
||||
admin.pages.content: Content
|
||||
admin.pages.delete-file: Delete File
|
||||
admin.pages.delete-file.prompt: Are you sure you want to delete this file? This action can’t be undone.
|
||||
admin.pages.delete-page: Delete Page
|
||||
admin.pages.delete-page.prompt: Are you sure you want to delete this page? This action can’t be undone.
|
||||
admin.pages.edit-page: Edit Page %s
|
||||
admin.pages.editor.bold: Bold
|
||||
admin.pages.editor.bullet-list: Bullet list
|
||||
admin.pages.editor.image: Image
|
||||
admin.pages.editor.italic: Italic
|
||||
admin.pages.editor.link: Link
|
||||
admin.pages.editor.numbered-list: Ordered list
|
||||
admin.pages.editor.quote: Quote
|
||||
admin.pages.editor.redo: Redo
|
||||
admin.pages.editor.summary: Summary
|
||||
admin.pages.editor.undo: Undo
|
||||
admin.pages.files: Files
|
||||
admin.pages.files.upload-label: <strong>Click</strong> to choose a file to upload or <strong>drag</strong> it here
|
||||
admin.pages.languages: Languages
|
||||
admin.pages.languages.add-language: Add %s
|
||||
admin.pages.languages.edit-language: Edit %s
|
||||
admin.pages.new-page: New Page
|
||||
admin.pages.new-page.parent: Parent Page
|
||||
admin.pages.new-page.site: Site
|
||||
admin.pages.new-page.slug-suggestion: letters, numbers and dashes only
|
||||
admin.pages.new-page.slug: Page Slug
|
||||
admin.pages.new-page.template: Template
|
||||
admin.pages.new-page.title: Title
|
||||
admin.pages.options: Options
|
||||
admin.pages.page: Page
|
||||
admin.pages.page.actions: Actions
|
||||
admin.pages.page.cacheable: Cacheable
|
||||
admin.pages.page.cannot-change-num: Cannot change page number
|
||||
admin.pages.page.cannot-create: Cannot create page
|
||||
admin.pages.page.cannot-create.already-exists: Cannot create page, a page with the same uri already exists
|
||||
admin.pages.page.cannot-create.invalid-parent: Cannot create page, invalid parent page
|
||||
admin.pages.page.cannot-create.invalid-slug: Cannot create page, page slug must contain only letters and numbers separated by dashes
|
||||
admin.pages.page.cannot-create.invalid-template: Cannot create page, invalid template
|
||||
admin.pages.page.cannot-create.var-missing: Cannot create page, missing a variable
|
||||
admin.pages.page.cannot-delete-file.file-not-found: Cannot delete file, file not found
|
||||
admin.pages.page.cannot-delete-file.page-not-found: Cannot delete file, file not found
|
||||
admin.pages.page.cannot-delete.invalid-language: 'Cannot delete page, invalid language: %s'
|
||||
admin.pages.page.cannot-delete.not-deletable: Cannot delete page, the page is not deletable
|
||||
admin.pages.page.cannot-delete.page-not-found: Cannot delete page, page not found
|
||||
admin.pages.page.cannot-edit.already-exists: Cannot edit page, a page with the same uri already exists
|
||||
admin.pages.page.cannot-edit.index-or-error-page-slug: Cannot edit page slug of index and error pages
|
||||
admin.pages.page.cannot-edit.invalid-language: 'Cannot edit page, invalid language: %s'
|
||||
admin.pages.page.cannot-edit.invalid-parent: Cannot edit page, invalid parent page
|
||||
admin.pages.page.cannot-edit.invalid-slug: Cannot edit page slug, it must contain only letters and numbers separated by dashes
|
||||
admin.pages.page.cannot-edit.invalid-template: Cannot edit page, invalid template
|
||||
admin.pages.page.cannot-edit.page-not-found: Cannot edit page, page not found
|
||||
admin.pages.page.cannot-edit.var-missing: Cannot edit page, missing a variable
|
||||
admin.pages.page.cannot-move: Cannot move page
|
||||
admin.pages.page.cannot-upload-file.page-not-found: Cannot upload file, page not found
|
||||
admin.pages.page.created: Page created!
|
||||
admin.pages.page.deleted: Page deleted
|
||||
admin.pages.page.edited: Page edited
|
||||
admin.pages.page.file-deleted: File deleted
|
||||
admin.pages.page.image: Image
|
||||
admin.pages.page.last-modified: Last Modified
|
||||
admin.pages.page.moved: Page moved!
|
||||
admin.pages.page.no-date: No Date
|
||||
admin.pages.page.no-image: No Image
|
||||
admin.pages.page.no-tags: No Tags
|
||||
admin.pages.page.not-found: Page not found
|
||||
admin.pages.page.posts-per-page: Posts per page
|
||||
admin.pages.page.publish-date: Publish Date
|
||||
admin.pages.page.status: Status
|
||||
admin.pages.page.tags: Tags
|
||||
admin.pages.page.title: Title
|
||||
admin.pages.page.unpublish-date: Unpublish Date
|
||||
admin.pages.page.listed: Visible in the menu
|
||||
admin.pages.pages: Pages
|
||||
admin.pages.pages.collapse-all: Collapse All
|
||||
admin.pages.pages.expand-all: Expand All
|
||||
admin.pages.pages.reorder: Reorder
|
||||
admin.pages.pages.search: Search Pages...
|
||||
admin.pages.parent: Parent Page
|
||||
admin.pages.preview-file: Preview
|
||||
admin.pages.preview: Preview
|
||||
admin.pages.save: Save
|
||||
admin.pages.status.not-published: Not Published
|
||||
admin.pages.status.not-routable: Not Routable
|
||||
admin.pages.status.published: Published
|
||||
admin.pages.status.routable: Routable
|
||||
admin.pages.summary: Summary
|
||||
admin.pages.template: Template
|
||||
admin.pages.text: Text
|
||||
admin.pages.toggle-children: Toggle Children Pages
|
||||
admin.panel: Administration Panel
|
||||
admin.register.create-user: Formwork Admin is installed but no users were found. Please register a user now.
|
||||
admin.register.register: Register New User
|
||||
admin.request.error.post-max-size: The HTTP POST request exceeds the maximum allowed size
|
||||
admin.updates.available-for-install: is available for install
|
||||
admin.updates.check: Check Updates
|
||||
admin.updates.install-prompt: Would you like to install the update?
|
||||
admin.updates.install: Install
|
||||
admin.updates.installed: Update installed!
|
||||
admin.updates.latest-version-available: is the latest version available
|
||||
admin.updates.status.cannot-check: Cannot check for updates. Try again later.
|
||||
admin.updates.status.cannot-install: Cannot install update
|
||||
admin.updates.status.cannot-make-backup: Cannot make backup before updating
|
||||
admin.updates.status.checking: Checking for updates...
|
||||
admin.updates.status.found: Updates found
|
||||
admin.updates.status.installing: Installing updates...
|
||||
admin.updates.status.up-to-date: Up-to-date!
|
||||
admin.uploader.error: Cannot upload file. %s.
|
||||
admin.uploader.error.already-exists: A file with the same name already exists
|
||||
admin.uploader.error.cannot-move-to-destination: Failed to move uploaded file to destination
|
||||
admin.uploader.error.cannot-write: Failed to write file to disk
|
||||
admin.uploader.error.destination-too-long: Destination path too long
|
||||
admin.uploader.error.file-name-too-long: File name too long
|
||||
admin.uploader.error.file-name: Invalid file name
|
||||
admin.uploader.error.hidden-files: Cannot upload hidden files beginning with a dot
|
||||
admin.uploader.error.mime-type: File type not allowed
|
||||
admin.uploader.error.no-file: No file was uploaded
|
||||
admin.uploader.error.no-temp: Missing a temporary folder
|
||||
admin.uploader.error.partial: The uploaded file was only partially uploaded
|
||||
admin.uploader.error.php-extension: File upload stopped by extension
|
||||
admin.uploader.error.size: The uploaded file exceeds the maximum file size
|
||||
admin.uploader.uploaded: File uploaded
|
||||
admin.user.actions: Actions
|
||||
admin.user.avatar: Avatar
|
||||
admin.user.avatar.uploaded: Avatar uploaded
|
||||
admin.user.color-scheme: Color Scheme
|
||||
admin.user.color-scheme.auto: Auto
|
||||
admin.user.color-scheme.dark: Dark
|
||||
admin.user.color-scheme.light: Light
|
||||
admin.user.email: Email
|
||||
admin.user.fullname: Full Name
|
||||
admin.user.language: Language
|
||||
admin.user.last-access: Last access
|
||||
admin.user.password: Password
|
||||
admin.user.password.type-new-password: Type a new password to change...
|
||||
admin.user.role: Role
|
||||
admin.user.role.admin: Administrator
|
||||
admin.user.role.user: User
|
||||
admin.user.username: Username
|
||||
admin.users.delete-user: Delete User
|
||||
admin.users.delete-user.prompt: Are you sure you want to delete this user? This action can’t be undone.
|
||||
admin.users.new-user: New User
|
||||
admin.users.new-user.password-suggestion: at least 8 characters
|
||||
admin.users.new-user.username-suggestion: between 3-20 letters, digits and dashes
|
||||
admin.users.options: Options
|
||||
admin.users.user-profile: '%s User Profile'
|
||||
admin.users.user: User
|
||||
admin.users.user.cannot-change-password: Cannot change the password of another user. The action is not allowed.
|
||||
admin.users.user.cannot-change-role: Cannot change the role of %s. The action is not allowed.
|
||||
admin.users.user.cannot-create.already-exists: Cannot create user, a user with the same name already exists
|
||||
admin.users.user.cannot-create.var-missing: Cannot create user, missing a variable
|
||||
admin.users.user.cannot-delete: Cannot delete user. You must be an administrator and the user must not be logged in.
|
||||
admin.users.user.cannot-edit: Cannot edit user %s. The action is not allowed.
|
||||
admin.users.user.created: User created
|
||||
admin.users.user.deleted: User deleted
|
||||
admin.users.user.edited: User data updated
|
||||
admin.users.user.not-found: User not found
|
||||
admin.users.users: Users
|
||||
admin.view-site: View Site
|
@ -1,248 +0,0 @@
|
||||
admin.backup.backup: Sauvegarde
|
||||
admin.backup.error.cannot-download: Impossible de télécharger la sauvegarde. %s.
|
||||
admin.backup.error.cannot-download.invalid-filename: Fichier de sauvegarde invalide
|
||||
admin.backup.error.cannot-make: Impossible de faire une sauvegarde. %s.
|
||||
admin.backup.ready: Sauvegarde prête. Démarrage du téléchargement…
|
||||
admin.cache.clear: Vider le cache
|
||||
admin.cache.cleared: Cache effacé
|
||||
admin.dashboard.dashboard: Tableau de bord
|
||||
admin.dashboard.last-modified-pages: Dernières pages éditées
|
||||
admin.dashboard.quick-actions: Actions rapides
|
||||
admin.dashboard.statistics: Statistiques
|
||||
admin.dashboard.statistics.unique-visitors: Visiteurs uniques
|
||||
admin.dashboard.statistics.visits: Visites
|
||||
admin.dashboard.welcome: Bienvenue
|
||||
admin.errors.action.report-to-github: Signaler le problème sur GitHub
|
||||
admin.errors.action.return-to-dashboard: Retour au tableau de bord
|
||||
admin.errors.error.forbidden.description: Vous n’êtes pas autorisé à accéder à cette page.
|
||||
admin.errors.error.forbidden.heading: Oups, permission requise!
|
||||
admin.errors.error.forbidden.status: Interdit
|
||||
admin.errors.error.internal-server-error.description: Une erreur s’est produite lors du traitement de votre demande. Veuillez vérifier la configuration du CMS ou le journal du serveur pour rechercher des erreurs.
|
||||
admin.errors.error.internal-server-error.heading: Oups, quelque chose s’est mal passé!
|
||||
admin.errors.error.internal-server-error.status: Erreur Interne du Serveur
|
||||
admin.errors.error.not-found.description: La page n’existe pas ou la demande n’est pas valide.
|
||||
admin.errors.error.not-found.heading: Oups, page non trouvée!
|
||||
admin.errors.error.not-found.status: Pas trouvé
|
||||
admin.login.attempt.failed: La tentative de connexion a échoué! Réessayer.
|
||||
admin.login.attempt.too-many: Trop de tentatives de connexion. Veuillez réessayer dans %d minutes.
|
||||
admin.login.logged-out: Vous avez été déconnecté
|
||||
admin.login.login: S’identifier
|
||||
admin.login.logout: Déconnexion
|
||||
admin.login.password: Mot de passe
|
||||
admin.login.suspicious-request-detected: Une demande suspecte a été détectée et pour des raisons de sécurité, vous avez été déconnecté. Veuillez vous reconnecter.
|
||||
admin.login.username: Nom d’utilisateur
|
||||
admin.manage: Gérer
|
||||
admin.modal.action.cancel: Annuler
|
||||
admin.modal.action.continue: Continuer
|
||||
admin.modal.action.delete: Supprimer
|
||||
admin.modal.action.save: Enregistrer
|
||||
admin.modal.action.upload-file: Parcourir…
|
||||
admin.modal.images.no-images: Aucun fichier média n’a été trouvé.
|
||||
admin.modal.images.no-images.upload: Sélectionnez vos fichiers à téléverser.
|
||||
admin.modal.images.title: Bibliothèque de médias
|
||||
admin.options.info: Information
|
||||
admin.options.options: Paramètres
|
||||
admin.options.site: Site
|
||||
admin.options.site.advanced: Options avancées
|
||||
admin.options.site.advanced.aliases: Alias
|
||||
admin.options.site.advanced.aliases.alias: Alias
|
||||
admin.options.site.advanced.aliases.route: Route
|
||||
admin.options.site.advanced.metadata: Métadonnées HTML
|
||||
admin.options.site.advanced.metadata.content: Contenu
|
||||
admin.options.site.advanced.metadata.name: Nom
|
||||
admin.options.site.info: Info
|
||||
admin.options.site.info.author: Auteur
|
||||
admin.options.site.info.description: Description
|
||||
admin.options.site.info.language: Langue
|
||||
admin.options.site.info.title: Titre
|
||||
admin.options.system: Système
|
||||
admin.options.system.admin-panel: Panneau d’administration
|
||||
admin.options.system.admin-panel.default-language: Langue par défaut
|
||||
admin.options.system.admin-panel.logout-redirects-to: Après déconnexion, redirection vers
|
||||
admin.options.system.admin-panel.logout-redirects-to.home: Page d’accueil
|
||||
admin.options.system.admin-panel.logout-redirects-to.login: Page d’identification
|
||||
admin.options.system.admin-panel.session-timeout: Expiration de la session (min)
|
||||
admin.options.system.backup: Sauvegarde
|
||||
admin.options.system.backup.backup-files-to-keep: Sauvegardes à conserver sur le serveur
|
||||
admin.options.system.cache: Cache
|
||||
admin.options.system.cache.disabled: Désactivé
|
||||
admin.options.system.cache.enabled: Activé
|
||||
admin.options.system.cache.time: Temps de mise cache (sec)
|
||||
admin.options.system.date-and-time: Date et heure
|
||||
admin.options.system.date-and-time.date-format: Format de date
|
||||
admin.options.system.date-and-time.first-weekday: La semaine débute le
|
||||
admin.options.system.date-and-time.first-weekday.monday: Lundi
|
||||
admin.options.system.date-and-time.first-weekday.sunday: Dimanche
|
||||
admin.options.system.date-and-time.hour-format: Format d’heure
|
||||
admin.options.system.date-and-time.timezone: Fuseau horaire
|
||||
admin.options.system.files: Fichiers
|
||||
admin.options.system.files.allowed-extensions: Extensions autorisées
|
||||
admin.options.system.images: Images
|
||||
admin.options.system.images.jpeg-quality: Qualité JPEG
|
||||
admin.options.system.images.jpeg-save-progressive: Enregistrer les images JPEG en progressif
|
||||
admin.options.system.images.jpeg-save-progressive.disabled: Désactivé
|
||||
admin.options.system.images.jpeg-save-progressive.enabled: Activé
|
||||
admin.options.system.images.png-compression-level: Niveau de compression PNG
|
||||
admin.options.system.images.process-uploads: Traitement (optimisé) des images envoyées
|
||||
admin.options.system.images.process-uploads.disabled: Désactivé
|
||||
admin.options.system.images.process-uploads.enabled: Activé
|
||||
admin.options.system.images.webp-quality: Qualité WebP
|
||||
admin.options.system.languages: Langues
|
||||
admin.options.system.languages.available-languages: Langues disponibles
|
||||
admin.options.system.languages.available-languages.no-languages: Aucune langue
|
||||
admin.options.system.languages.preferred-language: Utiliser la langue préférée du navigateur
|
||||
admin.options.system.languages.preferred-language.disabled: Désactivé
|
||||
admin.options.system.languages.preferred-language.enabled: Activé
|
||||
admin.options.updated: Options mises à jour
|
||||
admin.options.updates: Mises à jour
|
||||
admin.pages.attributes: Attributs
|
||||
admin.pages.change-slug: Modifier le permalien
|
||||
admin.pages.change-slug.generate: Générer automatiquement à partir du titre
|
||||
admin.pages.changes.continue: Continuer sans sauvegarder
|
||||
admin.pages.changes.detected: Changements détectés
|
||||
admin.pages.changes.detected.prompt: Vous avez des modifications qui n’ont pas été enregistrées. Êtes-vous sûr de vouloir quitter cette page ?
|
||||
admin.pages.content: Contenu
|
||||
admin.pages.delete-file: Supprimer le fichier
|
||||
admin.pages.delete-file.prompt: Êtes-vous sûr de vouloir supprimer ce fichier ? Cette action est irréversible.
|
||||
admin.pages.delete-page: Supprimer la page
|
||||
admin.pages.delete-page.prompt: Êtes-vous sûr de vouloir supprimer cette page ? Cette action est irréversible.
|
||||
admin.pages.edit-page: Modifier la page %s
|
||||
admin.pages.editor.bold: Gras
|
||||
admin.pages.editor.bullet-list: Liste à puce
|
||||
admin.pages.editor.image: Image
|
||||
admin.pages.editor.italic: Italique
|
||||
admin.pages.editor.link: Lien
|
||||
admin.pages.editor.numbered-list: Liste ordonnée
|
||||
admin.pages.editor.quote: Citer
|
||||
admin.pages.editor.redo: Refaire
|
||||
admin.pages.editor.summary: Résumé
|
||||
admin.pages.editor.undo: Annuler
|
||||
admin.pages.files: Fichiers
|
||||
admin.pages.languages: Langues
|
||||
admin.pages.languages.add-language: Ajouter %s
|
||||
admin.pages.languages.edit-language: Éditer %s
|
||||
admin.pages.new-page: Nouvelle page
|
||||
admin.pages.new-page.parent: Parent
|
||||
admin.pages.new-page.site: Site
|
||||
admin.pages.new-page.slug-suggestion: lettres, chiffres et tirets seulement
|
||||
admin.pages.new-page.slug: Permalien
|
||||
admin.pages.new-page.template: Modèle (Template)
|
||||
admin.pages.new-page.title: Titre
|
||||
admin.pages.options: Options
|
||||
admin.pages.page.actions: Actions
|
||||
admin.pages.page.cacheable: Activer le cache
|
||||
admin.pages.page.cannot-change-num: Impossible de changer le numéro de page
|
||||
admin.pages.page.cannot-create: Impossible de créer une page
|
||||
admin.pages.page.cannot-create.already-exists: Impossible de créer une page, une page avec le même uri existe déjà
|
||||
admin.pages.page.cannot-create.invalid-parent: Impossible de créer une page, page parente non valide
|
||||
admin.pages.page.cannot-create.invalid-slug: Impossible de créer une page, l’identifiant de la page ne doit contenir que des lettres et des chiffres séparés par des tirets
|
||||
admin.pages.page.cannot-create.invalid-template: Impossible de créer une page, modèle non valide
|
||||
admin.pages.page.cannot-create.var-missing: Impossible de créer une page, il manque une variable
|
||||
admin.pages.page.cannot-delete-file.file-not-found: Impossible de supprimer le fichier, fichier introuvable
|
||||
admin.pages.page.cannot-delete-file.page-not-found: Impossible de supprimer le fichier, page non trouvée
|
||||
admin.pages.page.cannot-delete.invalid-language: 'Impossible de supprimer la page, terme non défini : %s'
|
||||
admin.pages.page.cannot-delete.not-deletable: Impossible de supprimer la page, la page ne peut être supprimée
|
||||
admin.pages.page.cannot-delete.page-not-found: Impossible de supprimer la page, page introuvable
|
||||
admin.pages.page.cannot-edit.already-exists: Impossible de modifier la page, une page avec la même URL existe déjà
|
||||
admin.pages.page.cannot-edit.index-or-error-page-slug: Impossible de modifier l’identifiant de la page d’acceuil et celle de la page d’erreur
|
||||
admin.pages.page.cannot-edit.invalid-language: 'Impossible de modifier la page, terme non défini : %s'
|
||||
admin.pages.page.cannot-edit.invalid-parent: Impossible de modifier la page, page parente non valide
|
||||
admin.pages.page.cannot-edit.invalid-slug: Impossible de modifier l’identifiant de la page, il doit contenir que des lettres et des chiffres séparés par des tirets
|
||||
admin.pages.page.cannot-edit.invalid-template: Impossible de modifier la page, modèle non valide
|
||||
admin.pages.page.cannot-edit.page-not-found: Impossible de modifier la page, page non trouvée
|
||||
admin.pages.page.cannot-edit.var-missing: Impossible de modifier la page, il manque une variable
|
||||
admin.pages.page.cannot-move: Impossible de déplacer la page
|
||||
admin.pages.page.cannot-upload-file.page-not-found: Impossible de téléverser le fichier, page introuvable
|
||||
admin.pages.page.created: Page créée !
|
||||
admin.pages.page.deleted: Page supprimée
|
||||
admin.pages.page.edited: Page éditée
|
||||
admin.pages.page.file-deleted: Fichier supprimé
|
||||
admin.pages.page.image: Image d’accroche
|
||||
admin.pages.page.last-modified: Dernière modification
|
||||
admin.pages.page.moved: Page déplacée !
|
||||
admin.pages.page.no-date: Aucune date
|
||||
admin.pages.page.no-image: Aucune image
|
||||
admin.pages.page.no-tags: Aucun tag
|
||||
admin.pages.page.not-found: Page non trouvée
|
||||
admin.pages.page.posts-per-page: Articles par page
|
||||
admin.pages.page.publish-date: Date de publication
|
||||
admin.pages.page.status: Statut
|
||||
admin.pages.page.tags: Tags
|
||||
admin.pages.page.title: Titre
|
||||
admin.pages.page.unpublish-date: Date de péremption
|
||||
admin.pages.page.visible: Visible dans le menu
|
||||
admin.pages.pages: Pages
|
||||
admin.pages.pages.collapse-all: Tout réduire
|
||||
admin.pages.pages.expand-all: Tout développer
|
||||
admin.pages.pages.reorder: Réorganiser
|
||||
admin.pages.pages.search: Rechercher dans les Pages…
|
||||
admin.pages.parent: Parent
|
||||
admin.pages.preview-file: Aperçu
|
||||
admin.pages.preview: Aperçu
|
||||
admin.pages.save: Enregistrer
|
||||
admin.pages.status.not-published: Brouillon
|
||||
admin.pages.status.not-routable: Inaccessible
|
||||
admin.pages.status.published: Publié
|
||||
admin.pages.status.routable: Accessible
|
||||
admin.pages.template: Modèle
|
||||
admin.panel: Panneau d’administration
|
||||
admin.register.create-user: Le compte admin est installé mais aucun utilisateur n’a été trouvé. Veuillez enregistrer un utilisateur maintenant.
|
||||
admin.register.register: Enregistrer un nouvel utilisateur
|
||||
admin.request.error.post-max-size: La demande HTTP POST dépasse la taille maximale autorisée
|
||||
admin.updates.available-for-install: est disponible pour l’installation
|
||||
admin.updates.check: Vérifier les mises à jour
|
||||
admin.updates.install-prompt: Voulez-vous installer la mise à jour ?
|
||||
admin.updates.install: Installer
|
||||
admin.updates.installed: Mise à jour installée !
|
||||
admin.updates.latest-version-available: est la dernière version disponible
|
||||
admin.updates.status.cannot-install: Impossible d’installer la mise à jour
|
||||
admin.updates.status.cannot-make-backup: Impossible de faire une sauvegarde avant la mise à jour
|
||||
admin.updates.status.checking: Vérification des mises à jour…
|
||||
admin.updates.status.found: Mises à jour trouvées
|
||||
admin.updates.status.installing: Installation de mises à jour…
|
||||
admin.updates.status.up-to-date: À jour !
|
||||
admin.uploader.error: Impossible de télécharger le fichier. %s.
|
||||
admin.uploader.error.already-exists: Un fichier du même nom existe déjà
|
||||
admin.uploader.error.cannot-write: Échec de l’écriture du fichier sur le disque
|
||||
admin.uploader.error.file-name: Nom de fichier non valide
|
||||
admin.uploader.error.hidden-files: Impossible de téléverser des fichiers cachés commençant par un point
|
||||
admin.uploader.error.mime-type: Type de fichier non autorisé
|
||||
admin.uploader.error.no-file: Aucun fichier n’a été téléchargé
|
||||
admin.uploader.error.no-temp: Absence du dossier temporaire
|
||||
admin.uploader.error.partial: Le fichier envoyé n’a été que partiellement téléversé
|
||||
admin.uploader.error.php-extension: Téléversement du fichier arrêté par extension
|
||||
admin.uploader.error.size: Le fichier téléversé dépasse la taille de fichier maximale
|
||||
admin.uploader.uploaded: Fichier envoyé !
|
||||
admin.user.actions: Actions
|
||||
admin.user.avatar: Photo de profil
|
||||
admin.user.avatar.uploaded: Photo de profil téléversée avec succès.
|
||||
admin.user.email: Adresse de messagerie
|
||||
admin.user.fullname: Nom complet
|
||||
admin.user.language: Langue
|
||||
admin.user.last-access: Dernier accès
|
||||
admin.user.password: Mot de passe
|
||||
admin.user.password.type-new-password: Tapez un nouveau mot de passe pour le modifier...
|
||||
admin.user.role: Rôle
|
||||
admin.user.role.admin: Administrateur
|
||||
admin.user.role.user: Éditeur
|
||||
admin.user.username: Nom d’utilisateur
|
||||
admin.users.delete-user: Supprimer l’utilisateur
|
||||
admin.users.delete-user.prompt: Êtes-vous sûr de vouloir supprimer cet utilisateur? Cette action est irréversible.
|
||||
admin.users.new-user: Nouvel utilisateur
|
||||
admin.users.new-user.password-suggestion: au moins 8 caractères
|
||||
admin.users.new-user.username-suggestion: entre 3-20 lettres, chiffres et tirets
|
||||
admin.users.options: Options
|
||||
admin.users.user-profile: 'Profil utilisateur de %s'
|
||||
admin.users.user: Utilisateur
|
||||
admin.users.user.cannot-change-password: Impossible de changer le mot de passe d’un autre utilisateur. L’action n’est pas autorisée.
|
||||
admin.users.user.cannot-change-role: Impossible de changer le rôle de %s. L’action n’est pas autorisée.
|
||||
admin.users.user.cannot-create.already-exists: Impossible de créer l’utilisateur, un utilisateur portant le même nom existe déjà
|
||||
admin.users.user.cannot-create.var-missing: Impossible de créer l’utilisateur, il manque une variable
|
||||
admin.users.user.cannot-delete: Impossible de supprimer l’utilisateur. Vous devez être un administrateur et l’utilisateur ne doit pas être connecté.
|
||||
admin.users.user.cannot-edit: Impossible de modifier l’utilisateur %s. L’action n’est pas autorisée.
|
||||
admin.users.user.created: Compte utilisateur créé
|
||||
admin.users.user.deleted: Utilisateur supprimé
|
||||
admin.users.user.edited: Profil utilisateur mises à jour
|
||||
admin.users.user.not-found: Utilisateur non trouvé
|
||||
admin.users.users: Utilisateurs
|
||||
admin.view-site: Voir le site
|
@ -1,262 +0,0 @@
|
||||
admin.backup.backup: Esegui backup
|
||||
admin.backup.error.cannot-download: Impossibile scaricare il backup. %s.
|
||||
admin.backup.error.cannot-download.invalid-filename: File di backup non valido.
|
||||
admin.backup.error.cannot-make: Impossibile eseguire il backup. %s.
|
||||
admin.backup.ready: Backup pronto. Inizio a scaricare...
|
||||
admin.cache.clear: Svuota cache
|
||||
admin.cache.cleared: Cache svuotata
|
||||
admin.dashboard.dashboard: Riepilogo
|
||||
admin.dashboard.last-modified-pages: Ultime pagine modificate
|
||||
admin.dashboard.quick-actions: Azioni rapide
|
||||
admin.dashboard.statistics: Statistiche
|
||||
admin.dashboard.statistics.unique-visitors: Visitatori unici
|
||||
admin.dashboard.statistics.visits: Visite
|
||||
admin.dashboard.welcome: Benvenuto/a
|
||||
admin.drag-to-reorder: Trascina per riordinare
|
||||
admin.errors.action.report-to-github: Segnala un problema su GitHub
|
||||
admin.errors.action.return-to-dashboard: Torna al Riepilogo
|
||||
admin.errors.error.forbidden.description: Non si hanno i permessi per accedere a questa pagina.
|
||||
admin.errors.error.forbidden.heading: Oops, permessi mancanti!
|
||||
admin.errors.error.forbidden.status: Accesso negato
|
||||
admin.errors.error.internal-server-error.description: Formwork Admin ha riscontrato un errore nell’elaborare la richiesta. Controlla la configurazione di Formwork o il registro degli errori.
|
||||
admin.errors.error.internal-server-error.heading: Oops, qualcosa è andato storto!
|
||||
admin.errors.error.internal-server-error.status: Errore interno del server
|
||||
admin.errors.error.not-found.description: La pagina non esiste o la richiesta non è valida.
|
||||
admin.errors.error.not-found.heading: Oops, pagina non trovata!
|
||||
admin.errors.error.not-found.status: Non trovato
|
||||
admin.login.attempt.failed: Tentativo di accesso fallito! Riprova.
|
||||
admin.login.attempt.too-many: Sono stati sbagliati troppi tentativi di accesso. Riprova tra %d minuti.
|
||||
admin.login.logged-out: Sei stato disconnesso
|
||||
admin.login.login: Accedi
|
||||
admin.login.logout: Esci
|
||||
admin.login.password: Password
|
||||
admin.login.suspicious-request-detected: È stata rilevata una richiesta sospetta e per ragioni di sicurezza si è usciti dalla sessione. Effettua nuovamente l’accesso.
|
||||
admin.login.username: Nome utente
|
||||
admin.manage: Gestione
|
||||
admin.modal.action.cancel: Annulla
|
||||
admin.modal.action.continue: Continua
|
||||
admin.modal.action.delete: Elimina
|
||||
admin.modal.action.save: Salva
|
||||
admin.modal.action.upload-file: Carica file
|
||||
admin.modal.images.no-images: Qui non ci sono immagini
|
||||
admin.modal.images.no-images.upload: Carica qualche immagine
|
||||
admin.modal.images.title: Seleziona immagine
|
||||
admin.options.info: Informazioni
|
||||
admin.options.options: Impostazioni
|
||||
admin.options.site: Sito
|
||||
admin.options.site.advanced: Impostazioni avanzate
|
||||
admin.options.site.advanced.aliases: Alias
|
||||
admin.options.site.advanced.aliases.alias: Alias
|
||||
admin.options.site.advanced.aliases.route: Indirizzo
|
||||
admin.options.site.advanced.metadata: Metadati HTML
|
||||
admin.options.site.advanced.metadata.content: Contenuto
|
||||
admin.options.site.advanced.metadata.name: Nome
|
||||
admin.options.site.info: Informazioni
|
||||
admin.options.site.info.author: Autore
|
||||
admin.options.site.info.description: Descrizione
|
||||
admin.options.site.info.language: Lingua
|
||||
admin.options.site.info.title: Titolo
|
||||
admin.options.system: Sistema
|
||||
admin.options.system.admin-panel: Pannello di amministrazione
|
||||
admin.options.system.admin-panel.default-color-scheme: Combinazione di colori predefinita
|
||||
admin.options.system.admin-panel.default-color-scheme.dark: Scura
|
||||
admin.options.system.admin-panel.default-color-scheme.light: Chiara
|
||||
admin.options.system.admin-panel.default-language: Lingua predefinita
|
||||
admin.options.system.admin-panel.logout-redirects-to: Reindirizza dopo la disconnessione
|
||||
admin.options.system.admin-panel.logout-redirects-to.home: Pagina iniziale
|
||||
admin.options.system.admin-panel.logout-redirects-to.login: Accedi
|
||||
admin.options.system.admin-panel.session-timeout: Durata sessione (min)
|
||||
admin.options.system.backup: Backup
|
||||
admin.options.system.backup.backup-files-to-keep: Backup da tenere sul server
|
||||
admin.options.system.cache: Cache
|
||||
admin.options.system.cache.disabled: Disabilitata
|
||||
admin.options.system.cache.enabled: Abilitata
|
||||
admin.options.system.cache.time: Tempo cache (sec)
|
||||
admin.options.system.date-and-time: Data e ora
|
||||
admin.options.system.date-and-time.date-format: Formato data
|
||||
admin.options.system.date-and-time.first-weekday: Primo giorno della settimana
|
||||
admin.options.system.date-and-time.first-weekday.monday: Lunedì
|
||||
admin.options.system.date-and-time.first-weekday.sunday: Domenica
|
||||
admin.options.system.date-and-time.hour-format: Formato ora
|
||||
admin.options.system.date-and-time.timezone: Fuso orario
|
||||
admin.options.system.files: File
|
||||
admin.options.system.files.allowed-extensions: Estensioni consentite
|
||||
admin.options.system.images: Immagini
|
||||
admin.options.system.images.jpeg-quality: Qualità JPEG
|
||||
admin.options.system.images.jpeg-save-progressive: Salva le immagini JPEG come progressive
|
||||
admin.options.system.images.jpeg-save-progressive.disabled: Disabilitato
|
||||
admin.options.system.images.jpeg-save-progressive.enabled: Abilitato
|
||||
admin.options.system.images.png-compression-level: Livello di compressione PNG
|
||||
admin.options.system.images.process-uploads: Elabora (ottimizza) le immagini caricate
|
||||
admin.options.system.images.process-uploads.disabled: Disabilitato
|
||||
admin.options.system.images.process-uploads.enabled: Abilitato
|
||||
admin.options.system.images.webp-quality: Qualità WebP
|
||||
admin.options.system.languages: Lingue
|
||||
admin.options.system.languages.available-languages: Lingue disponibili
|
||||
admin.options.system.languages.available-languages.no-languages: Nessuna lingua
|
||||
admin.options.system.languages.preferred-language: Usa lingua preferita dal browser
|
||||
admin.options.system.languages.preferred-language.disabled: Disabilitato
|
||||
admin.options.system.languages.preferred-language.enabled: Abilitato
|
||||
admin.options.updated: Opzioni aggiornate
|
||||
admin.options.updates: Aggiornamenti
|
||||
admin.pages.attributes: Attributi
|
||||
admin.pages.change-slug: Modifica indirizzo
|
||||
admin.pages.change-slug.generate: Genera dal titolo
|
||||
admin.pages.changes.continue: Continua senza salvare
|
||||
admin.pages.changes.detected: Modifiche rilevate
|
||||
admin.pages.changes.detected.prompt: Alcune modifiche non sono state salvate. Si è sicuri di voler lasciare la pagina?
|
||||
admin.pages.content: Contenuto
|
||||
admin.pages.delete-file: Elimina file
|
||||
admin.pages.delete-file.prompt: Si è sicuri di eliminare il file? Questa azione non può essere annullata.
|
||||
admin.pages.delete-page: Elimina pagina
|
||||
admin.pages.delete-page.prompt: Si è sicuri di eliminare la pagina? Questa azione non può essere annullata.
|
||||
admin.pages.edit-page: Modifica pagina %s
|
||||
admin.pages.editor.bold: Grassetto
|
||||
admin.pages.editor.bullet-list: Elenco puntato
|
||||
admin.pages.editor.image: Immagine
|
||||
admin.pages.editor.italic: Corsivo
|
||||
admin.pages.editor.link: Collegamento
|
||||
admin.pages.editor.numbered-list: Elenco numerato
|
||||
admin.pages.editor.quote: Citazione
|
||||
admin.pages.editor.redo: Ripeti
|
||||
admin.pages.editor.summary: Sommario
|
||||
admin.pages.editor.undo: Annulla
|
||||
admin.pages.files: File
|
||||
admin.pages.languages: Lingue
|
||||
admin.pages.languages.add-language: Aggiungi %s
|
||||
admin.pages.languages.edit-language: Modifica %s
|
||||
admin.pages.new-page: Nuova pagina
|
||||
admin.pages.new-page.parent: Pagina superiore
|
||||
admin.pages.new-page.site: Sito
|
||||
admin.pages.new-page.slug-suggestion: solo lettere, numeri e trattini
|
||||
admin.pages.new-page.slug: Indirizzo pagina
|
||||
admin.pages.new-page.template: Template
|
||||
admin.pages.new-page.title: Titolo
|
||||
admin.pages.options: Opzioni
|
||||
admin.pages.page: Pagina
|
||||
admin.pages.page.actions: Azioni
|
||||
admin.pages.page.cacheable: Abilita cache
|
||||
admin.pages.page.cannot-change-num: Impossibile cambiare il numero della pagina
|
||||
admin.pages.page.cannot-create: Impossibile creare la pagina
|
||||
admin.pages.page.cannot-create.already-exists: Impossibile creare la pagina, una pagina con lo stesso indirizzo esiste già
|
||||
admin.pages.page.cannot-create.invalid-parent: Impossibile creare la pagina, la pagina superiore specificata non è valida
|
||||
admin.pages.page.cannot-create.invalid-slug: Impossibile creare la pagina, l'indirizzo deve contenere solo lettere e numeri separati da trattini
|
||||
admin.pages.page.cannot-create.invalid-template: Impossibile creare la pagina, il template specificato non è valido
|
||||
admin.pages.page.cannot-create.var-missing: Impossibile creare la pagina, manca una variabile
|
||||
admin.pages.page.cannot-delete-file.file-not-found: Impossibile eliminare il file, file non trovato
|
||||
admin.pages.page.cannot-delete-file.page-not-found: Impossibile eliminare il file, pagina non trovata
|
||||
admin.pages.page.cannot-delete.invalid-language: Impossibile eliminare la pagina, lingua %s non valida
|
||||
admin.pages.page.cannot-delete.not-deletable: Impossibile eliminare la pagina, la pagina non è eliminabile
|
||||
admin.pages.page.cannot-delete.page-not-found: Impossibile eliminare la pagina, pagina non trovata
|
||||
admin.pages.page.cannot-edit.already-exists: Impossibile modificare la pagina, una pagina con lo stesso indirizzo esiste già
|
||||
admin.pages.page.cannot-edit.index-or-error-page-slug: Impossibile cambiare l'indirizzo della pagina iniziale o di errore
|
||||
admin.pages.page.cannot-edit.invalid-language: Impossibile modificare la pagina, lingua %s non valida
|
||||
admin.pages.page.cannot-edit.invalid-parent: Impossibile modificare la pagina, pagina superiore non valida
|
||||
admin.pages.page.cannot-edit.invalid-slug: Impossibile cambiare l'indirizzo, l'indirizzo deve contenere solo lettere e numeri separati da trattini
|
||||
admin.pages.page.cannot-edit.invalid-template: Impossibile modificare la pagina, template non valido
|
||||
admin.pages.page.cannot-edit.page-not-found: Impossibile modificare la pagina, pagina non trovata
|
||||
admin.pages.page.cannot-edit.var-missing: Impossibile modificare la pagina, manca una variabile
|
||||
admin.pages.page.cannot-move: Impossibile spostare la pagina
|
||||
admin.pages.page.cannot-upload-file.page-not-found: Impossibile caricare il file, pagina non trovata
|
||||
admin.pages.page.created: Pagina creata!
|
||||
admin.pages.page.deleted: Pagina eliminata
|
||||
admin.pages.page.edited: Pagina modificata!
|
||||
admin.pages.page.file-deleted: File eliminato
|
||||
admin.pages.page.image: Immagine
|
||||
admin.pages.page.last-modified: Ultime modifiche
|
||||
admin.pages.page.moved: Pagina spostata!
|
||||
admin.pages.page.no-date: Nessuna data
|
||||
admin.pages.page.no-image: Nessuna immagine
|
||||
admin.pages.page.no-tags: Nessun tag
|
||||
admin.pages.page.not-found: Pagina non trovata
|
||||
admin.pages.page.posts-per-page: Post per pagina
|
||||
admin.pages.page.publish-date: Data di pubblicazione
|
||||
admin.pages.page.status: Stato
|
||||
admin.pages.page.tags: Tag
|
||||
admin.pages.page.title: Titolo
|
||||
admin.pages.page.unpublish-date: Data di rimozione
|
||||
admin.pages.page.visible: Visibile nel menu
|
||||
admin.pages.pages: Pagine
|
||||
admin.pages.pages.collapse-all: Riduci tutte
|
||||
admin.pages.pages.expand-all: Espandi tutte
|
||||
admin.pages.pages.reorder: Riordina
|
||||
admin.pages.pages.search: Cerca pagine...
|
||||
admin.pages.parent: Pagina superiore
|
||||
admin.pages.preview-file: Anteprima
|
||||
admin.pages.preview: Anteprima
|
||||
admin.pages.save: Salva
|
||||
admin.pages.status.not-published: Non pubblicato
|
||||
admin.pages.status.not-routable: Non raggiungibile
|
||||
admin.pages.status.published: Pubblicato
|
||||
admin.pages.status.routable: Raggiungibile
|
||||
admin.pages.template: Template
|
||||
admin.pages.toggle-children: Mostra/nascondi sottopagine
|
||||
admin.panel: Pannello di Amministrazione
|
||||
admin.register.create-user: Formwork Admin è installato ma non è stato trovato alcun utente. Registrane uno ora.
|
||||
admin.register.register: Registra nuovo utente
|
||||
admin.request.error.post-max-size: La richiesta HTTP con metodo POST supera la dimensione massima consentita
|
||||
admin.updates.available-for-install: è disponibile per l'installazione
|
||||
admin.updates.check: Cerca aggiornamenti
|
||||
admin.updates.install-prompt: Installare l'aggiornamento?
|
||||
admin.updates.install: Installa
|
||||
admin.updates.installed: Aggiornamento installato!
|
||||
admin.updates.latest-version-available: è l'ultima versione disponibile
|
||||
admin.updates.status.cannot-check: Impossibile cercare aggiornamenti. Riprova più tardi.
|
||||
admin.updates.status.cannot-install: Impossibile installare l'aggiornamento
|
||||
admin.updates.status.cannot-make-backup: Impossibile eseguire il backup prima di aggiornare
|
||||
admin.updates.status.checking: Cerco aggiornamenti...
|
||||
admin.updates.status.found: Aggiornamento disponibile
|
||||
admin.updates.status.installing: Installo aggiornamento...
|
||||
admin.updates.status.up-to-date: Aggiornato!
|
||||
admin.uploader.error: Impossibile caricare il file. %s.
|
||||
admin.uploader.error.already-exists: Un file con lo stesso nome esiste già
|
||||
admin.uploader.error.cannot-move-to-destination: Impossibile spostare il file caricato alla destinazione
|
||||
admin.uploader.error.cannot-write: Impossibile salvare il file sul disco
|
||||
admin.uploader.error.destination-too-long: Il percorso di destinazione è troppo lungo
|
||||
admin.uploader.error.file-name-too-long: Il nome del file è troppo lungo
|
||||
admin.uploader.error.file-name: Nome del file non valido
|
||||
admin.uploader.error.hidden-files: Impossibile caricare i file che iniziano con '.'
|
||||
admin.uploader.error.mime-type: Il tipo di file non è consentito
|
||||
admin.uploader.error.no-file: Nessun file caricato
|
||||
admin.uploader.error.no-temp: Cartella temporanea mancante
|
||||
admin.uploader.error.partial: Il file è stato caricato solo parzialmente
|
||||
admin.uploader.error.php-extension: Il caricamento è stato interrotto da un’estensione
|
||||
admin.uploader.error.size: Il file caricato supera la dimensione massima consentita
|
||||
admin.uploader.uploaded: File caricato
|
||||
admin.user.actions: Azioni
|
||||
admin.user.avatar: Immagine
|
||||
admin.user.avatar.uploaded: Immagine caricata
|
||||
admin.user.color-scheme: Combinazione di colori
|
||||
admin.user.color-scheme.auto: Automatica
|
||||
admin.user.color-scheme.dark: Scura
|
||||
admin.user.color-scheme.light: Chiara
|
||||
admin.user.email: E-mail
|
||||
admin.user.fullname: Nome completo
|
||||
admin.user.language: Lingua
|
||||
admin.user.last-access: Ultimo accesso
|
||||
admin.user.password: Password
|
||||
admin.user.password.type-new-password: Inserisci una nuova password per cambiarla...
|
||||
admin.user.role: Ruolo
|
||||
admin.user.role.admin: Amministratore
|
||||
admin.user.role.user: Utente
|
||||
admin.user.username: Nome utente
|
||||
admin.users.delete-user: Elimina utente
|
||||
admin.users.delete-user.prompt: Si è sicuri di eliminare l’utente? Questa azione non può essere annullata.
|
||||
admin.users.new-user: Nuovo utente
|
||||
admin.users.new-user.password-suggestion: almeno 8 caratteri
|
||||
admin.users.new-user.username-suggestion: da 3 a 20 lettere, numeri, - e _
|
||||
admin.users.options: Opzioni
|
||||
admin.users.user-profile: Profilo utente %s
|
||||
admin.users.user: Utente
|
||||
admin.users.user.cannot-change-password: Impossibile cambiare la password di un altro utente. L’azione non è consentita.
|
||||
admin.users.user.cannot-change-role: Impossible cambare il ruolo di %s. L’azione non è consentita.
|
||||
admin.users.user.cannot-create.already-exists: Impossibile creare l’utente, un utente con lo stesso nome esiste già
|
||||
admin.users.user.cannot-create.var-missing: Impossibile creare l’utente, manca una variabile
|
||||
admin.users.user.cannot-delete: Impossibile eliminare l’utente. Devi essere un amministratore e l’utente non deve essere connesso.
|
||||
admin.users.user.cannot-edit: Impossibile modificare l’utente %s. L’azione non è consentita.
|
||||
admin.users.user.created: Utente creato
|
||||
admin.users.user.deleted: Utente eliminato
|
||||
admin.users.user.edited: Dati utente aggiornati
|
||||
admin.users.user.not-found: Utente non trovato
|
||||
admin.users.users: Utenti
|
||||
admin.view-site: Visualizza sito
|
@ -1,261 +0,0 @@
|
||||
admin.backup.backup: Cópia de Segurança
|
||||
admin.backup.error.cannot-download: Não é possível efectuar download da cópia de segurança. %s.
|
||||
admin.backup.error.cannot-download.invalid-filename: Ficheiro de backup inválido
|
||||
admin.backup.error.cannot-make: Não é possível fazer cópia de segurança. %s.
|
||||
admin.backup.ready: Cópia de segurança pronta. A iniciar o download...
|
||||
admin.cache.clear: Limpar cache
|
||||
admin.cache.cleared: Cache limpa
|
||||
admin.dashboard.dashboard: Painel
|
||||
admin.dashboard.last-modified-pages: Últimas páginas editadas
|
||||
admin.dashboard.quick-actions: Acções Rápidas
|
||||
admin.dashboard.statistics: Estatisticas
|
||||
admin.dashboard.statistics.unique-visitors: Visitantes Únicos
|
||||
admin.dashboard.statistics.visits: Visitas
|
||||
admin.dashboard.welcome: Bem-Vindo
|
||||
admin.errors.action.report-to-github: Denúncie um problema no GitHub
|
||||
admin.errors.action.return-to-dashboard: Voltar ao Painel
|
||||
admin.errors.error.forbidden.description: Não tem permissões para aceder a esta página.
|
||||
admin.errors.error.forbidden.heading: Oops, permissão necessária!
|
||||
admin.errors.error.forbidden.status: Proibido
|
||||
admin.errors.error.internal-server-error.description: Formwork Admin encontrou um erro ao atender sua solicitação. Verifique a configuração do Formwork ou o log do servidor para erros.
|
||||
admin.errors.error.internal-server-error.heading: Ops, algo errado aconteceu!
|
||||
admin.errors.error.internal-server-error.status: Erro Interno do Servidor
|
||||
admin.errors.error.not-found.description: A página não existe ou a solicitação não é válida.
|
||||
admin.errors.error.not-found.heading: Ops, página não encontrada!
|
||||
admin.errors.error.not-found.status: Não Encontrado
|
||||
admin.login.attempt.failed: Falha ao tentar efetuar login! Tente novamente.
|
||||
admin.login.attempt.too-many: Demasiadas tentativas de login. Tente novamente em %d minutos.
|
||||
admin.login.logged-out: Você foi desconectado
|
||||
admin.login.login: Login
|
||||
admin.login.logout: Logout
|
||||
admin.login.password: Password
|
||||
admin.login.suspicious-request-detected: Uma solicitação suspeita foi detectada e, por motivos de segurança, você foi desconectado. Por favor faça login novamente.
|
||||
admin.login.username: Nome do Utilizador
|
||||
admin.manage: Administrar
|
||||
admin.modal.action.cancel: Cancelar
|
||||
admin.modal.action.continue: Continuar
|
||||
admin.modal.action.delete: Remover
|
||||
admin.modal.action.save: Guardar
|
||||
admin.modal.action.upload-file: Enviar um ficheiro
|
||||
admin.modal.images.no-images: Não há imagens aqui
|
||||
admin.modal.images.no-images.upload: Por favor carregue algumas imagens
|
||||
admin.modal.images.title: Escolha uma Imagem
|
||||
admin.options.info: Informações
|
||||
admin.options.options: Opções
|
||||
admin.options.site: Site
|
||||
admin.options.site.advanced: Opções Avançadas
|
||||
admin.options.site.advanced.aliases: Aliases
|
||||
admin.options.site.advanced.aliases.alias: Alias
|
||||
admin.options.site.advanced.aliases.route: Rota
|
||||
admin.options.site.advanced.metadata: Metadados HTML
|
||||
admin.options.site.advanced.metadata.content: Conteúdo
|
||||
admin.options.site.advanced.metadata.name: Nome
|
||||
admin.options.site.info: Informações
|
||||
admin.options.site.info.author: Autor
|
||||
admin.options.site.info.description: Descrição
|
||||
admin.options.site.info.language: Idiomas
|
||||
admin.options.site.info.title: Título
|
||||
admin.options.system: Sistema
|
||||
admin.options.system.admin-panel: Painel de Administração
|
||||
admin.options.system.admin-panel.default-color-scheme: Esquema de cores padrão
|
||||
admin.options.system.admin-panel.default-color-scheme.dark: Escuro
|
||||
admin.options.system.admin-panel.default-color-scheme.light: Claro
|
||||
admin.options.system.admin-panel.default-language: Idioma Padrão
|
||||
admin.options.system.admin-panel.logout-redirects-to: Logout redireciona para
|
||||
admin.options.system.admin-panel.logout-redirects-to.home: Principal
|
||||
admin.options.system.admin-panel.logout-redirects-to.login: Login
|
||||
admin.options.system.admin-panel.session-timeout: Tempo limite da sessão (min)
|
||||
admin.options.system.backup: Cópia de Segurança
|
||||
admin.options.system.backup.backup-files-to-keep: Backups para manter no servidor
|
||||
admin.options.system.cache: Cache
|
||||
admin.options.system.cache.disabled: Desactivado
|
||||
admin.options.system.cache.enabled: Activado
|
||||
admin.options.system.cache.time: Tempo de Cache (s)
|
||||
admin.options.system.date-and-time: Data e Hora
|
||||
admin.options.system.date-and-time.date-format: Formato de Data
|
||||
admin.options.system.date-and-time.first-weekday: Primeiro Dia da Semana
|
||||
admin.options.system.date-and-time.first-weekday.monday: Segunda
|
||||
admin.options.system.date-and-time.first-weekday.sunday: Domingo
|
||||
admin.options.system.date-and-time.hour-format: Formato de Hora
|
||||
admin.options.system.date-and-time.timezone: Fuso Horário
|
||||
admin.options.system.files: Ficheiros
|
||||
admin.options.system.files.allowed-extensions: Extensões Permitidas
|
||||
admin.options.system.images: Imagens
|
||||
admin.options.system.images.jpeg-quality: Qualidade JPEG
|
||||
admin.options.system.images.jpeg-save-progressive: Guardar imagens JPEG como progressivas
|
||||
admin.options.system.images.jpeg-save-progressive.disabled: Desactivado
|
||||
admin.options.system.images.jpeg-save-progressive.enabled: Activado
|
||||
admin.options.system.images.png-compression-level: Nível de compressão PNG
|
||||
admin.options.system.images.process-uploads: Processar (optimizar) imagens enviadas
|
||||
admin.options.system.images.process-uploads.disabled: Desactivado
|
||||
admin.options.system.images.process-uploads.enabled: Activado
|
||||
admin.options.system.images.webp-quality: Qualidade WebP
|
||||
admin.options.system.languages: Idiomas
|
||||
admin.options.system.languages.available-languages: Idiomas Disponiveis
|
||||
admin.options.system.languages.available-languages.no-languages: Sem Idiomas
|
||||
admin.options.system.languages.preferred-language: Use o idioma preferido do browser
|
||||
admin.options.system.languages.preferred-language.disabled: Desactivado
|
||||
admin.options.system.languages.preferred-language.enabled: Activado
|
||||
admin.options.updated: Opções Actualizadas
|
||||
admin.options.updates: Actualizações
|
||||
admin.pages.attributes: Atributos
|
||||
admin.pages.change-slug: Editar Slug
|
||||
admin.pages.change-slug.generate: Criar a partir do Título
|
||||
admin.pages.changes.continue: Continuar sem Guardar
|
||||
admin.pages.changes.detected: Alterações Encontradas
|
||||
admin.pages.changes.detected.prompt: Tem algumas alterações que não foram guardadas. Tem a certeza que deseja sair desta página?
|
||||
admin.pages.content: Conteúdo
|
||||
admin.pages.delete-file: Remover Ficheiro
|
||||
admin.pages.delete-file.prompt: Tem certeza de que deseja remover este ficheiro? Esta acção não pode ser desfeita.
|
||||
admin.pages.delete-page: Remover Página
|
||||
admin.pages.delete-page.prompt: Tem certeza que deseja remover esta página? Esta ação não pode ser desfeita.
|
||||
admin.pages.edit-page: Editar Página %s
|
||||
admin.pages.editor.bold: Negrito
|
||||
admin.pages.editor.bullet-list: Lista de marcadores
|
||||
admin.pages.editor.image: Imagem
|
||||
admin.pages.editor.italic: Itálico
|
||||
admin.pages.editor.link: Ligação
|
||||
admin.pages.editor.numbered-list: Lista ordenada
|
||||
admin.pages.editor.quote: Citar
|
||||
admin.pages.editor.redo: Refazer
|
||||
admin.pages.editor.summary: Sumário
|
||||
admin.pages.editor.undo: Desfazer
|
||||
admin.pages.files: Ficheiros
|
||||
admin.pages.files.upload-label: <strong>Clique</strong> aqui para escolher um ficheiro para enviar ou <strong>arrastar</strong> para aqui.
|
||||
admin.pages.languages: Idiomas
|
||||
admin.pages.languages.add-language: Criar %s
|
||||
admin.pages.languages.edit-language: Editar %s
|
||||
admin.pages.new-page: Criar Página
|
||||
admin.pages.new-page.parent: Página Parente
|
||||
admin.pages.new-page.site: Site
|
||||
admin.pages.new-page.slug-suggestion: letras, números e hifens apenas
|
||||
admin.pages.new-page.slug: Slug da Página
|
||||
admin.pages.new-page.template: Template
|
||||
admin.pages.new-page.title: Título
|
||||
admin.pages.options: Opções
|
||||
admin.pages.page.actions: Acções
|
||||
admin.pages.page.cacheable: Cache
|
||||
admin.pages.page.cannot-change-num: Não é possível alterar o número da página
|
||||
admin.pages.page.cannot-create: Não é possível criar página
|
||||
admin.pages.page.cannot-create.already-exists: Não é possível criar a página, já existe uma página com o mesmo uri
|
||||
admin.pages.page.cannot-create.invalid-parent: Não é possível criar página, página parente inválida
|
||||
admin.pages.page.cannot-create.invalid-slug: Não é possível criar a página, o slug da página deve conter apenas letras e números separados por hifens
|
||||
admin.pages.page.cannot-create.invalid-template: Não é possível criar página, template inválido
|
||||
admin.pages.page.cannot-create.var-missing: Não é possível criar página, falta uma variável
|
||||
admin.pages.page.cannot-delete-file.file-not-found: Não é possível excluir o ficheiro, ficheiro não encontrado
|
||||
admin.pages.page.cannot-delete-file.page-not-found: Não é possível excluir a página, página não encontrado
|
||||
admin.pages.page.cannot-delete.invalid-language: 'Não é possível excluir página, idioma inválido: %s'
|
||||
admin.pages.page.cannot-delete.not-deletable: Não é possível excluir a página, a página não pode ser excluída
|
||||
admin.pages.page.cannot-delete.page-not-found: Não é possível excluir página, página não encontrada
|
||||
admin.pages.page.cannot-edit.already-exists: Não é possível editar a página, já existe uma página com o mesmo uri
|
||||
admin.pages.page.cannot-edit.index-or-error-page-slug: Não é possível editar slug de página de índice e páginas de erro
|
||||
admin.pages.page.cannot-edit.invalid-language: 'Não é possível editar a página, idioma inválido: %s'
|
||||
admin.pages.page.cannot-edit.invalid-parent: Não é possível editar a página, página parente inválida
|
||||
admin.pages.page.cannot-edit.invalid-slug: Não é possível editar o slug da página, deve conter apenas letras e números separados por hifens.
|
||||
admin.pages.page.cannot-edit.invalid-template: Não é possível editar a página, template inválido
|
||||
admin.pages.page.cannot-edit.page-not-found: Não é possível editar a página, página não encontrada
|
||||
admin.pages.page.cannot-edit.var-missing: Não é possível editar a página, falta uma variável
|
||||
admin.pages.page.cannot-move: Não é possível mover a página
|
||||
admin.pages.page.cannot-upload-file.page-not-found: Não é possível efectuar envio do ficheiro, página não encontrada
|
||||
admin.pages.page.created: Página criada!
|
||||
admin.pages.page.deleted: Página removida
|
||||
admin.pages.page.edited: Página editada
|
||||
admin.pages.page.file-deleted: Ficheiro removido
|
||||
admin.pages.page.image: Imagem
|
||||
admin.pages.page.last-modified: Última Modificação
|
||||
admin.pages.page.moved: Página Movida!
|
||||
admin.pages.page.no-date: Sem Data
|
||||
admin.pages.page.no-image: Sem Imagem
|
||||
admin.pages.page.no-tags: Sem Tags
|
||||
admin.pages.page.not-found: Página não encontrada
|
||||
admin.pages.page.posts-per-page: Items por página
|
||||
admin.pages.page.publish-date: Data de Publicação
|
||||
admin.pages.page.status: Estado
|
||||
admin.pages.page.tags: Tags
|
||||
admin.pages.page.title: Titulo
|
||||
admin.pages.page.unpublish-date: Data de Cancelamento da Publicação
|
||||
admin.pages.page.visible: Visivel no menu
|
||||
admin.pages.pages: Páginas
|
||||
admin.pages.pages.collapse-all: Recolher Todas
|
||||
admin.pages.pages.expand-all: Expandir Todas
|
||||
admin.pages.pages.reorder: Reordenar
|
||||
admin.pages.pages.search: Procurar Páginas...
|
||||
admin.pages.parent: Página Parente
|
||||
admin.pages.preview-file: Preview
|
||||
admin.pages.preview: Preview
|
||||
admin.pages.save: Guardar
|
||||
admin.pages.status.not-published: Não Publicado
|
||||
admin.pages.status.not-routable: Não Roteável
|
||||
admin.pages.status.published: Publicado
|
||||
admin.pages.status.routable: Roteável
|
||||
admin.pages.template: Template
|
||||
admin.pages.toggle-children: Expandir Páginas
|
||||
admin.panel: Painel de Administração
|
||||
admin.register.create-user: O Formwork Admin está instalado, mas nenhum utilizador foi encontrado. Por favor, registre um agora.
|
||||
admin.register.register: Registrar Novo Utilizador
|
||||
admin.request.error.post-max-size: O pedido HTTP POST excede o tamanho máximo permitido
|
||||
admin.updates.available-for-install: está disponível para instalação
|
||||
admin.updates.check: Verificar actualizações
|
||||
admin.updates.install-prompt: Gostaria instalar a actualização?
|
||||
admin.updates.install: Instalar
|
||||
admin.updates.installed: Actualização instalada!
|
||||
admin.updates.latest-version-available: é a última versão disponível
|
||||
admin.updates.status.cannot-check: Não é possível verificar se há actualizações. Tente mais tarde.
|
||||
admin.updates.status.cannot-install: Não é possível instalar actualização
|
||||
admin.updates.status.cannot-make-backup: Não é possível efectuar cópia de segurança antes de actualizar
|
||||
admin.updates.status.checking: Verificando actualizações...
|
||||
admin.updates.status.found: Actualizações encontradas
|
||||
admin.updates.status.installing: Instalando actualizações...
|
||||
admin.updates.status.up-to-date: Actualizado!
|
||||
admin.uploader.error: Não é possível fazer upload do ficheiro. %s.
|
||||
admin.uploader.error.already-exists: Já existe um ficheiro com o mesmo nome
|
||||
admin.uploader.error.cannot-move-to-destination: Falha ao mover o ficheiro enviado para o destino
|
||||
admin.uploader.error.cannot-write: Falha ao gravar ficheiro no disco
|
||||
admin.uploader.error.destination-too-long: Caminho de destino demasiado longo
|
||||
admin.uploader.error.file-name-too-long: Nome do ficheiro demasiado longo
|
||||
admin.uploader.error.file-name: Nome do ficheiro inválido
|
||||
admin.uploader.error.hidden-files: Não é possível efectuar envio de ficheros ocultos que começam com um ponto
|
||||
admin.uploader.error.mime-type: Tipo de ficheiro inválido
|
||||
admin.uploader.error.no-file: Nenhum ficheiro foi enviado
|
||||
admin.uploader.error.no-temp: Pasta temporária inexistente
|
||||
admin.uploader.error.partial: O ficheiro foi enviado apenas parcialmente
|
||||
admin.uploader.error.php-extension: Envio de ficheiro interrompido por extensão
|
||||
admin.uploader.error.size: O ficheiro enviado excede o tamanho máximo permitido.
|
||||
admin.uploader.uploaded: Ficheiro enviado
|
||||
admin.user.actions: Acções
|
||||
admin.user.avatar: Avatar
|
||||
admin.user.avatar.uploaded: Avatar enviado
|
||||
admin.user.color-scheme: Esquema de cores
|
||||
admin.user.color-scheme.auto: Auto
|
||||
admin.user.color-scheme.dark: Escuro
|
||||
admin.user.color-scheme.light: Claro
|
||||
admin.user.email: E'mail
|
||||
admin.user.fullname: Nome Completo
|
||||
admin.user.language: Idioma
|
||||
admin.user.last-access: Último acesso
|
||||
admin.user.password: Password
|
||||
admin.user.password.type-new-password: Insira nova password para alterar...
|
||||
admin.user.role: Cargo
|
||||
admin.user.role.admin: Administrador
|
||||
admin.user.role.user: Utilizador
|
||||
admin.user.username: Nome do utilizador
|
||||
admin.users.delete-user: Apagar Utilizador
|
||||
admin.users.delete-user.prompt: Tem a certeza de que deseja excluir este utilizador? Esta acção não pode ser revertida.
|
||||
admin.users.new-user: Novo Utilizador
|
||||
admin.users.new-user.password-suggestion: pelo menos 8 caracteres
|
||||
admin.users.new-user.username-suggestion: entre 3 a 20 letras, números e hifens.
|
||||
admin.users.options: Opções
|
||||
admin.users.user-profile: 'Perfil de Utilizador %s'
|
||||
admin.users.user: Utilizador
|
||||
admin.users.user.cannot-change-password: Não é possível alterar a senha de outro utilizador. A acção não é permitida.
|
||||
admin.users.user.cannot-change-role: Não é possível alterar o cargo de %s. A acção não é permitida.
|
||||
admin.users.user.cannot-create.already-exists: Não é possível criar utilizador, já existe um utilizador com o mesmo nome
|
||||
admin.users.user.cannot-create.var-missing: Não é possível criar o utilizador, falta uma variável
|
||||
admin.users.user.cannot-delete: Não é possível remover o utilizador. Você deve ser um administrador e o utilizador não deve estar logado.
|
||||
admin.users.user.cannot-edit: Não é possível editar o utilizador %s. A acção não é permitida.
|
||||
admin.users.user.created: Utilizador criado.
|
||||
admin.users.user.deleted: Utilizador removido.
|
||||
admin.users.user.edited: Informação do utilizador actualizada
|
||||
admin.users.user.not-found: Utilizador não encontrado
|
||||
admin.users.users: Utilizadores
|
||||
admin.view-site: Ver Site
|
@ -1,240 +0,0 @@
|
||||
admin.backup.backup: Резерв
|
||||
admin.backup.error.cannot-download: Невозможно загрузить резервную копию. %s.
|
||||
admin.backup.error.cannot-download.invalid-filename: Недопустимый файл резервной копии
|
||||
admin.backup.error.cannot-make: Невозможно сделать резервную копию. %s.
|
||||
admin.backup.ready: Резервное копирование готовы. Начинается загрузка ...
|
||||
admin.cache.clear: Очистить кэш
|
||||
admin.cache.cleared: Кэш очищается
|
||||
admin.dashboard.dashboard: Приборная панель
|
||||
admin.dashboard.last-modified-pages: В последний раз редактировали Страницы
|
||||
admin.dashboard.quick-actions: Быстрые действия
|
||||
admin.dashboard.statistics: Статистика
|
||||
admin.dashboard.statistics.unique-visitors: Уникальные посетители
|
||||
admin.dashboard.statistics.visits: Просмотров
|
||||
admin.dashboard.welcome: Добро пожаловать
|
||||
admin.errors.action.report-to-github: Сообщить о проблеме на GitHub
|
||||
admin.errors.action.return-to-dashboard: Вернуться к панели управления
|
||||
admin.errors.error.forbidden.description: У вас нет разрешения на доступ к этой странице.
|
||||
admin.errors.error.forbidden.heading: К сожалению, разрешение не требуется!
|
||||
admin.errors.error.forbidden.status: Запрещено
|
||||
admin.errors.error.internal-server-error.description: Formwork Администратор обнаружил ошибку при обслуживании вашего запроса. Пожалуйста, проверьте конфигурацию опалубки или журнал сервера на наличие ошибок.
|
||||
admin.errors.error.internal-server-error.heading: Упс! Что-то пошло не так!
|
||||
admin.errors.error.internal-server-error.status: Внутренняя Ошибка Сервера
|
||||
admin.errors.error.not-found.description: Страница не существует или запрос не является действительным.
|
||||
admin.errors.error.not-found.heading: К сожалению, страница не найдена!
|
||||
admin.errors.error.not-found.status: Не обнаружена
|
||||
admin.login.attempt.failed: Войти попытка не удалась! Попробуйте еще раз.
|
||||
admin.login.attempt.too-many: Слишком много попыток входа в систему. Пожалуйста, попробуйте еще раз% D минут.
|
||||
admin.login.logged-out: Вы вышли из системы
|
||||
admin.login.login: Авторизация
|
||||
admin.login.logout: Выйти
|
||||
admin.login.password: Пароль
|
||||
admin.login.suspicious-request-detected: Подозрительный запрос был обнаружен, и по соображениям безопасности вы вышли из системы. Пожалуйста, войдите снова.
|
||||
admin.login.username: Имя пользователя
|
||||
admin.manage: Меню
|
||||
admin.modal.action.cancel: Отмена
|
||||
admin.modal.action.continue: Продолжить
|
||||
admin.modal.action.delete: Удалить
|
||||
admin.modal.action.save: Сохранить
|
||||
admin.modal.action.upload-file: Загрузить файл
|
||||
admin.modal.images.no-images: Там нет изображений здесь
|
||||
admin.modal.images.no-images.upload: Пожалуйста, загрузите некоторые изображения
|
||||
admin.modal.images.title: Выберите изображение
|
||||
admin.options.info: Информация
|
||||
admin.options.options: Параметры
|
||||
admin.options.site: Сайт
|
||||
admin.options.site.advanced: Расширенные настройки
|
||||
admin.options.site.advanced.aliases: Псевдонимы
|
||||
admin.options.site.advanced.aliases.alias: Псевдоним
|
||||
admin.options.site.advanced.aliases.route: Маршрут
|
||||
admin.options.site.advanced.metadata: Метаданные HTML
|
||||
admin.options.site.advanced.metadata.content: Содержание
|
||||
admin.options.site.advanced.metadata.name: Имя
|
||||
admin.options.site.info: Информация
|
||||
admin.options.site.info.author: Автор
|
||||
admin.options.site.info.description: Описание
|
||||
admin.options.site.info.language: Язык
|
||||
admin.options.site.info.title: Заглавие
|
||||
admin.options.system: Система
|
||||
admin.options.system.admin-panel: Панель администратора
|
||||
admin.options.system.admin-panel.default-language: Язык по умолчанию
|
||||
admin.options.system.admin-panel.logout-redirects-to: Выход Перенаправление
|
||||
admin.options.system.admin-panel.logout-redirects-to.home: Главная
|
||||
admin.options.system.admin-panel.logout-redirects-to.login: Логин
|
||||
admin.options.system.admin-panel.session-timeout: Тайм-аут сеанса (мин)
|
||||
admin.options.system.backup: Резервный
|
||||
admin.options.system.backup.backup-files-to-keep: Резервные копии, чтобы сохранить на сервере
|
||||
admin.options.system.cache: Кэш
|
||||
admin.options.system.cache.disabled: Выключить
|
||||
admin.options.system.cache.enabled: Включить
|
||||
admin.options.system.cache.time: Кэш Время (сек)
|
||||
admin.options.system.date-and-time: Дата и время
|
||||
admin.options.system.date-and-time.date-format: Формат даты
|
||||
admin.options.system.date-and-time.first-weekday: Первый день недели
|
||||
admin.options.system.date-and-time.first-weekday.monday: Понедельник
|
||||
admin.options.system.date-and-time.first-weekday.sunday: Воскресенье
|
||||
admin.options.system.date-and-time.hour-format: Часовой формат
|
||||
admin.options.system.date-and-time.timezone: Часовой пояс
|
||||
admin.options.system.files: Файлы
|
||||
admin.options.system.files.allowed-extensions: Допустимые расширения
|
||||
admin.options.system.images: Картинки
|
||||
admin.options.system.images.jpeg-quality: JPEG Качество
|
||||
admin.options.system.images.png-compression-level: PNG Уровень сжатия
|
||||
admin.options.system.languages: Языки
|
||||
admin.options.system.languages.available-languages: Доступные Языки
|
||||
admin.options.system.languages.available-languages.no-languages: Нет Языков
|
||||
admin.options.system.languages.preferred-language: Использовать предпочитаемый язык браузера
|
||||
admin.options.system.languages.preferred-language.disabled: Выключить
|
||||
admin.options.system.languages.preferred-language.enabled: Включить
|
||||
admin.options.updated: Опции обновляются
|
||||
admin.options.updates: Обновления
|
||||
admin.pages.attributes: Атрибуты
|
||||
admin.pages.change-slug: Редактировать Slug
|
||||
admin.pages.change-slug.generate: Сформировать из названия
|
||||
admin.pages.changes.continue: Продолжить без сохранения
|
||||
admin.pages.changes.detected: Изменения Обнаружены
|
||||
admin.pages.changes.detected.prompt: У вас есть какие-то изменения, которые не были сохранены. Вы уверены, что хотите покинуть эту страницу?
|
||||
admin.pages.content: Содержание
|
||||
admin.pages.delete-file: Удалить файл
|
||||
admin.pages.delete-file.prompt: Вы уверены, что хотите удалить этот файл? Это действие не может быть отменено.
|
||||
admin.pages.delete-page: Удалить страницу
|
||||
admin.pages.delete-page.prompt: Вы уверены, что хотите удалить эту страницу? Это действие не может быть отменено.
|
||||
admin.pages.edit-page: Отредактировать страницу %s
|
||||
admin.pages.editor.bold: Жирный
|
||||
admin.pages.editor.bullet-list: Маркированный список
|
||||
admin.pages.editor.image: Изображение
|
||||
admin.pages.editor.italic: Курсивный
|
||||
admin.pages.editor.link: Ссылка
|
||||
admin.pages.editor.numbered-list: Нумерованный список
|
||||
admin.pages.editor.quote: Кавычки
|
||||
admin.pages.editor.redo: Выбор
|
||||
admin.pages.editor.summary: Краткий
|
||||
admin.pages.editor.undo: Открыть
|
||||
admin.pages.files: Файлы
|
||||
admin.pages.languages: Языки
|
||||
admin.pages.languages.add-language: Добавлять %s
|
||||
admin.pages.languages.edit-language: Редактировать %s
|
||||
admin.pages.new-page: Новая страница
|
||||
admin.pages.new-page.parent: Родитель страницы
|
||||
admin.pages.new-page.site: Сайт
|
||||
admin.pages.new-page.slug-suggestion: буквы, цифры и дефис только
|
||||
admin.pages.new-page.slug: Страница Slug
|
||||
admin.pages.new-page.template: Шаблон
|
||||
admin.pages.new-page.title: Заглавие
|
||||
admin.pages.options: Параметры
|
||||
admin.pages.page.actions: Действия
|
||||
admin.pages.page.cacheable: Кешируемый
|
||||
admin.pages.page.cannot-change-num: Невозможно изменить номер страницы
|
||||
admin.pages.page.cannot-create: Не удается создать страницу
|
||||
admin.pages.page.cannot-create.already-exists: Невозможно создать страницу, страницу с тем же URI уже существует
|
||||
admin.pages.page.cannot-create.invalid-parent: Не удается создать страницу, недействительны родительской страницы
|
||||
admin.pages.page.cannot-create.invalid-slug: Невозможно создать страницу, страницу пробкового должны содержать только буквы и цифры, разделенные тире
|
||||
admin.pages.page.cannot-create.invalid-template: Не удается создать страницу, недопустимый шаблон
|
||||
admin.pages.page.cannot-create.var-missing: Не удается создать страницу, отсутствует переменная
|
||||
admin.pages.page.cannot-delete-file.file-not-found: Не удается удалить файл, файл не найден
|
||||
admin.pages.page.cannot-delete-file.page-not-found: Не удается удалить файл, файл не найден
|
||||
admin.pages.page.cannot-delete.invalid-language: 'Невозможно удалить страницу, недопустимый язык: %s'
|
||||
admin.pages.page.cannot-delete.not-deletable: Невозможно удалить страницу, страница не файл удаляемая
|
||||
admin.pages.page.cannot-delete.page-not-found: Невозможно удалить страницу, страница не найдена
|
||||
admin.pages.page.cannot-edit.already-exists: Не могу редактировать страницу, страница с той же URI уже существует
|
||||
admin.pages.page.cannot-edit.index-or-error-page-slug: Не могу редактировать страницу слизняка индекса и ошибок страниц
|
||||
admin.pages.page.cannot-edit.invalid-language: 'Не могу редактировать страницы, недопустимый язык: %s'
|
||||
admin.pages.page.cannot-edit.invalid-parent: Не могу редактировать страницы, недопустимую родительскую страницу
|
||||
admin.pages.page.cannot-edit.invalid-slug: Не можете редактировать страницу слизняка, он должен содержать только буквы и цифры, разделенные тире
|
||||
admin.pages.page.cannot-edit.invalid-template: Не могу редактировать страницы, неверный шаблон
|
||||
admin.pages.page.cannot-edit.page-not-found: Не могу редактировать страницу, страница не найдена
|
||||
admin.pages.page.cannot-edit.var-missing: Не могу редактировать страницу, отсутствует переменный
|
||||
admin.pages.page.cannot-move: Невозможно переместить страницу
|
||||
admin.pages.page.cannot-upload-file.page-not-found: Невозможно загрузить файл, страница не найдена
|
||||
admin.pages.page.created: Страница сгенерирована!
|
||||
admin.pages.page.deleted: Страница удалена
|
||||
admin.pages.page.edited: Страница отредактирован
|
||||
admin.pages.page.file-deleted: Файл удален
|
||||
admin.pages.page.image: Изображение
|
||||
admin.pages.page.last-modified: Последнее изменение
|
||||
admin.pages.page.moved: Страница переехала!
|
||||
admin.pages.page.no-date: Без даты
|
||||
admin.pages.page.no-image: Нет изображения
|
||||
admin.pages.page.no-tags: Нет тегов
|
||||
admin.pages.page.not-found: Страница не найдена
|
||||
admin.pages.page.posts-per-page: Сообщения на странице
|
||||
admin.pages.page.publish-date: Дата публикации
|
||||
admin.pages.page.status: Статус
|
||||
admin.pages.page.tags: Теги
|
||||
admin.pages.page.title: Заглавие
|
||||
admin.pages.page.unpublish-date: Дата Отменить публикацию
|
||||
admin.pages.page.visible: Видимые в меню
|
||||
admin.pages.pages: Страницы
|
||||
admin.pages.pages.collapse-all: Свернуть все
|
||||
admin.pages.pages.expand-all: Расширить все
|
||||
admin.pages.pages.reorder: Изменение порядка
|
||||
admin.pages.pages.search: Поиск Страницы ...
|
||||
admin.pages.parent: Родитель страницы
|
||||
admin.pages.preview-file: Предварительный просмотр
|
||||
admin.pages.preview: Предварительный просмотр
|
||||
admin.pages.save: Сохранить
|
||||
admin.pages.status.not-published: Не Опубликовано
|
||||
admin.pages.status.not-routable: Не маршрутизируемый
|
||||
admin.pages.status.published: Опубликованный
|
||||
admin.pages.status.routable: Маршрутизируемый
|
||||
admin.pages.template: Шаблон
|
||||
admin.panel: Панель администрирования
|
||||
admin.register.create-user: Formwork Администратор установлен, но не было найдено ни одного пользователя. Пожалуйста зарегистрировать пользователя в настоящее время.
|
||||
admin.register.register: Регистрация нового пользователя
|
||||
admin.request.error.post-max-size: Запрос HTTP POST превышает максимально допустимый размер
|
||||
admin.updates.available-for-install: доступен для установки
|
||||
admin.updates.check: Проверка обновлений
|
||||
admin.updates.install-prompt: Вы хотите установить обновление?
|
||||
admin.updates.install: Устанавливать
|
||||
admin.updates.installed: Обновление установлено!
|
||||
admin.updates.latest-version-available: это последняя версия доступна
|
||||
admin.updates.status.cannot-install: Не удается установить обновление
|
||||
admin.updates.status.cannot-make-backup: Невозможно сделать резервную копию перед обновлением
|
||||
admin.updates.status.checking: Проверка обновлений...
|
||||
admin.updates.status.found: Обновления найдены
|
||||
admin.updates.status.installing: Установка обновлений ...
|
||||
admin.updates.status.up-to-date: До настоящего времени!
|
||||
admin.uploader.error: Невозможно загрузить файл. %s.
|
||||
admin.uploader.error.cannot-write: Не удалось записать файл на диск
|
||||
admin.uploader.error.file-name: Неверное имя файла
|
||||
admin.uploader.error.hidden-files: Невозможно загрузить скрытые файлы, начинающиеся с точки
|
||||
admin.uploader.error.mime-type: Тип файла не допускается
|
||||
admin.uploader.error.no-file: Файл не был загружен
|
||||
admin.uploader.error.no-temp: Отсутствующие временную папку
|
||||
admin.uploader.error.partial: Загруженный файл был загружен только частично
|
||||
admin.uploader.error.php-extension: Загрузка файла останавливали расширения
|
||||
admin.uploader.error.size: Загруженный файл превышает максимальный размер файла
|
||||
admin.uploader.uploaded: Файл загружен
|
||||
admin.user.actions: Действия
|
||||
admin.user.avatar: Аватар
|
||||
admin.user.avatar.uploaded: Аватар закачанный
|
||||
admin.user.email: Email
|
||||
admin.user.fullname: Полное имя
|
||||
admin.user.language: Язык
|
||||
admin.user.last-access: Последний доступ
|
||||
admin.user.password: Пароль
|
||||
admin.user.password.type-new-password: Введите новый пароль для изменения ...
|
||||
admin.user.role: Роль
|
||||
admin.user.role.admin: Администратор
|
||||
admin.user.role.user: Пользователь
|
||||
admin.user.username: Имя пользователя
|
||||
admin.users.delete-user: Удалить пользователя
|
||||
admin.users.delete-user.prompt: Вы уверены, что хотите удалить этого пользователя? Это действие не может быть отменено.
|
||||
admin.users.new-user: Новый пользователь
|
||||
admin.users.new-user.password-suggestion: не менее 8 символов
|
||||
admin.users.new-user.username-suggestion: между 3-20 букв, цифр и тире
|
||||
admin.users.options: Параметры
|
||||
admin.users.user-profile: '%s Профиль пользователя'
|
||||
admin.users.user: Пользователь
|
||||
admin.users.user.cannot-change-password: Невозможно изменить пароль другого пользователя. Действие не допускается.
|
||||
admin.users.user.cannot-change-role: Невозможно изменить роль %s. Действие не допускается.
|
||||
admin.users.user.cannot-create.already-exists: Невозможно создать пользователь, пользователь с таким именем уже существует
|
||||
admin.users.user.cannot-create.var-missing: Невозможно создать пользователя, пропуская переменную
|
||||
admin.users.user.cannot-delete: Невозможно удалить пользователь. Вы должны быть администратором, и пользователь не должен быть авторизован.
|
||||
admin.users.user.cannot-edit: Невозможно изменить пользователя %s. Действие не допускается.
|
||||
admin.users.user.created: Пользователь создан
|
||||
admin.users.user.deleted: Пользователь удален
|
||||
admin.users.user.edited: Пользовательские данные обновляются
|
||||
admin.users.user.not-found: Пользователь не найден
|
||||
admin.users.users: Пользователей
|
||||
admin.view-site: Просмотр сайта
|
@ -1,56 +0,0 @@
|
||||
<button type="button" class="toggle-navigation hide-from-s"><?= $this->icon('list') ?></button>
|
||||
<div class="sidebar show-from-s">
|
||||
<div class="logo"><a href="<?= $admin->uri('/dashboard/') ?>"><img src="<?= $this->assets()->uri('images/icon.svg') ?>" alt=""> Formwork</a></div>
|
||||
<a href="<?= $admin->uri('/users/' . $admin->user()->username() . '/profile/') ?>">
|
||||
<div class="admin-user-card">
|
||||
<div class="admin-user-avatar">
|
||||
<img src="<?= $admin->user()->avatar()->uri() ?>" alt="">
|
||||
</div>
|
||||
<div class="admin-user-details">
|
||||
<div class="admin-user-fullname"><?= $this->escape($admin->user()->fullname()) ?></div>
|
||||
<div class="admin-user-username"><?= $this->escape($admin->user()->username()) ?></div>
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
<div class="sidebar-wrapper">
|
||||
<h3 class="caption"><?= $this->translate('admin.manage') ?></h3>
|
||||
<ul class="sidebar-navigation">
|
||||
<?php
|
||||
if ($admin->user()->permissions()->has('dashboard')):
|
||||
?>
|
||||
<li class="<?= ($location === 'dashboard') ? 'active' : '' ?>">
|
||||
<a href="<?= $admin->uri('/dashboard/') ?>"><?= $this->translate('admin.dashboard.dashboard') ?></a>
|
||||
</li>
|
||||
<?php
|
||||
endif;
|
||||
|
||||
if ($admin->user()->permissions()->has('pages')):
|
||||
?>
|
||||
<li class="<?= ($location === 'pages') ? 'active' : '' ?>">
|
||||
<a href="<?= $admin->uri('/pages/') ?>"><?= $this->translate('admin.pages.pages') ?></a>
|
||||
</li>
|
||||
<?php
|
||||
endif;
|
||||
|
||||
if ($admin->user()->permissions()->has('options')):
|
||||
?>
|
||||
<li class="<?= ($location === 'options') ? 'active' : '' ?>">
|
||||
<a href="<?= $admin->uri('/options/') ?>"><?= $this->translate('admin.options.options') ?></a>
|
||||
</li>
|
||||
<?php
|
||||
endif;
|
||||
|
||||
if ($admin->user()->permissions()->has('users')):
|
||||
?>
|
||||
<li class="<?= ($location === 'users') ? 'active' : '' ?>">
|
||||
<a href="<?= $admin->uri('/users/') ?>"><?= $this->translate('admin.users.users') ?></a>
|
||||
</li>
|
||||
<?php
|
||||
endif;
|
||||
?>
|
||||
<li>
|
||||
<a href="<?= $admin->uri('/logout/') ?>"><?= $this->translate('admin.login.logout') ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
Before Width: | Height: | Size: 213 KiB After Width: | Height: | Size: 213 KiB |
@ -4,7 +4,7 @@
|
||||
const FORMWORK_PATH = ROOT_PATH . 'formwork' . DS;
|
||||
const SITE_PATH = ROOT_PATH . 'site' . DS;
|
||||
const CONFIG_PATH = SITE_PATH . 'config' . DS;
|
||||
const ADMIN_PATH = ROOT_PATH . 'admin' . DS;
|
||||
const PANEL_PATH = ROOT_PATH . 'panel' . DS;
|
||||
|
||||
// Check PHP version requirements
|
||||
if (!version_compare(PHP_VERSION, '8.0.2', '>=')) {
|
||||
|
@ -1,9 +1,9 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
'admin' => [
|
||||
'panel' => [
|
||||
'enabled' => true,
|
||||
'root' => 'admin',
|
||||
'root' => 'panel',
|
||||
'lang' => 'en',
|
||||
'login_attempts' => 10,
|
||||
'login_reset_time' => 300,
|
||||
@ -12,8 +12,8 @@ return [
|
||||
'avatar_size' => 512,
|
||||
'color_scheme' => 'light',
|
||||
'paths' => [
|
||||
'accounts' => ADMIN_PATH . 'accounts' . DS,
|
||||
'logs' => ADMIN_PATH . 'logs' . DS
|
||||
'accounts' => PANEL_PATH . 'accounts' . DS,
|
||||
'logs' => PANEL_PATH . 'logs' . DS
|
||||
]
|
||||
],
|
||||
'backup' => [
|
||||
@ -76,13 +76,13 @@ return [
|
||||
],
|
||||
'routes' => [
|
||||
'files' => [
|
||||
'admin' => ADMIN_PATH . 'routes.php',
|
||||
'panel' => PANEL_PATH . 'routes.php',
|
||||
'system' => FORMWORK_PATH . 'routes.php'
|
||||
]
|
||||
],
|
||||
'schemes' => [
|
||||
'paths' => [
|
||||
'admin' => ADMIN_PATH . 'schemes' . DS,
|
||||
'panel' => PANEL_PATH . 'schemes' . DS,
|
||||
'config' => CONFIG_PATH . 'schemes' . DS,
|
||||
'pages' => SITE_PATH . 'schemes' . DS
|
||||
]
|
||||
@ -97,7 +97,7 @@ return [
|
||||
'translations' => [
|
||||
'fallback' => 'en',
|
||||
'paths' => [
|
||||
'admin' => ADMIN_PATH . 'translations' . DS,
|
||||
'panel' => PANEL_PATH . 'translations' . DS,
|
||||
'system' => FORMWORK_PATH . 'translations' . DS
|
||||
]
|
||||
],
|
||||
@ -106,7 +106,7 @@ return [
|
||||
],
|
||||
'views' => [
|
||||
'paths' => [
|
||||
'admin' => ADMIN_PATH . 'views' . DS,
|
||||
'panel' => PANEL_PATH . 'views' . DS,
|
||||
'system' => FORMWORK_PATH . 'views' . DS
|
||||
]
|
||||
]
|
||||
|
@ -2,8 +2,8 @@
|
||||
|
||||
namespace Formwork;
|
||||
|
||||
use Formwork\Admin\Admin;
|
||||
use Formwork\Admin\Statistics;
|
||||
use Formwork\Panel\Panel;
|
||||
use Formwork\Panel\Statistics;
|
||||
use Formwork\Cache\FilesCache;
|
||||
use Formwork\Languages\Languages;
|
||||
use Formwork\Pages\Site;
|
||||
@ -62,9 +62,9 @@ final class Formwork
|
||||
protected FilesCache $cache;
|
||||
|
||||
/**
|
||||
* Admin instance
|
||||
* Panel instance
|
||||
*/
|
||||
protected ?Admin $admin;
|
||||
protected ?Panel $panel;
|
||||
|
||||
/**
|
||||
* Create a new Formwork instance
|
||||
@ -151,15 +151,15 @@ final class Formwork
|
||||
}
|
||||
|
||||
/**
|
||||
* Return admin instance
|
||||
* Return panel instance
|
||||
*/
|
||||
public function admin(): ?Admin
|
||||
public function panel(): ?Panel
|
||||
{
|
||||
if (isset($this->admin)) {
|
||||
return $this->admin;
|
||||
if (isset($this->panel)) {
|
||||
return $this->panel;
|
||||
}
|
||||
return $this->admin = $this->config->get('admin.enabled')
|
||||
? new Admin()
|
||||
return $this->panel = $this->config->get('panel.enabled')
|
||||
? new Panel()
|
||||
: null;
|
||||
}
|
||||
|
||||
@ -197,9 +197,9 @@ final class Formwork
|
||||
$data = YAML::parseFile(CONFIG_PATH . 'system.yml');
|
||||
|
||||
if ($data !== []) {
|
||||
if (isset($data['admin.root'])) {
|
||||
// Trim slashes from admin.root
|
||||
$data['admin.root'] = trim($data['admin.root'], '/');
|
||||
if (isset($data['panel.root'])) {
|
||||
// Trim slashes from panel.root
|
||||
$data['panel.root'] = trim($data['panel.root'], '/');
|
||||
}
|
||||
$this->config = new Config(array_replace_recursive($this->defaults(), $data));
|
||||
}
|
||||
@ -227,8 +227,8 @@ final class Formwork
|
||||
if ($this->languages->requested() !== null) {
|
||||
$this->request = Str::removeStart($this->request, '/' . $this->languages->current());
|
||||
} elseif ($this->languages->preferred() !== null) {
|
||||
// Don't redirect if we are in Admin
|
||||
if (!Str::startsWith($this->request, '/' . $this->config()->get('admin.root'))) {
|
||||
// Don't redirect if we are in Panel
|
||||
if (!Str::startsWith($this->request, '/' . $this->config()->get('panel.root'))) {
|
||||
Header::redirect(HTTPRequest::root() . $this->languages->preferred() . $this->request);
|
||||
}
|
||||
}
|
||||
@ -277,10 +277,10 @@ final class Formwork
|
||||
*/
|
||||
protected function loadRoutes(): void
|
||||
{
|
||||
if ($this->config->get('admin.enabled')) {
|
||||
if ($this->config->get('panel.enabled')) {
|
||||
$this->router->loadFromFile(
|
||||
$this->config()->get('routes.files.admin'),
|
||||
Str::wrap($this->config()->get('admin.root'), '/')
|
||||
$this->config()->get('routes.files.panel'),
|
||||
Str::wrap($this->config()->get('panel.root'), '/')
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin;
|
||||
namespace Formwork\Panel;
|
||||
|
||||
use Formwork\Exceptions\TranslatedException;
|
||||
use Formwork\Formwork;
|
||||
@ -45,7 +45,7 @@ class Backupper
|
||||
'*.DS_Store',
|
||||
'*.gitignore',
|
||||
'*.gitkeep',
|
||||
'admin/node_modules/*',
|
||||
'panel/node_modules/*',
|
||||
'backup/*'
|
||||
]
|
||||
];
|
@ -1,10 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Admin;
|
||||
use Formwork\Admin\Security\CSRFToken;
|
||||
use Formwork\Admin\Users\User;
|
||||
use Formwork\Panel\Panel;
|
||||
use Formwork\Panel\Security\CSRFToken;
|
||||
use Formwork\Panel\Users\User;
|
||||
use Formwork\Controllers\AbstractController as BaseAbstractController;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Parsers\JSON;
|
||||
@ -22,11 +22,11 @@ abstract class AbstractController extends BaseAbstractController
|
||||
protected array $modals = [];
|
||||
|
||||
/**
|
||||
* Return admin instance
|
||||
* Return panel instance
|
||||
*/
|
||||
protected function admin(): Admin
|
||||
protected function panel(): Panel
|
||||
{
|
||||
return Formwork::instance()->admin();
|
||||
return Formwork::instance()->panel();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -45,31 +45,31 @@ abstract class AbstractController extends BaseAbstractController
|
||||
{
|
||||
return [
|
||||
'location' => $this->name,
|
||||
'admin' => $this->admin(),
|
||||
'panel' => $this->panel(),
|
||||
'csrfToken' => CSRFToken::get(),
|
||||
'modals' => implode('', $this->modals),
|
||||
'colorScheme' => $this->getColorScheme(),
|
||||
'appConfig' => JSON::encode([
|
||||
'baseUri' => $this->admin()->panelUri(),
|
||||
'baseUri' => $this->panel()->panelUri(),
|
||||
'DateInput' => [
|
||||
'weekStarts' => Formwork::instance()->config()->get('date.week_starts'),
|
||||
'format' => Date::formatToPattern(Formwork::instance()->config()->get('date.format') . ' ' . Formwork::instance()->config()->get('date.time_format')),
|
||||
'time' => true,
|
||||
'labels' => [
|
||||
'today' => $this->admin()->translate('date.today'),
|
||||
'weekdays' => ['long' => $this->admin()->translate('date.weekdays.long'), 'short' => $this->admin()->translate('date.weekdays.short')],
|
||||
'months' => ['long' => $this->admin()->translate('date.months.long'), 'short' => $this->admin()->translate('date.months.short')]
|
||||
'today' => $this->panel()->translate('date.today'),
|
||||
'weekdays' => ['long' => $this->panel()->translate('date.weekdays.long'), 'short' => $this->panel()->translate('date.weekdays.short')],
|
||||
'months' => ['long' => $this->panel()->translate('date.months.long'), 'short' => $this->panel()->translate('date.months.short')]
|
||||
]
|
||||
],
|
||||
'DurationInput' => [
|
||||
'labels' => [
|
||||
'years' => $this->admin()->translate('date.duration.years'),
|
||||
'months' => $this->admin()->translate('date.duration.months'),
|
||||
'weeks' => $this->admin()->translate('date.duration.weeks'),
|
||||
'days' => $this->admin()->translate('date.duration.days'),
|
||||
'hours' => $this->admin()->translate('date.duration.hours'),
|
||||
'minutes' => $this->admin()->translate('date.duration.minutes'),
|
||||
'seconds' => $this->admin()->translate('date.duration.seconds')
|
||||
'years' => $this->panel()->translate('date.duration.years'),
|
||||
'months' => $this->panel()->translate('date.duration.months'),
|
||||
'weeks' => $this->panel()->translate('date.duration.weeks'),
|
||||
'days' => $this->panel()->translate('date.duration.days'),
|
||||
'hours' => $this->panel()->translate('date.duration.hours'),
|
||||
'minutes' => $this->panel()->translate('date.duration.minutes'),
|
||||
'seconds' => $this->panel()->translate('date.duration.seconds')
|
||||
]
|
||||
]
|
||||
])
|
||||
@ -81,7 +81,7 @@ abstract class AbstractController extends BaseAbstractController
|
||||
*/
|
||||
protected function user(): User
|
||||
{
|
||||
return $this->admin()->user();
|
||||
return $this->panel()->user();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -121,8 +121,8 @@ abstract class AbstractController extends BaseAbstractController
|
||||
$view = new View(
|
||||
$name,
|
||||
array_merge($this->defaults(), $data),
|
||||
Formwork::instance()->config()->get('views.paths.admin'),
|
||||
PHP::parseFile(ADMIN_PATH . 'helpers.php')
|
||||
Formwork::instance()->config()->get('views.paths.panel'),
|
||||
PHP::parseFile(PANEL_PATH . 'helpers.php')
|
||||
);
|
||||
return $view->render($return);
|
||||
}
|
||||
@ -132,8 +132,8 @@ abstract class AbstractController extends BaseAbstractController
|
||||
*/
|
||||
private function getColorScheme(): string
|
||||
{
|
||||
$default = Formwork::instance()->config()->get('admin.color_scheme');
|
||||
if ($this->admin()->isLoggedIn()) {
|
||||
$default = Formwork::instance()->config()->get('panel.color_scheme');
|
||||
if ($this->panel()->isLoggedIn()) {
|
||||
if ($this->user()->colorScheme() === 'auto') {
|
||||
return HTTPRequest::cookies()->get('formwork_preferred_color_scheme', $default);
|
||||
}
|
@ -1,9 +1,9 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Security\AccessLimiter;
|
||||
use Formwork\Admin\Security\CSRFToken;
|
||||
use Formwork\Panel\Security\AccessLimiter;
|
||||
use Formwork\Panel\Security\CSRFToken;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Response\RedirectResponse;
|
||||
use Formwork\Response\Response;
|
||||
@ -19,30 +19,30 @@ class AuthenticationController extends AbstractController
|
||||
*/
|
||||
public function login(): Response
|
||||
{
|
||||
$attemptsRegistry = new Registry(Formwork::instance()->config()->get('admin.paths.logs') . 'accessAttempts.json');
|
||||
$attemptsRegistry = new Registry(Formwork::instance()->config()->get('panel.paths.logs') . 'accessAttempts.json');
|
||||
|
||||
$limiter = new AccessLimiter(
|
||||
$attemptsRegistry,
|
||||
Formwork::instance()->config()->get('admin.login_attempts'),
|
||||
Formwork::instance()->config()->get('admin.login_reset_time')
|
||||
Formwork::instance()->config()->get('panel.login_attempts'),
|
||||
Formwork::instance()->config()->get('panel.login_reset_time')
|
||||
);
|
||||
|
||||
if ($limiter->hasReachedLimit()) {
|
||||
$minutes = round(Formwork::instance()->config()->get('admin.login_reset_time') / 60);
|
||||
return $this->error($this->admin()->translate('admin.login.attempt.too-many', $minutes));
|
||||
$minutes = round(Formwork::instance()->config()->get('panel.login_reset_time') / 60);
|
||||
return $this->error($this->panel()->translate('panel.login.attempt.too-many', $minutes));
|
||||
}
|
||||
|
||||
switch (HTTPRequest::method()) {
|
||||
case 'GET':
|
||||
if (Session::has('FORMWORK_USERNAME')) {
|
||||
return $this->admin()->redirectToPanel();
|
||||
return $this->panel()->redirectToPanel();
|
||||
}
|
||||
|
||||
// Always generate a new CSRF token
|
||||
CSRFToken::generate();
|
||||
|
||||
return new Response($this->view('authentication.login', [
|
||||
'title' => $this->admin()->translate('admin.login.login')
|
||||
'title' => $this->panel()->translate('panel.login.login')
|
||||
], true));
|
||||
|
||||
break;
|
||||
@ -55,12 +55,12 @@ class AuthenticationController extends AbstractController
|
||||
|
||||
// Ensure no required data is missing
|
||||
if (!$data->hasMultiple(['username', 'password'])) {
|
||||
$this->error($this->admin()->translate('admin.login.attempt.failed'));
|
||||
$this->error($this->panel()->translate('panel.login.attempt.failed'));
|
||||
}
|
||||
|
||||
$limiter->registerAttempt();
|
||||
|
||||
$user = $this->admin()->users()->get($data->get('username'));
|
||||
$user = $this->panel()->users()->get($data->get('username'));
|
||||
|
||||
// Authenticate user
|
||||
if ($user !== null && $user->authenticate($data->get('password'))) {
|
||||
@ -72,8 +72,8 @@ class AuthenticationController extends AbstractController
|
||||
// Regenerate CSRF token
|
||||
CSRFToken::generate();
|
||||
|
||||
$accessLog = new Log(Formwork::instance()->config()->get('admin.paths.logs') . 'access.json');
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('admin.paths.logs') . 'lastAccess.json');
|
||||
$accessLog = new Log(Formwork::instance()->config()->get('panel.paths.logs') . 'access.json');
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('panel.paths.logs') . 'lastAccess.json');
|
||||
|
||||
$time = $accessLog->log($data->get('username'));
|
||||
$lastAccessRegistry->set($data->get('username'), $time);
|
||||
@ -82,13 +82,13 @@ class AuthenticationController extends AbstractController
|
||||
|
||||
if (($destination = Session::get('FORMWORK_REDIRECT_TO')) !== null) {
|
||||
Session::remove('FORMWORK_REDIRECT_TO');
|
||||
return $this->admin()->redirect($destination);
|
||||
return $this->panel()->redirect($destination);
|
||||
}
|
||||
|
||||
return $this->admin()->redirectToPanel();
|
||||
return $this->panel()->redirectToPanel();
|
||||
}
|
||||
|
||||
return $this->error($this->admin()->translate('admin.login.attempt.failed'), [
|
||||
return $this->error($this->panel()->translate('panel.login.attempt.failed'), [
|
||||
'username' => $data->get('username'),
|
||||
'error' => true
|
||||
]);
|
||||
@ -106,11 +106,11 @@ class AuthenticationController extends AbstractController
|
||||
Session::remove('FORMWORK_USERNAME');
|
||||
Session::destroy();
|
||||
|
||||
if (Formwork::instance()->config()->get('admin.logout_redirect') === 'home') {
|
||||
return $this->admin()->redirectToSite();
|
||||
if (Formwork::instance()->config()->get('panel.logout_redirect') === 'home') {
|
||||
return $this->panel()->redirectToSite();
|
||||
}
|
||||
$this->admin()->notify($this->admin()->translate('admin.login.logged-out'), 'info');
|
||||
return $this->admin()->redirectToPanel();
|
||||
$this->panel()->notify($this->panel()->translate('panel.login.logged-out'), 'info');
|
||||
return $this->panel()->redirectToPanel();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -124,8 +124,8 @@ class AuthenticationController extends AbstractController
|
||||
// Ensure CSRF token is re-generated
|
||||
CSRFToken::generate();
|
||||
|
||||
$defaults = ['title' => $this->admin()->translate('admin.login.login')];
|
||||
$this->admin()->notify($message, 'error');
|
||||
$defaults = ['title' => $this->panel()->translate('panel.login.login')];
|
||||
$this->panel()->notify($message, 'error');
|
||||
return new Response($this->view('authentication.login', array_merge($defaults, $data), true));
|
||||
}
|
||||
}
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Backupper;
|
||||
use Formwork\Panel\Backupper;
|
||||
use Formwork\Exceptions\TranslatedException;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Response\FileResponse;
|
||||
@ -24,12 +24,12 @@ class BackupController extends AbstractController
|
||||
try {
|
||||
$file = $backupper->backup();
|
||||
} catch (TranslatedException $e) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.backup.error.cannot-make', $e->getTranslatedMessage()), 500);
|
||||
return JSONResponse::error($this->panel()->translate('panel.backup.error.cannot-make', $e->getTranslatedMessage()), 500);
|
||||
}
|
||||
$filename = basename($file);
|
||||
return JSONResponse::success($this->admin()->translate('admin.backup.ready'), 200, [
|
||||
return JSONResponse::success($this->panel()->translate('panel.backup.ready'), 200, [
|
||||
'filename' => $filename,
|
||||
'uri' => $this->admin()->uri('/backup/download/' . urlencode(base64_encode($filename)) . '/')
|
||||
'uri' => $this->panel()->uri('/backup/download/' . urlencode(base64_encode($filename)) . '/')
|
||||
]);
|
||||
}
|
||||
|
||||
@ -44,10 +44,10 @@ class BackupController extends AbstractController
|
||||
if (FileSystem::isFile($file, false)) {
|
||||
return new FileResponse($file, true);
|
||||
}
|
||||
throw new RuntimeException($this->admin()->translate('admin.backup.error.cannot-download.invalid-filename'));
|
||||
throw new RuntimeException($this->panel()->translate('panel.backup.error.cannot-download.invalid-filename'));
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.backup.error.cannot-download', $e->getTranslatedMessage()), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/dashboard/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.backup.error.cannot-download', $e->getTranslatedMessage()), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/dashboard/');
|
||||
}
|
||||
}
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Response\JSONResponse;
|
||||
@ -16,6 +16,6 @@ class CacheController extends AbstractController
|
||||
if (Formwork::instance()->config()->get('cache.enabled')) {
|
||||
Formwork::instance()->cache()->clear();
|
||||
}
|
||||
return JSONResponse::success($this->admin()->translate('admin.cache.cleared'));
|
||||
return JSONResponse::success($this->panel()->translate('panel.cache.cleared'));
|
||||
}
|
||||
}
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Statistics;
|
||||
use Formwork\Panel\Statistics;
|
||||
use Formwork\Parsers\JSON;
|
||||
use Formwork\Response\Response;
|
||||
|
||||
@ -25,7 +25,7 @@ class DashboardController extends AbstractController
|
||||
$this->modal('deletePage');
|
||||
|
||||
return new Response($this->view('dashboard.index', [
|
||||
'title' => $this->admin()->translate('admin.dashboard.dashboard'),
|
||||
'title' => $this->panel()->translate('panel.dashboard.dashboard'),
|
||||
'lastModifiedPages' => $this->view('pages.list', [
|
||||
'pages' => $this->site()->descendants()->sortBy('lastModifiedTime', direction: SORT_DESC)->slice(0, 5),
|
||||
'subpages' => false,
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Response\Response;
|
||||
@ -15,8 +15,8 @@ class ErrorsController extends AbstractController
|
||||
public function notFound(): Response
|
||||
{
|
||||
return $this->makeErrorResponse(404, 'not-found', [
|
||||
'href' => $this->admin()->uri('/dashboard/'),
|
||||
'label' => $this->admin()->translate('admin.errors.action.return-to-dashboard')
|
||||
'href' => $this->panel()->uri('/dashboard/'),
|
||||
'label' => $this->panel()->translate('panel.errors.action.return-to-dashboard')
|
||||
]);
|
||||
}
|
||||
|
||||
@ -27,7 +27,7 @@ class ErrorsController extends AbstractController
|
||||
{
|
||||
return $this->makeErrorResponse(500, 'internal-server-error', [
|
||||
'href' => $this->makeGitHubIssueUri($exception),
|
||||
'label' => $this->admin()->translate('admin.errors.action.report-to-github')
|
||||
'label' => $this->panel()->translate('panel.errors.action.report-to-github')
|
||||
]);
|
||||
}
|
||||
|
||||
@ -37,8 +37,8 @@ class ErrorsController extends AbstractController
|
||||
public function forbidden(): Response
|
||||
{
|
||||
return $this->makeErrorResponse(403, 'forbidden', [
|
||||
'href' => $this->admin()->uri('/dashboard/'),
|
||||
'label' => $this->admin()->translate('admin.errors.action.return-to-dashboard')
|
||||
'href' => $this->panel()->uri('/dashboard/'),
|
||||
'label' => $this->panel()->translate('panel.errors.action.return-to-dashboard')
|
||||
]);
|
||||
}
|
||||
|
||||
@ -53,11 +53,11 @@ class ErrorsController extends AbstractController
|
||||
{
|
||||
HTTPResponse::cleanOutputBuffers();
|
||||
return new Response($this->view('errors.error', [
|
||||
'title' => $this->admin()->translate('admin.errors.error.' . $name . '.status'),
|
||||
'title' => $this->panel()->translate('panel.errors.error.' . $name . '.status'),
|
||||
'code' => $status,
|
||||
'status' => $this->admin()->translate('admin.errors.error.' . $name . '.status'),
|
||||
'heading' => $this->admin()->translate('admin.errors.error.' . $name . '.heading'),
|
||||
'description' => $this->admin()->translate('admin.errors.error.' . $name . '.description'),
|
||||
'status' => $this->panel()->translate('panel.errors.error.' . $name . '.status'),
|
||||
'heading' => $this->panel()->translate('panel.errors.error.' . $name . '.heading'),
|
||||
'description' => $this->panel()->translate('panel.errors.error.' . $name . '.description'),
|
||||
'action' => $action
|
||||
], true), $status);
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Fields\FieldCollection;
|
||||
use Formwork\Formwork;
|
||||
@ -26,7 +26,7 @@ class OptionsController extends AbstractController
|
||||
public function index(): RedirectResponse
|
||||
{
|
||||
$this->ensurePermission('options.system');
|
||||
return $this->admin()->redirect('/options/system/');
|
||||
return $this->panel()->redirect('/options/system/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -52,8 +52,8 @@ class OptionsController extends AbstractController
|
||||
FileSystem::touch(Formwork::instance()->config()->get('content.path'));
|
||||
}
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.options.updated'), 'success');
|
||||
return $this->admin()->redirect('/options/system/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.options.updated'), 'success');
|
||||
return $this->panel()->redirect('/options/system/');
|
||||
}
|
||||
|
||||
$fields->validate(Formwork::instance()->config());
|
||||
@ -61,7 +61,7 @@ class OptionsController extends AbstractController
|
||||
$this->modal('changes');
|
||||
|
||||
return new Response($this->view('options.system', [
|
||||
'title' => $this->admin()->translate('admin.options.options'),
|
||||
'title' => $this->panel()->translate('panel.options.options'),
|
||||
'tabs' => $this->view('options.tabs', [
|
||||
'tabs' => $this->tabs,
|
||||
'current' => 'system'
|
||||
@ -92,8 +92,8 @@ class OptionsController extends AbstractController
|
||||
FileSystem::touch(Formwork::instance()->config()->get('content.path'));
|
||||
}
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.options.updated'), 'success');
|
||||
return $this->admin()->redirect('/options/site/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.options.updated'), 'success');
|
||||
return $this->panel()->redirect('/options/site/');
|
||||
}
|
||||
|
||||
$fields->validate($this->site()->data());
|
||||
@ -101,7 +101,7 @@ class OptionsController extends AbstractController
|
||||
$this->modal('changes');
|
||||
|
||||
return new Response($this->view('options.site', [
|
||||
'title' => $this->admin()->translate('admin.options.options'),
|
||||
'title' => $this->panel()->translate('panel.options.options'),
|
||||
'tabs' => $this->view('options.tabs', [
|
||||
'tabs' => $this->tabs,
|
||||
'current' => 'site'
|
||||
@ -118,7 +118,7 @@ class OptionsController extends AbstractController
|
||||
$this->ensurePermission('options.updates');
|
||||
|
||||
return new Response($this->view('options.updates', [
|
||||
'title' => $this->admin()->translate('admin.options.updates'),
|
||||
'title' => $this->panel()->translate('panel.options.updates'),
|
||||
'tabs' => $this->view('options.tabs', [
|
||||
'tabs' => $this->tabs,
|
||||
'current' => 'updates'
|
||||
@ -228,7 +228,7 @@ class OptionsController extends AbstractController
|
||||
ksort($data['HTTP Response Headers']);
|
||||
|
||||
return new Response($this->view('options.info', [
|
||||
'title' => $this->admin()->translate('admin.options.options'),
|
||||
'title' => $this->panel()->translate('panel.options.options'),
|
||||
'tabs' => $this->view('options.tabs', [
|
||||
'tabs' => $this->tabs,
|
||||
'current' => 'info'
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Uploader;
|
||||
use Formwork\Panel\Uploader;
|
||||
use Formwork\Data\DataGetter;
|
||||
use Formwork\Exceptions\TranslatedException;
|
||||
use Formwork\Fields\FieldCollection;
|
||||
@ -52,7 +52,7 @@ class PagesController extends AbstractController
|
||||
$this->modal('deletePage');
|
||||
|
||||
return new Response($this->view('pages.index', [
|
||||
'title' => $this->admin()->translate('admin.pages.pages'),
|
||||
'title' => $this->panel()->translate('panel.pages.pages'),
|
||||
'pagesList' => $this->view('pages.list', [
|
||||
'pages' => $this->site()->pages(),
|
||||
'subpages' => true,
|
||||
@ -76,13 +76,13 @@ class PagesController extends AbstractController
|
||||
// Let's create the page
|
||||
try {
|
||||
$page = $this->createPage($data);
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.created'), 'success');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.created'), 'success');
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($e->getTranslatedMessage(), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($e->getTranslatedMessage(), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
|
||||
return $this->admin()->redirect('/pages/' . trim($page->route(), '/') . '/edit/');
|
||||
return $this->panel()->redirect('/pages/' . trim($page->route(), '/') . '/edit/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -95,20 +95,20 @@ class PagesController extends AbstractController
|
||||
$page = $this->site()->findPage($params->get('page'));
|
||||
|
||||
if ($page === null) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-edit.page-not-found'), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-edit.page-not-found'), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
|
||||
if ($params->has('language')) {
|
||||
if (empty(Formwork::instance()->config()->get('languages.available'))) {
|
||||
return $this->admin()->redirect('/pages/' . trim($page->route(), '/') . '/edit/');
|
||||
return $this->panel()->redirect('/pages/' . trim($page->route(), '/') . '/edit/');
|
||||
}
|
||||
|
||||
$language = $params->get('language');
|
||||
|
||||
if (!in_array($language, Formwork::instance()->config()->get('languages.available'), true)) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-edit.invalid-language', $language), 'error');
|
||||
return $this->admin()->redirect('/pages/' . trim($page->route(), '/') . '/edit/language/' . $this->site()->languages()->default() . '/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-edit.invalid-language', $language), 'error');
|
||||
return $this->panel()->redirect('/pages/' . trim($page->route(), '/') . '/edit/language/' . $this->site()->languages()->default() . '/');
|
||||
}
|
||||
|
||||
if ($page->hasLanguage($language)) {
|
||||
@ -116,7 +116,7 @@ class PagesController extends AbstractController
|
||||
}
|
||||
} elseif ($page->language() !== null) {
|
||||
// Redirect to proper language
|
||||
return $this->admin()->redirect('/pages/' . trim($page->route(), '/') . '/edit/language/' . $page->language() . '/');
|
||||
return $this->panel()->redirect('/pages/' . trim($page->route(), '/') . '/edit/language/' . $page->language() . '/');
|
||||
}
|
||||
|
||||
// Load page fields
|
||||
@ -142,22 +142,22 @@ class PagesController extends AbstractController
|
||||
// Update the page
|
||||
try {
|
||||
$page = $this->updatePage($page, $data, $fields);
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.edited'), 'success');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.edited'), 'success');
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($e->getTranslatedMessage(), 'error');
|
||||
$this->panel()->notify($e->getTranslatedMessage(), 'error');
|
||||
}
|
||||
|
||||
if (HTTPRequest::hasFiles()) {
|
||||
try {
|
||||
$this->processPageUploads($page);
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.uploader.error', $e->getTranslatedMessage()), 'error');
|
||||
$this->panel()->notify($this->panel()->translate('panel.uploader.error', $e->getTranslatedMessage()), 'error');
|
||||
}
|
||||
}
|
||||
|
||||
// Redirect if page route has changed
|
||||
if ($params->get('page') !== ($route = trim($page->route(), '/'))) {
|
||||
return $this->admin()->redirect('/pages/' . $route . '/edit/');
|
||||
return $this->panel()->redirect('/pages/' . $route . '/edit/');
|
||||
}
|
||||
|
||||
break;
|
||||
@ -176,7 +176,7 @@ class PagesController extends AbstractController
|
||||
$this->modal('deleteFile');
|
||||
|
||||
return new Response($this->view('pages.editor', [
|
||||
'title' => $this->admin()->translate('admin.pages.edit-page', $page->title()),
|
||||
'title' => $this->panel()->translate('panel.pages.edit-page', $page->title()),
|
||||
'page' => $page,
|
||||
'fields' => $fields,
|
||||
'templates' => $this->site()->templates()->keys(),
|
||||
@ -196,16 +196,16 @@ class PagesController extends AbstractController
|
||||
$data = HTTPRequest::postData();
|
||||
|
||||
if (!$data->hasMultiple(['parent', 'from', 'to'])) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.pages.page.cannot-move'));
|
||||
return JSONResponse::error($this->panel()->translate('panel.pages.page.cannot-move'));
|
||||
}
|
||||
|
||||
if (!is_numeric($data->get('from')) || !is_numeric($data->get('to'))) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.pages.page.cannot-move'));
|
||||
return JSONResponse::error($this->panel()->translate('panel.pages.page.cannot-move'));
|
||||
}
|
||||
|
||||
$parent = $this->resolveParent($data->get('parent'));
|
||||
if ($parent === null || !$parent->hasChildren()) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.pages.page.cannot-move'));
|
||||
return JSONResponse::error($this->panel()->translate('panel.pages.page.cannot-move'));
|
||||
}
|
||||
|
||||
$pages = $parent->children()->toArray();
|
||||
@ -229,7 +229,7 @@ class PagesController extends AbstractController
|
||||
}
|
||||
}
|
||||
|
||||
return JSONResponse::success($this->admin()->translate('admin.pages.page.moved'));
|
||||
return JSONResponse::success($this->panel()->translate('panel.pages.page.moved'));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -242,8 +242,8 @@ class PagesController extends AbstractController
|
||||
$page = $this->site()->findPage($params->get('page'));
|
||||
|
||||
if ($page === null) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-delete.page-not-found'), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-delete.page-not-found'), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
|
||||
if ($params->has('language')) {
|
||||
@ -251,14 +251,14 @@ class PagesController extends AbstractController
|
||||
if ($page->hasLanguage($language)) {
|
||||
$page->setLanguage($language);
|
||||
} else {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-delete.invalid-language', $language), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-delete.invalid-language', $language), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
}
|
||||
|
||||
if (!$page->isDeletable()) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-delete.not-deletable'), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-delete.not-deletable'), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
|
||||
// Delete just the content file only if there are more than one language
|
||||
@ -268,13 +268,13 @@ class PagesController extends AbstractController
|
||||
FileSystem::delete($page->path(), true);
|
||||
}
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.deleted'), 'success');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.deleted'), 'success');
|
||||
|
||||
// Don't redirect to referer if it's to Pages@edit
|
||||
if (!Str::startsWith(Uri::normalize(HTTPRequest::referer()), Uri::make(['path' => $this->admin()->uri('/pages/' . $params->get('page') . '/edit/')]))) {
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
if (!Str::startsWith(Uri::normalize(HTTPRequest::referer()), Uri::make(['path' => $this->panel()->uri('/pages/' . $params->get('page') . '/edit/')]))) {
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
return $this->admin()->redirect('/pages/');
|
||||
return $this->panel()->redirect('/pages/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -287,21 +287,21 @@ class PagesController extends AbstractController
|
||||
$page = $this->site()->findPage($params->get('page'));
|
||||
|
||||
if ($page === null) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-upload-file.page-not-found'), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-upload-file.page-not-found'), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
|
||||
if (HTTPRequest::hasFiles()) {
|
||||
try {
|
||||
$this->processPageUploads($page);
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.uploader.error', $e->getTranslatedMessage()), 'error');
|
||||
return $this->admin()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.uploader.error', $e->getTranslatedMessage()), 'error');
|
||||
return $this->panel()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
}
|
||||
}
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.uploader.uploaded'), 'success');
|
||||
return $this->admin()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.uploader.uploaded'), 'success');
|
||||
return $this->panel()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -314,19 +314,19 @@ class PagesController extends AbstractController
|
||||
$page = $this->site()->findPage($params->get('page'));
|
||||
|
||||
if ($page === null) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-delete-file.page-not-found'), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/pages/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-delete-file.page-not-found'), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/pages/');
|
||||
}
|
||||
|
||||
if (!$page->files()->has($params->get('filename'))) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.cannot-delete-file.file-not-found'), 'error');
|
||||
return $this->admin()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.cannot-delete-file.file-not-found'), 'error');
|
||||
return $this->panel()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
}
|
||||
|
||||
FileSystem::delete($page->path() . $params->get('filename'));
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.pages.page.file-deleted'), 'success');
|
||||
return $this->admin()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.pages.page.file-deleted'), 'success');
|
||||
return $this->panel()->redirect('/pages/' . $params->get('page') . '/edit/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -336,30 +336,30 @@ class PagesController extends AbstractController
|
||||
{
|
||||
// Ensure no required data is missing
|
||||
if (!$data->hasMultiple(['title', 'slug', 'template', 'parent'])) {
|
||||
throw new TranslatedException('Missing required POST data', 'admin.pages.page.cannot-create.var-missing');
|
||||
throw new TranslatedException('Missing required POST data', 'panel.pages.page.cannot-create.var-missing');
|
||||
}
|
||||
|
||||
$parent = $this->resolveParent($data->get('parent'));
|
||||
|
||||
if ($parent === null) {
|
||||
throw new TranslatedException('Parent page not found', 'admin.pages.page.cannot-create.invalid-parent');
|
||||
throw new TranslatedException('Parent page not found', 'panel.pages.page.cannot-create.invalid-parent');
|
||||
}
|
||||
|
||||
// Validate page slug
|
||||
if (!$this->validateSlug($data->get('slug'))) {
|
||||
throw new TranslatedException('Invalid page slug', 'admin.pages.page.cannot-create.invalid-slug');
|
||||
throw new TranslatedException('Invalid page slug', 'panel.pages.page.cannot-create.invalid-slug');
|
||||
}
|
||||
|
||||
$route = $parent->route() . $data->get('slug') . '/';
|
||||
|
||||
// Ensure there isn't a page with the same route
|
||||
if ($this->site()->findPage($route)) {
|
||||
throw new TranslatedException('A page with the same route already exists', 'admin.pages.page.cannot-create.already-exists');
|
||||
throw new TranslatedException('A page with the same route already exists', 'panel.pages.page.cannot-create.already-exists');
|
||||
}
|
||||
|
||||
// Validate page template
|
||||
if (!$this->site()->templates()->has($data->get('template'))) {
|
||||
throw new TranslatedException('Invalid page template', 'admin.pages.page.cannot-create.invalid-template');
|
||||
throw new TranslatedException('Invalid page template', 'panel.pages.page.cannot-create.invalid-template');
|
||||
}
|
||||
|
||||
$scheme = Formwork::instance()->schemes()->get('pages', $data->get('template'));
|
||||
@ -395,7 +395,7 @@ class PagesController extends AbstractController
|
||||
{
|
||||
// Ensure no required data is missing
|
||||
if (!$data->hasMultiple(['title', 'content'])) {
|
||||
throw new TranslatedException('Missing required POST data', 'admin.pages.page.cannot-edit.var-missing');
|
||||
throw new TranslatedException('Missing required POST data', 'panel.pages.page.cannot-edit.var-missing');
|
||||
}
|
||||
|
||||
// Load current page frontmatter
|
||||
@ -429,7 +429,7 @@ class PagesController extends AbstractController
|
||||
|
||||
// Validate language
|
||||
if (!empty($language) && !in_array($language, Formwork::instance()->config()->get('languages.available'), true)) {
|
||||
throw new TranslatedException('Invalid page language', 'admin.pages.page.cannot-edit.invalid-language');
|
||||
throw new TranslatedException('Invalid page language', 'panel.pages.page.cannot-edit.invalid-language');
|
||||
}
|
||||
|
||||
$differ = $frontmatter !== $page->frontmatter() || $content !== $page->data()['content'] || $language !== $page->language();
|
||||
@ -458,7 +458,7 @@ class PagesController extends AbstractController
|
||||
try {
|
||||
$page = $this->changePageName($page, $name);
|
||||
} catch (RuntimeException $e) {
|
||||
throw new TranslatedException('Cannot change page num', 'admin.pages.page.cannot-change-num');
|
||||
throw new TranslatedException('Cannot change page num', 'panel.pages.page.cannot-change-num');
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -466,7 +466,7 @@ class PagesController extends AbstractController
|
||||
// Check if parent page has to change
|
||||
if ($page->parent() !== ($parent = $this->resolveParent($data->get('parent')))) {
|
||||
if ($parent === null) {
|
||||
throw new TranslatedException('Invalid parent page', 'admin.pages.page.cannot-edit.invalid-parent');
|
||||
throw new TranslatedException('Invalid parent page', 'panel.pages.page.cannot-edit.invalid-parent');
|
||||
}
|
||||
$page = $this->changePageParent($page, $parent);
|
||||
}
|
||||
@ -474,7 +474,7 @@ class PagesController extends AbstractController
|
||||
// Check if page template has to change
|
||||
if ($page->template()->name() !== ($template = $data->get('template'))) {
|
||||
if (!$this->site()->templates()->has($template)) {
|
||||
throw new TranslatedException('Invalid page template', 'admin.pages.page.cannot-edit.invalid-template');
|
||||
throw new TranslatedException('Invalid page template', 'panel.pages.page.cannot-edit.invalid-template');
|
||||
}
|
||||
$page = $this->changePageTemplate($page, $template);
|
||||
}
|
||||
@ -482,14 +482,14 @@ class PagesController extends AbstractController
|
||||
// Check if page slug has to change
|
||||
if ($page->slug() !== ($slug = $data->get('slug'))) {
|
||||
if (!$this->validateSlug($slug)) {
|
||||
throw new TranslatedException('Invalid page slug', 'admin.pages.page.cannot-edit.invalid-slug');
|
||||
throw new TranslatedException('Invalid page slug', 'panel.pages.page.cannot-edit.invalid-slug');
|
||||
}
|
||||
// Don't change index and error pages slug
|
||||
if ($page->isIndexPage() || $page->isErrorPage()) {
|
||||
throw new TranslatedException('Cannot change slug of index or error pages', 'admin.pages.page.cannot-edit.index-or-error-page-slug');
|
||||
throw new TranslatedException('Cannot change slug of index or error pages', 'panel.pages.page.cannot-edit.index-or-error-page-slug');
|
||||
}
|
||||
if ($this->site()->findPage($page->parent()->route() . $slug . '/')) {
|
||||
throw new TranslatedException('A page with the same route already exists', 'admin.pages.page.cannot-edit.already-exists');
|
||||
throw new TranslatedException('A page with the same route already exists', 'panel.pages.page.cannot-edit.already-exists');
|
||||
}
|
||||
$page = $this->changePageName($page, ltrim($page->num() . '-', '-') . $slug);
|
||||
}
|
@ -1,9 +1,9 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Security\CSRFToken;
|
||||
use Formwork\Admin\Security\Password;
|
||||
use Formwork\Panel\Security\CSRFToken;
|
||||
use Formwork\Panel\Security\Password;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Parsers\YAML;
|
||||
use Formwork\Response\Response;
|
||||
@ -25,7 +25,7 @@ class RegisterController extends AbstractController
|
||||
switch (HTTPRequest::method()) {
|
||||
case 'GET':
|
||||
return new Response($this->view('register.register', [
|
||||
'title' => $this->admin()->translate('admin.register.register')
|
||||
'title' => $this->panel()->translate('panel.register.register')
|
||||
], true));
|
||||
|
||||
break;
|
||||
@ -34,8 +34,8 @@ class RegisterController extends AbstractController
|
||||
$data = HTTPRequest::postData();
|
||||
|
||||
if (!$data->hasMultiple(['username', 'fullname', 'password', 'language', 'email'])) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.cannot-create.var-missing'), 'error');
|
||||
return $this->admin()->redirectToPanel();
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.cannot-create.var-missing'), 'error');
|
||||
return $this->panel()->redirectToPanel();
|
||||
}
|
||||
|
||||
$userData = [
|
||||
@ -44,20 +44,20 @@ class RegisterController extends AbstractController
|
||||
'hash' => Password::hash($data->get('password')),
|
||||
'email' => $data->get('email'),
|
||||
'language' => $data->get('language'),
|
||||
'role' => 'admin'
|
||||
'role' => 'panel'
|
||||
];
|
||||
|
||||
YAML::encodeToFile($userData, Formwork::instance()->config()->get('admin.paths.accounts') . $data->get('username') . '.yml');
|
||||
YAML::encodeToFile($userData, Formwork::instance()->config()->get('panel.paths.accounts') . $data->get('username') . '.yml');
|
||||
|
||||
Session::set('FORMWORK_USERNAME', $data->get('username'));
|
||||
|
||||
$accessLog = new Log(Formwork::instance()->config()->get('admin.paths.logs') . 'access.json');
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('admin.paths.logs') . 'lastAccess.json');
|
||||
$accessLog = new Log(Formwork::instance()->config()->get('panel.paths.logs') . 'access.json');
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('panel.paths.logs') . 'lastAccess.json');
|
||||
|
||||
$time = $accessLog->log($data->get('username'));
|
||||
$lastAccessRegistry->set($data->get('username'), $time);
|
||||
|
||||
return $this->admin()->redirectToPanel();
|
||||
return $this->panel()->redirectToPanel();
|
||||
|
||||
break;
|
||||
}
|
@ -1,9 +1,9 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Backupper;
|
||||
use Formwork\Admin\Updater;
|
||||
use Formwork\Panel\Backupper;
|
||||
use Formwork\Panel\Updater;
|
||||
use Formwork\Exceptions\TranslatedException;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Response\JSONResponse;
|
||||
@ -21,16 +21,16 @@ class UpdatesController extends AbstractController
|
||||
try {
|
||||
$upToDate = $updater->checkUpdates();
|
||||
} catch (RuntimeException $e) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.updates.status.cannot-check'), 500, [
|
||||
'status' => $this->admin()->translate('admin.updates.status.cannot-check')
|
||||
return JSONResponse::error($this->panel()->translate('panel.updates.status.cannot-check'), 500, [
|
||||
'status' => $this->panel()->translate('panel.updates.status.cannot-check')
|
||||
]);
|
||||
}
|
||||
if ($upToDate) {
|
||||
return JSONResponse::success($this->admin()->translate('admin.updates.status.up-to-date'), 200, [
|
||||
return JSONResponse::success($this->panel()->translate('panel.updates.status.up-to-date'), 200, [
|
||||
'uptodate' => true
|
||||
]);
|
||||
}
|
||||
return JSONResponse::success($this->admin()->translate('admin.updates.status.found'), 200, [
|
||||
return JSONResponse::success($this->panel()->translate('panel.updates.status.found'), 200, [
|
||||
'uptodate' => false,
|
||||
'release' => $updater->latestRelease()
|
||||
]);
|
||||
@ -48,23 +48,23 @@ class UpdatesController extends AbstractController
|
||||
try {
|
||||
$backupper->backup();
|
||||
} catch (TranslatedException $e) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.updates.status.cannot-make-backup'), 500, [
|
||||
'status' => $this->admin()->translate('admin.updates.status.cannot-make-backup')
|
||||
return JSONResponse::error($this->panel()->translate('panel.updates.status.cannot-make-backup'), 500, [
|
||||
'status' => $this->panel()->translate('panel.updates.status.cannot-make-backup')
|
||||
]);
|
||||
}
|
||||
}
|
||||
try {
|
||||
$updater->update();
|
||||
} catch (RuntimeException $e) {
|
||||
return JSONResponse::error($this->admin()->translate('admin.updates.status.cannot-install'), 500, [
|
||||
'status' => $this->admin()->translate('admin.updates.status.cannot-install')
|
||||
return JSONResponse::error($this->panel()->translate('panel.updates.status.cannot-install'), 500, [
|
||||
'status' => $this->panel()->translate('panel.updates.status.cannot-install')
|
||||
]);
|
||||
}
|
||||
if (Formwork::instance()->config()->get('cache.enabled')) {
|
||||
Formwork::instance()->cache()->clear();
|
||||
}
|
||||
return JSONResponse::success($this->admin()->translate('admin.updates.installed'), 200, [
|
||||
'status' => $this->admin()->translate('admin.updates.status.up-to-date')
|
||||
return JSONResponse::success($this->panel()->translate('panel.updates.installed'), 200, [
|
||||
'status' => $this->panel()->translate('panel.updates.status.up-to-date')
|
||||
]);
|
||||
}
|
||||
}
|
@ -1,10 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Controllers;
|
||||
namespace Formwork\Panel\Controllers;
|
||||
|
||||
use Formwork\Admin\Security\Password;
|
||||
use Formwork\Admin\Uploader;
|
||||
use Formwork\Admin\Users\User;
|
||||
use Formwork\Panel\Security\Password;
|
||||
use Formwork\Panel\Uploader;
|
||||
use Formwork\Panel\Users\User;
|
||||
use Formwork\Exceptions\TranslatedException;
|
||||
use Formwork\Files\Image;
|
||||
use Formwork\Formwork;
|
||||
@ -30,8 +30,8 @@ class UsersController extends AbstractController
|
||||
$this->modal('deleteUser');
|
||||
|
||||
return new Response($this->view('users.index', [
|
||||
'title' => $this->admin()->translate('admin.users.users'),
|
||||
'users' => $this->admin()->users()
|
||||
'title' => $this->panel()->translate('panel.users.users'),
|
||||
'users' => $this->panel()->users()
|
||||
], true));
|
||||
}
|
||||
|
||||
@ -46,14 +46,14 @@ class UsersController extends AbstractController
|
||||
|
||||
// Ensure no required data is missing
|
||||
if (!$data->hasMultiple(['username', 'fullname', 'password', 'email', 'language'])) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.cannot-create.var-missing'), 'error');
|
||||
return $this->admin()->redirect('/users/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.cannot-create.var-missing'), 'error');
|
||||
return $this->panel()->redirect('/users/');
|
||||
}
|
||||
|
||||
// Ensure there isn't a user with the same username
|
||||
if ($this->admin()->users()->has($data->get('username'))) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.cannot-create.already-exists'), 'error');
|
||||
return $this->admin()->redirect('/users/');
|
||||
if ($this->panel()->users()->has($data->get('username'))) {
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.cannot-create.already-exists'), 'error');
|
||||
return $this->panel()->redirect('/users/');
|
||||
}
|
||||
|
||||
$userData = [
|
||||
@ -64,10 +64,10 @@ class UsersController extends AbstractController
|
||||
'language' => $data->get('language')
|
||||
];
|
||||
|
||||
YAML::encodeToFile($userData, Formwork::instance()->config()->get('admin.paths.accounts') . $data->get('username') . '.yml');
|
||||
YAML::encodeToFile($userData, Formwork::instance()->config()->get('panel.paths.accounts') . $data->get('username') . '.yml');
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.created'), 'success');
|
||||
return $this->admin()->redirect('/users/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.created'), 'success');
|
||||
return $this->panel()->redirect('/users/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -77,11 +77,11 @@ class UsersController extends AbstractController
|
||||
{
|
||||
$this->ensurePermission('users.delete');
|
||||
|
||||
$user = $this->admin()->users()->get($params->get('user'));
|
||||
$user = $this->panel()->users()->get($params->get('user'));
|
||||
|
||||
try {
|
||||
if (!$user) {
|
||||
throw new TranslatedException(sprintf('User "%s" not found', $params->get('user')), 'admin.users.user.not-found');
|
||||
throw new TranslatedException(sprintf('User "%s" not found', $params->get('user')), 'panel.users.user.not-found');
|
||||
}
|
||||
if (!$this->user()->canDeleteUser($user)) {
|
||||
throw new TranslatedException(
|
||||
@ -89,20 +89,20 @@ class UsersController extends AbstractController
|
||||
'users.user.cannot-delete'
|
||||
);
|
||||
}
|
||||
FileSystem::delete(Formwork::instance()->config()->get('admin.paths.accounts') . $user->username() . '.yml');
|
||||
FileSystem::delete(Formwork::instance()->config()->get('panel.paths.accounts') . $user->username() . '.yml');
|
||||
$this->deleteAvatar($user);
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($e->getTranslatedMessage(), 'error');
|
||||
return $this->admin()->redirectToReferer(302, '/users/');
|
||||
$this->panel()->notify($e->getTranslatedMessage(), 'error');
|
||||
return $this->panel()->redirectToReferer(302, '/users/');
|
||||
}
|
||||
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('admin.paths.logs') . 'lastAccess.json');
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('panel.paths.logs') . 'lastAccess.json');
|
||||
|
||||
// Remove user last access from registry
|
||||
$lastAccessRegistry->remove($user->username());
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.deleted'), 'success');
|
||||
return $this->admin()->redirect('/users/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.deleted'), 'success');
|
||||
return $this->panel()->redirect('/users/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -110,15 +110,15 @@ class UsersController extends AbstractController
|
||||
*/
|
||||
public function profile(RouteParams $params): Response
|
||||
{
|
||||
$scheme = Formwork::instance()->schemes()->get('admin', 'user');
|
||||
$scheme = Formwork::instance()->schemes()->get('panel', 'user');
|
||||
|
||||
$fields = $scheme->fields();
|
||||
|
||||
$user = $this->admin()->users()->get($params->get('user'));
|
||||
$user = $this->panel()->users()->get($params->get('user'));
|
||||
|
||||
if ($user === null) {
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.not-found'), 'error');
|
||||
return $this->admin()->redirect('/users/');
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.not-found'), 'error');
|
||||
return $this->panel()->redirect('/users/');
|
||||
}
|
||||
|
||||
// Disable password and/or role fields if they cannot be changed
|
||||
@ -132,15 +132,15 @@ class UsersController extends AbstractController
|
||||
$fields->validate($data);
|
||||
try {
|
||||
$this->updateUser($user, $data);
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.edited'), 'success');
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.edited'), 'success');
|
||||
} catch (TranslatedException $e) {
|
||||
$this->admin()->notify($this->admin()->translate($e->getLanguageString(), $user->username()), 'error');
|
||||
$this->panel()->notify($this->panel()->translate($e->getLanguageString(), $user->username()), 'error');
|
||||
}
|
||||
} else {
|
||||
$this->admin()->notify($this->admin()->translate('admin.users.user.cannot-edit', $user->username()), 'error');
|
||||
$this->panel()->notify($this->panel()->translate('panel.users.user.cannot-edit', $user->username()), 'error');
|
||||
}
|
||||
|
||||
return $this->admin()->redirect('/users/' . $user->username() . '/profile/');
|
||||
return $this->panel()->redirect('/users/' . $user->username() . '/profile/');
|
||||
}
|
||||
|
||||
$fields = $fields->validate($user);
|
||||
@ -150,7 +150,7 @@ class UsersController extends AbstractController
|
||||
$this->modal('deleteUser');
|
||||
|
||||
return new Response($this->view('users.profile', [
|
||||
'title' => $this->admin()->translate('admin.users.user-profile', $user->username()),
|
||||
'title' => $this->panel()->translate('panel.users.user-profile', $user->username()),
|
||||
'user' => $user,
|
||||
'fields' => $fields
|
||||
], true));
|
||||
@ -167,7 +167,7 @@ class UsersController extends AbstractController
|
||||
if (!empty($data['password'])) {
|
||||
// Ensure that password can be changed
|
||||
if (!$this->user()->canChangePasswordOf($user)) {
|
||||
throw new TranslatedException(sprintf('Cannot change the password of %s', $user->username()), 'admin.users.user.cannot-change-password');
|
||||
throw new TranslatedException(sprintf('Cannot change the password of %s', $user->username()), 'panel.users.user.cannot-change-password');
|
||||
}
|
||||
|
||||
// Hash the new password
|
||||
@ -179,7 +179,7 @@ class UsersController extends AbstractController
|
||||
|
||||
// Ensure that user role can be changed
|
||||
if (($data['role'] ?? $user->role()) !== $user->role() && !$this->user()->canChangeRoleOf($user)) {
|
||||
throw new TranslatedException(sprintf('Cannot change the role of %s', $user->username()), 'admin.users.user.cannot-change-role');
|
||||
throw new TranslatedException(sprintf('Cannot change the role of %s', $user->username()), 'panel.users.user.cannot-change-role');
|
||||
}
|
||||
|
||||
// Handle incoming files
|
||||
@ -190,7 +190,7 @@ class UsersController extends AbstractController
|
||||
// Filter empty elements from $data and merge them with $user ones
|
||||
$userData = array_merge($user->toArray(), $data);
|
||||
|
||||
YAML::encodeToFile($userData, Formwork::instance()->config()->get('admin.paths.accounts') . $user->username() . '.yml');
|
||||
YAML::encodeToFile($userData, Formwork::instance()->config()->get('panel.paths.accounts') . $user->username() . '.yml');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -198,7 +198,7 @@ class UsersController extends AbstractController
|
||||
*/
|
||||
protected function uploadAvatar(User $user): ?string
|
||||
{
|
||||
$avatarsPath = ADMIN_PATH . 'avatars' . DS;
|
||||
$avatarsPath = PANEL_PATH . 'avatars' . DS;
|
||||
|
||||
$uploader = new Uploader(
|
||||
$avatarsPath,
|
||||
@ -210,7 +210,7 @@ class UsersController extends AbstractController
|
||||
$hasUploaded = $uploader->upload(FileSystem::randomName());
|
||||
|
||||
if ($hasUploaded) {
|
||||
$avatarSize = Formwork::instance()->config()->get('admin.avatar_size');
|
||||
$avatarSize = Formwork::instance()->config()->get('panel.avatar_size');
|
||||
|
||||
// Square off uploaded avatar
|
||||
$image = new Image($avatarsPath . $uploader->uploadedFiles()[0]);
|
||||
@ -219,7 +219,7 @@ class UsersController extends AbstractController
|
||||
// Delete old avatar
|
||||
$this->deleteAvatar($user);
|
||||
|
||||
$this->admin()->notify($this->admin()->translate('admin.user.avatar.uploaded'), 'success');
|
||||
$this->panel()->notify($this->panel()->translate('panel.user.avatar.uploaded'), 'success');
|
||||
return $uploader->uploadedFiles()[0];
|
||||
}
|
||||
}
|
@ -1,10 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin;
|
||||
namespace Formwork\Panel;
|
||||
|
||||
use Formwork\Admin\Controllers\ErrorsController;
|
||||
use Formwork\Admin\Users\User;
|
||||
use Formwork\Admin\Users\Users;
|
||||
use Formwork\Panel\Controllers\ErrorsController;
|
||||
use Formwork\Panel\Users\User;
|
||||
use Formwork\Panel\Users\Users;
|
||||
use Formwork\Assets;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Languages\LanguageCodes;
|
||||
@ -18,7 +18,7 @@ use Formwork\Utils\Str;
|
||||
use Formwork\Utils\Uri;
|
||||
use Throwable;
|
||||
|
||||
final class Admin
|
||||
final class Panel
|
||||
{
|
||||
/**
|
||||
* All the registered users
|
||||
@ -36,7 +36,7 @@ final class Admin
|
||||
protected Assets $assets;
|
||||
|
||||
/**
|
||||
* Create a new Admin instance
|
||||
* Create a new Panel instance
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
@ -86,11 +86,11 @@ final class Admin
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a URI relative to the real Admin root
|
||||
* Return a URI relative to the real Panel root
|
||||
*/
|
||||
public function realUri(string $route): string
|
||||
{
|
||||
return HTTPRequest::root() . 'admin/' . ltrim($route, '/');
|
||||
return HTTPRequest::root() . 'panel/' . ltrim($route, '/');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -106,7 +106,7 @@ final class Admin
|
||||
*/
|
||||
public function panelRoot(): string
|
||||
{
|
||||
return Uri::normalize(Formwork::instance()->config()->get('admin.root'));
|
||||
return Uri::normalize(Formwork::instance()->config()->get('panel.root'));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -218,7 +218,7 @@ final class Admin
|
||||
if (isset($this->assets)) {
|
||||
return $this->assets;
|
||||
}
|
||||
return $this->assets = new Assets(ADMIN_PATH . 'assets' . DS, Formwork::instance()->admin()->realUri('/assets/'));
|
||||
return $this->assets = new Assets(PANEL_PATH . 'assets' . DS, Formwork::instance()->panel()->realUri('/assets/'));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -232,7 +232,7 @@ final class Admin
|
||||
return $translations;
|
||||
}
|
||||
|
||||
$path = Formwork::instance()->config()->get('translations.paths.admin');
|
||||
$path = Formwork::instance()->config()->get('translations.paths.panel');
|
||||
|
||||
foreach (FileSystem::listFiles($path) as $file) {
|
||||
if (FileSystem::extension($file) === 'yml') {
|
||||
@ -251,7 +251,7 @@ final class Admin
|
||||
*/
|
||||
protected function loadTranslations(): void
|
||||
{
|
||||
$path = Formwork::instance()->config()->get('translations.paths.admin');
|
||||
$path = Formwork::instance()->config()->get('translations.paths.panel');
|
||||
Formwork::instance()->translations()->loadFromPath($path);
|
||||
|
||||
if ($this->isLoggedIn()) {
|
||||
@ -261,8 +261,8 @@ final class Admin
|
||||
|
||||
protected function loadSchemes(): void
|
||||
{
|
||||
$path = Formwork::instance()->config()->get('schemes.paths.admin');
|
||||
Formwork::instance()->schemes()->loadFromPath('admin', $path);
|
||||
$path = Formwork::instance()->config()->get('schemes.paths.panel');
|
||||
Formwork::instance()->schemes()->loadFromPath('panel', $path);
|
||||
}
|
||||
|
||||
/**
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Security;
|
||||
namespace Formwork\Panel\Security;
|
||||
|
||||
use Formwork\Utils\HTTPRequest;
|
||||
use Formwork\Utils\Registry;
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Security;
|
||||
namespace Formwork\Panel\Security;
|
||||
|
||||
use Formwork\Traits\StaticClass;
|
||||
use Formwork\Utils\HTTPRequest;
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Security;
|
||||
namespace Formwork\Panel\Security;
|
||||
|
||||
use Formwork\Traits\StaticClass;
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin;
|
||||
namespace Formwork\Panel;
|
||||
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Utils\Date;
|
||||
@ -67,7 +67,7 @@ class Statistics
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
$base = Formwork::instance()->config()->get('admin.paths.logs') . 'statistics' . DS;
|
||||
$base = Formwork::instance()->config()->get('panel.paths.logs') . 'statistics' . DS;
|
||||
|
||||
if (!FileSystem::exists($base)) {
|
||||
FileSystem::createDirectory($base);
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin;
|
||||
namespace Formwork\Panel;
|
||||
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Parsers\JSON;
|
||||
@ -90,14 +90,14 @@ class Updater
|
||||
return [
|
||||
'time' => 900,
|
||||
'force' => false,
|
||||
'registryFile' => Formwork::instance()->config()->get('admin.paths.logs') . 'updates.json',
|
||||
'registryFile' => Formwork::instance()->config()->get('panel.paths.logs') . 'updates.json',
|
||||
'tempFile' => ROOT_PATH . '.formwork-update.zip',
|
||||
'preferDistAssets' => false,
|
||||
'cleanupAfterInstall' => false,
|
||||
'ignore' => [
|
||||
'admin/accounts/*',
|
||||
'admin/avatars/*',
|
||||
'admin/logs/*',
|
||||
'panel/accounts/*',
|
||||
'panel/avatars/*',
|
||||
'panel/logs/*',
|
||||
'assets/*',
|
||||
'backup/*',
|
||||
'cache/*',
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin;
|
||||
namespace Formwork\Panel;
|
||||
|
||||
use Formwork\Exceptions\TranslatedException;
|
||||
use Formwork\Formwork;
|
||||
@ -27,13 +27,13 @@ class Uploader
|
||||
* Uploader errors language strings
|
||||
*/
|
||||
protected const ERROR_LANGUAGE_STRINGS = [
|
||||
UPLOAD_ERR_INI_SIZE => 'admin.uploader.error.size',
|
||||
UPLOAD_ERR_FORM_SIZE => 'admin.uploader.error.size',
|
||||
UPLOAD_ERR_PARTIAL => 'admin.uploader.error.partial',
|
||||
UPLOAD_ERR_NO_FILE => 'admin.uploader.error.no-file',
|
||||
UPLOAD_ERR_NO_TMP_DIR => 'admin.uploader.error.no-temp',
|
||||
UPLOAD_ERR_CANT_WRITE => 'admin.uploader.error.cannot-write',
|
||||
UPLOAD_ERR_EXTENSION => 'admin.uploader.error.php-extension'
|
||||
UPLOAD_ERR_INI_SIZE => 'panel.uploader.error.size',
|
||||
UPLOAD_ERR_FORM_SIZE => 'panel.uploader.error.size',
|
||||
UPLOAD_ERR_PARTIAL => 'panel.uploader.error.partial',
|
||||
UPLOAD_ERR_NO_FILE => 'panel.uploader.error.no-file',
|
||||
UPLOAD_ERR_NO_TMP_DIR => 'panel.uploader.error.no-temp',
|
||||
UPLOAD_ERR_CANT_WRITE => 'panel.uploader.error.cannot-write',
|
||||
UPLOAD_ERR_EXTENSION => 'panel.uploader.error.php-extension'
|
||||
];
|
||||
|
||||
/**
|
||||
@ -130,11 +130,11 @@ class Uploader
|
||||
$mimeType = FileSystem::mimeType($source);
|
||||
|
||||
if (!$this->isAllowedMimeType($mimeType)) {
|
||||
throw new TranslatedException(sprintf('MIME type %s is not allowed', $mimeType), 'admin.uploader.error.mime-type');
|
||||
throw new TranslatedException(sprintf('MIME type %s is not allowed', $mimeType), 'panel.uploader.error.mime-type');
|
||||
}
|
||||
|
||||
if (basename($filename)[0] === '.') {
|
||||
throw new TranslatedException(sprintf('Hidden file "%s" not allowed', $filename), 'admin.uploader.error.hidden-files');
|
||||
throw new TranslatedException(sprintf('Hidden file "%s" not allowed', $filename), 'panel.uploader.error.hidden-files');
|
||||
}
|
||||
|
||||
$name = str_replace([' ', '.'], '-', FileSystem::name($filename));
|
||||
@ -147,21 +147,21 @@ class Uploader
|
||||
$filename = $name . '.' . $extension;
|
||||
|
||||
if (strlen($filename) > FileSystem::MAX_NAME_LENGTH) {
|
||||
throw new TranslatedException('File name too long', 'admin.uploader.error.file-name-too-long');
|
||||
throw new TranslatedException('File name too long', 'panel.uploader.error.file-name-too-long');
|
||||
}
|
||||
|
||||
if (!(bool) preg_match('/^[a-z0-9_-]+(?:\.[a-z0-9]+)?$/i', $filename)) {
|
||||
throw new TranslatedException(sprintf('Invalid file name "%s"', $filename), 'admin.uploader.error.file-name');
|
||||
throw new TranslatedException(sprintf('Invalid file name "%s"', $filename), 'panel.uploader.error.file-name');
|
||||
}
|
||||
|
||||
$destinationPath = FileSystem::joinPaths($destination, $filename);
|
||||
|
||||
if (strlen($destinationPath) > FileSystem::MAX_PATH_LENGTH) {
|
||||
throw new TranslatedException('Destination path too long', 'admin.uploader.error.destination-too-long');
|
||||
throw new TranslatedException('Destination path too long', 'panel.uploader.error.destination-too-long');
|
||||
}
|
||||
|
||||
if (!$this->options['overwrite'] && FileSystem::exists($destinationPath)) {
|
||||
throw new TranslatedException(sprintf('File "%s" already exists', $filename), 'admin.uploader.error.already-exists');
|
||||
throw new TranslatedException(sprintf('File "%s" already exists', $filename), 'panel.uploader.error.already-exists');
|
||||
}
|
||||
|
||||
if (@move_uploaded_file($source, $destinationPath)) {
|
||||
@ -169,7 +169,7 @@ class Uploader
|
||||
return true;
|
||||
}
|
||||
|
||||
throw new TranslatedException('Cannot move uploaded file to destination', 'admin.uploader.error.cannot-move-to-destination');
|
||||
throw new TranslatedException('Cannot move uploaded file to destination', 'panel.uploader.error.cannot-move-to-destination');
|
||||
|
||||
return false;
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Users;
|
||||
namespace Formwork\Panel\Users;
|
||||
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Utils\FileSystem;
|
||||
@ -27,12 +27,12 @@ class Avatar
|
||||
*/
|
||||
public function __construct(?string $filename)
|
||||
{
|
||||
$path = ADMIN_PATH . 'avatars/' . $filename;
|
||||
$path = PANEL_PATH . 'avatars/' . $filename;
|
||||
if ($filename !== null && FileSystem::exists($path)) {
|
||||
$this->uri = Formwork::instance()->admin()->realUri('/avatars/' . basename($path));
|
||||
$this->uri = Formwork::instance()->panel()->realUri('/avatars/' . basename($path));
|
||||
$this->path = $path;
|
||||
} else {
|
||||
$this->uri = Formwork::instance()->admin()->realUri(self::DEFAULT_AVATAR_URI);
|
||||
$this->uri = Formwork::instance()->panel()->realUri(self::DEFAULT_AVATAR_URI);
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Users;
|
||||
namespace Formwork\Panel\Users;
|
||||
|
||||
use Formwork\Utils\Str;
|
||||
|
@ -1,8 +1,8 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Users;
|
||||
namespace Formwork\Panel\Users;
|
||||
|
||||
use Formwork\Admin\Security\Password;
|
||||
use Formwork\Panel\Security\Password;
|
||||
use Formwork\Data\Contracts\Arrayable;
|
||||
use Formwork\Formwork;
|
||||
use Formwork\Utils\Registry;
|
||||
@ -164,11 +164,11 @@ class User implements Arrayable
|
||||
}
|
||||
|
||||
/**
|
||||
* Return whether the user has 'admin' role
|
||||
* Return whether the user has 'panel' role
|
||||
*/
|
||||
public function isAdmin(): bool
|
||||
public function isPanel(): bool
|
||||
{
|
||||
return $this->role === 'admin';
|
||||
return $this->role === 'panel';
|
||||
}
|
||||
|
||||
/**
|
||||
@ -176,7 +176,7 @@ class User implements Arrayable
|
||||
*/
|
||||
public function canDeleteUser(User $user): bool
|
||||
{
|
||||
return $this->isAdmin() && !$user->isLogged();
|
||||
return $this->isPanel() && !$user->isLogged();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -184,7 +184,7 @@ class User implements Arrayable
|
||||
*/
|
||||
public function canChangeOptionsOf(User $user): bool
|
||||
{
|
||||
return $this->isAdmin() || $user->isLogged();
|
||||
return $this->isPanel() || $user->isLogged();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -192,7 +192,7 @@ class User implements Arrayable
|
||||
*/
|
||||
public function canChangePasswordOf(User $user): bool
|
||||
{
|
||||
return $this->isAdmin() || $user->isLogged();
|
||||
return $this->isPanel() || $user->isLogged();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -200,7 +200,7 @@ class User implements Arrayable
|
||||
*/
|
||||
public function canChangeRoleOf(User $user): bool
|
||||
{
|
||||
return $this->isAdmin() && !$user->isLogged();
|
||||
return $this->isPanel() && !$user->isLogged();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -211,7 +211,7 @@ class User implements Arrayable
|
||||
if (isset($this->lastAccess)) {
|
||||
return $this->lastAccess;
|
||||
}
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('admin.paths.logs') . 'lastAccess.json');
|
||||
$lastAccessRegistry = new Registry(Formwork::instance()->config()->get('panel.paths.logs') . 'lastAccess.json');
|
||||
$lastAccess = (int) $lastAccessRegistry->get($this->username);
|
||||
return $this->lastAccess = $lastAccess ?: null;
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Users;
|
||||
namespace Formwork\Panel\Users;
|
||||
|
||||
use Formwork\Data\AbstractCollection;
|
||||
use Formwork\Formwork;
|
||||
@ -23,10 +23,10 @@ class Users extends AbstractCollection
|
||||
*/
|
||||
public static function load(): self
|
||||
{
|
||||
static::$roles = Formwork::instance()->schemes()->get('admin', 'roles')->get('data');
|
||||
static::$roles = Formwork::instance()->schemes()->get('panel', 'roles')->get('data');
|
||||
$users = [];
|
||||
foreach (FileSystem::listFiles(Formwork::instance()->config()->get('admin.paths.accounts')) as $file) {
|
||||
$parsedData = YAML::parseFile(Formwork::instance()->config()->get('admin.paths.accounts') . $file);
|
||||
foreach (FileSystem::listFiles(Formwork::instance()->config()->get('panel.paths.accounts')) as $file) {
|
||||
$parsedData = YAML::parseFile(Formwork::instance()->config()->get('panel.paths.accounts') . $file);
|
||||
$users[$parsedData['username']] = new User($parsedData);
|
||||
}
|
||||
return new static($users);
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Formwork\Admin\Utils;
|
||||
namespace Formwork\Panel\Utils;
|
||||
|
||||
use Formwork\Traits\StaticClass;
|
||||
use Formwork\Utils\Date;
|
@ -113,7 +113,7 @@ class Session
|
||||
'httponly' => true,
|
||||
'samesite' => Cookie::SAMESITE_STRICT
|
||||
];
|
||||
if (($timeout = Formwork::instance()->config()->get('admin.session_timeout')) > 0) {
|
||||
if (($timeout = Formwork::instance()->config()->get('panel.session_timeout')) > 0) {
|
||||
$options['expires'] = time() + $timeout * 60;
|
||||
}
|
||||
return $options;
|
||||
|
0
admin/.gitignore → panel/.gitignore
vendored
Before Width: | Height: | Size: 755 B After Width: | Height: | Size: 755 B |
Before Width: | Height: | Size: 353 B After Width: | Height: | Size: 353 B |
Before Width: | Height: | Size: 437 B After Width: | Height: | Size: 437 B |
Before Width: | Height: | Size: 352 B After Width: | Height: | Size: 352 B |
Before Width: | Height: | Size: 412 B After Width: | Height: | Size: 412 B |
Before Width: | Height: | Size: 441 B After Width: | Height: | Size: 441 B |
Before Width: | Height: | Size: 346 B After Width: | Height: | Size: 346 B |
Before Width: | Height: | Size: 350 B After Width: | Height: | Size: 350 B |
Before Width: | Height: | Size: 469 B After Width: | Height: | Size: 469 B |
Before Width: | Height: | Size: 356 B After Width: | Height: | Size: 356 B |
Before Width: | Height: | Size: 595 B After Width: | Height: | Size: 595 B |
Before Width: | Height: | Size: 355 B After Width: | Height: | Size: 355 B |
Before Width: | Height: | Size: 350 B After Width: | Height: | Size: 350 B |
Before Width: | Height: | Size: 687 B After Width: | Height: | Size: 687 B |
Before Width: | Height: | Size: 401 B After Width: | Height: | Size: 401 B |
Before Width: | Height: | Size: 345 B After Width: | Height: | Size: 345 B |
Before Width: | Height: | Size: 607 B After Width: | Height: | Size: 607 B |
Before Width: | Height: | Size: 622 B After Width: | Height: | Size: 622 B |
Before Width: | Height: | Size: 1013 B After Width: | Height: | Size: 1013 B |
Before Width: | Height: | Size: 691 B After Width: | Height: | Size: 691 B |
Before Width: | Height: | Size: 533 B After Width: | Height: | Size: 533 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 574 B After Width: | Height: | Size: 574 B |
Before Width: | Height: | Size: 531 B After Width: | Height: | Size: 531 B |
Before Width: | Height: | Size: 413 B After Width: | Height: | Size: 413 B |
Before Width: | Height: | Size: 463 B After Width: | Height: | Size: 463 B |
Before Width: | Height: | Size: 290 B After Width: | Height: | Size: 290 B |
Before Width: | Height: | Size: 289 B After Width: | Height: | Size: 289 B |
Before Width: | Height: | Size: 289 B After Width: | Height: | Size: 289 B |
Before Width: | Height: | Size: 288 B After Width: | Height: | Size: 288 B |
Before Width: | Height: | Size: 289 B After Width: | Height: | Size: 289 B |
Before Width: | Height: | Size: 165 B After Width: | Height: | Size: 165 B |
Before Width: | Height: | Size: 246 B After Width: | Height: | Size: 246 B |
Before Width: | Height: | Size: 246 B After Width: | Height: | Size: 246 B |
Before Width: | Height: | Size: 535 B After Width: | Height: | Size: 535 B |
Before Width: | Height: | Size: 535 B After Width: | Height: | Size: 535 B |
Before Width: | Height: | Size: 393 B After Width: | Height: | Size: 393 B |
Before Width: | Height: | Size: 952 B After Width: | Height: | Size: 952 B |
Before Width: | Height: | Size: 950 B After Width: | Height: | Size: 950 B |
Before Width: | Height: | Size: 693 B After Width: | Height: | Size: 693 B |
Before Width: | Height: | Size: 412 B After Width: | Height: | Size: 412 B |
Before Width: | Height: | Size: 653 B After Width: | Height: | Size: 653 B |
Before Width: | Height: | Size: 462 B After Width: | Height: | Size: 462 B |
Before Width: | Height: | Size: 491 B After Width: | Height: | Size: 491 B |
Before Width: | Height: | Size: 257 B After Width: | Height: | Size: 257 B |
Before Width: | Height: | Size: 585 B After Width: | Height: | Size: 585 B |
Before Width: | Height: | Size: 701 B After Width: | Height: | Size: 701 B |
Before Width: | Height: | Size: 763 B After Width: | Height: | Size: 763 B |
Before Width: | Height: | Size: 672 B After Width: | Height: | Size: 672 B |
Before Width: | Height: | Size: 785 B After Width: | Height: | Size: 785 B |
Before Width: | Height: | Size: 512 B After Width: | Height: | Size: 512 B |
Before Width: | Height: | Size: 710 B After Width: | Height: | Size: 710 B |
Before Width: | Height: | Size: 585 B After Width: | Height: | Size: 585 B |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |