From 4b82368e16ef31a3d24dadc09d6b5c9e75caf2af Mon Sep 17 00:00:00 2001 From: Stuart Laverick Date: Tue, 7 Nov 2023 12:39:50 +0000 Subject: [PATCH] Added environment flag to hide help section --- .env.example | 1 + .eslintrc.js | 8 +- babel.config.js | 8 +- jest.config.js | 8 +- package-lock.json | 4 +- postcss.config.js | 4 +- src/App.vue | 41 +- src/classes/Auth.js | 23 +- src/classes/Errors.js | 2 +- src/classes/Form.js | 4 +- src/classes/MarkdownConverter.js | 8 +- src/components/Ck/CkBannerInput.vue | 18 +- src/components/Ck/CkCallToAction.vue | 10 +- src/components/Ck/CkCarousel.vue | 10 +- src/components/Ck/CkCharacterCount.vue | 8 +- src/components/Ck/CkCharacterCountBar.vue | 10 +- src/components/Ck/CkCharacterCountGroup.vue | 2 +- src/components/Ck/CkCollectionInput.vue | 24 +- src/components/Ck/CkDateInput.vue | 18 +- src/components/Ck/CkDatePicker.vue | 32 +- src/components/Ck/CkFileInput.vue | 24 +- src/components/Ck/CkImageInput.vue | 24 +- src/components/Ck/CkLocationInput.vue | 48 +- src/components/Ck/CkNodeCheckboxes.vue | 18 +- src/components/Ck/CkPagination.vue | 12 +- src/components/Ck/CkRadioInput.vue | 18 +- src/components/Ck/CkResourceListingTable.vue | 26 +- src/components/Ck/CkSelectInput.vue | 22 +- src/components/Ck/CkSocialMediasInput.vue | 22 +- src/components/Ck/CkTableFilters.vue | 8 +- src/components/Ck/CkTaxonomyInput.vue | 38 +- src/components/Ck/CkTaxonomyList.vue | 20 +- src/components/Ck/CkTaxonomyTree.vue | 18 +- src/components/Ck/CkTextInput.vue | 20 +- src/components/Ck/CkTextareaInput.vue | 18 +- src/components/Ck/CkTimePeriodInput.vue | 18 +- src/components/Ck/CkTreeList.vue | 16 +- src/components/Ck/CkWysiwygInput.vue | 28 +- src/components/CkAuditDetails.vue | 8 +- src/components/CkCode.vue | 2 +- src/components/CkDeleteButton.vue | 12 +- src/components/CkEnvironmentWarning.vue | 4 +- src/components/CkLoader.vue | 4 +- src/components/CkNotificationDetails.vue | 16 +- src/components/CkNotificationsTable.vue | 18 +- src/components/CkOrganisationDetails.vue | 18 +- src/components/CkPageContent.vue | 22 +- src/components/CkPageFeedbackDetails.vue | 8 +- src/components/CkReferralDetails.vue | 25 +- src/components/CkServiceLocationsTable.vue | 8 +- src/components/CkThesaurusList.vue | 6 +- src/components/CkUserDetails.vue | 18 +- src/components/CkWysiwyg.vue | 22 +- src/components/Gov/GovBackLink.vue | 6 +- src/components/Gov/GovBody.vue | 10 +- src/components/Gov/GovButton.vue | 30 +- src/components/Gov/GovCaption.vue | 8 +- src/components/Gov/GovCheckbox.vue | 16 +- src/components/Gov/GovCheckboxes.vue | 2 +- src/components/Gov/GovDetails.vue | 6 +- src/components/Gov/GovErrorMessage.vue | 8 +- src/components/Gov/GovErrorSummary.vue | 6 +- src/components/Gov/GovFieldsetLegend.vue | 8 +- src/components/Gov/GovFileUpload.vue | 16 +- src/components/Gov/GovFooter.vue | 12 +- src/components/Gov/GovFormGroup.vue | 6 +- src/components/Gov/GovGridColumn.vue | 8 +- src/components/Gov/GovGridRow.vue | 2 +- src/components/Gov/GovHeader.vue | 14 +- src/components/Gov/GovHeading.vue | 10 +- src/components/Gov/GovHint.vue | 8 +- src/components/Gov/GovInput.vue | 22 +- src/components/Gov/GovInsetText.vue | 2 +- src/components/Gov/GovLabel.vue | 2 +- src/components/Gov/GovLink.vue | 10 +- src/components/Gov/GovList.vue | 8 +- src/components/Gov/GovMainWrapper.vue | 2 +- src/components/Gov/GovRadio.vue | 18 +- src/components/Gov/GovRadios.vue | 6 +- src/components/Gov/GovSectionBreak.vue | 12 +- src/components/Gov/GovSelect.vue | 16 +- src/components/Gov/GovSkipLink.vue | 6 +- src/components/Gov/GovTabPanel.vue | 2 +- src/components/Gov/GovTable.vue | 2 +- src/components/Gov/GovTableCell.vue | 14 +- src/components/Gov/GovTableHeader.vue | 16 +- src/components/Gov/GovTableRow.vue | 2 +- src/components/Gov/GovTabs.vue | 18 +- src/components/Gov/GovTag.vue | 2 +- src/components/Gov/GovTextarea.vue | 16 +- src/components/Gov/GovWarningText.vue | 6 +- src/components/Gov/GovWidthContainer.vue | 2 +- src/components/SpreadsheetImportErrors.vue | 20 +- src/components/SpreadsheetImportForm.vue | 14 +- src/http.js | 10 +- src/main.js | 23 +- src/router.js | 252 ++- src/storage/countries.js | 28 +- src/storage/icons.js | 1624 ++++++++--------- src/views/Dashboard.vue | 10 +- src/views/admin/Index.vue | 16 +- src/views/admin/index/AuditLogs.vue | 38 +- src/views/admin/index/Cms.vue | 32 +- src/views/admin/index/Collections.vue | 10 +- src/views/admin/index/Feedback.vue | 26 +- src/views/admin/index/Notifications.vue | 8 +- src/views/admin/index/SearchEngine.vue | 10 +- src/views/admin/index/Taxonomies.vue | 10 +- src/views/admin/index/cms/Updated.vue | 2 +- src/views/admin/index/cms/frontend/About.vue | 12 +- .../cms/frontend/AccessibilityStatement.vue | 12 +- src/views/admin/index/cms/frontend/Banner.vue | 16 +- .../admin/index/cms/frontend/Contact.vue | 12 +- .../admin/index/cms/frontend/Favourites.vue | 12 +- .../admin/index/cms/frontend/GetInvolved.vue | 12 +- src/views/admin/index/cms/frontend/Global.vue | 12 +- src/views/admin/index/cms/frontend/Home.vue | 16 +- .../index/cms/frontend/PrivacyPolicy.vue | 12 +- .../index/cms/frontend/TermsAndConditions.vue | 12 +- .../admin/index/collections/Categories.vue | 14 +- .../index/collections/CollectionListItem.vue | 12 +- src/views/admin/index/collections/Events.vue | 14 +- .../admin/index/collections/Personas.vue | 14 +- .../admin/index/search-engine/StopWords.vue | 8 +- .../admin/index/search-engine/Thesaurus.vue | 8 +- .../admin/index/taxonomies/Categories.vue | 20 +- .../admin/index/taxonomies/Organisations.vue | 8 +- .../index/taxonomies/ServiceEligibilities.vue | 12 +- src/views/audits/Show.vue | 6 +- src/views/auth/Login.vue | 8 +- src/views/auth/Logout.vue | 4 +- src/views/collections/categories/Create.vue | 8 +- src/views/collections/categories/Edit.vue | 10 +- .../categories/forms/CollectionForm.vue | 26 +- src/views/collections/events/Create.vue | 8 +- src/views/collections/events/Edit.vue | 14 +- .../events/forms/CollectionForm.vue | 24 +- .../inputs/CollectionEnabledInput.vue | 18 +- .../inputs/CollectionHomepageInput.vue | 14 +- .../collections/inputs/SideboxesInput.vue | 18 +- src/views/collections/personas/Create.vue | 8 +- src/views/collections/personas/Edit.vue | 10 +- .../personas/forms/CollectionForm.vue | 28 +- src/views/errors/404.vue | 2 +- src/views/events/Create.vue | 26 +- src/views/events/Edit.vue | 24 +- src/views/events/Index.vue | 28 +- src/views/events/Show.vue | 8 +- src/views/events/Updated.vue | 8 +- src/views/events/forms/DetailsTab.vue | 84 +- src/views/events/forms/TaxonomiesTab.vue | 10 +- .../events/inputs/EventHomepageInput.vue | 14 +- src/views/events/show/EventDetails.vue | 10 +- src/views/help/Index.vue | 19 +- src/views/help/components/VideoIframe.vue | 18 +- src/views/locations/Create.vue | 10 +- src/views/locations/Edit.vue | 12 +- src/views/locations/Index.vue | 22 +- src/views/locations/Show.vue | 6 +- src/views/locations/Updated.vue | 8 +- src/views/locations/forms/LocationForm.vue | 32 +- src/views/locations/show/LocationDetails.vue | 6 +- src/views/notifications/Show.vue | 16 +- src/views/organisations/Create.vue | 20 +- src/views/organisations/Edit.vue | 28 +- src/views/organisations/Import.vue | 28 +- src/views/organisations/Index.vue | 26 +- src/views/organisations/OrganisationTab.vue | 8 +- src/views/organisations/Show.vue | 8 +- src/views/organisations/Updated.vue | 10 +- .../organisations/forms/OrganisationForm.vue | 26 +- src/views/page-feedbacks/Show.vue | 16 +- src/views/pages/Create.vue | 57 +- src/views/pages/Edit.vue | 14 +- src/views/pages/Index.vue | 2 +- src/views/pages/List.vue | 36 +- src/views/pages/Show.vue | 12 +- src/views/pages/Updated.vue | 10 +- src/views/pages/forms/PageForm.vue | 56 +- src/views/pages/show/PageContent.vue | 10 +- src/views/referrals/Confirmation.vue | 6 +- src/views/referrals/Index.vue | 47 +- src/views/referrals/Show.vue | 20 +- src/views/register/Index.vue | 16 +- src/views/register/Search.vue | 14 +- src/views/register/existing/Information.vue | 4 +- src/views/register/existing/User.vue | 16 +- .../register/forms/AdditionalInfoTab.vue | 30 +- src/views/register/forms/DescriptionTab.vue | 14 +- src/views/register/forms/DetailsTab.vue | 16 +- .../register/forms/OrganisationSearch.vue | 16 +- src/views/register/forms/UsefulInfoTab.vue | 10 +- src/views/register/forms/UserAccount.vue | 10 +- src/views/register/forms/WhoForTab.vue | 48 +- src/views/register/new/Criteria.vue | 14 +- src/views/register/new/Information.vue | 4 +- src/views/register/new/Organisation.vue | 12 +- src/views/register/new/Register.vue | 20 +- src/views/register/new/Service.vue | 32 +- src/views/register/new/User.vue | 16 +- src/views/reports/Edit.vue | 73 +- src/views/reports/Index.vue | 8 +- src/views/reports/View.vue | 21 +- src/views/service-locations/Create.vue | 14 +- src/views/service-locations/Edit.vue | 20 +- src/views/service-locations/Show.vue | 12 +- src/views/service-locations/Updated.vue | 14 +- .../forms/ServiceLocationForm.vue | 110 +- .../show/ServiceLocationDetails.vue | 22 +- src/views/services/Create.vue | 38 +- src/views/services/Edit.vue | 50 +- src/views/services/Import.vue | 18 +- src/views/services/Index.vue | 34 +- src/views/services/PostCreate.vue | 12 +- src/views/services/Refresh.vue | 14 +- src/views/services/Show.vue | 18 +- src/views/services/Updated.vue | 8 +- .../services/forms/AdditionalInfoTab.vue | 46 +- src/views/services/forms/DescriptionTab.vue | 20 +- src/views/services/forms/DetailsTab.vue | 64 +- src/views/services/forms/EligibilityTab.vue | 18 +- src/views/services/forms/ReferralTab.vue | 34 +- src/views/services/forms/TaxonomiesTab.vue | 14 +- src/views/services/forms/UsefulInfoTab.vue | 10 +- src/views/services/inputs/CriteriaInput.vue | 20 +- .../services/inputs/GalleryItemsInput.vue | 20 +- src/views/services/inputs/IsClosedInput.vue | 12 +- src/views/services/inputs/OfferingsInput.vue | 18 +- .../inputs/ServiceEligibilityInput.vue | 37 +- src/views/services/inputs/TagInput.vue | 26 +- .../services/inputs/UsefulInfosInput.vue | 26 +- src/views/services/show/AdditionalInfoTab.vue | 8 +- src/views/services/show/ContactInfoTab.vue | 6 +- src/views/services/show/DetailsTab.vue | 18 +- src/views/services/show/EligibilityTab.vue | 14 +- src/views/services/show/LocationsTab.vue | 8 +- src/views/services/show/ReferralTab.vue | 8 +- src/views/services/show/UsefulInfoTab.vue | 8 +- src/views/stop-words/Edit.vue | 12 +- src/views/stop-words/forms/StopWordsForm.vue | 10 +- src/views/taxonomies/categories/Create.vue | 8 +- src/views/taxonomies/categories/Edit.vue | 8 +- .../categories/forms/TaxonomyForm.vue | 20 +- src/views/taxonomies/organisations/Create.vue | 8 +- src/views/taxonomies/organisations/Edit.vue | 8 +- .../organisations/forms/TaxonomyForm.vue | 12 +- .../service-eligibilities/Create.vue | 10 +- .../taxonomies/service-eligibilities/Edit.vue | 20 +- .../forms/ServiceEligibilityForm.vue | 22 +- src/views/thesaurus/Edit.vue | 16 +- src/views/thesaurus/forms/ThesaurusForm.vue | 10 +- src/views/update-requests/Index.vue | 32 +- src/views/update-requests/Show.vue | 32 +- .../update-requests/show/LocationDetails.vue | 16 +- .../show/OrganisationDetails.vue | 18 +- .../show/OrganisationEventDetails.vue | 36 +- .../show/OrganisationSignUpFormDetails.vue | 16 +- .../update-requests/show/PageDetails.vue | 36 +- .../update-requests/show/ServiceDetails.vue | 72 +- .../show/ServiceLocationDetails.vue | 36 +- src/views/users/Create.vue | 12 +- src/views/users/Edit.vue | 36 +- src/views/users/Index.vue | 38 +- src/views/users/Show.vue | 10 +- src/views/users/forms/UserForm.vue | 20 +- src/views/users/inputs/UserRolesInput.vue | 48 +- tests/e2e/custom-assertions/elementCount.js | 6 +- tests/e2e/specs/test.js | 4 +- tests/unit/.eslintrc.js | 6 +- tests/unit/HelloWorld.spec.js | 2 +- vue.config.js | 8 +- 271 files changed, 3245 insertions(+), 3186 deletions(-) diff --git a/.env.example b/.env.example index 77bb874f..81b4f7ad 100644 --- a/.env.example +++ b/.env.example @@ -10,6 +10,7 @@ VUE_APP_BUGSNAG_API_KEY= VUE_APP_CONTACT_EMAIL= VUE_APP_CQC_LOCATION_ACTIVE= VUE_APP_SERVICE_TAGS= +VUE_APP_HELP_SECTION=false VUE_APP_S3D_REGION=eu-west-2 VUE_APP_S3D_BUCKET= VUE_APP_S3D_ACL=private diff --git a/.eslintrc.js b/.eslintrc.js index 9b10e0ca..3f3df4f7 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,14 +1,14 @@ module.exports = { root: true, env: { - node: true, + node: true }, extends: ["plugin:vue/essential", "@vue/prettier"], rules: { "no-console": process.env.NODE_ENV === "production" ? "error" : "off", - "no-debugger": process.env.NODE_ENV === "production" ? "error" : "off", + "no-debugger": process.env.NODE_ENV === "production" ? "error" : "off" }, parserOptions: { - parser: "babel-eslint", - }, + parser: "babel-eslint" + } }; diff --git a/babel.config.js b/babel.config.js index 55296ea2..54c5b310 100644 --- a/babel.config.js +++ b/babel.config.js @@ -3,8 +3,8 @@ module.exports = { [ "@vue/app", { - useBuiltIns: "entry", - }, - ], - ], + useBuiltIns: "entry" + } + ] + ] }; diff --git a/jest.config.js b/jest.config.js index 271d4e03..d9814132 100644 --- a/jest.config.js +++ b/jest.config.js @@ -4,14 +4,14 @@ module.exports = { "^.+\\.vue$": "vue-jest", ".+\\.(css|styl|less|sass|scss|png|jpg|ttf|woff|woff2)$": "jest-transform-stub", - "^.+\\.jsx?$": "babel-jest", + "^.+\\.jsx?$": "babel-jest" }, moduleNameMapper: { - "^@/(.*)$": "/src/$1", + "^@/(.*)$": "/src/$1" }, snapshotSerializers: ["jest-serializer-vue"], testMatch: [ - "**/tests/unit/**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)", + "**/tests/unit/**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)" ], - testURL: "http://localhost/", + testURL: "http://localhost/" }; diff --git a/package-lock.json b/package-lock.json index c5330ec2..f9642c86 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4978,7 +4978,7 @@ "de-indent": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/de-indent/-/de-indent-1.0.2.tgz", - "integrity": "sha1-sgOOhG3DO6pXlhKNCAS0VbjB4h0=", + "integrity": "sha512-e/1zu3xH5MQryN2zdVaF0OrdNLUbvWxzMbi+iNA6Bky7l1RoP8a2fIbRocyHclXt/arDrrR6lL3TqFD9pMQTsg==", "dev": true }, "deasync": { @@ -6915,7 +6915,7 @@ "format": { "version": "0.2.2", "resolved": "https://registry.npmjs.org/format/-/format-0.2.2.tgz", - "integrity": "sha1-1hcBB+nv3E7TDJ3DkBbflCtctYs=" + "integrity": "sha512-wzsgA6WOq+09wrU1tsJ09udeR/YZRaeArL9e1wPbFg3GG2yDnC2ldKpxs4xunpFF9DgqCqOIra3bc1HWrJ37Ww==" }, "forwarded": { "version": "0.1.2", diff --git a/postcss.config.js b/postcss.config.js index a47ef4f9..5bfb8f62 100644 --- a/postcss.config.js +++ b/postcss.config.js @@ -1,5 +1,5 @@ module.exports = { plugins: { - autoprefixer: {}, - }, + autoprefixer: {} + } }; diff --git a/src/App.vue b/src/App.vue index 6b650a09..ed070d32 100644 --- a/src/App.vue +++ b/src/App.vue @@ -37,23 +37,23 @@ export default { bodyClasses: ["js-enabled"], mainClasses: [], headerNav: [], - logoutInterval: null, + logoutInterval: null }; }, computed: { headAttributes() { return { "meta[name=theme-color]": { - content: this.themeColor, + content: this.themeColor }, - "meta[name=robots]": { content: "noindex" }, + "meta[name=robots]": { content: "noindex" } }; }, htmlAttributes() { return { body: { - class: [document.body.className, ...this.bodyClasses].join(" "), - }, + class: [document.body.className, ...this.bodyClasses].join(" ") + } }; }, loggedInItems() { @@ -61,65 +61,66 @@ export default { { text: "Services", to: { name: "services-index" }, - hide: !Auth.canView("services"), + hide: !Auth.canView("services") }, { text: "Locations", to: { name: "locations-index" }, - hide: !Auth.canView("locations"), + hide: !Auth.canView("locations") }, { text: "Referrals", to: { name: "referrals-index" }, - hide: !Auth.canView("referrals"), + hide: !Auth.canView("referrals") }, { text: "Organisations", to: { name: "organisations-index" }, - hide: !Auth.canView("organisations"), + hide: !Auth.canView("organisations") }, { text: "Events", to: { name: "events-index" }, - hide: !Auth.canView("events"), + hide: !Auth.canView("events") }, { text: "Pages", to: { name: "pages-index" }, - hide: !Auth.canView("pages"), + hide: !Auth.canView("pages") }, { text: "Users", to: { name: "users-index" }, - hide: !Auth.canView("users"), + hide: !Auth.canView("users") }, { text: "Reports", to: { name: "reports-index" }, - hide: !Auth.canView("reports"), + hide: !Auth.canView("reports") }, { text: "Admin", to: { name: "admin-index" }, - hide: !Auth.canView("admin"), + hide: !Auth.canView("admin") }, { text: "Update requests", to: { name: "update-requests-index" }, - hide: !Auth.canView("update requests"), + hide: !Auth.canView("update requests") }, { text: "Help", to: { name: "help-index" }, - }, + hide: !this.appHelpSectionActive + } ]; }, loggedOutItems() { return [ { text: "Register", to: { name: "register-index" } }, - { text: "Login", href: Auth.authorizeUrl }, + { text: "Login", href: Auth.authorizeUrl } ]; - }, + } }, methods: { setHeaderItems() { @@ -148,7 +149,7 @@ export default { endAutoLogoutInterval() { clearInterval(this.logoutInterval); this.logoutInterval = null; - }, + } }, created() { @@ -164,6 +165,6 @@ export default { destroyed() { this.endAutoLogoutInterval(); - }, + } }; diff --git a/src/classes/Auth.js b/src/classes/Auth.js index d6f822c6..97625434 100644 --- a/src/classes/Auth.js +++ b/src/classes/Auth.js @@ -9,7 +9,7 @@ class Auth { this.appUri = process.env.VUE_APP_URI; this.appApiClientId = process.env.VUE_APP_API_CLIENT_ID; this.http = axios.create({ - baseURL: this.appApiUri, + baseURL: this.appApiUri }); } @@ -31,7 +31,7 @@ class Auth { let e, a = /\+/g, // Regex for replacing addition symbol with a space r = /([^&;=]+)=?([^&;]*)/g, - d = function (s) { + d = function(s) { return decodeURIComponent(s.replace(a, " ")); }, q = query, @@ -64,7 +64,7 @@ class Auth { "oauth", JSON.stringify({ expires_at: expiresIn * 1000 + new Date().setHours(24, 0, 0, 0), - access_token: accessToken, + access_token: accessToken }) ); @@ -80,8 +80,8 @@ class Auth { params: { include: "user-roles" }, headers: { "Content-Type": "application/json", - Authorization: `Bearer ${this.accessToken}`, - }, + Authorization: `Bearer ${this.accessToken}` + } }); localStorage.setItem("user", JSON.stringify(data.data)); @@ -105,8 +105,8 @@ class Auth { await this.http.delete("/core/v1/users/user/sessions", { headers: { "Content-Type": "application/json", - Authorization: `Bearer ${this.accessToken}`, - }, + Authorization: `Bearer ${this.accessToken}` + } }); } @@ -193,7 +193,7 @@ class Auth { { text: "Content admin", value: "Content Admin" }, { text: "Organisation admin", value: "Organisation Admin" }, { text: "Service admin", value: "Service Admin" }, - { text: "Service worker", value: "Service Worker" }, + { text: "Service worker", value: "Service Worker" } ]; } @@ -209,7 +209,7 @@ class Auth { } return ( - this.user.roles.find((role) => { + this.user.roles.find(role => { if (role.role !== roleName) { return false; } @@ -437,11 +437,10 @@ class Auth { * @returns {string} */ displayHighestRole(userRoles) { - const roleNames = this.roles.map((role) => role.value); + const roleNames = this.roles.map(role => role.value); const highestRole = roleNames.find( - (roleName) => - userRoles.find((role) => role.role === roleName) !== undefined + roleName => userRoles.find(role => role.role === roleName) !== undefined ); return highestRole || "None"; diff --git a/src/classes/Errors.js b/src/classes/Errors.js index 73293af1..96e62d58 100644 --- a/src/classes/Errors.js +++ b/src/classes/Errors.js @@ -69,7 +69,7 @@ export default class Errors { record(errors) { let keys = Object.keys(errors); - keys.forEach((key) => { + keys.forEach(key => { if (key.includes(".")) { let new_key = key.replace(/\./g, "_"); errors[new_key] = errors[key]; diff --git a/src/classes/Form.js b/src/classes/Form.js index a9a8f7c7..be6267e5 100644 --- a/src/classes/Form.js +++ b/src/classes/Form.js @@ -96,12 +96,12 @@ export default class Form { return new Promise((resolve, reject) => { this.$http[requestType](url, data, config) - .then((response) => { + .then(response => { this.onSuccess(response.data); resolve(response.data); }) - .catch((error) => { + .catch(error => { if (error.response.hasOwnProperty("data")) { this.onFail(error.response.data); } diff --git a/src/classes/MarkdownConverter.js b/src/classes/MarkdownConverter.js index a420c34d..2a90abf8 100644 --- a/src/classes/MarkdownConverter.js +++ b/src/classes/MarkdownConverter.js @@ -14,16 +14,16 @@ class MarkdownConverter { h2: "govuk-heading-l", h3: "govuk-heading-m", ul: "govuk-list govuk-list--bullet", - ol: "govuk-list govuk-list--number", + ol: "govuk-list govuk-list--number" }; - const bindings = Object.keys(classMap).map((key) => ({ + const bindings = Object.keys(classMap).map(key => ({ type: "output", regex: new RegExp(`<${key}>`, "g"), - replace: `<${key} class="${classMap[key]}">`, + replace: `<${key} class="${classMap[key]}">` })); this.showdownConverter = new Showdown.Converter({ extensions: [...bindings], - noHeaderId: true, + noHeaderId: true }); } diff --git a/src/components/Ck/CkBannerInput.vue b/src/components/Ck/CkBannerInput.vue index 69dc0f90..19bb6c8e 100644 --- a/src/components/Ck/CkBannerInput.vue +++ b/src/components/Ck/CkBannerInput.vue @@ -59,12 +59,12 @@ import CkImageInput from "./CkImageInput"; export default { components: { - CkImageInput, + CkImageInput }, model: { prop: "banner", - event: "update", + event: "update" }, props: { @@ -75,20 +75,20 @@ export default { title: "", content: "", button_text: "", - button_url: "", + button_url: "" }; - }, + } }, errors: { type: Object, default() { return {}; - }, + } }, showImageInput: { type: Boolean, - default: false, - }, + default: false + } }, methods: { @@ -99,8 +99,8 @@ export default { this.$emit("update", banner); this.$emit("clear", `banner.${field}`); - }, - }, + } + } }; diff --git a/src/components/Ck/CkCallToAction.vue b/src/components/Ck/CkCallToAction.vue index 5cbf6da8..b4b09e4b 100644 --- a/src/components/Ck/CkCallToAction.vue +++ b/src/components/Ck/CkCallToAction.vue @@ -43,11 +43,11 @@ export default { props: { callToAction: { type: Object, - required: true, + required: true }, error: { - required: true, - }, + required: true + } }, methods: { @@ -56,8 +56,8 @@ export default { callToAction[field] = value; this.$emit("input", callToAction); this.$emit("clear", "callToAction"); - }, - }, + } + } }; diff --git a/src/components/Ck/CkCarousel.vue b/src/components/Ck/CkCarousel.vue index e0e902c7..032f4aec 100644 --- a/src/components/Ck/CkCarousel.vue +++ b/src/components/Ck/CkCarousel.vue @@ -32,21 +32,21 @@ export default { props: { imageUrls: { type: Array, - required: true, - }, + required: true + } }, data() { return { - currentPage: 0, + currentPage: 0 }; }, computed: { count() { return this.imageUrls.length; - }, - }, + } + } }; diff --git a/src/components/Ck/CkCharacterCount.vue b/src/components/Ck/CkCharacterCount.vue index ab0a3aaa..ef4957c1 100644 --- a/src/components/Ck/CkCharacterCount.vue +++ b/src/components/Ck/CkCharacterCount.vue @@ -9,14 +9,14 @@ export default { props: { count: { type: Number, - required: true, + required: true }, maxLength: { type: Number, - required: true, - }, - }, + required: true + } + } }; diff --git a/src/components/Ck/CkCharacterCountBar.vue b/src/components/Ck/CkCharacterCountBar.vue index f4bbfb52..30fd7682 100644 --- a/src/components/Ck/CkCharacterCountBar.vue +++ b/src/components/Ck/CkCharacterCountBar.vue @@ -19,13 +19,13 @@ export default { props: { count: { type: Number, - required: true, + required: true }, maxLength: { type: Number, - required: true, - }, + required: true + } }, computed: { @@ -42,8 +42,8 @@ export default { }, barWidthStyle() { return `${this.barWidth}%`; - }, - }, + } + } }; diff --git a/src/components/Ck/CkCharacterCountGroup.vue b/src/components/Ck/CkCharacterCountGroup.vue index 09199cdf..c2bc6f09 100644 --- a/src/components/Ck/CkCharacterCountGroup.vue +++ b/src/components/Ck/CkCharacterCountGroup.vue @@ -6,7 +6,7 @@ diff --git a/src/components/Ck/CkCollectionInput.vue b/src/components/Ck/CkCollectionInput.vue index 070de97a..bd6543a3 100644 --- a/src/components/Ck/CkCollectionInput.vue +++ b/src/components/Ck/CkCollectionInput.vue @@ -36,29 +36,29 @@ export default { name: "CollectionInput", components: { - CkNodeCheckboxes, + CkNodeCheckboxes }, props: { value: { required: true, - type: Array, + type: Array }, error: { - required: true, + required: true }, disabled: { required: false, type: Boolean, - default: false, + default: false }, root: { required: true, type: String, - validator: function (value) { + validator: function(value) { return ["categories", "organisations"].indexOf(value) !== -1; - }, - }, + } + } }, data() { @@ -67,8 +67,8 @@ export default { enabledCollections: [], loading: false, filters: { - name: "", - }, + name: "" + } }; }, @@ -92,7 +92,7 @@ export default { } else { return this.collections; } - }, + } }, methods: { @@ -125,13 +125,13 @@ export default { const index = this.enabledCollections.indexOf(collection.id); this.enabledCollections.splice(index, 1); } - }, + } }, created() { this.fetchCollections(); this.enabledCollections = this.value; - }, + } }; diff --git a/src/components/Ck/CkDateInput.vue b/src/components/Ck/CkDateInput.vue index ad9cf15d..09802683 100644 --- a/src/components/Ck/CkDateInput.vue +++ b/src/components/Ck/CkDateInput.vue @@ -42,26 +42,26 @@ export default { name: "CkDateInput", props: { value: { - required: true, + required: true }, error: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, label: { type: String, - required: true, - }, + required: true + } }, data() { return { year: "", month: "", day: "", - validDate: true, + validDate: true }; }, methods: { @@ -97,7 +97,7 @@ export default { this.year = date.year().toString(); this.month = (date.month() + 1).toString(); this.day = date.date().toString(); - }, + } }, watch: { @@ -109,13 +109,13 @@ export default { if (newValue !== "") { this.parseDate(newValue); } - }, + } }, created() { if (this.value) { this.parseDate(this.value); } - }, + } }; diff --git a/src/components/Ck/CkDatePicker.vue b/src/components/Ck/CkDatePicker.vue index 05d39161..197f9f07 100644 --- a/src/components/Ck/CkDatePicker.vue +++ b/src/components/Ck/CkDatePicker.vue @@ -23,31 +23,31 @@ export default { props: { value: { type: String, - required: true, + required: true }, label: { type: String, - required: true, + required: true }, error: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, max: { type: String, - default: "", + default: "" }, min: { type: String, - default: "", + default: "" }, required: { type: Boolean, - default: false, - }, + default: false + } }, data() { @@ -69,7 +69,7 @@ export default { "Wednesday", "Thursday", "Friday", - "Saturday", + "Saturday" ], monthNames: [ "January", @@ -83,7 +83,7 @@ export default { "September", "October", "November", - "December", + "December" ], monthNamesShort: [ "Jan", @@ -97,17 +97,17 @@ export default { "Sep", "Oct", "Nov", - "Dec", - ], + "Dec" + ] }, - formatError: null, + formatError: null }; }, computed: { dateError() { return this.formatError ? this.formatError : this.error; - }, + } }, methods: { @@ -141,8 +141,8 @@ export default { return `${String(dateObj.getDate()).padStart(2, "0")}/${String( dateObj.getMonth() + 1 ).padStart(2, "0")}/${dateObj.getFullYear()}`; - }, - }, + } + } }; diff --git a/src/components/Ck/CkFileInput.vue b/src/components/Ck/CkFileInput.vue index 44b60426..86b1561d 100644 --- a/src/components/Ck/CkFileInput.vue +++ b/src/components/Ck/CkFileInput.vue @@ -57,41 +57,41 @@ export default { name: "CkFileInput", props: { value: { - required: true, + required: true }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, error: { - required: true, + required: true }, accept: { required: false, - default: null, + default: null }, id: { required: true, - type: String, + type: String }, existingUrl: { required: false, - type: String, + type: String }, image: { required: false, type: Boolean, - default: false, - }, + default: false + } }, data() { return { - removeExisting: false, + removeExisting: false }; }, @@ -107,7 +107,7 @@ export default { // For existing file. this.removeExisting = true; this.$emit("input", false); - }, - }, + } + } }; diff --git a/src/components/Ck/CkImageInput.vue b/src/components/Ck/CkImageInput.vue index f5ea6dbc..8c798d6e 100644 --- a/src/components/Ck/CkImageInput.vue +++ b/src/components/Ck/CkImageInput.vue @@ -61,29 +61,29 @@ export default { props: { label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, accept: { required: false, - default: null, + default: null }, id: { required: true, - type: String, + type: String }, existingUrl: { required: false, - type: String, + type: String }, private: { required: false, type: Boolean, - default: false, - }, + default: false + } }, data() { @@ -92,8 +92,8 @@ export default { form: new Form({ is_private: this.private, mime_type: null, - file: null, - }), + file: null + }) }; }, @@ -124,7 +124,7 @@ export default { // Upload the file and retrieve the ID. const { - data: { id }, + data: { id } } = await this.form.post("/files"); if (!this.form.$errors.any()) { @@ -147,7 +147,7 @@ export default { // For existing file. this.removeExisting = true; this.$emit("input", { file_id: false, image: null }); - }, - }, + } + } }; diff --git a/src/components/Ck/CkLocationInput.vue b/src/components/Ck/CkLocationInput.vue index 6288ac0f..f4c3f928 100644 --- a/src/components/Ck/CkLocationInput.vue +++ b/src/components/Ck/CkLocationInput.vue @@ -64,55 +64,55 @@ export default { name: "CkLocationInput", components: { - LocationForm, + LocationForm }, props: { error: { - required: true, + required: true }, location_id: { - required: false, + required: false }, address_line_1: { required: false, - type: String, + type: String }, address_line_2: { required: false, - type: String, + type: String }, address_line_3: { required: false, - type: String, + type: String }, city: { required: false, - type: String, + type: String }, county: { required: false, - type: String, + type: String }, postcode: { required: false, - type: String, + type: String }, country: { required: false, - type: String, + type: String }, has_induction_loop: { required: false, - type: Boolean, + type: Boolean }, has_wheelchair_access: { required: false, - type: Boolean, + type: Boolean }, has_accessible_toilet: { required: false, - type: Boolean, - }, + type: Boolean + } }, data() { @@ -132,35 +132,35 @@ export default { has_wheelchair_access: false, has_induction_loop: false, has_accessible_toilet: false, - image_file_id: null, + image_file_id: null }), countries: [ { text: "Please select", value: null, disabled: true }, - ...countries, + ...countries ], locationTypes: [ { value: "existing", label: "Existing" }, - { value: "new", label: "New" }, - ], + { value: "new", label: "New" } + ] }; }, computed: { selectLocations() { - const locations = this.locations.map((location) => { + const locations = this.locations.map(location => { return { text: `${location.address_line_1}, ${location.city}, ${location.postcode}`, - value: location.id, + value: location.id }; }); locations.unshift({ text: "Please select", value: null, - disabled: true, + disabled: true }); return locations; - }, + } }, methods: { @@ -180,12 +180,12 @@ export default { this.locations.push(data); this.locationType = "existing"; }); - }, + } }, created() { this.fetchLocations(); - }, + } }; diff --git a/src/components/Ck/CkNodeCheckboxes.vue b/src/components/Ck/CkNodeCheckboxes.vue index d8ba22cf..240ac9be 100644 --- a/src/components/Ck/CkNodeCheckboxes.vue +++ b/src/components/Ck/CkNodeCheckboxes.vue @@ -42,26 +42,26 @@ export default { props: { nodes: { required: true, - type: Array, + type: Array }, checked: { required: true, - type: Array, + type: Array }, filteredNodeIds: { type: [Array, Boolean], default() { return []; - }, + } }, disabled: { type: Boolean, - default: false, + default: false }, nested: { type: Boolean, - default: false, - }, + default: false + } }, methods: { @@ -76,13 +76,13 @@ export default { onChildUpdate({ node, enabled }) { this.onUpdate({ node, enabled }); if (node.parent_id) { - const parent = this.nodes.find((n) => n.id === node.parent_id); + const parent = this.nodes.find(n => n.id === node.parent_id); if (parent) { this.onUpdate({ node: parent, enabled }); } } - }, - }, + } + } }; diff --git a/src/components/Ck/CkPagination.vue b/src/components/Ck/CkPagination.vue index 06c073f4..1dcbefb4 100644 --- a/src/components/Ck/CkPagination.vue +++ b/src/components/Ck/CkPagination.vue @@ -16,19 +16,19 @@ export default { components: { GovBody, - GovLink, + GovLink }, props: { currentPage: { required: true, - type: Number, + type: Number }, totalPages: { required: true, - type: Number, - }, + type: Number + } }, methods: { @@ -38,7 +38,7 @@ export default { onNext() { this.$emit("next"); - }, - }, + } + } }; diff --git a/src/components/Ck/CkRadioInput.vue b/src/components/Ck/CkRadioInput.vue index 16f0ee39..f1e50ee3 100644 --- a/src/components/Ck/CkRadioInput.vue +++ b/src/components/Ck/CkRadioInput.vue @@ -33,32 +33,32 @@ export default { name: "CkRadioInput", props: { value: { - required: true, + required: true }, label: { required: false, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, error: { - required: true, + required: true }, id: { required: true, - type: String, + type: String }, options: { required: true, - type: Array, + type: Array }, disabled: { required: false, type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Ck/CkResourceListingTable.vue b/src/components/Ck/CkResourceListingTable.vue index 7531b311..6c1d142b 100644 --- a/src/components/Ck/CkResourceListingTable.vue +++ b/src/components/Ck/CkResourceListingTable.vue @@ -70,42 +70,42 @@ export default { GovTableRow, GovLink, CkLoader, - CkPagination, + CkPagination }, props: { uri: { required: true, - type: String, + type: String }, params: { required: false, type: Object, - default: () => ({}), + default: () => ({}) }, columns: { required: true, - type: Array, + type: Array }, viewRoute: { required: false, - type: Function, + type: Function }, defaultSort: { required: false, type: String, - default: "", + default: "" }, actionText: { required: false, type: String, - default: "View", - }, + default: "View" + } }, data() { @@ -114,7 +114,7 @@ export default { loading: false, currentPage: 1, totalPages: 1, - sort: this.defaultSort, + sort: this.defaultSort }; }, @@ -122,7 +122,7 @@ export default { allParams() { const params = { ...this.params, - page: this.currentPage, + page: this.currentPage }; if (this.sort !== "") { @@ -130,7 +130,7 @@ export default { } return params; - }, + } }, methods: { @@ -197,11 +197,11 @@ export default { onAction(resource) { this.$emit("action", resource); - }, + } }, created() { this.fetchResources(); - }, + } }; diff --git a/src/components/Ck/CkSelectInput.vue b/src/components/Ck/CkSelectInput.vue index 1b638d03..497b779c 100644 --- a/src/components/Ck/CkSelectInput.vue +++ b/src/components/Ck/CkSelectInput.vue @@ -44,42 +44,42 @@ export default { name: "CkSelectInput", props: { value: { - required: true, + required: true }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, error: { - required: true, + required: true }, options: { required: false, - type: Array, + type: Array }, id: { required: true, - type: String, + type: String }, width: { type: Number, - required: false, + required: false }, hasIcons: { type: Boolean, required: false, - default: false, + default: false }, disabled: { required: false, type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Ck/CkSocialMediasInput.vue b/src/components/Ck/CkSocialMediasInput.vue index 1c1b7f5b..c2adf038 100644 --- a/src/components/Ck/CkSocialMediasInput.vue +++ b/src/components/Ck/CkSocialMediasInput.vue @@ -40,17 +40,17 @@ export default { name: "SocialMediasInput", model: { prop: "socialMedias", - event: "input", + event: "input" }, props: { socialMedias: { required: true, - type: Array, + type: Array }, errors: { required: true, - type: Object, - }, + type: Object + } }, data() { return { @@ -60,28 +60,28 @@ export default { { text: "Facebook", value: "facebook" }, { text: "Instagram", value: "instagram" }, { text: "YouTube", value: "youtube" }, - { text: "Other", value: "other" }, + { text: "Other", value: "other" } ], exampleSocialMediaUrls: { twitter: "https://twitter.com/example", facebook: "https://www.facebook.com/example", instagram: "https://www.instagram.com/example", youtube: "https://www.youtube.com/channel/example-channelId", - other: "the public link from your social media account", + other: "the public link from your social media account" }, - socialMediasIndex: 1, + socialMediasIndex: 1 }; }, methods: { cloneSocialMedias() { - return this.socialMedias.map((socialMedia) => ({ ...socialMedia })); + return this.socialMedias.map(socialMedia => ({ ...socialMedia })); }, onAddSocialMedia() { let socialMedias = this.cloneSocialMedias(); socialMedias.push({ type: null, url: "", - index: this.socialMediasIndex, + index: this.socialMediasIndex }); this.$emit("input", socialMedias); @@ -108,7 +108,7 @@ export default { return `Copy the link from your browser, e.g. ${ this.exampleSocialMediaUrls[type || "other"] }`; - }, - }, + } + } }; diff --git a/src/components/Ck/CkTableFilters.vue b/src/components/Ck/CkTableFilters.vue index 72a65561..ae7c4ba9 100644 --- a/src/components/Ck/CkTableFilters.vue +++ b/src/components/Ck/CkTableFilters.vue @@ -31,14 +31,14 @@ export default { hideExtra: { required: false, type: Boolean, - default: false, - }, + default: false + } }, data() { return { - showAll: false, + showAll: false }; - }, + } }; diff --git a/src/components/Ck/CkTaxonomyInput.vue b/src/components/Ck/CkTaxonomyInput.vue index a96a6f12..cd87cc63 100644 --- a/src/components/Ck/CkTaxonomyInput.vue +++ b/src/components/Ck/CkTaxonomyInput.vue @@ -43,34 +43,34 @@ export default { name: "TaxonomyInput", components: { - CkTaxonomyTree, + CkTaxonomyTree }, props: { value: { required: true, - type: Array, + type: Array }, error: { - required: true, + required: true }, root: { required: true, type: String, - validator: function (value) { + validator: function(value) { return ["categories", "organisations"].indexOf(value) !== -1; - }, + } }, disabled: { required: false, type: Boolean, - default: false, + default: false }, hierarchy: { required: false, type: Boolean, - default: true, - }, + default: true + } }, data() { return { @@ -80,8 +80,8 @@ export default { loading: false, enabledTaxonomies: [], filters: { - name: "", - }, + name: "" + } }; }, computed: { @@ -104,9 +104,9 @@ export default { ); return [...new Set(filteredTaxonomyIds)]; } else { - return this.flattenedTaxonomies.map((taxonomy) => taxonomy.id); + return this.flattenedTaxonomies.map(taxonomy => taxonomy.id); } - }, + } }, methods: { async fetchTaxonomies() { @@ -126,7 +126,7 @@ export default { taxonomies = this.taxonomies; } - taxonomies.forEach((taxonomy) => { + taxonomies.forEach(taxonomy => { this.flattenedTaxonomies.push(taxonomy); if (taxonomy.children.length > 0) { @@ -135,8 +135,8 @@ export default { }); }, setTaxonomyCollections(collections) { - collections.forEach((collection) => { - collection.category_taxonomies.forEach((taxonomy) => { + collections.forEach(collection => { + collection.category_taxonomies.forEach(taxonomy => { this.taxonomyCollections[taxonomy.id] = this.taxonomyCollections[taxonomy.id] || []; this.taxonomyCollections[taxonomy.id].push(collection.name); @@ -168,22 +168,22 @@ export default { let ids = [taxonomy.id]; if (taxonomy.parent_id) { const parent = this.flattenedTaxonomies.find( - (tax) => tax.id === taxonomy.parent_id + tax => tax.id === taxonomy.parent_id ); ids = ids.concat(this.getTaxonomyAndAncestorsIds(parent)); } return ids; }, filteredTaxonomies(taxonomies) { - return taxonomies.filter((taxonomy) => + return taxonomies.filter(taxonomy => this.filteredTaxonomyIds.includes(taxonomy.id) ); - }, + } }, created() { this.fetchTaxonomies(); this.enabledTaxonomies = this.value; - }, + } }; diff --git a/src/components/Ck/CkTaxonomyList.vue b/src/components/Ck/CkTaxonomyList.vue index 685ce1ae..df1f4db7 100644 --- a/src/components/Ck/CkTaxonomyList.vue +++ b/src/components/Ck/CkTaxonomyList.vue @@ -6,7 +6,7 @@ Edit { + ? this.taxonomies.filter(taxonomy => { return this.filteredTaxonomyIds.includes(taxonomy.id); }) : this.taxonomies; - }, - }, + } + } }; diff --git a/src/components/Ck/CkTaxonomyTree.vue b/src/components/Ck/CkTaxonomyTree.vue index 27a45a0e..b82b4979 100644 --- a/src/components/Ck/CkTaxonomyTree.vue +++ b/src/components/Ck/CkTaxonomyTree.vue @@ -26,38 +26,38 @@ export default { name: "TaxonomyTree", components: { - CkNodeCheckboxes, + CkNodeCheckboxes }, props: { taxonomies: { required: true, - type: Array, + type: Array }, checked: { required: true, - type: Array, + type: Array }, error: { - required: true, + required: true }, filteredTaxonomyIds: { type: [Array, Boolean], default() { return []; - }, + } }, taxonomyCollections: { type: Object, default() { return {}; - }, + } }, disabled: { type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Ck/CkTextInput.vue b/src/components/Ck/CkTextInput.vue index c58031f0..c2850010 100644 --- a/src/components/Ck/CkTextInput.vue +++ b/src/components/Ck/CkTextInput.vue @@ -30,37 +30,37 @@ export default { props: { value: { required: true, - type: String, + type: String }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, error: { - required: true, + required: true }, type: { required: false, type: String, - default: "text", + default: "text" }, id: { required: true, - type: String, + type: String }, maxlength: { required: false, - type: Number, + type: Number }, disabled: { required: false, type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Ck/CkTextareaInput.vue b/src/components/Ck/CkTextareaInput.vue index 57cc85b5..96fd538a 100644 --- a/src/components/Ck/CkTextareaInput.vue +++ b/src/components/Ck/CkTextareaInput.vue @@ -40,32 +40,32 @@ export default { props: { value: { required: true, - type: String, + type: String }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, error: { - required: true, + required: true }, id: { required: true, - type: String, + type: String }, rows: { required: false, type: Number, - default: 5, + default: 5 }, maxlength: { required: false, - type: Number, - }, - }, + type: Number + } + } }; diff --git a/src/components/Ck/CkTimePeriodInput.vue b/src/components/Ck/CkTimePeriodInput.vue index d10ccef4..7908c98b 100644 --- a/src/components/Ck/CkTimePeriodInput.vue +++ b/src/components/Ck/CkTimePeriodInput.vue @@ -27,27 +27,27 @@ export default { props: { id: { required: true, - type: String, + type: String }, opens_at: { - required: true, + required: true }, closes_at: { - required: true, + required: true }, opens_at_label: { - required: true, + required: true }, closes_at_label: { - required: true, + required: true }, error: { - required: true, - }, + required: true + } }, data() { return { - hours: [{ text: "--:--", value: null, disabled: true }], + hours: [{ text: "--:--", value: null, disabled: true }] }; }, created() { @@ -60,6 +60,6 @@ export default { this.hours.push({ text, value }); } this.hours.push({ text: "24:00", value: "23:59:59" }); - }, + } }; diff --git a/src/components/Ck/CkTreeList.vue b/src/components/Ck/CkTreeList.vue index d91edb6b..7dad104c 100644 --- a/src/components/Ck/CkTreeList.vue +++ b/src/components/Ck/CkTreeList.vue @@ -9,7 +9,7 @@ v-if="canEdit" :to="{ name: edit, - params: { [nodeType]: node.id }, + params: { [nodeType]: node.id } }" > Edit @@ -60,26 +60,26 @@ export default { props: { nodes: { required: true, - type: Array, + type: Array }, nodeType: { type: String, - default: "", + default: "" }, edit: { type: String, - default: "", + default: "" }, bullet: { type: Boolean, - default: false, - }, + default: false + } }, computed: { canEdit() { return this.edit.length > 0 && this.nodeType.length > 0; - }, - }, + } + } }; diff --git a/src/components/Ck/CkWysiwygInput.vue b/src/components/Ck/CkWysiwygInput.vue index daf22c86..f6e9bce0 100644 --- a/src/components/Ck/CkWysiwygInput.vue +++ b/src/components/Ck/CkWysiwygInput.vue @@ -41,7 +41,7 @@ import { ListItem, Bold, Italic, - Link, + Link } from "tiptap-extensions"; export default { @@ -50,31 +50,31 @@ export default { props: { value: { required: true, - type: String, + type: String }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, + type: String }, error: { - required: true, + required: true }, id: { required: true, - type: String, + type: String }, large: { required: false, type: Boolean, - deafult: false, + deafult: false }, maxlength: { required: false, - type: Number, + type: Number }, extensions: { required: false, @@ -88,20 +88,20 @@ export default { new ListItem(), new Bold(), new Italic(), - new Link(), + new Link() ]; - }, - }, + } + } }, data() { return { - count: 0, + count: 0 }; }, methods: { onCount(count) { this.count = count; - }, - }, + } + } }; diff --git a/src/components/CkAuditDetails.vue b/src/components/CkAuditDetails.vue index 59d4f42b..9c1b0284 100644 --- a/src/components/CkAuditDetails.vue +++ b/src/components/CkAuditDetails.vue @@ -57,8 +57,8 @@ export default { props: { audit: { type: Object, - required: true, - }, + required: true + } }, methods: { autoDeleteDate(updated_at) { @@ -66,8 +66,8 @@ export default { .clone() .add(24, "months") .format("Y-MM-DD[T]HH:mm:ssZ"); - }, - }, + } + } }; diff --git a/src/components/CkCode.vue b/src/components/CkCode.vue index d5850555..3a15bcd2 100644 --- a/src/components/CkCode.vue +++ b/src/components/CkCode.vue @@ -6,7 +6,7 @@ diff --git a/src/components/CkDeleteButton.vue b/src/components/CkDeleteButton.vue index 4d0e4c74..c52760f9 100644 --- a/src/components/CkDeleteButton.vue +++ b/src/components/CkDeleteButton.vue @@ -33,17 +33,17 @@ export default { props: { resource: { required: true, - type: String, + type: String }, endpoint: { required: true, - type: String, - }, + type: String + } }, data() { return { form: new Form({}), - showConfirm: false, + showConfirm: false }; }, methods: { @@ -56,7 +56,7 @@ export default { }, onCancel() { this.showConfirm = false; - }, - }, + } + } }; diff --git a/src/components/CkEnvironmentWarning.vue b/src/components/CkEnvironmentWarning.vue index 6be3c7fb..23342876 100644 --- a/src/components/CkEnvironmentWarning.vue +++ b/src/components/CkEnvironmentWarning.vue @@ -22,8 +22,8 @@ export default { }, adminUrl() { return String(process.env.VUE_APP_URI).replace("staging.", ""); - }, - }, + } + } }; diff --git a/src/components/CkLoader.vue b/src/components/CkLoader.vue index 8586d95d..34b48c70 100644 --- a/src/components/CkLoader.vue +++ b/src/components/CkLoader.vue @@ -10,7 +10,7 @@ export default { data() { return { dots: 0, - interval: null, + interval: null }; }, mounted() { @@ -20,6 +20,6 @@ export default { }, beforeDestroy() { clearInterval(this.interval); - }, + } }; diff --git a/src/components/CkNotificationDetails.vue b/src/components/CkNotificationDetails.vue index d15d4caa..87d56afe 100644 --- a/src/components/CkNotificationDetails.vue +++ b/src/components/CkNotificationDetails.vue @@ -5,9 +5,11 @@ Status {{ formatStatus(notification) }} @@ -52,8 +54,8 @@ export default { props: { notification: { type: Object, - required: true, - }, + required: true + } }, methods: { formatStatus(notification) { @@ -97,8 +99,8 @@ export default { } else { return "Sending..."; } - }, - }, + } + } }; diff --git a/src/components/CkNotificationsTable.vue b/src/components/CkNotificationsTable.vue index d3418cef..8ffe7dbe 100644 --- a/src/components/CkNotificationsTable.vue +++ b/src/components/CkNotificationsTable.vue @@ -17,9 +17,11 @@ > {{ formatStatus(notification) }} @@ -35,7 +37,7 @@ View @@ -54,8 +56,8 @@ export default { props: { notifications: { type: Array, - required: true, - }, + required: true + } }, methods: { formatStatus(notification) { @@ -99,8 +101,8 @@ export default { } else { return "Sending..."; } - }, - }, + } + } }; diff --git a/src/components/CkOrganisationDetails.vue b/src/components/CkOrganisationDetails.vue index 0ffdc53d..8ebc230d 100644 --- a/src/components/CkOrganisationDetails.vue +++ b/src/components/CkOrganisationDetails.vue @@ -79,29 +79,27 @@ export default { name: "CkOrganisationDetails", components: { - CkTaxonomyList, + CkTaxonomyList }, props: { organisation: { type: Object, - required: true, - }, + required: true + } }, data() { return { loading: false, - taxonomies: [], + taxonomies: [] }; }, computed: { organisationTaxonomyIds() { - return this.organisation.category_taxonomies.map( - (taxonomy) => taxonomy.id - ); - }, + return this.organisation.category_taxonomies.map(taxonomy => taxonomy.id); + } }, methods: { @@ -124,11 +122,11 @@ export default { const { data: taxonomies } = await http.get("/taxonomies/categories"); this.taxonomies = taxonomies.data; this.loading = false; - }, + } }, created() { this.fetchTaxonomies(); - }, + } }; diff --git a/src/components/CkPageContent.vue b/src/components/CkPageContent.vue index e1fcdc91..87a2a9b9 100644 --- a/src/components/CkPageContent.vue +++ b/src/components/CkPageContent.vue @@ -68,17 +68,17 @@ export default { name: "PageContent", components: { - CkCallToAction, + CkCallToAction }, props: { content: { type: Object, - required: true, + required: true }, errors: { - required: true, - }, + required: true + } }, data() { @@ -87,8 +87,8 @@ export default { introduction: 1, about: 2, info_pages: 3, - collections: 4, - }, + collections: 4 + } }; }, @@ -104,7 +104,7 @@ export default { .sort((a, b) => { return a[1].order - b[1].order; }); - }, + } }, methods: { @@ -137,7 +137,7 @@ export default { content[section]["content"].splice(index + 1, 0, { type: "copy", - value: "", + value: "" }); this.$emit("update", content); @@ -151,7 +151,7 @@ export default { title: "", description: "", url: "", - buttonText: "", + buttonText: "" }); this.$emit("update", content); @@ -192,8 +192,8 @@ export default { this.$emit("update", content); this.$emit("clear", `content_${section}_content`); - }, - }, + } + } }; diff --git a/src/components/CkPageFeedbackDetails.vue b/src/components/CkPageFeedbackDetails.vue index 70fdbf21..7ed3157a 100644 --- a/src/components/CkPageFeedbackDetails.vue +++ b/src/components/CkPageFeedbackDetails.vue @@ -47,8 +47,8 @@ export default { props: { pageFeedback: { type: Object, - required: true, - }, + required: true + } }, methods: { autoDeleteDate(updated_at) { @@ -56,7 +56,7 @@ export default { .clone() .add(6, "months") .format("Y-MM-DD[T]HH:mm:ssZ"); - }, - }, + } + } }; diff --git a/src/components/CkReferralDetails.vue b/src/components/CkReferralDetails.vue index 16b59cfc..37ad4ef0 100644 --- a/src/components/CkReferralDetails.vue +++ b/src/components/CkReferralDetails.vue @@ -32,7 +32,7 @@ {{ referral.service.name }} @@ -48,7 +48,7 @@ v-else :to="{ name: 'organisations-show', - params: { organisation: organisation.id }, + params: { organisation: organisation.id } }" > {{ organisation.name }} @@ -132,13 +132,13 @@ export default { props: { referral: { type: Object, - required: true, - }, + required: true + } }, data() { return { loadingOrganisation: false, - organisation: null, + organisation: null }; }, computed: { @@ -155,7 +155,7 @@ export default { }, consented() { return this.referral.referral_consented_at === null ? "No" : "Yes"; - }, + } }, created() { this.fetchOrganisation(); @@ -174,7 +174,10 @@ export default { let businessDays = 0; for (var i = 0; i < duration; i++) { - const day = start.clone().add(i, "days").isoWeekday(); + const day = start + .clone() + .add(i, "days") + .isoWeekday(); if (day < 6) { businessDays += 1; @@ -196,14 +199,14 @@ export default { this.loadingOrganisation = true; const { - data: { data: organisation }, + data: { data: organisation } } = await http.get( `/organisations/${this.referral.service.organisation_id}` ); this.organisation = organisation; this.loadingOrganisation = false; - }, + } }, filters: { status(status) { @@ -219,7 +222,7 @@ export default { default: return "Invalid status"; } - }, - }, + } + } }; diff --git a/src/components/CkServiceLocationsTable.vue b/src/components/CkServiceLocationsTable.vue index d9165dbb..efc12333 100644 --- a/src/components/CkServiceLocationsTable.vue +++ b/src/components/CkServiceLocationsTable.vue @@ -24,7 +24,7 @@ View @@ -45,8 +45,8 @@ export default { props: { serviceLocations: { type: Array, - required: true, - }, - }, + required: true + } + } }; diff --git a/src/components/CkThesaurusList.vue b/src/components/CkThesaurusList.vue index dc030b59..28ab688f 100644 --- a/src/components/CkThesaurusList.vue +++ b/src/components/CkThesaurusList.vue @@ -15,8 +15,8 @@ export default { props: { synonyms: { required: true, - type: Array, - }, - }, + type: Array + } + } }; diff --git a/src/components/CkUserDetails.vue b/src/components/CkUserDetails.vue index a2151cd2..14d0cc42 100644 --- a/src/components/CkUserDetails.vue +++ b/src/components/CkUserDetails.vue @@ -37,7 +37,7 @@ @@ -57,7 +57,7 @@ @@ -77,7 +77,7 @@ @@ -97,8 +97,8 @@ export default { props: { user: { type: Object, - required: true, - }, + required: true + } }, data() { return { @@ -107,7 +107,7 @@ export default { contentAdmin: false, organisationAdmin: [], serviceAdmin: [], - serviceWorker: [], + serviceWorker: [] }; }, methods: { @@ -118,7 +118,7 @@ export default { this.serviceAdmin = []; this.serviceWorker = []; - this.user.roles.forEach((role) => { + this.user.roles.forEach(role => { if (role.role === "Super Admin") { this.superAdmin = true; } else if (role.role === "Global Admin") { @@ -139,10 +139,10 @@ export default { this.serviceWorker.push(role); } }); - }, + } }, created() { this.sortRoles(); - }, + } }; diff --git a/src/components/CkWysiwyg.vue b/src/components/CkWysiwyg.vue index 78803a52..8fff356e 100644 --- a/src/components/CkWysiwyg.vue +++ b/src/components/CkWysiwyg.vue @@ -100,7 +100,7 @@ import { ListItem, Bold, Italic, - Link, + Link } from "tiptap-extensions"; export default { @@ -108,20 +108,20 @@ export default { components: { EditorMenuBar, - EditorContent, + EditorContent }, props: { value: { type: String, required: false, - default: "", + default: "" }, large: { type: Boolean, required: false, - default: false, + default: false }, extensions: { @@ -136,15 +136,15 @@ export default { new ListItem(), new Bold(), new Italic(), - new Link(), + new Link() ]; - }, - }, + } + } }, data() { return { - editor: null, + editor: null }; }, @@ -154,7 +154,7 @@ export default { content: this.toHtml(this.value), onUpdate: ({ getHTML }) => { this.onEdit(getHTML()); - }, + } }); }, @@ -168,7 +168,7 @@ export default { promptUrl() { return window.prompt("Please enter a URL"); - }, + } }, mounted() { @@ -180,7 +180,7 @@ export default { beforeDestroy() { this.editor.destroy(); - }, + } }; diff --git a/src/components/Gov/GovBackLink.vue b/src/components/Gov/GovBackLink.vue index 20f426eb..2997b38c 100644 --- a/src/components/Gov/GovBackLink.vue +++ b/src/components/Gov/GovBackLink.vue @@ -18,8 +18,8 @@ export default { name: "GovBackLink", props: { to: { - required: false, - }, - }, + required: false + } + } }; diff --git a/src/components/Gov/GovBody.vue b/src/components/Gov/GovBody.vue index 9ca57533..3e796d51 100644 --- a/src/components/Gov/GovBody.vue +++ b/src/components/Gov/GovBody.vue @@ -16,18 +16,18 @@ export default { props: { size: { type: String, - required: false, + required: false }, tag: { type: String, required: false, - default: "p", - }, + default: "p" + } }, computed: { computedClass() { return this.size ? ["govuk-body", this.size].join("-") : "govuk-body"; - }, - }, + } + } }; diff --git a/src/components/Gov/GovButton.vue b/src/components/Gov/GovButton.vue index 73309ca2..6b962289 100644 --- a/src/components/Gov/GovButton.vue +++ b/src/components/Gov/GovButton.vue @@ -38,54 +38,54 @@ export default { type: { type: String, required: false, - default: "submit", + default: "submit" }, expand: { type: Boolean, required: false, - default: false, + default: false }, error: { type: Boolean, required: false, - default: false, + default: false }, start: { type: Boolean, required: false, - default: false, + default: false }, warning: { type: Boolean, required: false, - default: false, + default: false }, to: { - required: false, + required: false }, href: { - required: false, + required: false }, active: { type: Boolean, required: false, - default: false, + default: false }, success: { type: Boolean, required: false, - default: false, + default: false }, disabled: { type: Boolean, required: false, - default: false, - }, + default: false + } }, methods: { onClick() { this.$emit("click"); - }, + } }, computed: { computedClasses() { @@ -96,10 +96,10 @@ export default { "govuk-button--warning": this.warning, "ck-button--active": this.active, "ck-button--success": this.success, - "ck-button--disabled": this.disabled, + "ck-button--disabled": this.disabled }; - }, - }, + } + } }; diff --git a/src/components/Gov/GovCaption.vue b/src/components/Gov/GovCaption.vue index 1cef9a6e..d900e202 100644 --- a/src/components/Gov/GovCaption.vue +++ b/src/components/Gov/GovCaption.vue @@ -10,13 +10,13 @@ export default { props: { size: { type: String, - required: true, - }, + required: true + } }, computed: { computedClass() { return `govuk-caption-${this.size}`; - }, - }, + } + } }; diff --git a/src/components/Gov/GovCheckbox.vue b/src/components/Gov/GovCheckbox.vue index 4d832724..d6405943 100644 --- a/src/components/Gov/GovCheckbox.vue +++ b/src/components/Gov/GovCheckbox.vue @@ -22,31 +22,31 @@ export default { props: { value: { type: Boolean, - required: true, + required: true }, id: { type: String, - required: true, + required: true }, name: { type: String, - required: true, + required: true }, label: { type: String, - required: true, + required: true }, disabled: { type: Boolean, required: false, - default: false, - }, + default: false + } }, computed: { ariaDescribedBy() { return `${this.name}-hint`; - }, - }, + } + } }; diff --git a/src/components/Gov/GovCheckboxes.vue b/src/components/Gov/GovCheckboxes.vue index bdc7b080..c6624cb7 100644 --- a/src/components/Gov/GovCheckboxes.vue +++ b/src/components/Gov/GovCheckboxes.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovDetails.vue b/src/components/Gov/GovDetails.vue index 707bfd1a..9869ebc3 100644 --- a/src/components/Gov/GovDetails.vue +++ b/src/components/Gov/GovDetails.vue @@ -17,8 +17,8 @@ export default { props: { summary: { type: String, - required: false, - }, - }, + required: false + } + } }; diff --git a/src/components/Gov/GovErrorMessage.vue b/src/components/Gov/GovErrorMessage.vue index e222e28b..f57b0333 100644 --- a/src/components/Gov/GovErrorMessage.vue +++ b/src/components/Gov/GovErrorMessage.vue @@ -10,13 +10,13 @@ export default { props: { for: { type: String, - required: true, - }, + required: true + } }, computed: { id() { return [this.for, "error"].join("-"); - }, - }, + } + } }; diff --git a/src/components/Gov/GovErrorSummary.vue b/src/components/Gov/GovErrorSummary.vue index b882b04b..ab539065 100644 --- a/src/components/Gov/GovErrorSummary.vue +++ b/src/components/Gov/GovErrorSummary.vue @@ -18,8 +18,8 @@ export default { title: { required: false, type: String, - default: "", - }, - }, + default: "" + } + } }; diff --git a/src/components/Gov/GovFieldsetLegend.vue b/src/components/Gov/GovFieldsetLegend.vue index 47c79e73..963d43bc 100644 --- a/src/components/Gov/GovFieldsetLegend.vue +++ b/src/components/Gov/GovFieldsetLegend.vue @@ -10,13 +10,13 @@ export default { props: { size: { type: String, - required: true, - }, + required: true + } }, computed: { computedClass() { return `govuk-fieldset__legend--${this.size}`; - }, - }, + } + } }; diff --git a/src/components/Gov/GovFileUpload.vue b/src/components/Gov/GovFileUpload.vue index 89fdc0ac..a082ba84 100644 --- a/src/components/Gov/GovFileUpload.vue +++ b/src/components/Gov/GovFileUpload.vue @@ -16,22 +16,22 @@ export default { props: { id: { type: String, - required: true, + required: true }, name: { type: String, - required: true, - }, + required: true + } }, data() { return { - fileReader: new FileReader(), + fileReader: new FileReader() }; }, computed: { ariaDescribedBy() { return `${this.name}-hint`; - }, + } }, methods: { onChange() { @@ -47,10 +47,10 @@ export default { this.$emit("change", { mime_type: file.type, bytes: file.size, - content: this.fileReader.result, + content: this.fileReader.result }); this.fileReader.readAsDataURL(file); - }, - }, + } + } }; diff --git a/src/components/Gov/GovFooter.vue b/src/components/Gov/GovFooter.vue index 7562a19f..b72c568f 100644 --- a/src/components/Gov/GovFooter.vue +++ b/src/components/Gov/GovFooter.vue @@ -68,21 +68,21 @@ export default { required: false, default() { return []; - }, + } }, navigation: { type: Array, - required: false, + required: false }, meta: { type: Object, - required: false, - }, + required: false + } }, methods: { listClasses(item) { return item.items ? `govuk-footer__list--columns-${item.columns}` : null; - }, - }, + } + } }; diff --git a/src/components/Gov/GovFormGroup.vue b/src/components/Gov/GovFormGroup.vue index 0bc7bfeb..9988cece 100644 --- a/src/components/Gov/GovFormGroup.vue +++ b/src/components/Gov/GovFormGroup.vue @@ -11,8 +11,8 @@ export default { invalid: { type: Boolean, required: false, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Gov/GovGridColumn.vue b/src/components/Gov/GovGridColumn.vue index 8c856437..ff30154c 100644 --- a/src/components/Gov/GovGridColumn.vue +++ b/src/components/Gov/GovGridColumn.vue @@ -10,13 +10,13 @@ export default { props: { width: { type: String, - required: true, - }, + required: true + } }, computed: { computedClass() { return `govuk-grid-column-${this.width}`; - }, - }, + } + } }; diff --git a/src/components/Gov/GovGridRow.vue b/src/components/Gov/GovGridRow.vue index 47df9b3c..a7cc55eb 100644 --- a/src/components/Gov/GovGridRow.vue +++ b/src/components/Gov/GovGridRow.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovHeader.vue b/src/components/Gov/GovHeader.vue index 0a122a8a..2153b7e7 100644 --- a/src/components/Gov/GovHeader.vue +++ b/src/components/Gov/GovHeader.vue @@ -82,22 +82,22 @@ export default { props: { serviceName: { type: String, - required: true, + required: true }, navigation: { type: Array, required: false, default() { return []; - }, - }, + } + } }, components: { - CkEnvironmentWarning, + CkEnvironmentWarning }, data() { return { - navExpanded: false, + navExpanded: false }; }, methods: { @@ -106,8 +106,8 @@ export default { }, onToggleMenu() { this.navExpanded = !this.navExpanded; - }, - }, + } + } }; diff --git a/src/components/Gov/GovHeading.vue b/src/components/Gov/GovHeading.vue index 2a267b13..fc3614bb 100644 --- a/src/components/Gov/GovHeading.vue +++ b/src/components/Gov/GovHeading.vue @@ -37,18 +37,18 @@ export default { size: { type: String, required: false, - default: "m", + default: "m" }, tag: { type: String, required: false, - default: "h1", - }, + default: "h1" + } }, computed: { computedClass() { return `govuk-heading-${this.size}`; - }, - }, + } + } }; diff --git a/src/components/Gov/GovHint.vue b/src/components/Gov/GovHint.vue index d6bd86a8..211771e9 100644 --- a/src/components/Gov/GovHint.vue +++ b/src/components/Gov/GovHint.vue @@ -9,13 +9,13 @@ export default { name: "GovHint", props: { for: { - type: String, - }, + type: String + } }, computed: { id() { return this.for ? [this.for, "hint"].join("-") : null; - }, - }, + } + } }; diff --git a/src/components/Gov/GovInput.vue b/src/components/Gov/GovInput.vue index 7ca54108..0d4aae16 100644 --- a/src/components/Gov/GovInput.vue +++ b/src/components/Gov/GovInput.vue @@ -20,31 +20,31 @@ export default { props: { value: { type: String, - required: true, + required: true }, id: { type: String, - required: true, + required: true }, name: { type: String, - required: true, + required: true }, type: { type: String, required: false, - default: "text", + default: "text" }, width: { type: Number, - required: false, + required: false }, min: { - type: [String, Number], + type: [String, Number] }, max: { - type: [String, Number], - }, + type: [String, Number] + } }, computed: { computedClass() { @@ -52,12 +52,12 @@ export default { }, ariaDescribedBy() { return `${this.name}-hint`; - }, + } }, methods: { onEnter() { this.$emit("enter"); - }, - }, + } + } }; diff --git a/src/components/Gov/GovInsetText.vue b/src/components/Gov/GovInsetText.vue index a9a32388..bc32a999 100644 --- a/src/components/Gov/GovInsetText.vue +++ b/src/components/Gov/GovInsetText.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovLabel.vue b/src/components/Gov/GovLabel.vue index c35a800f..c6edd55d 100644 --- a/src/components/Gov/GovLabel.vue +++ b/src/components/Gov/GovLabel.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovLink.vue b/src/components/Gov/GovLink.vue index f08a8a34..97be5614 100644 --- a/src/components/Gov/GovLink.vue +++ b/src/components/Gov/GovLink.vue @@ -24,16 +24,16 @@ export default { name: "GovLink", props: { to: { - required: false, + required: false }, href: { - required: false, - }, + required: false + } }, methods: { onClick() { this.$emit("click"); - }, - }, + } + } }; diff --git a/src/components/Gov/GovList.vue b/src/components/Gov/GovList.vue index 1b7d4359..75930200 100644 --- a/src/components/Gov/GovList.vue +++ b/src/components/Gov/GovList.vue @@ -18,13 +18,13 @@ export default { type: { type: String, required: false, - default: "unordered", + default: "unordered" }, bullet: { required: false, type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Gov/GovMainWrapper.vue b/src/components/Gov/GovMainWrapper.vue index c174d6e7..61ee629d 100644 --- a/src/components/Gov/GovMainWrapper.vue +++ b/src/components/Gov/GovMainWrapper.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovRadio.vue b/src/components/Gov/GovRadio.vue index 7a971235..0f822031 100644 --- a/src/components/Gov/GovRadio.vue +++ b/src/components/Gov/GovRadio.vue @@ -19,32 +19,32 @@ export default { name: "GovRadioInput", model: { prop: "bindTo", - event: "input", + event: "input" }, props: { bindTo: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, name: { type: String, - required: true, + required: true }, label: { type: String, - required: true, + required: true }, value: { - required: true, + required: true }, disabled: { required: false, type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Gov/GovRadios.vue b/src/components/Gov/GovRadios.vue index bd2f15d2..9debfe25 100644 --- a/src/components/Gov/GovRadios.vue +++ b/src/components/Gov/GovRadios.vue @@ -11,8 +11,8 @@ export default { inline: { required: false, type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/components/Gov/GovSectionBreak.vue b/src/components/Gov/GovSectionBreak.vue index 60aab8d6..2371ed4e 100644 --- a/src/components/Gov/GovSectionBreak.vue +++ b/src/components/Gov/GovSectionBreak.vue @@ -8,18 +8,18 @@ export default { props: { size: { type: String, - required: false, + required: false }, visible: { type: Boolean, required: false, - default: false, - }, + default: false + } }, computed: { computedClasses() { let classes = { - "govuk-section-break--visible": this.visible, + "govuk-section-break--visible": this.visible }; if (this.size) { @@ -27,7 +27,7 @@ export default { } return classes; - }, - }, + } + } }; diff --git a/src/components/Gov/GovSelect.vue b/src/components/Gov/GovSelect.vue index ea3c2eff..fedc9c30 100644 --- a/src/components/Gov/GovSelect.vue +++ b/src/components/Gov/GovSelect.vue @@ -27,24 +27,24 @@ export default { name: "GovSelect", props: { value: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, name: { type: String, - required: true, + required: true }, options: { type: Array, - required: false, + required: false }, width: { type: Number, - required: false, - }, + required: false + } }, computed: { ariaDescribedBy() { @@ -52,7 +52,7 @@ export default { }, computedClasses() { return this.width ? `govuk-input--width-${this.width}` : null; - }, - }, + } + } }; diff --git a/src/components/Gov/GovSkipLink.vue b/src/components/Gov/GovSkipLink.vue index c49c4dca..229f93f6 100644 --- a/src/components/Gov/GovSkipLink.vue +++ b/src/components/Gov/GovSkipLink.vue @@ -11,8 +11,8 @@ export default { href: { type: String, required: false, - default: "#content", - }, - }, + default: "#content" + } + } }; diff --git a/src/components/Gov/GovTabPanel.vue b/src/components/Gov/GovTabPanel.vue index c54ee32e..92d372bc 100644 --- a/src/components/Gov/GovTabPanel.vue +++ b/src/components/Gov/GovTabPanel.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovTable.vue b/src/components/Gov/GovTable.vue index f4d45f7f..d1c1f07f 100644 --- a/src/components/Gov/GovTable.vue +++ b/src/components/Gov/GovTable.vue @@ -11,6 +11,6 @@ diff --git a/src/components/Gov/GovTableCell.vue b/src/components/Gov/GovTableCell.vue index 88929e7c..e25fae43 100644 --- a/src/components/Gov/GovTableCell.vue +++ b/src/components/Gov/GovTableCell.vue @@ -11,28 +11,28 @@ export default { center: { type: Boolean, required: false, - default: false, + default: false }, right: { type: Boolean, required: false, - default: false, + default: false }, break: { type: Boolean, required: false, - default: false, - }, + default: false + } }, computed: { computedClasses() { return { "text-center": this.center, "text-right": this.right, - "govuk-table__cell--break-word": this.break, + "govuk-table__cell--break-word": this.break }; - }, - }, + } + } }; diff --git a/src/components/Gov/GovTableHeader.vue b/src/components/Gov/GovTableHeader.vue index 5ae51fab..94bcd4fc 100644 --- a/src/components/Gov/GovTableHeader.vue +++ b/src/components/Gov/GovTableHeader.vue @@ -15,23 +15,23 @@ export default { top: { type: Boolean, required: false, - default: false, + default: false }, center: { type: Boolean, required: false, - default: false, + default: false }, right: { type: Boolean, required: false, - default: false, + default: false }, clickable: { type: Boolean, required: false, - default: false, - }, + default: false + } }, computed: { computedClasses() { @@ -39,10 +39,10 @@ export default { "align-top": this.top, "text-center": this.center, "text-right": this.right, - "ck-table__header--clickable": this.clickable, + "ck-table__header--clickable": this.clickable }; - }, - }, + } + } }; diff --git a/src/components/Gov/GovTableRow.vue b/src/components/Gov/GovTableRow.vue index 8dcfdb99..641a377f 100644 --- a/src/components/Gov/GovTableRow.vue +++ b/src/components/Gov/GovTableRow.vue @@ -6,6 +6,6 @@ diff --git a/src/components/Gov/GovTabs.vue b/src/components/Gov/GovTabs.vue index 9ff0d925..8bf8a570 100644 --- a/src/components/Gov/GovTabs.vue +++ b/src/components/Gov/GovTabs.vue @@ -13,7 +13,7 @@ class="govuk-tabs__tab" :class="{ 'govuk-tabs__tab--active': tab.active, - 'govuk-tabs__tab--bar': bar, + 'govuk-tabs__tab--bar': bar }" href="javascript:;" v-text="tab.heading" @@ -42,34 +42,34 @@ export default { props: { tabs: { type: Array, - required: true, + required: true }, title: { type: String, required: false, - default: "Contents", + default: "Contents" }, noRouter: { type: Boolean, required: false, - default: false, + default: false }, bar: { type: Boolean, required: false, - default: false, + default: false }, panel: { type: Boolean, required: false, - default: true, - }, + default: true + } }, methods: { onTabClick(tab, index) { this.$emit("tab-changed", { index, tab }); - }, - }, + } + } }; diff --git a/src/components/Gov/GovTag.vue b/src/components/Gov/GovTag.vue index e9611be8..1f35628d 100644 --- a/src/components/Gov/GovTag.vue +++ b/src/components/Gov/GovTag.vue @@ -6,7 +6,7 @@ diff --git a/src/components/Gov/GovTextarea.vue b/src/components/Gov/GovTextarea.vue index 3df24f1f..9a2fcd63 100644 --- a/src/components/Gov/GovTextarea.vue +++ b/src/components/Gov/GovTextarea.vue @@ -17,32 +17,32 @@ export default { props: { value: { type: String, - required: true, + required: true }, id: { type: String, - required: true, + required: true }, name: { type: String, - required: true, + required: true }, rows: { type: Number, required: false, - default: 5, - }, + default: 5 + } }, computed: { ariaDescribedBy() { return `${this.name}-hint`; - }, + } }, methods: { onEnter() { this.$emit("enter"); - }, - }, + } + } }; diff --git a/src/components/Gov/GovWarningText.vue b/src/components/Gov/GovWarningText.vue index 9df43926..fd374000 100644 --- a/src/components/Gov/GovWarningText.vue +++ b/src/components/Gov/GovWarningText.vue @@ -16,8 +16,8 @@ export default { title: { required: false, type: String, - default: "Warning", - }, - }, + default: "Warning" + } + } }; diff --git a/src/components/Gov/GovWidthContainer.vue b/src/components/Gov/GovWidthContainer.vue index c79622d2..7d790a3a 100644 --- a/src/components/Gov/GovWidthContainer.vue +++ b/src/components/Gov/GovWidthContainer.vue @@ -6,6 +6,6 @@ diff --git a/src/components/SpreadsheetImportErrors.vue b/src/components/SpreadsheetImportErrors.vue index 5fd35a79..e373cbe4 100644 --- a/src/components/SpreadsheetImportErrors.vue +++ b/src/components/SpreadsheetImportErrors.vue @@ -46,7 +46,7 @@ {{ original.name }} @@ -79,29 +79,29 @@ export default { props: { fields: { type: Object, - required: true, + required: true }, invalidRows: { type: Array, required: false, default() { return []; - }, + } }, duplicateRows: { type: Array, required: false, default() { return []; - }, - }, + } + } }, computed: { combinedRows() { const combinedRows = this.invalidRows.slice(); if (this.duplicateRows.length) { - this.duplicateRows.forEach((duplicateRow) => { - const index = this.invalidRows.findIndex((invalidRow) => { + this.duplicateRows.forEach(duplicateRow => { + const index = this.invalidRows.findIndex(invalidRow => { return invalidRow.row.index === duplicateRow.row.index; }); if (-1 === index) { @@ -112,7 +112,7 @@ export default { }); } return combinedRows; - }, + } }, methods: { trimString(s) { @@ -120,8 +120,8 @@ export default { }, ignoreDuplicate(duplicate) { this.$emit("ignoreDuplicate", duplicate.id); - }, - }, + } + } }; diff --git a/src/components/SpreadsheetImportForm.vue b/src/components/SpreadsheetImportForm.vue index ca3aa8db..971497dc 100644 --- a/src/components/SpreadsheetImportForm.vue +++ b/src/components/SpreadsheetImportForm.vue @@ -19,17 +19,17 @@ export default { props: { errors: { required: true, - type: Object, + type: Object }, spreadsheet: { - required: true, + required: true }, feedback: { type: String, - default: null, - }, + default: null + } }, watch: { @@ -37,14 +37,14 @@ export default { if (wasThen && !isNow) { this.$refs.fileInput.$refs.file.$el.value = ""; } - }, + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, - }, + } + } }; diff --git a/src/http.js b/src/http.js index 563f5a55..6969c329 100644 --- a/src/http.js +++ b/src/http.js @@ -3,12 +3,12 @@ import Auth from "@/classes/Auth"; import router from "@/router"; const http = axios.create({ - baseURL: `${process.env.VUE_APP_API_URI}/core/v1`, + baseURL: `${process.env.VUE_APP_API_URI}/core/v1` }); http.defaults.headers.post["Content-Type"] = "application/json"; http.interceptors.request.use( - (config) => { + config => { // If the user has been inactive for too long. if (Auth.inactive()) { router.push({ name: "logout" }); @@ -29,11 +29,11 @@ http.interceptors.request.use( // If the user is not authenticated. return config; }, - (error) => Promise.reject(error) + error => Promise.reject(error) ); http.interceptors.response.use( - (response) => response, - (error) => { + response => response, + error => { if (error.response.status === 403) { alert("You are not authorised to perform this action."); } else if (error.response.status === 401) { diff --git a/src/main.js b/src/main.js index 8d39af9e..d6dc5887 100644 --- a/src/main.js +++ b/src/main.js @@ -20,8 +20,8 @@ import MarkdownConverter from "@/classes/MarkdownConverter"; import * as VueGoogleMaps from "vue2-google-maps"; Vue.use(VueGoogleMaps, { load: { - key: process.env.VUE_APP_GOOGLE_API_KEY, - }, + key: process.env.VUE_APP_GOOGLE_API_KEY + } }); // Import Duet Date Picker @@ -46,7 +46,7 @@ if (process.env.VUE_APP_BUGSNAG_API_KEY) { delete user.roles; report.user = user; - }, + } }); bugsnagClient.use(bugsnagVue(Vue)); @@ -143,7 +143,7 @@ Vue.mixin({ data() { return { auth: Auth, - moment, + moment }; }, computed: { @@ -184,6 +184,11 @@ Vue.mixin({ ? process.env.VUE_APP_SERVICE_TAGS === "true" : false; }, + appHelpSectionActive() { + return process.env.hasOwnProperty("VUE_APP_HELP_SECTION") + ? process.env.VUE_APP_HELP_SECTION === "true" + : false; + } }, methods: { apiUrl(path) { @@ -237,7 +242,7 @@ Vue.mixin({ } while (!allFetched); return resources; - }, + } }, filters: { ucfirst(string) { @@ -248,12 +253,12 @@ Vue.mixin({ service: "services", activity: "activities", club: "clubs", - group: "groups", + group: "groups" }; return plurals[string]; - }, - }, + } + } }); Vue.config.productionTip = false; @@ -266,5 +271,5 @@ defineCustomElements(window); new Vue({ router, - render: (h) => h(App), + render: h => h(App) }).$mount("#app"); diff --git a/src/router.js b/src/router.js index 57ad87c4..d04480b6 100644 --- a/src/router.js +++ b/src/router.js @@ -12,192 +12,192 @@ let router = new Router({ path: "/login", name: "login", component: () => import("@/views/auth/Login"), - meta: { auth: false }, + meta: { auth: false } }, { path: "/logout", name: "logout", - component: () => import("@/views/auth/Logout"), + component: () => import("@/views/auth/Logout") }, { path: "/", name: "dashboard", component: () => import("@/views/Dashboard"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/help", name: "help-index", component: () => import("@/views/help/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/organisations", name: "organisations-index", component: () => import("@/views/organisations/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/organisations/create", name: "organisations-create", component: () => import("@/views/organisations/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/organisations/import", name: "organisations-import", component: () => import("@/views/organisations/Import"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/organisations/:organisation", name: "organisations-show", component: () => import("@/views/organisations/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/organisations/:organisation/edit", name: "organisations-edit", component: () => import("@/views/organisations/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/organisations/:organisation/updated", name: "organisations-updated", component: () => import("@/views/organisations/Updated"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/events", name: "events-index", component: () => import("@/views/events/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/events/create", name: "events-create", component: () => import("@/views/events/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/events/:event", name: "events-show", component: () => import("@/views/events/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/events/:event/edit", name: "events-edit", component: () => import("@/views/events/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/events/:event/updated", name: "events-updated", component: () => import("@/views/events/Updated"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/referrals", name: "referrals-index", component: () => import("@/views/referrals/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/referrals/:referral/confirmation", name: "referrals-confirmation", component: () => import("@/views/referrals/Confirmation"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/referrals/:referral", name: "referrals-show", component: () => import("@/views/referrals/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/locations", name: "locations-index", component: () => import("@/views/locations/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/locations/create", name: "locations-create", component: () => import("@/views/locations/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/locations/:location", name: "locations-show", component: () => import("@/views/locations/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/locations/:location/edit", name: "locations-edit", component: () => import("@/views/locations/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/locations/:location/updated", name: "locations-updated", component: () => import("@/views/locations/Updated"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/users", name: "users-index", component: () => import("@/views/users/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/users/create", name: "users-create", component: () => import("@/views/users/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/users/:user", name: "users-show", component: () => import("@/views/users/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/users/:user/edit", name: "users-edit", component: () => import("@/views/users/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services", name: "services-index", component: () => import("@/views/services/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/pre-create", name: "services-pre-create", component: () => import("@/views/services/PreCreate"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/create", name: "services-create", component: () => import("@/views/services/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/import", name: "services-import", component: () => import("@/views/services/Import"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/:service/created", name: "services-post-create", component: () => import("@/views/services/PostCreate"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/:service", @@ -207,92 +207,92 @@ let router = new Router({ { path: "", name: "services-show", - component: () => import("@/views/services/show/DetailsTab"), + component: () => import("@/views/services/show/DetailsTab") }, { path: "additional-info", name: "services-show-additional-info", - component: () => import("@/views/services/show/AdditionalInfoTab"), + component: () => import("@/views/services/show/AdditionalInfoTab") }, { path: "useful-info", name: "services-show-useful-info", - component: () => import("@/views/services/show/UsefulInfoTab"), + component: () => import("@/views/services/show/UsefulInfoTab") }, { path: "contact-info", name: "services-show-contact-info", - component: () => import("@/views/services/show/ContactInfoTab"), + component: () => import("@/views/services/show/ContactInfoTab") }, { path: "eligibility", name: "services-show-eligibility", - component: () => import("@/views/services/show/EligibilityTab"), + component: () => import("@/views/services/show/EligibilityTab") }, { path: "locations", name: "services-show-locations", - component: () => import("@/views/services/show/LocationsTab"), + component: () => import("@/views/services/show/LocationsTab") }, { path: "referral", name: "services-show-referral", - component: () => import("@/views/services/show/ReferralTab"), - }, - ], + component: () => import("@/views/services/show/ReferralTab") + } + ] }, { path: "/services/:service/edit", name: "services-edit", component: () => import("@/views/services/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/:service/updated", name: "services-updated", component: () => import("@/views/services/Updated"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/services/:service/refresh", name: "services-refresh", - component: () => import("@/views/services/Refresh"), + component: () => import("@/views/services/Refresh") }, { path: "/services/:service/service-locations/create", name: "service-locations-create", component: () => import("@/views/service-locations/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/service-locations/:serviceLocation", name: "service-locations-show", component: () => import("@/views/service-locations/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/service-locations/:serviceLocation/edit", name: "service-locations-edit", component: () => import("@/views/service-locations/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/service-locations/:serviceLocation/updated", name: "service-locations-updated", component: () => import("@/views/service-locations/Updated"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/update-requests", name: "update-requests-index", component: () => import("@/views/update-requests/Index"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/update-requests/:updateRequest", name: "update-requests-show", component: () => import("@/views/update-requests/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/reports", @@ -302,14 +302,14 @@ let router = new Router({ { path: "", name: "reports-index", - component: () => import("@/views/reports/View"), + component: () => import("@/views/reports/View") }, { path: "edit", name: "reports-edit", - component: () => import("@/views/reports/Edit"), - }, - ], + component: () => import("@/views/reports/Edit") + } + ] }, { path: "/pages", @@ -320,37 +320,37 @@ let router = new Router({ path: "create/landing", name: "pages-create-landing", component: () => import("@/views/pages/Create"), - props: { type: "landing" }, + props: { type: "landing" } }, { path: "create/information", name: "pages-create-information", component: () => import("@/views/pages/Create"), - props: { type: "information" }, + props: { type: "information" } }, { path: ":page", name: "pages-show", - component: () => import("@/views/pages/Show"), + component: () => import("@/views/pages/Show") }, { path: ":page/edit", name: "pages-edit", - component: () => import("@/views/pages/Edit"), + component: () => import("@/views/pages/Edit") }, { path: ":page/updated", name: "pages-updated", component: () => import("@/views/pages/Updated"), - meta: { auth: true }, + meta: { auth: true } }, { path: "", name: "pages-index", - component: () => import("@/views/pages/List"), - }, - ], + component: () => import("@/views/pages/List") + } + ] }, { path: "/admin", @@ -360,17 +360,17 @@ let router = new Router({ { path: "", name: "admin-index", - component: () => import("@/views/admin/index/AuditLogs"), + component: () => import("@/views/admin/index/AuditLogs") }, { path: "notifications", name: "admin-index-notifications", - component: () => import("@/views/admin/index/Notifications"), + component: () => import("@/views/admin/index/Notifications") }, { path: "feedback", name: "admin-index-feedback", - component: () => import("@/views/admin/index/Feedback"), + component: () => import("@/views/admin/index/Feedback") }, { path: "taxonomies", @@ -380,21 +380,21 @@ let router = new Router({ path: "", name: "admin-index-taxonomies", component: () => - import("@/views/admin/index/taxonomies/Categories"), + import("@/views/admin/index/taxonomies/Categories") }, { path: "organisations", name: "admin-index-taxonomies-organisations", component: () => - import("@/views/admin/index/taxonomies/Organisations"), + import("@/views/admin/index/taxonomies/Organisations") }, { path: "service-eligibilities", name: "admin-index-taxonomies-service-eligibilities", component: () => - import("@/views/admin/index/taxonomies/ServiceEligibilities"), - }, - ], + import("@/views/admin/index/taxonomies/ServiceEligibilities") + } + ] }, { path: "collections", @@ -404,20 +404,20 @@ let router = new Router({ path: "", name: "admin-index-collections", component: () => - import("@/views/admin/index/collections/Categories"), + import("@/views/admin/index/collections/Categories") }, { path: "personas", name: "admin-index-collections-personas", component: () => - import("@/views/admin/index/collections/Personas"), + import("@/views/admin/index/collections/Personas") }, { path: "events", name: "admin-index-collections-events", - component: () => import("@/views/admin/index/collections/Events"), - }, - ], + component: () => import("@/views/admin/index/collections/Events") + } + ] }, { path: "search-engine", @@ -427,15 +427,15 @@ let router = new Router({ path: "", name: "admin-index-search-engine", component: () => - import("@/views/admin/index/search-engine/Thesaurus"), + import("@/views/admin/index/search-engine/Thesaurus") }, { path: "stop-words", name: "admin-index-search-engine-stop-words", component: () => - import("@/views/admin/index/search-engine/StopWords"), - }, - ], + import("@/views/admin/index/search-engine/StopWords") + } + ] }, { path: "cms", @@ -444,25 +444,24 @@ let router = new Router({ { path: "", name: "admin-index-cms", - component: () => - import("@/views/admin/index/cms/frontend/Global"), + component: () => import("@/views/admin/index/cms/frontend/Global") }, { path: "frontend/home", name: "admin-index-cms-frontend-home", - component: () => import("@/views/admin/index/cms/frontend/Home"), + component: () => import("@/views/admin/index/cms/frontend/Home") }, { path: "frontend/terms-and-conditions", name: "admin-index-cms-frontend-terms-and-conditions", component: () => - import("@/views/admin/index/cms/frontend/TermsAndConditions"), + import("@/views/admin/index/cms/frontend/TermsAndConditions") }, { path: "frontend/privacy-policy", name: "admin-index-cms-frontend-privacy-policy", component: () => - import("@/views/admin/index/cms/frontend/PrivacyPolicy"), + import("@/views/admin/index/cms/frontend/PrivacyPolicy") }, { path: "frontend/accessibility-statement", @@ -470,148 +469,147 @@ let router = new Router({ component: () => import( "@/views/admin/index/cms/frontend/AccessibilityStatement" - ), + ) }, { path: "frontend/about", name: "admin-index-cms-frontend-about", - component: () => import("@/views/admin/index/cms/frontend/About"), + component: () => import("@/views/admin/index/cms/frontend/About") }, { path: "frontend/contact", name: "admin-index-cms-frontend-contact", component: () => - import("@/views/admin/index/cms/frontend/Contact"), + import("@/views/admin/index/cms/frontend/Contact") }, { path: "frontend/get-involved", name: "admin-index-cms-frontend-get-involved", component: () => - import("@/views/admin/index/cms/frontend/GetInvolved"), + import("@/views/admin/index/cms/frontend/GetInvolved") }, { path: "frontend/favourites", name: "admin-index-cms-frontend-favourites", component: () => - import("@/views/admin/index/cms/frontend/Favourites"), + import("@/views/admin/index/cms/frontend/Favourites") }, { path: "frontend/banner", name: "admin-index-cms-frontend-banner", - component: () => - import("@/views/admin/index/cms/frontend/Banner"), - }, - ], + component: () => import("@/views/admin/index/cms/frontend/Banner") + } + ] }, { path: "cms/updated", name: "admin-index-cms-updated", - component: () => import("@/views/admin/index/cms/Updated"), - }, - ], + component: () => import("@/views/admin/index/cms/Updated") + } + ] }, { path: "/audits/:audit", name: "audits-show", component: () => import("@/views/audits/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/notifications/:notification", name: "notifications-show", component: () => import("@/views/notifications/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/page-feedbacks/:pageFeedback", name: "page-feedbacks-show", component: () => import("@/views/page-feedbacks/Show"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/taxonomies/categories/create", name: "taxonomies-categories-create", component: () => import("@/views/taxonomies/categories/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/taxonomies/categories/:taxonomy/edit", name: "taxonomies-categories-edit", component: () => import("@/views/taxonomies/categories/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/taxonomies/organisations/create", name: "taxonomies-organisations-create", component: () => import("@/views/taxonomies/organisations/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/taxonomies/organisations/:taxonomy/edit", name: "taxonomies-organisations-edit", component: () => import("@/views/taxonomies/organisations/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/taxonomies/service-eligibilities/create", name: "taxonomies-service-eligibilities-create", component: () => import("@/views/taxonomies/service-eligibilities/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/taxonomies/service-eligibilities/:taxonomy/edit", name: "taxonomies-service-eligibilities-edit", component: () => import("@/views/taxonomies/service-eligibilities/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/collections/categories/create", name: "collections-categories-create", component: () => import("@/views/collections/categories/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/collections/categories/:collection/edit", name: "collections-categories-edit", component: () => import("@/views/collections/categories/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/collections/personas/create", name: "collections-personas-create", component: () => import("@/views/collections/personas/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/collections/personas/:collection/edit", name: "collections-personas-edit", component: () => import("@/views/collections/personas/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/collections/events/create", name: "collections-events-create", component: () => import("@/views/collections/events/Create"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/collections/events/:collection/edit", name: "collections-events-edit", component: () => import("@/views/collections/events/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/thesuarus/edit", name: "thesaurus-edit", component: () => import("@/views/thesaurus/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/stop-words/edit", name: "stop-words-edit", component: () => import("@/views/stop-words/Edit"), - meta: { auth: true }, + meta: { auth: true } }, { path: "/register", @@ -621,58 +619,58 @@ let router = new Router({ path: "", name: "register-index", component: () => import("@/views/register/Search"), - meta: { auth: false }, + meta: { auth: false } }, { path: "new/step-2", name: "register-new-step2", component: () => import("@/views/register/new/Criteria"), - meta: { auth: false }, + meta: { auth: false } }, { path: "new/step-3", name: "register-new-step3", component: () => import("@/views/register/new/Information"), - meta: { auth: false }, + meta: { auth: false } }, { path: "new/step-4", name: "register-new-step4", component: () => import("@/views/register/new/User"), - meta: { auth: false }, + meta: { auth: false } }, { path: "new/step-5", name: "register-new-step5", component: () => import("@/views/register/new/Organisation"), - meta: { auth: false }, + meta: { auth: false } }, { path: "existing/step-2", name: "register-existing-step2", component: () => import("@/views/register/existing/Information"), - meta: { auth: false }, + meta: { auth: false } }, { path: "existing/step-3", name: "register-existing-step3", component: () => import("@/views/register/existing/User"), - meta: { auth: false }, + meta: { auth: false } }, { path: "completed", name: "register-completed", component: () => import("@/views/register/Completed"), - meta: { auth: false }, - }, - ], + meta: { auth: false } + } + ] }, { path: "*", name: "404", - component: () => import("@/views/errors/404"), - }, - ], + component: () => import("@/views/errors/404") + } + ] }); // Middleware. @@ -692,7 +690,7 @@ router.beforeEach((to, from, next) => { } // If user needs to be authenticated, then redirect them to the auth URL. - if (to.matched.some((route) => route.meta.auth)) { + if (to.matched.some(route => route.meta.auth)) { if (!Auth.isLoggedIn) { return next({ name: "login" }); } diff --git a/src/storage/countries.js b/src/storage/countries.js index 7a33cef8..109937c8 100644 --- a/src/storage/countries.js +++ b/src/storage/countries.js @@ -31,7 +31,7 @@ export default [ { text: "Brazil", value: "Brazil" }, { text: "British Indian Ocean Territory", - value: "British Indian Ocean Territory", + value: "British Indian Ocean Territory" }, { text: "Brunei Darussalam", value: "Brunei Darussalam" }, { text: "Bulgaria", value: "Bulgaria" }, @@ -53,7 +53,7 @@ export default [ { text: "Congo", value: "Congo" }, { text: "Congo, The Democratic Republic of the", - value: "Congo, The Democratic Republic of the", + value: "Congo, The Democratic Republic of the" }, { text: "Cook Islands", value: "Cook Islands" }, { text: "Costa Rica", value: "Costa Rica" }, @@ -100,11 +100,11 @@ export default [ { text: "Haiti", value: "Haiti" }, { text: "Heard Island and Mcdonald Islands", - value: "Heard Island and Mcdonald Islands", + value: "Heard Island and Mcdonald Islands" }, { text: "Holy See (Vatican City State)", - value: "Holy See (Vatican City State)", + value: "Holy See (Vatican City State)" }, { text: "Honduras", value: "Honduras" }, { text: "Hong Kong", value: "Hong Kong" }, @@ -127,14 +127,14 @@ export default [ { text: "Kiribati", value: "Kiribati" }, { text: "Korea, Democratic People's Republic of", - value: "Korea, Democratic People's Republic of", + value: "Korea, Democratic People's Republic of" }, { text: "Korea, Republic of", value: "Korea, Republic of" }, { text: "Kuwait", value: "Kuwait" }, { text: "Kyrgyzstan", value: "Kyrgyzstan" }, { text: "Lao People's Democratic Republic", - value: "Lao People's Democratic Republic", + value: "Lao People's Democratic Republic" }, { text: "Latvia", value: "Latvia" }, { text: "Lebanon", value: "Lebanon" }, @@ -147,7 +147,7 @@ export default [ { text: "Macao", value: "Macao" }, { text: "Macedonia, The Former Yugoslav Republic of", - value: "Macedonia, The Former Yugoslav Republic of", + value: "Macedonia, The Former Yugoslav Republic of" }, { text: "Madagascar", value: "Madagascar" }, { text: "Malawi", value: "Malawi" }, @@ -163,7 +163,7 @@ export default [ { text: "Mexico", value: "Mexico" }, { text: "Micronesia, Federated States of", - value: "Micronesia, Federated States of", + value: "Micronesia, Federated States of" }, { text: "Moldova, Republic of", value: "Moldova, Republic of" }, { text: "Monaco", value: "Monaco" }, @@ -192,7 +192,7 @@ export default [ { text: "Palau", value: "Palau" }, { text: "Palestinian Territory, Occupied", - value: "Palestinian Territory, Occupied", + value: "Palestinian Territory, Occupied" }, { text: "Panama", value: "Panama" }, { text: "Papua New Guinea", value: "Papua New Guinea" }, @@ -214,7 +214,7 @@ export default [ { text: "Saint Pierre and Miquelon", value: "Saint Pierre and Miquelon" }, { text: "Saint Vincent and the Grenadines", - value: "Saint Vincent and the Grenadines", + value: "Saint Vincent and the Grenadines" }, { text: "Samoa", value: "Samoa" }, { text: "San Marino", value: "San Marino" }, @@ -232,7 +232,7 @@ export default [ { text: "South Africa", value: "South Africa" }, { text: "South Georgia and the South Sandwich Islands", - value: "South Georgia and the South Sandwich Islands", + value: "South Georgia and the South Sandwich Islands" }, { text: "Spain", value: "Spain" }, { text: "Sri Lanka", value: "Sri Lanka" }, @@ -247,7 +247,7 @@ export default [ { text: "Tajikistan", value: "Tajikistan" }, { text: "Tanzania, United Republic of", - value: "Tanzania, United Republic of", + value: "Tanzania, United Republic of" }, { text: "Thailand", value: "Thailand" }, { text: "Timor-Leste", value: "Timor-Leste" }, @@ -267,7 +267,7 @@ export default [ { text: "United States", value: "United States" }, { text: "United States Minor Outlying Islands", - value: "United States Minor Outlying Islands", + value: "United States Minor Outlying Islands" }, { text: "Uruguay", value: "Uruguay" }, { text: "Uzbekistan", value: "Uzbekistan" }, @@ -280,5 +280,5 @@ export default [ { text: "Western Sahara", value: "Western Sahara" }, { text: "Yemen", value: "Yemen" }, { text: "Zambia", value: "Zambia" }, - { text: "Zimbabwe", value: "Zimbabwe" }, + { text: "Zimbabwe", value: "Zimbabwe" } ]; diff --git a/src/storage/icons.js b/src/storage/icons.js index 69856e85..b2b137ee 100644 --- a/src/storage/icons.js +++ b/src/storage/icons.js @@ -1,3246 +1,3246 @@ export default [ { value: "ad", - text: "ad ", + text: "ad " }, { value: "address-book", - text: "address-book ", + text: "address-book " }, { value: "address-card", - text: "address-card ", + text: "address-card " }, { value: "adjust", - text: "adjust ", + text: "adjust " }, { value: "air-freshener", - text: "air-freshener ", + text: "air-freshener " }, { value: "align-center", - text: "align-center ", + text: "align-center " }, { value: "align-justify", - text: "align-justify ", + text: "align-justify " }, { value: "align-left", - text: "align-left ", + text: "align-left " }, { value: "align-right", - text: "align-right ", + text: "align-right " }, { value: "allergies", - text: "allergies ", + text: "allergies " }, { value: "ambulance", - text: "ambulance ", + text: "ambulance " }, { value: "american-sign-language-interpreting", - text: "american-sign-language-interpreting ", + text: "american-sign-language-interpreting " }, { value: "anchor", - text: "anchor ", + text: "anchor " }, { value: "angle-double-down", - text: "angle-double-down ", + text: "angle-double-down " }, { value: "angle-double-left", - text: "angle-double-left ", + text: "angle-double-left " }, { value: "angle-double-right", - text: "angle-double-right ", + text: "angle-double-right " }, { value: "angle-double-up", - text: "angle-double-up ", + text: "angle-double-up " }, { value: "angle-down", - text: "angle-down ", + text: "angle-down " }, { value: "angle-left", - text: "angle-left ", + text: "angle-left " }, { value: "angle-right", - text: "angle-right ", + text: "angle-right " }, { value: "angle-up", - text: "angle-up ", + text: "angle-up " }, { value: "angry", - text: "angry ", + text: "angry " }, { value: "ankh", - text: "ankh ", + text: "ankh " }, { value: "apple-alt", - text: "apple-alt ", + text: "apple-alt " }, { value: "archive", - text: "archive ", + text: "archive " }, { value: "archway", - text: "archway ", + text: "archway " }, { value: "arrow-alt-circle-down", - text: "arrow-alt-circle-down ", + text: "arrow-alt-circle-down " }, { value: "arrow-alt-circle-left", - text: "arrow-alt-circle-left ", + text: "arrow-alt-circle-left " }, { value: "arrow-alt-circle-right", - text: "arrow-alt-circle-right ", + text: "arrow-alt-circle-right " }, { value: "arrow-alt-circle-up", - text: "arrow-alt-circle-up ", + text: "arrow-alt-circle-up " }, { value: "arrow-circle-down", - text: "arrow-circle-down ", + text: "arrow-circle-down " }, { value: "arrow-circle-left", - text: "arrow-circle-left ", + text: "arrow-circle-left " }, { value: "arrow-circle-right", - text: "arrow-circle-right ", + text: "arrow-circle-right " }, { value: "arrow-circle-up", - text: "arrow-circle-up ", + text: "arrow-circle-up " }, { value: "arrow-down", - text: "arrow-down ", + text: "arrow-down " }, { value: "arrow-left", - text: "arrow-left ", + text: "arrow-left " }, { value: "arrow-right", - text: "arrow-right ", + text: "arrow-right " }, { value: "arrow-up", - text: "arrow-up ", + text: "arrow-up " }, { value: "arrows-alt", - text: "arrows-alt ", + text: "arrows-alt " }, { value: "arrows-alt-h", - text: "arrows-alt-h ", + text: "arrows-alt-h " }, { value: "arrows-alt-v", - text: "arrows-alt-v ", + text: "arrows-alt-v " }, { value: "assistive-listening-systems", - text: "assistive-listening-systems ", + text: "assistive-listening-systems " }, { value: "asterisk", - text: "asterisk ", + text: "asterisk " }, { value: "at", - text: "at ", + text: "at " }, { value: "atlas", - text: "atlas ", + text: "atlas " }, { value: "atom", - text: "atom ", + text: "atom " }, { value: "audio-description", - text: "audio-description ", + text: "audio-description " }, { value: "award", - text: "award ", + text: "award " }, { value: "backspace", - text: "backspace ", + text: "backspace " }, { value: "backward", - text: "backward ", + text: "backward " }, { value: "balance-scale", - text: "balance-scale ", + text: "balance-scale " }, { value: "ban", - text: "ban ", + text: "ban " }, { value: "band-aid", - text: "band-aid ", + text: "band-aid " }, { value: "barcode", - text: "barcode ", + text: "barcode " }, { value: "bars", - text: "bars ", + text: "bars " }, { value: "baseball-ball", - text: "baseball-ball ", + text: "baseball-ball " }, { value: "basketball-ball", - text: "basketball-ball ", + text: "basketball-ball " }, { value: "bath", - text: "bath ", + text: "bath " }, { value: "battery-empty", - text: "battery-empty ", + text: "battery-empty " }, { value: "battery-full", - text: "battery-full ", + text: "battery-full " }, { value: "battery-half", - text: "battery-half ", + text: "battery-half " }, { value: "battery-quarter", - text: "battery-quarter ", + text: "battery-quarter " }, { value: "battery-three-quarters", - text: "battery-three-quarters ", + text: "battery-three-quarters " }, { value: "bed", - text: "bed ", + text: "bed " }, { value: "beer", - text: "beer ", + text: "beer " }, { value: "bell", - text: "bell ", + text: "bell " }, { value: "bell-slash", - text: "bell-slash ", + text: "bell-slash " }, { value: "bezier-curve", - text: "bezier-curve ", + text: "bezier-curve " }, { value: "bible", - text: "bible ", + text: "bible " }, { value: "bicycle", - text: "bicycle ", + text: "bicycle " }, { value: "binoculars", - text: "binoculars ", + text: "binoculars " }, { value: "birthday-cake", - text: "birthday-cake ", + text: "birthday-cake " }, { value: "blender", - text: "blender ", + text: "blender " }, { value: "blind", - text: "blind ", + text: "blind " }, { value: "bold", - text: "bold ", + text: "bold " }, { value: "bolt", - text: "bolt ", + text: "bolt " }, { value: "bomb", - text: "bomb ", + text: "bomb " }, { value: "bone", - text: "bone ", + text: "bone " }, { value: "bong", - text: "bong ", + text: "bong " }, { value: "book", - text: "book ", + text: "book " }, { value: "book-open", - text: "book-open ", + text: "book-open " }, { value: "book-reader", - text: "book-reader ", + text: "book-reader " }, { value: "bookmark", - text: "bookmark ", + text: "bookmark " }, { value: "bowling-ball", - text: "bowling-ball ", + text: "bowling-ball " }, { value: "box", - text: "box ", + text: "box " }, { value: "box-open", - text: "box-open ", + text: "box-open " }, { value: "boxes", - text: "boxes ", + text: "boxes " }, { value: "braille", - text: "braille ", + text: "braille " }, { value: "brain", - text: "brain ", + text: "brain " }, { value: "briefcase", - text: "briefcase ", + text: "briefcase " }, { value: "briefcase-medical", - text: "briefcase-medical ", + text: "briefcase-medical " }, { value: "broadcast-tower", - text: "broadcast-tower ", + text: "broadcast-tower " }, { value: "broom", - text: "broom ", + text: "broom " }, { value: "brush", - text: "brush ", + text: "brush " }, { value: "bug", - text: "bug ", + text: "bug " }, { value: "building", - text: "building ", + text: "building " }, { value: "bullhorn", - text: "bullhorn ", + text: "bullhorn " }, { value: "bullseye", - text: "bullseye ", + text: "bullseye " }, { value: "burn", - text: "burn ", + text: "burn " }, { value: "bus", - text: "bus ", + text: "bus " }, { value: "bus-alt", - text: "bus-alt ", + text: "bus-alt " }, { value: "business-time", - text: "business-time ", + text: "business-time " }, { value: "calculator", - text: "calculator ", + text: "calculator " }, { value: "calendar", - text: "calendar ", + text: "calendar " }, { value: "calendar-alt", - text: "calendar-alt ", + text: "calendar-alt " }, { value: "calendar-check", - text: "calendar-check ", + text: "calendar-check " }, { value: "calendar-minus", - text: "calendar-minus ", + text: "calendar-minus " }, { value: "calendar-plus", - text: "calendar-plus ", + text: "calendar-plus " }, { value: "calendar-times", - text: "calendar-times ", + text: "calendar-times " }, { value: "camera", - text: "camera ", + text: "camera " }, { value: "camera-retro", - text: "camera-retro ", + text: "camera-retro " }, { value: "cannabis", - text: "cannabis ", + text: "cannabis " }, { value: "capsules", - text: "capsules ", + text: "capsules " }, { value: "car", - text: "car ", + text: "car " }, { value: "car-alt", - text: "car-alt ", + text: "car-alt " }, { value: "car-battery", - text: "car-battery ", + text: "car-battery " }, { value: "car-crash", - text: "car-crash ", + text: "car-crash " }, { value: "car-side", - text: "car-side ", + text: "car-side " }, { value: "caret-down", - text: "caret-down ", + text: "caret-down " }, { value: "caret-left", - text: "caret-left ", + text: "caret-left " }, { value: "caret-right", - text: "caret-right ", + text: "caret-right " }, { value: "caret-square-down", - text: "caret-square-down ", + text: "caret-square-down " }, { value: "caret-square-left", - text: "caret-square-left ", + text: "caret-square-left " }, { value: "caret-square-right", - text: "caret-square-right ", + text: "caret-square-right " }, { value: "caret-square-up", - text: "caret-square-up ", + text: "caret-square-up " }, { value: "caret-up", - text: "caret-up ", + text: "caret-up " }, { value: "cart-arrow-down", - text: "cart-arrow-down ", + text: "cart-arrow-down " }, { value: "cart-plus", - text: "cart-plus ", + text: "cart-plus " }, { value: "certificate", - text: "certificate ", + text: "certificate " }, { value: "chalkboard", - text: "chalkboard ", + text: "chalkboard " }, { value: "chalkboard-teacher", - text: "chalkboard-teacher ", + text: "chalkboard-teacher " }, { value: "charging-station", - text: "charging-station ", + text: "charging-station " }, { value: "chart-area", - text: "chart-area ", + text: "chart-area " }, { value: "chart-bar", - text: "chart-bar ", + text: "chart-bar " }, { value: "chart-line", - text: "chart-line ", + text: "chart-line " }, { value: "chart-pie", - text: "chart-pie ", + text: "chart-pie " }, { value: "check", - text: "check ", + text: "check " }, { value: "check-circle", - text: "check-circle ", + text: "check-circle " }, { value: "check-double", - text: "check-double ", + text: "check-double " }, { value: "check-square", - text: "check-square ", + text: "check-square " }, { value: "chess", - text: "chess ", + text: "chess " }, { value: "chess-bishop", - text: "chess-bishop ", + text: "chess-bishop " }, { value: "chess-board", - text: "chess-board ", + text: "chess-board " }, { value: "chess-king", - text: "chess-king ", + text: "chess-king " }, { value: "chess-knight", - text: "chess-knight ", + text: "chess-knight " }, { value: "chess-pawn", - text: "chess-pawn ", + text: "chess-pawn " }, { value: "chess-queen", - text: "chess-queen ", + text: "chess-queen " }, { value: "chess-rook", - text: "chess-rook ", + text: "chess-rook " }, { value: "chevron-circle-down", - text: "chevron-circle-down ", + text: "chevron-circle-down " }, { value: "chevron-circle-left", - text: "chevron-circle-left ", + text: "chevron-circle-left " }, { value: "chevron-circle-right", - text: "chevron-circle-right ", + text: "chevron-circle-right " }, { value: "chevron-circle-up", - text: "chevron-circle-up ", + text: "chevron-circle-up " }, { value: "chevron-down", - text: "chevron-down ", + text: "chevron-down " }, { value: "chevron-left", - text: "chevron-left ", + text: "chevron-left " }, { value: "chevron-right", - text: "chevron-right ", + text: "chevron-right " }, { value: "chevron-up", - text: "chevron-up ", + text: "chevron-up " }, { value: "child", - text: "child ", + text: "child " }, { value: "church", - text: "church ", + text: "church " }, { value: "circle", - text: "circle ", + text: "circle " }, { value: "circle-notch", - text: "circle-notch ", + text: "circle-notch " }, { value: "city", - text: "city ", + text: "city " }, { value: "clipboard", - text: "clipboard ", + text: "clipboard " }, { value: "clipboard-check", - text: "clipboard-check ", + text: "clipboard-check " }, { value: "clipboard-list", - text: "clipboard-list ", + text: "clipboard-list " }, { value: "clock", - text: "clock ", + text: "clock " }, { value: "clone", - text: "clone ", + text: "clone " }, { value: "closed-captioning", - text: "closed-captioning ", + text: "closed-captioning " }, { value: "cloud", - text: "cloud ", + text: "cloud " }, { value: "cloud-download-alt", - text: "cloud-download-alt ", + text: "cloud-download-alt " }, { value: "cloud-upload-alt", - text: "cloud-upload-alt ", + text: "cloud-upload-alt " }, { value: "cocktail", - text: "cocktail ", + text: "cocktail " }, { value: "code", - text: "code ", + text: "code " }, { value: "code-branch", - text: "code-branch ", + text: "code-branch " }, { value: "coffee", - text: "coffee ", + text: "coffee " }, { value: "cog", - text: "cog ", + text: "cog " }, { value: "cogs", - text: "cogs ", + text: "cogs " }, { value: "coins", - text: "coins ", + text: "coins " }, { value: "columns", - text: "columns ", + text: "columns " }, { value: "comment", - text: "comment ", + text: "comment " }, { value: "comment-alt", - text: "comment-alt ", + text: "comment-alt " }, { value: "comment-dollar", - text: "comment-dollar ", + text: "comment-dollar " }, { value: "comment-dots", - text: "comment-dots ", + text: "comment-dots " }, { value: "comment-slash", - text: "comment-slash ", + text: "comment-slash " }, { value: "comments", - text: "comments ", + text: "comments " }, { value: "comments-dollar", - text: "comments-dollar ", + text: "comments-dollar " }, { value: "compact-disc", - text: "compact-disc ", + text: "compact-disc " }, { value: "compass", - text: "compass ", + text: "compass " }, { value: "compress", - text: "compress ", + text: "compress " }, { value: "concierge-bell", - text: "concierge-bell ", + text: "concierge-bell " }, { value: "cookie", - text: "cookie ", + text: "cookie " }, { value: "cookie-bite", - text: "cookie-bite ", + text: "cookie-bite " }, { value: "copy", - text: "copy ", + text: "copy " }, { value: "copyright", - text: "copyright ", + text: "copyright " }, { value: "couch", - text: "couch ", + text: "couch " }, { value: "credit-card", - text: "credit-card ", + text: "credit-card " }, { value: "crop", - text: "crop ", + text: "crop " }, { value: "crop-alt", - text: "crop-alt ", + text: "crop-alt " }, { value: "cross", - text: "cross ", + text: "cross " }, { value: "crosshairs", - text: "crosshairs ", + text: "crosshairs " }, { value: "crow", - text: "crow ", + text: "crow " }, { value: "crown", - text: "crown ", + text: "crown " }, { value: "cube", - text: "cube ", + text: "cube " }, { value: "cubes", - text: "cubes ", + text: "cubes " }, { value: "cut", - text: "cut ", + text: "cut " }, { value: "database", - text: "database ", + text: "database " }, { value: "deaf", - text: "deaf ", + text: "deaf " }, { value: "desktop", - text: "desktop ", + text: "desktop " }, { value: "dharmachakra", - text: "dharmachakra ", + text: "dharmachakra " }, { value: "diagnoses", - text: "diagnoses ", + text: "diagnoses " }, { value: "dice", - text: "dice ", + text: "dice " }, { value: "dice-five", - text: "dice-five ", + text: "dice-five " }, { value: "dice-four", - text: "dice-four ", + text: "dice-four " }, { value: "dice-one", - text: "dice-one ", + text: "dice-one " }, { value: "dice-six", - text: "dice-six ", + text: "dice-six " }, { value: "dice-three", - text: "dice-three ", + text: "dice-three " }, { value: "dice-two", - text: "dice-two ", + text: "dice-two " }, { value: "digital-tachograph", - text: "digital-tachograph ", + text: "digital-tachograph " }, { value: "directions", - text: "directions ", + text: "directions " }, { value: "divide", - text: "divide ", + text: "divide " }, { value: "dizzy", - text: "dizzy ", + text: "dizzy " }, { value: "dna", - text: "dna ", + text: "dna " }, { value: "dollar-sign", - text: "dollar-sign ", + text: "dollar-sign " }, { value: "dolly", - text: "dolly ", + text: "dolly " }, { value: "dolly-flatbed", - text: "dolly-flatbed ", + text: "dolly-flatbed " }, { value: "donate", - text: "donate ", + text: "donate " }, { value: "door-closed", - text: "door-closed ", + text: "door-closed " }, { value: "door-open", - text: "door-open ", + text: "door-open " }, { value: "dot-circle", - text: "dot-circle ", + text: "dot-circle " }, { value: "dove", - text: "dove ", + text: "dove " }, { value: "download", - text: "download ", + text: "download " }, { value: "drafting-compass", - text: "drafting-compass ", + text: "drafting-compass " }, { value: "draw-polygon", - text: "draw-polygon ", + text: "draw-polygon " }, { value: "drum", - text: "drum ", + text: "drum " }, { value: "drum-steelpan", - text: "drum-steelpan ", + text: "drum-steelpan " }, { value: "dumbbell", - text: "dumbbell ", + text: "dumbbell " }, { value: "edit", - text: "edit ", + text: "edit " }, { value: "eject", - text: "eject ", + text: "eject " }, { value: "ellipsis-h", - text: "ellipsis-h ", + text: "ellipsis-h " }, { value: "ellipsis-v", - text: "ellipsis-v ", + text: "ellipsis-v " }, { value: "envelope", - text: "envelope ", + text: "envelope " }, { value: "envelope-open", - text: "envelope-open ", + text: "envelope-open " }, { value: "envelope-open-text", - text: "envelope-open-text ", + text: "envelope-open-text " }, { value: "envelope-square", - text: "envelope-square ", + text: "envelope-square " }, { value: "equals", - text: "equals ", + text: "equals " }, { value: "eraser", - text: "eraser ", + text: "eraser " }, { value: "euro-sign", - text: "euro-sign ", + text: "euro-sign " }, { value: "exchange-alt", - text: "exchange-alt ", + text: "exchange-alt " }, { value: "exclamation", - text: "exclamation ", + text: "exclamation " }, { value: "exclamation-circle", - text: "exclamation-circle ", + text: "exclamation-circle " }, { value: "exclamation-triangle", - text: "exclamation-triangle ", + text: "exclamation-triangle " }, { value: "expand", - text: "expand ", + text: "expand " }, { value: "expand-arrows-alt", - text: "expand-arrows-alt ", + text: "expand-arrows-alt " }, { value: "external-link-alt", - text: "external-link-alt ", + text: "external-link-alt " }, { value: "external-link-square-alt", - text: "external-link-square-alt ", + text: "external-link-square-alt " }, { value: "eye", - text: "eye ", + text: "eye " }, { value: "eye-dropper", - text: "eye-dropper ", + text: "eye-dropper " }, { value: "eye-slash", - text: "eye-slash ", + text: "eye-slash " }, { value: "fast-backward", - text: "fast-backward ", + text: "fast-backward " }, { value: "fast-forward", - text: "fast-forward ", + text: "fast-forward " }, { value: "fax", - text: "fax ", + text: "fax " }, { value: "feather", - text: "feather ", + text: "feather " }, { value: "feather-alt", - text: "feather-alt ", + text: "feather-alt " }, { value: "female", - text: "female ", + text: "female " }, { value: "fighter-jet", - text: "fighter-jet ", + text: "fighter-jet " }, { value: "file", - text: "file ", + text: "file " }, { value: "file-alt", - text: "file-alt ", + text: "file-alt " }, { value: "file-archive", - text: "file-archive ", + text: "file-archive " }, { value: "file-audio", - text: "file-audio ", + text: "file-audio " }, { value: "file-code", - text: "file-code ", + text: "file-code " }, { value: "file-contract", - text: "file-contract ", + text: "file-contract " }, { value: "file-download", - text: "file-download ", + text: "file-download " }, { value: "file-excel", - text: "file-excel ", + text: "file-excel " }, { value: "file-export", - text: "file-export ", + text: "file-export " }, { value: "file-image", - text: "file-image ", + text: "file-image " }, { value: "file-import", - text: "file-import ", + text: "file-import " }, { value: "file-invoice", - text: "file-invoice ", + text: "file-invoice " }, { value: "file-invoice-dollar", - text: "file-invoice-dollar ", + text: "file-invoice-dollar " }, { value: "file-medical", - text: "file-medical ", + text: "file-medical " }, { value: "file-medical-alt", - text: "file-medical-alt ", + text: "file-medical-alt " }, { value: "file-pdf", - text: "file-pdf ", + text: "file-pdf " }, { value: "file-powerpoint", - text: "file-powerpoint ", + text: "file-powerpoint " }, { value: "file-prescription", - text: "file-prescription ", + text: "file-prescription " }, { value: "file-signature", - text: "file-signature ", + text: "file-signature " }, { value: "file-upload", - text: "file-upload ", + text: "file-upload " }, { value: "file-video", - text: "file-video ", + text: "file-video " }, { value: "file-word", - text: "file-word ", + text: "file-word " }, { value: "fill", - text: "fill ", + text: "fill " }, { value: "fill-drip", - text: "fill-drip ", + text: "fill-drip " }, { value: "film", - text: "film ", + text: "film " }, { value: "filter", - text: "filter ", + text: "filter " }, { value: "fingerprint", - text: "fingerprint ", + text: "fingerprint " }, { value: "fire", - text: "fire ", + text: "fire " }, { value: "fire-extinguisher", - text: "fire-extinguisher ", + text: "fire-extinguisher " }, { value: "first-aid", - text: "first-aid ", + text: "first-aid " }, { value: "fish", - text: "fish ", + text: "fish " }, { value: "flag", - text: "flag ", + text: "flag " }, { value: "flag-checkered", - text: "flag-checkered ", + text: "flag-checkered " }, { value: "flask", - text: "flask ", + text: "flask " }, { value: "flushed", - text: "flushed ", + text: "flushed " }, { value: "folder", - text: "folder ", + text: "folder " }, { value: "folder-minus", - text: "folder-minus ", + text: "folder-minus " }, { value: "folder-open", - text: "folder-open ", + text: "folder-open " }, { value: "folder-plus", - text: "folder-plus ", + text: "folder-plus " }, { value: "font", - text: "font ", + text: "font " }, { value: "font-awesome-logo-full", - text: "font-awesome-logo-full ", + text: "font-awesome-logo-full " }, { value: "football-ball", - text: "football-ball ", + text: "football-ball " }, { value: "forward", - text: "forward ", + text: "forward " }, { value: "frog", - text: "frog ", + text: "frog " }, { value: "frown", - text: "frown ", + text: "frown " }, { value: "frown-open", - text: "frown-open ", + text: "frown-open " }, { value: "funnel-dollar", - text: "funnel-dollar ", + text: "funnel-dollar " }, { value: "futbol", - text: "futbol ", + text: "futbol " }, { value: "gamepad", - text: "gamepad ", + text: "gamepad " }, { value: "gas-pump", - text: "gas-pump ", + text: "gas-pump " }, { value: "gavel", - text: "gavel ", + text: "gavel " }, { value: "gem", - text: "gem ", + text: "gem " }, { value: "genderless", - text: "genderless ", + text: "genderless " }, { value: "gift", - text: "gift ", + text: "gift " }, { value: "glass-martini", - text: "glass-martini ", + text: "glass-martini " }, { value: "glass-martini-alt", - text: "glass-martini-alt ", + text: "glass-martini-alt " }, { value: "glasses", - text: "glasses ", + text: "glasses " }, { value: "globe", - text: "globe ", + text: "globe " }, { value: "globe-africa", - text: "globe-africa ", + text: "globe-africa " }, { value: "globe-americas", - text: "globe-americas ", + text: "globe-americas " }, { value: "globe-asia", - text: "globe-asia ", + text: "globe-asia " }, { value: "golf-ball", - text: "golf-ball ", + text: "golf-ball " }, { value: "gopuram", - text: "gopuram ", + text: "gopuram " }, { value: "graduation-cap", - text: "graduation-cap ", + text: "graduation-cap " }, { value: "greater-than", - text: "greater-than ", + text: "greater-than " }, { value: "greater-than-equal", - text: "greater-than-equal ", + text: "greater-than-equal " }, { value: "grimace", - text: "grimace ", + text: "grimace " }, { value: "grin", - text: "grin ", + text: "grin " }, { value: "grin-alt", - text: "grin-alt ", + text: "grin-alt " }, { value: "grin-beam", - text: "grin-beam ", + text: "grin-beam " }, { value: "grin-beam-sweat", - text: "grin-beam-sweat ", + text: "grin-beam-sweat " }, { value: "grin-hearts", - text: "grin-hearts ", + text: "grin-hearts " }, { value: "grin-squint", - text: "grin-squint ", + text: "grin-squint " }, { value: "grin-squint-tears", - text: "grin-squint-tears ", + text: "grin-squint-tears " }, { value: "grin-stars", - text: "grin-stars ", + text: "grin-stars " }, { value: "grin-tears", - text: "grin-tears ", + text: "grin-tears " }, { value: "grin-tongue", - text: "grin-tongue ", + text: "grin-tongue " }, { value: "grin-tongue-squint", - text: "grin-tongue-squint ", + text: "grin-tongue-squint " }, { value: "grin-tongue-wink", - text: "grin-tongue-wink ", + text: "grin-tongue-wink " }, { value: "grin-wink", - text: "grin-wink ", + text: "grin-wink " }, { value: "grip-horizontal", - text: "grip-horizontal ", + text: "grip-horizontal " }, { value: "grip-vertical", - text: "grip-vertical ", + text: "grip-vertical " }, { value: "h-square", - text: "h-square ", + text: "h-square " }, { value: "hamsa", - text: "hamsa ", + text: "hamsa " }, { value: "hand-holding", - text: "hand-holding ", + text: "hand-holding " }, { value: "hand-holding-heart", - text: "hand-holding-heart ", + text: "hand-holding-heart " }, { value: "hand-holding-usd", - text: "hand-holding-usd ", + text: "hand-holding-usd " }, { value: "hand-lizard", - text: "hand-lizard ", + text: "hand-lizard " }, { value: "hand-paper", - text: "hand-paper ", + text: "hand-paper " }, { value: "hand-peace", - text: "hand-peace ", + text: "hand-peace " }, { value: "hand-point-down", - text: "hand-point-down ", + text: "hand-point-down " }, { value: "hand-point-left", - text: "hand-point-left ", + text: "hand-point-left " }, { value: "hand-point-right", - text: "hand-point-right ", + text: "hand-point-right " }, { value: "hand-point-up", - text: "hand-point-up ", + text: "hand-point-up " }, { value: "hand-pointer", - text: "hand-pointer ", + text: "hand-pointer " }, { value: "hand-rock", - text: "hand-rock ", + text: "hand-rock " }, { value: "hand-scissors", - text: "hand-scissors ", + text: "hand-scissors " }, { value: "hand-spock", - text: "hand-spock ", + text: "hand-spock " }, { value: "hands", - text: "hands ", + text: "hands " }, { value: "hands-helping", - text: "hands-helping ", + text: "hands-helping " }, { value: "handshake", - text: "handshake ", + text: "handshake " }, { value: "hashtag", - text: "hashtag ", + text: "hashtag " }, { value: "haykal", - text: "haykal ", + text: "haykal " }, { value: "hdd", - text: "hdd ", + text: "hdd " }, { value: "heading", - text: "heading ", + text: "heading " }, { value: "headphones", - text: "headphones ", + text: "headphones " }, { value: "headphones-alt", - text: "headphones-alt ", + text: "headphones-alt " }, { value: "headset", - text: "headset ", + text: "headset " }, { value: "heart", - text: "heart ", + text: "heart " }, { value: "heartbeat", - text: "heartbeat ", + text: "heartbeat " }, { value: "helicopter", - text: "helicopter ", + text: "helicopter " }, { value: "highlighter", - text: "highlighter ", + text: "highlighter " }, { value: "history", - text: "history ", + text: "history " }, { value: "hockey-puck", - text: "hockey-puck ", + text: "hockey-puck " }, { value: "home", - text: "home ", + text: "home " }, { value: "hospital", - text: "hospital ", + text: "hospital " }, { value: "hospital-alt", - text: "hospital-alt ", + text: "hospital-alt " }, { value: "hospital-symbol", - text: "hospital-symbol ", + text: "hospital-symbol " }, { value: "hot-tub", - text: "hot-tub ", + text: "hot-tub " }, { value: "hotel", - text: "hotel ", + text: "hotel " }, { value: "hourglass", - text: "hourglass ", + text: "hourglass " }, { value: "hourglass-end", - text: "hourglass-end ", + text: "hourglass-end " }, { value: "hourglass-half", - text: "hourglass-half ", + text: "hourglass-half " }, { value: "hourglass-start", - text: "hourglass-start ", + text: "hourglass-start " }, { value: "i-cursor", - text: "i-cursor ", + text: "i-cursor " }, { value: "id-badge", - text: "id-badge ", + text: "id-badge " }, { value: "id-card", - text: "id-card ", + text: "id-card " }, { value: "id-card-alt", - text: "id-card-alt ", + text: "id-card-alt " }, { value: "image", - text: "image ", + text: "image " }, { value: "images", - text: "images ", + text: "images " }, { value: "inbox", - text: "inbox ", + text: "inbox " }, { value: "indent", - text: "indent ", + text: "indent " }, { value: "industry", - text: "industry ", + text: "industry " }, { value: "infinity", - text: "infinity ", + text: "infinity " }, { value: "info", - text: "info ", + text: "info " }, { value: "info-circle", - text: "info-circle ", + text: "info-circle " }, { value: "italic", - text: "italic ", + text: "italic " }, { value: "jedi", - text: "jedi ", + text: "jedi " }, { value: "joint", - text: "joint ", + text: "joint " }, { value: "journal-whills", - text: "journal-whills ", + text: "journal-whills " }, { value: "kaaba", - text: "kaaba ", + text: "kaaba " }, { value: "key", - text: "key ", + text: "key " }, { value: "keyboard", - text: "keyboard ", + text: "keyboard " }, { value: "khanda", - text: "khanda ", + text: "khanda " }, { value: "kiss", - text: "kiss ", + text: "kiss " }, { value: "kiss-beam", - text: "kiss-beam ", + text: "kiss-beam " }, { value: "kiss-wink-heart", - text: "kiss-wink-heart ", + text: "kiss-wink-heart " }, { value: "kiwi-bird", - text: "kiwi-bird ", + text: "kiwi-bird " }, { value: "landmark", - text: "landmark ", + text: "landmark " }, { value: "language", - text: "language ", + text: "language " }, { value: "laptop", - text: "laptop ", + text: "laptop " }, { value: "laptop-code", - text: "laptop-code ", + text: "laptop-code " }, { value: "laugh", - text: "laugh ", + text: "laugh " }, { value: "laugh-beam", - text: "laugh-beam ", + text: "laugh-beam " }, { value: "laugh-squint", - text: "laugh-squint ", + text: "laugh-squint " }, { value: "laugh-wink", - text: "laugh-wink ", + text: "laugh-wink " }, { value: "layer-group", - text: "layer-group ", + text: "layer-group " }, { value: "leaf", - text: "leaf ", + text: "leaf " }, { value: "lemon", - text: "lemon ", + text: "lemon " }, { value: "less-than", - text: "less-than ", + text: "less-than " }, { value: "less-than-equal", - text: "less-than-equal ", + text: "less-than-equal " }, { value: "level-down-alt", - text: "level-down-alt ", + text: "level-down-alt " }, { value: "level-up-alt", - text: "level-up-alt ", + text: "level-up-alt " }, { value: "life-ring", - text: "life-ring ", + text: "life-ring " }, { value: "lightbulb", - text: "lightbulb ", + text: "lightbulb " }, { value: "link", - text: "link ", + text: "link " }, { value: "lira-sign", - text: "lira-sign ", + text: "lira-sign " }, { value: "list", - text: "list ", + text: "list " }, { value: "list-alt", - text: "list-alt ", + text: "list-alt " }, { value: "list-ol", - text: "list-ol ", + text: "list-ol " }, { value: "list-ul", - text: "list-ul ", + text: "list-ul " }, { value: "location-arrow", - text: "location-arrow ", + text: "location-arrow " }, { value: "lock", - text: "lock ", + text: "lock " }, { value: "lock-open", - text: "lock-open ", + text: "lock-open " }, { value: "long-arrow-alt-down", - text: "long-arrow-alt-down ", + text: "long-arrow-alt-down " }, { value: "long-arrow-alt-left", - text: "long-arrow-alt-left ", + text: "long-arrow-alt-left " }, { value: "long-arrow-alt-right", - text: "long-arrow-alt-right ", + text: "long-arrow-alt-right " }, { value: "long-arrow-alt-up", - text: "long-arrow-alt-up ", + text: "long-arrow-alt-up " }, { value: "low-vision", - text: "low-vision ", + text: "low-vision " }, { value: "luggage-cart", - text: "luggage-cart ", + text: "luggage-cart " }, { value: "magic", - text: "magic ", + text: "magic " }, { value: "magnet", - text: "magnet ", + text: "magnet " }, { value: "mail-bulk", - text: "mail-bulk ", + text: "mail-bulk " }, { value: "male", - text: "male ", + text: "male " }, { value: "map", - text: "map ", + text: "map " }, { value: "map-marked", - text: "map-marked ", + text: "map-marked " }, { value: "map-marked-alt", - text: "map-marked-alt ", + text: "map-marked-alt " }, { value: "map-marker", - text: "map-marker ", + text: "map-marker " }, { value: "map-marker-alt", - text: "map-marker-alt ", + text: "map-marker-alt " }, { value: "map-pin", - text: "map-pin ", + text: "map-pin " }, { value: "map-signs", - text: "map-signs ", + text: "map-signs " }, { value: "marker", - text: "marker ", + text: "marker " }, { value: "mars", - text: "mars ", + text: "mars " }, { value: "mars-double", - text: "mars-double ", + text: "mars-double " }, { value: "mars-stroke", - text: "mars-stroke ", + text: "mars-stroke " }, { value: "mars-stroke-h", - text: "mars-stroke-h ", + text: "mars-stroke-h " }, { value: "mars-stroke-v", - text: "mars-stroke-v ", + text: "mars-stroke-v " }, { value: "medal", - text: "medal ", + text: "medal " }, { value: "medkit", - text: "medkit ", + text: "medkit " }, { value: "meh", - text: "meh ", + text: "meh " }, { value: "meh-blank", - text: "meh-blank ", + text: "meh-blank " }, { value: "meh-rolling-eyes", - text: "meh-rolling-eyes ", + text: "meh-rolling-eyes " }, { value: "memory", - text: "memory ", + text: "memory " }, { value: "menorah", - text: "menorah ", + text: "menorah " }, { value: "mercury", - text: "mercury ", + text: "mercury " }, { value: "microchip", - text: "microchip ", + text: "microchip " }, { value: "microphone", - text: "microphone ", + text: "microphone " }, { value: "microphone-alt", - text: "microphone-alt ", + text: "microphone-alt " }, { value: "microphone-alt-slash", - text: "microphone-alt-slash ", + text: "microphone-alt-slash " }, { value: "microphone-slash", - text: "microphone-slash ", + text: "microphone-slash " }, { value: "microscope", - text: "microscope ", + text: "microscope " }, { value: "minus", - text: "minus ", + text: "minus " }, { value: "minus-circle", - text: "minus-circle ", + text: "minus-circle " }, { value: "minus-square", - text: "minus-square ", + text: "minus-square " }, { value: "mobile", - text: "mobile ", + text: "mobile " }, { value: "mobile-alt", - text: "mobile-alt ", + text: "mobile-alt " }, { value: "money-bill", - text: "money-bill ", + text: "money-bill " }, { value: "money-bill-alt", - text: "money-bill-alt ", + text: "money-bill-alt " }, { value: "money-bill-wave", - text: "money-bill-wave ", + text: "money-bill-wave " }, { value: "money-bill-wave-alt", - text: "money-bill-wave-alt ", + text: "money-bill-wave-alt " }, { value: "money-check", - text: "money-check ", + text: "money-check " }, { value: "money-check-alt", - text: "money-check-alt ", + text: "money-check-alt " }, { value: "monument", - text: "monument ", + text: "monument " }, { value: "moon", - text: "moon ", + text: "moon " }, { value: "mortar-pestle", - text: "mortar-pestle ", + text: "mortar-pestle " }, { value: "mosque", - text: "mosque ", + text: "mosque " }, { value: "motorcycle", - text: "motorcycle ", + text: "motorcycle " }, { value: "mouse-pointer", - text: "mouse-pointer ", + text: "mouse-pointer " }, { value: "music", - text: "music ", + text: "music " }, { value: "neuter", - text: "neuter ", + text: "neuter " }, { value: "newspaper", - text: "newspaper ", + text: "newspaper " }, { value: "not-equal", - text: "not-equal ", + text: "not-equal " }, { value: "notes-medical", - text: "notes-medical ", + text: "notes-medical " }, { value: "object-group", - text: "object-group ", + text: "object-group " }, { value: "object-ungroup", - text: "object-ungroup ", + text: "object-ungroup " }, { value: "oil-can", - text: "oil-can ", + text: "oil-can " }, { value: "om", - text: "om ", + text: "om " }, { value: "outdent", - text: "outdent ", + text: "outdent " }, { value: "paint-brush", - text: "paint-brush ", + text: "paint-brush " }, { value: "paint-roller", - text: "paint-roller ", + text: "paint-roller " }, { value: "palette", - text: "palette ", + text: "palette " }, { value: "pallet", - text: "pallet ", + text: "pallet " }, { value: "paper-plane", - text: "paper-plane ", + text: "paper-plane " }, { value: "paperclip", - text: "paperclip ", + text: "paperclip " }, { value: "parachute-box", - text: "parachute-box ", + text: "parachute-box " }, { value: "paragraph", - text: "paragraph ", + text: "paragraph " }, { value: "parking", - text: "parking ", + text: "parking " }, { value: "passport", - text: "passport ", + text: "passport " }, { value: "pastafarianism", - text: "pastafarianism ", + text: "pastafarianism " }, { value: "paste", - text: "paste ", + text: "paste " }, { value: "pause", - text: "pause ", + text: "pause " }, { value: "pause-circle", - text: "pause-circle ", + text: "pause-circle " }, { value: "paw", - text: "paw ", + text: "paw " }, { value: "peace", - text: "peace ", + text: "peace " }, { value: "pen", - text: "pen ", + text: "pen " }, { value: "pen-alt", - text: "pen-alt ", + text: "pen-alt " }, { value: "pen-fancy", - text: "pen-fancy ", + text: "pen-fancy " }, { value: "pen-nib", - text: "pen-nib ", + text: "pen-nib " }, { value: "pen-square", - text: "pen-square ", + text: "pen-square " }, { value: "pencil-alt", - text: "pencil-alt ", + text: "pencil-alt " }, { value: "pencil-ruler", - text: "pencil-ruler ", + text: "pencil-ruler " }, { value: "people-carry", - text: "people-carry ", + text: "people-carry " }, { value: "percent", - text: "percent ", + text: "percent " }, { value: "percentage", - text: "percentage ", + text: "percentage " }, { value: "phone", - text: "phone ", + text: "phone " }, { value: "phone-slash", - text: "phone-slash ", + text: "phone-slash " }, { value: "phone-square", - text: "phone-square ", + text: "phone-square " }, { value: "phone-volume", - text: "phone-volume ", + text: "phone-volume " }, { value: "piggy-bank", - text: "piggy-bank ", + text: "piggy-bank " }, { value: "pills", - text: "pills ", + text: "pills " }, { value: "place-of-worship", - text: "place-of-worship ", + text: "place-of-worship " }, { value: "plane", - text: "plane ", + text: "plane " }, { value: "plane-arrival", - text: "plane-arrival ", + text: "plane-arrival " }, { value: "plane-departure", - text: "plane-departure ", + text: "plane-departure " }, { value: "play", - text: "play ", + text: "play " }, { value: "play-circle", - text: "play-circle ", + text: "play-circle " }, { value: "plug", - text: "plug ", + text: "plug " }, { value: "plus", - text: "plus ", + text: "plus " }, { value: "plus-circle", - text: "plus-circle ", + text: "plus-circle " }, { value: "plus-square", - text: "plus-square ", + text: "plus-square " }, { value: "podcast", - text: "podcast ", + text: "podcast " }, { value: "poll", - text: "poll ", + text: "poll " }, { value: "poll-h", - text: "poll-h ", + text: "poll-h " }, { value: "poo", - text: "poo ", + text: "poo " }, { value: "poop", - text: "poop ", + text: "poop " }, { value: "portrait", - text: "portrait ", + text: "portrait " }, { value: "pound-sign", - text: "pound-sign ", + text: "pound-sign " }, { value: "power-off", - text: "power-off ", + text: "power-off " }, { value: "pray", - text: "pray ", + text: "pray " }, { value: "praying-hands", - text: "praying-hands ", + text: "praying-hands " }, { value: "prescription", - text: "prescription ", + text: "prescription " }, { value: "prescription-bottle", - text: "prescription-bottle ", + text: "prescription-bottle " }, { value: "prescription-bottle-alt", - text: "prescription-bottle-alt ", + text: "prescription-bottle-alt " }, { value: "print", - text: "print ", + text: "print " }, { value: "procedures", - text: "procedures ", + text: "procedures " }, { value: "project-diagram", - text: "project-diagram ", + text: "project-diagram " }, { value: "puzzle-piece", - text: "puzzle-piece ", + text: "puzzle-piece " }, { value: "qrcode", - text: "qrcode ", + text: "qrcode " }, { value: "question", - text: "question ", + text: "question " }, { value: "question-circle", - text: "question-circle ", + text: "question-circle " }, { value: "quidditch", - text: "quidditch ", + text: "quidditch " }, { value: "quote-left", - text: "quote-left ", + text: "quote-left " }, { value: "quote-right", - text: "quote-right ", + text: "quote-right " }, { value: "quran", - text: "quran ", + text: "quran " }, { value: "random", - text: "random ", + text: "random " }, { value: "receipt", - text: "receipt ", + text: "receipt " }, { value: "recycle", - text: "recycle ", + text: "recycle " }, { value: "redo", - text: "redo ", + text: "redo " }, { value: "redo-alt", - text: "redo-alt ", + text: "redo-alt " }, { value: "registered", - text: "registered ", + text: "registered " }, { value: "reply", - text: "reply ", + text: "reply " }, { value: "reply-all", - text: "reply-all ", + text: "reply-all " }, { value: "retweet", - text: "retweet ", + text: "retweet " }, { value: "ribbon", - text: "ribbon ", + text: "ribbon " }, { value: "road", - text: "road ", + text: "road " }, { value: "robot", - text: "robot ", + text: "robot " }, { value: "rocket", - text: "rocket ", + text: "rocket " }, { value: "route", - text: "route ", + text: "route " }, { value: "rss", - text: "rss ", + text: "rss " }, { value: "rss-square", - text: "rss-square ", + text: "rss-square " }, { value: "ruble-sign", - text: "ruble-sign ", + text: "ruble-sign " }, { value: "ruler", - text: "ruler ", + text: "ruler " }, { value: "ruler-combined", - text: "ruler-combined ", + text: "ruler-combined " }, { value: "ruler-horizontal", - text: "ruler-horizontal ", + text: "ruler-horizontal " }, { value: "ruler-vertical", - text: "ruler-vertical ", + text: "ruler-vertical " }, { value: "rupee-sign", - text: "rupee-sign ", + text: "rupee-sign " }, { value: "sad-cry", - text: "sad-cry ", + text: "sad-cry " }, { value: "sad-tear", - text: "sad-tear ", + text: "sad-tear " }, { value: "save", - text: "save ", + text: "save " }, { value: "school", - text: "school ", + text: "school " }, { value: "screwdriver", - text: "screwdriver ", + text: "screwdriver " }, { value: "search", - text: "search ", + text: "search " }, { value: "search-dollar", - text: "search-dollar ", + text: "search-dollar " }, { value: "search-location", - text: "search-location ", + text: "search-location " }, { value: "search-minus", - text: "search-minus ", + text: "search-minus " }, { value: "search-plus", - text: "search-plus ", + text: "search-plus " }, { value: "seedling", - text: "seedling ", + text: "seedling " }, { value: "server", - text: "server ", + text: "server " }, { value: "shapes", - text: "shapes ", + text: "shapes " }, { value: "share", - text: "share ", + text: "share " }, { value: "share-alt", - text: "share-alt ", + text: "share-alt " }, { value: "share-alt-square", - text: "share-alt-square ", + text: "share-alt-square " }, { value: "share-square", - text: "share-square ", + text: "share-square " }, { value: "shekel-sign", - text: "shekel-sign ", + text: "shekel-sign " }, { value: "shield-alt", - text: "shield-alt ", + text: "shield-alt " }, { value: "ship", - text: "ship ", + text: "ship " }, { value: "shipping-fast", - text: "shipping-fast ", + text: "shipping-fast " }, { value: "shoe-prints", - text: "shoe-prints ", + text: "shoe-prints " }, { value: "shopping-bag", - text: "shopping-bag ", + text: "shopping-bag " }, { value: "shopping-basket", - text: "shopping-basket ", + text: "shopping-basket " }, { value: "shopping-cart", - text: "shopping-cart ", + text: "shopping-cart " }, { value: "shower", - text: "shower ", + text: "shower " }, { value: "shuttle-van", - text: "shuttle-van ", + text: "shuttle-van " }, { value: "sign", - text: "sign ", + text: "sign " }, { value: "sign-in-alt", - text: "sign-in-alt ", + text: "sign-in-alt " }, { value: "sign-language", - text: "sign-language ", + text: "sign-language " }, { value: "sign-out-alt", - text: "sign-out-alt ", + text: "sign-out-alt " }, { value: "signal", - text: "signal ", + text: "signal " }, { value: "signature", - text: "signature ", + text: "signature " }, { value: "sitemap", - text: "sitemap ", + text: "sitemap " }, { value: "skull", - text: "skull ", + text: "skull " }, { value: "sliders-h", - text: "sliders-h ", + text: "sliders-h " }, { value: "smile", - text: "smile ", + text: "smile " }, { value: "smile-beam", - text: "smile-beam ", + text: "smile-beam " }, { value: "smile-wink", - text: "smile-wink ", + text: "smile-wink " }, { value: "smoking", - text: "smoking ", + text: "smoking " }, { value: "smoking-ban", - text: "smoking-ban ", + text: "smoking-ban " }, { value: "snowflake", - text: "snowflake ", + text: "snowflake " }, { value: "socks", - text: "socks ", + text: "socks " }, { value: "solar-panel", - text: "solar-panel ", + text: "solar-panel " }, { value: "sort", - text: "sort ", + text: "sort " }, { value: "sort-alpha-down", - text: "sort-alpha-down ", + text: "sort-alpha-down " }, { value: "sort-alpha-up", - text: "sort-alpha-up ", + text: "sort-alpha-up " }, { value: "sort-amount-down", - text: "sort-amount-down ", + text: "sort-amount-down " }, { value: "sort-amount-up", - text: "sort-amount-up ", + text: "sort-amount-up " }, { value: "sort-down", - text: "sort-down ", + text: "sort-down " }, { value: "sort-numeric-down", - text: "sort-numeric-down ", + text: "sort-numeric-down " }, { value: "sort-numeric-up", - text: "sort-numeric-up ", + text: "sort-numeric-up " }, { value: "sort-up", - text: "sort-up ", + text: "sort-up " }, { value: "spa", - text: "spa ", + text: "spa " }, { value: "space-shuttle", - text: "space-shuttle ", + text: "space-shuttle " }, { value: "spinner", - text: "spinner ", + text: "spinner " }, { value: "splotch", - text: "splotch ", + text: "splotch " }, { value: "spray-can", - text: "spray-can ", + text: "spray-can " }, { value: "square", - text: "square ", + text: "square " }, { value: "square-full", - text: "square-full ", + text: "square-full " }, { value: "square-root-alt", - text: "square-root-alt ", + text: "square-root-alt " }, { value: "stamp", - text: "stamp ", + text: "stamp " }, { value: "star", - text: "star ", + text: "star " }, { value: "star-and-crescent", - text: "star-and-crescent ", + text: "star-and-crescent " }, { value: "star-half", - text: "star-half ", + text: "star-half " }, { value: "star-half-alt", - text: "star-half-alt ", + text: "star-half-alt " }, { value: "star-of-david", - text: "star-of-david ", + text: "star-of-david " }, { value: "star-of-life", - text: "star-of-life ", + text: "star-of-life " }, { value: "step-backward", - text: "step-backward ", + text: "step-backward " }, { value: "step-forward", - text: "step-forward ", + text: "step-forward " }, { value: "stethoscope", - text: "stethoscope ", + text: "stethoscope " }, { value: "sticky-note", - text: "sticky-note ", + text: "sticky-note " }, { value: "stop", - text: "stop ", + text: "stop " }, { value: "stop-circle", - text: "stop-circle ", + text: "stop-circle " }, { value: "stopwatch", - text: "stopwatch ", + text: "stopwatch " }, { value: "store", - text: "store ", + text: "store " }, { value: "store-alt", - text: "store-alt ", + text: "store-alt " }, { value: "stream", - text: "stream ", + text: "stream " }, { value: "street-view", - text: "street-view ", + text: "street-view " }, { value: "strikethrough", - text: "strikethrough ", + text: "strikethrough " }, { value: "stroopwafel", - text: "stroopwafel ", + text: "stroopwafel " }, { value: "subscript", - text: "subscript ", + text: "subscript " }, { value: "subway", - text: "subway ", + text: "subway " }, { value: "suitcase", - text: "suitcase ", + text: "suitcase " }, { value: "suitcase-rolling", - text: "suitcase-rolling ", + text: "suitcase-rolling " }, { value: "sun", - text: "sun ", + text: "sun " }, { value: "superscript", - text: "superscript ", + text: "superscript " }, { value: "surprise", - text: "surprise ", + text: "surprise " }, { value: "swatchbook", - text: "swatchbook ", + text: "swatchbook " }, { value: "swimmer", - text: "swimmer ", + text: "swimmer " }, { value: "swimming-pool", - text: "swimming-pool ", + text: "swimming-pool " }, { value: "synagogue", - text: "synagogue ", + text: "synagogue " }, { value: "sync", - text: "sync ", + text: "sync " }, { value: "sync-alt", - text: "sync-alt ", + text: "sync-alt " }, { value: "syringe", - text: "syringe ", + text: "syringe " }, { value: "table", - text: "table ", + text: "table " }, { value: "table-tennis", - text: "table-tennis ", + text: "table-tennis " }, { value: "tablet", - text: "tablet ", + text: "tablet " }, { value: "tablet-alt", - text: "tablet-alt ", + text: "tablet-alt " }, { value: "tablets", - text: "tablets ", + text: "tablets " }, { value: "tachometer-alt", - text: "tachometer-alt ", + text: "tachometer-alt " }, { value: "tag", - text: "tag ", + text: "tag " }, { value: "tags", - text: "tags ", + text: "tags " }, { value: "tape", - text: "tape ", + text: "tape " }, { value: "tasks", - text: "tasks ", + text: "tasks " }, { value: "taxi", - text: "taxi ", + text: "taxi " }, { value: "teeth", - text: "teeth ", + text: "teeth " }, { value: "teeth-open", - text: "teeth-open ", + text: "teeth-open " }, { value: "terminal", - text: "terminal ", + text: "terminal " }, { value: "text-height", - text: "text-height ", + text: "text-height " }, { value: "text-width", - text: "text-width ", + text: "text-width " }, { value: "th", - text: "th ", + text: "th " }, { value: "th-large", - text: "th-large ", + text: "th-large " }, { value: "th-list", - text: "th-list ", + text: "th-list " }, { value: "theater-masks", - text: "theater-masks ", + text: "theater-masks " }, { value: "thermometer", - text: "thermometer ", + text: "thermometer " }, { value: "thermometer-empty", - text: "thermometer-empty ", + text: "thermometer-empty " }, { value: "thermometer-full", - text: "thermometer-full ", + text: "thermometer-full " }, { value: "thermometer-half", - text: "thermometer-half ", + text: "thermometer-half " }, { value: "thermometer-quarter", - text: "thermometer-quarter ", + text: "thermometer-quarter " }, { value: "thermometer-three-quarters", - text: "thermometer-three-quarters ", + text: "thermometer-three-quarters " }, { value: "thumbs-down", - text: "thumbs-down ", + text: "thumbs-down " }, { value: "thumbs-up", - text: "thumbs-up ", + text: "thumbs-up " }, { value: "thumbtack", - text: "thumbtack ", + text: "thumbtack " }, { value: "ticket-alt", - text: "ticket-alt ", + text: "ticket-alt " }, { value: "times", - text: "times ", + text: "times " }, { value: "times-circle", - text: "times-circle ", + text: "times-circle " }, { value: "tint", - text: "tint ", + text: "tint " }, { value: "tint-slash", - text: "tint-slash ", + text: "tint-slash " }, { value: "tired", - text: "tired ", + text: "tired " }, { value: "toggle-off", - text: "toggle-off ", + text: "toggle-off " }, { value: "toggle-on", - text: "toggle-on ", + text: "toggle-on " }, { value: "toolbox", - text: "toolbox ", + text: "toolbox " }, { value: "tooth", - text: "tooth ", + text: "tooth " }, { value: "torah", - text: "torah ", + text: "torah " }, { value: "torii-gate", - text: "torii-gate ", + text: "torii-gate " }, { value: "trademark", - text: "trademark ", + text: "trademark " }, { value: "traffic-light", - text: "traffic-light ", + text: "traffic-light " }, { value: "train", - text: "train ", + text: "train " }, { value: "transgender", - text: "transgender ", + text: "transgender " }, { value: "transgender-alt", - text: "transgender-alt ", + text: "transgender-alt " }, { value: "trash", - text: "trash ", + text: "trash " }, { value: "trash-alt", - text: "trash-alt ", + text: "trash-alt " }, { value: "tree", - text: "tree ", + text: "tree " }, { value: "trophy", - text: "trophy ", + text: "trophy " }, { value: "truck", - text: "truck ", + text: "truck " }, { value: "truck-loading", - text: "truck-loading ", + text: "truck-loading " }, { value: "truck-monster", - text: "truck-monster ", + text: "truck-monster " }, { value: "truck-moving", - text: "truck-moving ", + text: "truck-moving " }, { value: "truck-pickup", - text: "truck-pickup ", + text: "truck-pickup " }, { value: "tshirt", - text: "tshirt ", + text: "tshirt " }, { value: "tty", - text: "tty ", + text: "tty " }, { value: "tv", - text: "tv ", + text: "tv " }, { value: "umbrella", - text: "umbrella ", + text: "umbrella " }, { value: "umbrella-beach", - text: "umbrella-beach ", + text: "umbrella-beach " }, { value: "underline", - text: "underline ", + text: "underline " }, { value: "undo", - text: "undo ", + text: "undo " }, { value: "undo-alt", - text: "undo-alt ", + text: "undo-alt " }, { value: "universal-access", - text: "universal-access ", + text: "universal-access " }, { value: "university", - text: "university ", + text: "university " }, { value: "unlink", - text: "unlink ", + text: "unlink " }, { value: "unlock", - text: "unlock ", + text: "unlock " }, { value: "unlock-alt", - text: "unlock-alt ", + text: "unlock-alt " }, { value: "upload", - text: "upload ", + text: "upload " }, { value: "user", - text: "user ", + text: "user " }, { value: "user-alt", - text: "user-alt ", + text: "user-alt " }, { value: "user-alt-slash", - text: "user-alt-slash ", + text: "user-alt-slash " }, { value: "user-astronaut", - text: "user-astronaut ", + text: "user-astronaut " }, { value: "user-check", - text: "user-check ", + text: "user-check " }, { value: "user-circle", - text: "user-circle ", + text: "user-circle " }, { value: "user-clock", - text: "user-clock ", + text: "user-clock " }, { value: "user-cog", - text: "user-cog ", + text: "user-cog " }, { value: "user-edit", - text: "user-edit ", + text: "user-edit " }, { value: "user-friends", - text: "user-friends ", + text: "user-friends " }, { value: "user-graduate", - text: "user-graduate ", + text: "user-graduate " }, { value: "user-lock", - text: "user-lock ", + text: "user-lock " }, { value: "user-md", - text: "user-md ", + text: "user-md " }, { value: "user-minus", - text: "user-minus ", + text: "user-minus " }, { value: "user-ninja", - text: "user-ninja ", + text: "user-ninja " }, { value: "user-plus", - text: "user-plus ", + text: "user-plus " }, { value: "user-secret", - text: "user-secret ", + text: "user-secret " }, { value: "user-shield", - text: "user-shield ", + text: "user-shield " }, { value: "user-slash", - text: "user-slash ", + text: "user-slash " }, { value: "user-tag", - text: "user-tag ", + text: "user-tag " }, { value: "user-tie", - text: "user-tie ", + text: "user-tie " }, { value: "user-times", - text: "user-times ", + text: "user-times " }, { value: "users", - text: "users ", + text: "users " }, { value: "users-cog", - text: "users-cog ", + text: "users-cog " }, { value: "utensil-spoon", - text: "utensil-spoon ", + text: "utensil-spoon " }, { value: "utensils", - text: "utensils ", + text: "utensils " }, { value: "vector-square", - text: "vector-square ", + text: "vector-square " }, { value: "venus", - text: "venus ", + text: "venus " }, { value: "venus-double", - text: "venus-double ", + text: "venus-double " }, { value: "venus-mars", - text: "venus-mars ", + text: "venus-mars " }, { value: "vial", - text: "vial ", + text: "vial " }, { value: "vials", - text: "vials ", + text: "vials " }, { value: "video", - text: "video ", + text: "video " }, { value: "video-slash", - text: "video-slash ", + text: "video-slash " }, { value: "vihara", - text: "vihara ", + text: "vihara " }, { value: "volleyball-ball", - text: "volleyball-ball ", + text: "volleyball-ball " }, { value: "volume-down", - text: "volume-down ", + text: "volume-down " }, { value: "volume-off", - text: "volume-off ", + text: "volume-off " }, { value: "volume-up", - text: "volume-up ", + text: "volume-up " }, { value: "walking", - text: "walking ", + text: "walking " }, { value: "wallet", - text: "wallet ", + text: "wallet " }, { value: "warehouse", - text: "warehouse ", + text: "warehouse " }, { value: "weight", - text: "weight ", + text: "weight " }, { value: "weight-hanging", - text: "weight-hanging ", + text: "weight-hanging " }, { value: "wheelchair", - text: "wheelchair ", + text: "wheelchair " }, { value: "wifi", - text: "wifi ", + text: "wifi " }, { value: "window-close", - text: "window-close ", + text: "window-close " }, { value: "window-maximize", - text: "window-maximize ", + text: "window-maximize " }, { value: "window-minimize", - text: "window-minimize ", + text: "window-minimize " }, { value: "window-restore", - text: "window-restore ", + text: "window-restore " }, { value: "wine-glass", - text: "wine-glass ", + text: "wine-glass " }, { value: "wine-glass-alt", - text: "wine-glass-alt ", + text: "wine-glass-alt " }, { value: "won-sign", - text: "won-sign ", + text: "won-sign " }, { value: "wrench", - text: "wrench ", + text: "wrench " }, { value: "x-ray", - text: "x-ray ", + text: "x-ray " }, { value: "yen-sign", - text: "yen-sign ", + text: "yen-sign " }, { value: "yin-yang", - text: "yin-yang ", - }, + text: "yin-yang " + } ]; diff --git a/src/views/Dashboard.vue b/src/views/Dashboard.vue index f746f3e5..28108a29 100644 --- a/src/views/Dashboard.vue +++ b/src/views/Dashboard.vue @@ -15,8 +15,10 @@ {{ contactEmail }} - or view our - help videos + + or view our + help videos + @@ -126,8 +128,8 @@ export default { data() { return { - auth: Auth, + auth: Auth }; - }, + } }; diff --git a/src/views/admin/Index.vue b/src/views/admin/Index.vue index 931ece1b..6bdb0e52 100644 --- a/src/views/admin/Index.vue +++ b/src/views/admin/Index.vue @@ -28,44 +28,44 @@ export default { if (this.auth.canView("audits")) { tabs[0] = { heading: "Audit Logs", - to: { name: "admin-index" }, + to: { name: "admin-index" } }; } if (this.auth.canView("notifications")) { tabs[1] = { heading: "Notifications", - to: { name: "admin-index-notifications" }, + to: { name: "admin-index-notifications" } }; } if (this.auth.canView("feedback")) { tabs[2] = { heading: "Feedback", - to: { name: "admin-index-feedback" }, + to: { name: "admin-index-feedback" } }; } if (this.auth.canView("taxonomies")) { tabs[3] = { heading: "Taxonomies", - to: { name: "admin-index-taxonomies" }, + to: { name: "admin-index-taxonomies" } }; } if (this.auth.canView("collections")) { tabs[4] = { heading: "Collections", - to: { name: "admin-index-collections" }, + to: { name: "admin-index-collections" } }; } if (this.auth.canView("search engine")) { tabs[5] = { heading: "Search engine", - to: { name: "admin-index-search-engine" }, + to: { name: "admin-index-search-engine" } }; } if (this.auth.canView("cms")) { tabs[6] = { heading: "CMS", to: { name: "admin-index-cms" } }; } return tabs; - }, - }, + } + } }; diff --git a/src/views/admin/index/AuditLogs.vue b/src/views/admin/index/AuditLogs.vue index 7e65de42..eb62ebf0 100644 --- a/src/views/admin/index/AuditLogs.vue +++ b/src/views/admin/index/AuditLogs.vue @@ -65,29 +65,29 @@ { heading: 'Action', sort: 'action', - render: (audit) => formatAction(audit.action), + render: audit => formatAction(audit.action) }, { heading: 'Description', sort: 'description', - render: (audit) => audit.description, + render: audit => audit.description }, { heading: 'User', sort: 'user_full_name', - render: (audit) => formatUserName(audit.user), + render: audit => formatUserName(audit.user) }, { heading: 'Date / Time', sort: 'created_at', - render: (audit) => formatDateTime(audit.created_at), - }, + render: audit => formatDateTime(audit.created_at) + } ]" :view-route=" - (audit) => { + audit => { return { name: 'audits-show', - params: { audit: audit.id }, + params: { audit: audit.id } }; } " @@ -111,23 +111,23 @@ export default { action: "", description: "", user_id: "", - oauth_client_id: "", + oauth_client_id: "" }, actions: [ { value: "", text: "All" }, { value: "create", text: "Create" }, { value: "read", text: "Read" }, { value: "update", text: "Update" }, - { value: "delete", text: "Delete" }, + { value: "delete", text: "Delete" } ], users: [], - oauthClients: [], + oauthClients: [] }; }, computed: { params() { const params = { - include: "user", + include: "user" }; if (this.filters.action !== "") { @@ -147,17 +147,17 @@ export default { } return params; - }, + } }, methods: { async fetchUsers() { this.loadingUsers = true; let users = await this.fetchAll("/users"); - users = users.map((user) => { + users = users.map(user => { return { value: user.id, - text: `${user.first_name} ${user.last_name}`, + text: `${user.first_name} ${user.last_name}` }; }); this.users = [{ value: "", text: "All" }, ...users]; @@ -170,12 +170,12 @@ export default { let { data: oauthClients } = await http({ method: "get", url: "/oauth/clients", - baseURL: this.appApiUri, + baseURL: this.appApiUri }); - oauthClients = oauthClients.map((oauthClient) => ({ + oauthClients = oauthClients.map(oauthClient => ({ value: oauthClient.id, - text: oauthClient.name, + text: oauthClient.name })); this.oauthClients = [{ value: "", text: "All" }, ...oauthClients]; @@ -195,11 +195,11 @@ export default { }, formatAction(action) { return action.charAt(0).toUpperCase() + action.substr(1); - }, + } }, created() { this.fetchUsers(); this.fetchOauthClients(); - }, + } }; diff --git a/src/views/admin/index/Cms.vue b/src/views/admin/index/Cms.vue index 6e8f7230..601d23cd 100644 --- a/src/views/admin/index/Cms.vue +++ b/src/views/admin/index/Cms.vue @@ -45,47 +45,47 @@ export default { tabs: [ { heading: "Global", - to: { name: "admin-index-cms" }, + to: { name: "admin-index-cms" } }, { heading: "Home", - to: { name: "admin-index-cms-frontend-home" }, + to: { name: "admin-index-cms-frontend-home" } }, { heading: "Terms and Conditions", - to: { name: "admin-index-cms-frontend-terms-and-conditions" }, + to: { name: "admin-index-cms-frontend-terms-and-conditions" } }, { heading: "Privacy Policy", - to: { name: "admin-index-cms-frontend-privacy-policy" }, + to: { name: "admin-index-cms-frontend-privacy-policy" } }, { heading: "Accessibility Statement", - to: { name: "admin-index-cms-frontend-accessibility-statement" }, + to: { name: "admin-index-cms-frontend-accessibility-statement" } }, { heading: "About", - to: { name: "admin-index-cms-frontend-about" }, + to: { name: "admin-index-cms-frontend-about" } }, { heading: "Contact", - to: { name: "admin-index-cms-frontend-contact" }, + to: { name: "admin-index-cms-frontend-contact" } }, { heading: "Get Involved", - to: { name: "admin-index-cms-frontend-get-involved" }, + to: { name: "admin-index-cms-frontend-get-involved" } }, { heading: "Favourites", - to: { name: "admin-index-cms-frontend-favourites" }, + to: { name: "admin-index-cms-frontend-favourites" } }, { heading: "Banner", - to: { name: "admin-index-cms-frontend-banner" }, - }, + to: { name: "admin-index-cms-frontend-banner" } + } ], settings: null, - loading: false, + loading: false }; }, @@ -98,7 +98,7 @@ export default { this.loading = true; const { - data: { data: settings }, + data: { data: settings } } = await http.get("/settings"); settings.cms.frontend.banner.enabled = @@ -131,7 +131,7 @@ export default { delete data.cms.frontend.banner.enabled; data.cms.frontend.home.banners = data.cms.frontend.home.banners.filter( - (banner) => { + banner => { return !( (banner.title == "") & (banner.content == "") & @@ -142,7 +142,7 @@ export default { ); }); this.$router.push({ name: "admin-index-cms-updated" }); - }, - }, + } + } }; diff --git a/src/views/admin/index/Collections.vue b/src/views/admin/index/Collections.vue index 558bc584..c043b511 100644 --- a/src/views/admin/index/Collections.vue +++ b/src/views/admin/index/Collections.vue @@ -17,14 +17,14 @@ export default { { heading: "Categories", to: { name: "admin-index-collections" } }, { heading: "Personas", - to: { name: "admin-index-collections-personas" }, + to: { name: "admin-index-collections-personas" } }, { heading: "Events", - to: { name: "admin-index-collections-events" }, - }, - ], + to: { name: "admin-index-collections-events" } + } + ] }; - }, + } }; diff --git a/src/views/admin/index/Feedback.vue b/src/views/admin/index/Feedback.vue index e0883588..ebeea6b1 100644 --- a/src/views/admin/index/Feedback.vue +++ b/src/views/admin/index/Feedback.vue @@ -29,28 +29,28 @@ { heading: 'Page URL', sort: 'url', - render: (pageFeedback) => pageFeedback.url, + render: pageFeedback => pageFeedback.url }, { heading: 'Contact name', - render: (pageFeedback) => pageFeedback.name || '-', + render: pageFeedback => pageFeedback.name || '-' }, { heading: 'Contact details', - render: (pageFeedback) => - pageFeedback.email || pageFeedback.phone || '-', + render: pageFeedback => + pageFeedback.email || pageFeedback.phone || '-' }, { heading: 'Date / Time', sort: 'created_at', - render: (pageFeedback) => formatDateTime(pageFeedback.created_at), - }, + render: pageFeedback => formatDateTime(pageFeedback.created_at) + } ]" :view-route=" - (pageFeedback) => { + pageFeedback => { return { name: 'page-feedbacks-show', - params: { pageFeedback: pageFeedback.id }, + params: { pageFeedback: pageFeedback.id } }; } " @@ -68,8 +68,8 @@ export default { data() { return { filters: { - url: "", - }, + url: "" + } }; }, computed: { @@ -81,13 +81,13 @@ export default { } return params; - }, + } }, methods: { onSearch() { this.$refs.pageFeedbacksTable.currentPage = 1; this.$refs.pageFeedbacksTable.fetchResources(); - }, - }, + } + } }; diff --git a/src/views/admin/index/Notifications.vue b/src/views/admin/index/Notifications.vue index 60d7a583..d7fd7867 100644 --- a/src/views/admin/index/Notifications.vue +++ b/src/views/admin/index/Notifications.vue @@ -28,7 +28,7 @@ export default { loading: false, notifications: [], currentPage: 1, - lastPage: 1, + lastPage: 1 }; }, methods: { @@ -36,7 +36,7 @@ export default { this.loading = true; const { data } = await http.get("/notifications", { - params: { page: this.currentPage }, + params: { page: this.currentPage } }); this.notifications = data.data; this.currentPage = data.meta.current_page; @@ -51,10 +51,10 @@ export default { onPrevious() { this.currentPage--; this.fetchNotifications(); - }, + } }, created() { this.fetchNotifications(); - }, + } }; diff --git a/src/views/admin/index/SearchEngine.vue b/src/views/admin/index/SearchEngine.vue index 70dc5781..8fad4941 100644 --- a/src/views/admin/index/SearchEngine.vue +++ b/src/views/admin/index/SearchEngine.vue @@ -16,14 +16,14 @@ export default { tabs: [ { heading: "Thesaurus", - to: { name: "admin-index-search-engine" }, + to: { name: "admin-index-search-engine" } }, { heading: "Stop words", - to: { name: "admin-index-search-engine-stop-words" }, - }, - ], + to: { name: "admin-index-search-engine-stop-words" } + } + ] }; - }, + } }; diff --git a/src/views/admin/index/Taxonomies.vue b/src/views/admin/index/Taxonomies.vue index 2c1c6475..c0121294 100644 --- a/src/views/admin/index/Taxonomies.vue +++ b/src/views/admin/index/Taxonomies.vue @@ -17,14 +17,14 @@ export default { { heading: "Categories", to: { name: "admin-index-taxonomies" } }, { heading: "Organisations", - to: { name: "admin-index-taxonomies-organisations" }, + to: { name: "admin-index-taxonomies-organisations" } }, { heading: "Service Eligibilities", - to: { name: "admin-index-taxonomies-service-eligibilities" }, - }, - ], + to: { name: "admin-index-taxonomies-service-eligibilities" } + } + ] }; - }, + } }; diff --git a/src/views/admin/index/cms/Updated.vue b/src/views/admin/index/cms/Updated.vue index 53dbeaba..796fa922 100644 --- a/src/views/admin/index/cms/Updated.vue +++ b/src/views/admin/index/cms/Updated.vue @@ -17,6 +17,6 @@ diff --git a/src/views/admin/index/cms/frontend/About.vue b/src/views/admin/index/cms/frontend/About.vue index 40553f61..94c85eec 100644 --- a/src/views/admin/index/cms/frontend/About.vue +++ b/src/views/admin/index/cms/frontend/About.vue @@ -42,19 +42,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -65,7 +65,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.about.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/AccessibilityStatement.vue b/src/views/admin/index/cms/frontend/AccessibilityStatement.vue index a227d4e2..24038c16 100644 --- a/src/views/admin/index/cms/frontend/AccessibilityStatement.vue +++ b/src/views/admin/index/cms/frontend/AccessibilityStatement.vue @@ -32,19 +32,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -55,7 +55,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.accessibility_statement.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/Banner.vue b/src/views/admin/index/cms/frontend/Banner.vue index 62718d31..2309d78b 100644 --- a/src/views/admin/index/cms/frontend/Banner.vue +++ b/src/views/admin/index/cms/frontend/Banner.vue @@ -13,7 +13,7 @@ hint="Banner configuration will be shown when enabled" :options="[ { value: false, label: 'Disabled' }, - { value: true, label: 'Enabled' }, + { value: true, label: 'Enabled' } ]" :error="null" /> @@ -36,24 +36,24 @@ export default { name: "CmsFrontendBanner", components: { - CkBannerInput, + CkBannerInput }, model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -64,7 +64,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.banner.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/Contact.vue b/src/views/admin/index/cms/frontend/Contact.vue index 34616560..cb1062cd 100644 --- a/src/views/admin/index/cms/frontend/Contact.vue +++ b/src/views/admin/index/cms/frontend/Contact.vue @@ -32,19 +32,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -55,7 +55,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.contact.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/Favourites.vue b/src/views/admin/index/cms/frontend/Favourites.vue index 07a15e3e..ff3b345a 100644 --- a/src/views/admin/index/cms/frontend/Favourites.vue +++ b/src/views/admin/index/cms/frontend/Favourites.vue @@ -32,19 +32,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -55,7 +55,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.favourites.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/GetInvolved.vue b/src/views/admin/index/cms/frontend/GetInvolved.vue index 828f258d..51cdcd98 100644 --- a/src/views/admin/index/cms/frontend/GetInvolved.vue +++ b/src/views/admin/index/cms/frontend/GetInvolved.vue @@ -32,19 +32,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -55,7 +55,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.get_involved.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/Global.vue b/src/views/admin/index/cms/frontend/Global.vue index 0d2bebae..9622027f 100644 --- a/src/views/admin/index/cms/frontend/Global.vue +++ b/src/views/admin/index/cms/frontend/Global.vue @@ -65,19 +65,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -88,7 +88,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.global.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/Home.vue b/src/views/admin/index/cms/frontend/Home.vue index 462a9033..a071bf83 100644 --- a/src/views/admin/index/cms/frontend/Home.vue +++ b/src/views/admin/index/cms/frontend/Home.vue @@ -63,24 +63,24 @@ export default { name: "CmsFrontendHome", components: { - CkBannerInput, + CkBannerInput }, model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -90,7 +90,7 @@ export default { title: "", content: "", button_text: "", - button_url: "", + button_url: "" }); this.frontend.home.banners = banners; }, @@ -104,7 +104,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.home.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/PrivacyPolicy.vue b/src/views/admin/index/cms/frontend/PrivacyPolicy.vue index 2b3ac702..dc3fe3dc 100644 --- a/src/views/admin/index/cms/frontend/PrivacyPolicy.vue +++ b/src/views/admin/index/cms/frontend/PrivacyPolicy.vue @@ -32,19 +32,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -55,7 +55,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.privacy_policy.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/cms/frontend/TermsAndConditions.vue b/src/views/admin/index/cms/frontend/TermsAndConditions.vue index 749a0b3c..464068a3 100644 --- a/src/views/admin/index/cms/frontend/TermsAndConditions.vue +++ b/src/views/admin/index/cms/frontend/TermsAndConditions.vue @@ -32,19 +32,19 @@ export default { model: { prop: "frontend", - event: "input", + event: "input" }, props: { frontend: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { @@ -55,7 +55,7 @@ export default { this.$emit("input", frontend); this.$emit("clear", `frontend.terms_and_conditions.${field}`); - }, - }, + } + } }; diff --git a/src/views/admin/index/collections/Categories.vue b/src/views/admin/index/collections/Categories.vue index d7c086d3..02ddbd7e 100644 --- a/src/views/admin/index/collections/Categories.vue +++ b/src/views/admin/index/collections/Categories.vue @@ -60,7 +60,7 @@ export default { data() { return { loading: false, - collections: [], + collections: [] }; }, methods: { @@ -74,7 +74,7 @@ export default { await http.put(`/collections/categories/${collection.id}`, { ...this.parseCollectionForUpdate(collection), - order: collection.order - 1, + order: collection.order - 1 }); this.fetchCollections(); @@ -84,7 +84,7 @@ export default { await http.put(`/collections/categories/${collection.id}`, { ...this.parseCollectionForUpdate(collection), - order: collection.order + 1, + order: collection.order + 1 }); this.fetchCollections(); @@ -99,13 +99,13 @@ export default { homepage: collection.homepage, sideboxes: collection.sideboxes, category_taxonomies: collection.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }; - }, + } }, created() { this.fetchCollections(); - }, + } }; diff --git a/src/views/admin/index/collections/CollectionListItem.vue b/src/views/admin/index/collections/CollectionListItem.vue index 26881eb1..0fe654d6 100644 --- a/src/views/admin/index/collections/CollectionListItem.vue +++ b/src/views/admin/index/collections/CollectionListItem.vue @@ -8,7 +8,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: editCollectionRoute, - params: { collection: collection.id }, + params: { collection: collection.id } }" > Edit @@ -30,17 +30,17 @@ export default { props: { collections: { type: Array, - required: true, + required: true }, collection: { type: Object, - required: true, + required: true }, editCollectionRoute: { type: String, - required: true, - }, - }, + required: true + } + } }; diff --git a/src/views/admin/index/collections/Events.vue b/src/views/admin/index/collections/Events.vue index 5731f503..84295876 100644 --- a/src/views/admin/index/collections/Events.vue +++ b/src/views/admin/index/collections/Events.vue @@ -59,7 +59,7 @@ export default { data() { return { loading: false, - collections: [], + collections: [] }; }, methods: { @@ -75,7 +75,7 @@ export default { await http.put(`/collections/organisation-events/${collection.id}`, { ...this.parseCollectionForUpdate(collection), - order: collection.order - 1, + order: collection.order - 1 }); this.fetchCollections(); @@ -85,7 +85,7 @@ export default { await http.put(`/collections/organisation-events/${collection.id}`, { ...this.parseCollectionForUpdate(collection), - order: collection.order + 1, + order: collection.order + 1 }); this.fetchCollections(); @@ -99,13 +99,13 @@ export default { enabled: collection.enabled, sideboxes: collection.sideboxes, category_taxonomies: collection.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }; - }, + } }, created() { this.fetchCollections(); - }, + } }; diff --git a/src/views/admin/index/collections/Personas.vue b/src/views/admin/index/collections/Personas.vue index f2e47063..31260d14 100644 --- a/src/views/admin/index/collections/Personas.vue +++ b/src/views/admin/index/collections/Personas.vue @@ -58,7 +58,7 @@ export default { data() { return { loading: false, - collections: [], + collections: [] }; }, methods: { @@ -72,7 +72,7 @@ export default { await http.put(`/collections/personas/${collection.id}`, { ...this.parseCollectionForUpdate(collection), - order: collection.order - 1, + order: collection.order - 1 }); this.fetchCollections(); @@ -82,7 +82,7 @@ export default { await http.put(`/collections/personas/${collection.id}`, { ...this.parseCollectionForUpdate(collection), - order: collection.order + 1, + order: collection.order + 1 }); this.fetchCollections(); @@ -97,13 +97,13 @@ export default { homepage: collection.homepage, sideboxes: collection.sideboxes, category_taxonomies: collection.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }; - }, + } }, created() { this.fetchCollections(); - }, + } }; diff --git a/src/views/admin/index/search-engine/StopWords.vue b/src/views/admin/index/search-engine/StopWords.vue index 5d08390d..66e2c312 100644 --- a/src/views/admin/index/search-engine/StopWords.vue +++ b/src/views/admin/index/search-engine/StopWords.vue @@ -43,7 +43,7 @@ export default { loading: false, stopWords: [], currentPage: 1, - lastPage: 1, + lastPage: 1 }; }, @@ -60,7 +60,7 @@ export default { onExportCsv() { let csvContent = "data:text/csv;charset=utf-8,"; - this.stopWords.forEach((stopWord) => { + this.stopWords.forEach(stopWord => { csvContent += stopWord + "\r\n"; }); @@ -70,11 +70,11 @@ export default { link.setAttribute("download", "stop-words.csv"); document.body.appendChild(link); link.click(); - }, + } }, created() { this.fetchStopWords(); - }, + } }; diff --git a/src/views/admin/index/search-engine/Thesaurus.vue b/src/views/admin/index/search-engine/Thesaurus.vue index 2ee6d823..2a585a71 100644 --- a/src/views/admin/index/search-engine/Thesaurus.vue +++ b/src/views/admin/index/search-engine/Thesaurus.vue @@ -41,7 +41,7 @@ export default { loading: false, synonyms: [], currentPage: 1, - lastPage: 1, + lastPage: 1 }; }, @@ -58,7 +58,7 @@ export default { onExportCsv() { let csvContent = "data:text/csv;charset=utf-8,"; - this.synonyms.forEach((rowArray) => { + this.synonyms.forEach(rowArray => { let row = rowArray.join(","); csvContent += row + "\r\n"; }); @@ -69,11 +69,11 @@ export default { link.setAttribute("download", "thesaurus.csv"); document.body.appendChild(link); link.click(); - }, + } }, created() { this.fetchSynonyms(); - }, + } }; diff --git a/src/views/admin/index/taxonomies/Categories.vue b/src/views/admin/index/taxonomies/Categories.vue index e8cb0359..dd41d9ba 100644 --- a/src/views/admin/index/taxonomies/Categories.vue +++ b/src/views/admin/index/taxonomies/Categories.vue @@ -39,7 +39,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -54,7 +54,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -68,7 +68,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -85,7 +85,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -102,7 +102,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -119,7 +119,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -139,7 +139,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-categories-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -181,7 +181,7 @@ export default { data() { return { loading: false, - taxonomies: [], + taxonomies: [] }; }, methods: { @@ -192,10 +192,10 @@ export default { this.taxonomies = data.data; this.loading = false; - }, + } }, created() { this.fetchTaxonomies(); - }, + } }; diff --git a/src/views/admin/index/taxonomies/Organisations.vue b/src/views/admin/index/taxonomies/Organisations.vue index 286afc4f..876c9e76 100644 --- a/src/views/admin/index/taxonomies/Organisations.vue +++ b/src/views/admin/index/taxonomies/Organisations.vue @@ -40,7 +40,7 @@ v-if="auth.isGlobalAdmin" :to="{ name: 'taxonomies-organisations-edit', - params: { taxonomy: taxonomy.id }, + params: { taxonomy: taxonomy.id } }" > Edit @@ -62,7 +62,7 @@ export default { data() { return { loading: false, - taxonomies: [], + taxonomies: [] }; }, methods: { @@ -73,10 +73,10 @@ export default { this.taxonomies = data.data; this.loading = false; - }, + } }, created() { this.fetchTaxonomies(); - }, + } }; diff --git a/src/views/admin/index/taxonomies/ServiceEligibilities.vue b/src/views/admin/index/taxonomies/ServiceEligibilities.vue index 49c59acb..a5ab2a58 100644 --- a/src/views/admin/index/taxonomies/ServiceEligibilities.vue +++ b/src/views/admin/index/taxonomies/ServiceEligibilities.vue @@ -55,13 +55,13 @@ export default { name: "ListTaxonomyServiceEligibilitied", components: { - CkTaxonomyList, + CkTaxonomyList }, data() { return { loading: false, - serviceEligibilities: [], + serviceEligibilities: [] }; }, @@ -77,21 +77,21 @@ export default { async onMoveUp(taxonomy) { taxonomy.order--; await http.put(`/taxonomies/service-eligibilities/${taxonomy.id}`, { - ...taxonomy, + ...taxonomy }); this.fetchServiceEligibilities(); }, async onMoveDown(taxonomy) { taxonomy.order++; await http.put(`/taxonomies/service-eligibilities/${taxonomy.id}`, { - ...taxonomy, + ...taxonomy }); this.fetchServiceEligibilities(); - }, + } }, created() { this.fetchServiceEligibilities(); - }, + } }; diff --git a/src/views/audits/Show.vue b/src/views/audits/Show.vue index 66e3b191..aba798b2 100644 --- a/src/views/audits/Show.vue +++ b/src/views/audits/Show.vue @@ -28,7 +28,7 @@ export default { data() { return { loading: false, - audit: null, + audit: null }; }, methods: { @@ -39,10 +39,10 @@ export default { ); this.audit = data.data; this.loading = false; - }, + } }, created() { this.fetchAudit(); - }, + } }; diff --git a/src/views/auth/Login.vue b/src/views/auth/Login.vue index d0cac28d..f34517e9 100644 --- a/src/views/auth/Login.vue +++ b/src/views/auth/Login.vue @@ -35,7 +35,7 @@ export default { return { accessToken: Auth.parseQueryString(window.location.href).access_token || null, - expiresIn: Auth.parseQueryString(window.location.href).expires_in || null, + expiresIn: Auth.parseQueryString(window.location.href).expires_in || null }; }, computed: { @@ -52,19 +52,19 @@ export default { } return true; - }, + } }, methods: { async login() { await Auth.login(this.accessToken, this.expiresIn); this.$root.$emit("login"); this.$router.push({ name: "dashboard" }); - }, + } }, created() { if (this.validateRequest) { this.login(); } - }, + } }; diff --git a/src/views/auth/Logout.vue b/src/views/auth/Logout.vue index 374d5642..20435587 100644 --- a/src/views/auth/Logout.vue +++ b/src/views/auth/Logout.vue @@ -24,7 +24,7 @@ import Auth from "@/classes/Auth"; export default { data() { return { - loginUri: Auth.authorizeUrl, + loginUri: Auth.authorizeUrl }; }, created() { @@ -32,6 +32,6 @@ export default { Auth.logout(); this.$root.$emit("logout"); - }, + } }; diff --git a/src/views/collections/categories/Create.vue b/src/views/collections/categories/Create.vue index cd5ab287..9658ec4a 100644 --- a/src/views/collections/categories/Create.vue +++ b/src/views/collections/categories/Create.vue @@ -60,15 +60,15 @@ export default { enabled: true, homepage: false, sideboxes: [], - category_taxonomies: [], - }), + category_taxonomies: [] + }) }; }, methods: { async onSubmit() { await this.form.post("/collections/categories"); this.$router.push({ name: "admin-index-collections" }); - }, - }, + } + } }; diff --git a/src/views/collections/categories/Edit.vue b/src/views/collections/categories/Edit.vue index 8ab934b6..ae4f18a7 100644 --- a/src/views/collections/categories/Edit.vue +++ b/src/views/collections/categories/Edit.vue @@ -71,7 +71,7 @@ export default { return { loading: false, collection: null, - form: null, + form: null }; }, methods: { @@ -91,8 +91,8 @@ export default { homepage: this.collection.homepage, sideboxes: this.collection.sideboxes, category_taxonomies: this.collection.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }); this.loading = false; @@ -103,10 +103,10 @@ export default { }, onDelete() { this.$router.push({ name: "admin-index-collections" }); - }, + } }, created() { this.fetchCollection(); - }, + } }; diff --git a/src/views/collections/categories/forms/CollectionForm.vue b/src/views/collections/categories/forms/CollectionForm.vue index d64e945c..741e7f97 100644 --- a/src/views/collections/categories/forms/CollectionForm.vue +++ b/src/views/collections/categories/forms/CollectionForm.vue @@ -99,44 +99,44 @@ export default { CollectionHomepageInput, CkTaxonomyInput, CkSideboxesInput, - CkImageInput, + CkImageInput }, props: { errors: { required: true, - type: Object, + type: Object }, id: { required: false, - type: String, + type: String }, name: { - required: true, + required: true }, intro: { - required: true, + required: true }, order: { - required: true, + required: true }, enabled: { - required: true, + required: true }, homepage: { - required: true, + required: true }, sideboxes: { - required: true, + required: true }, category_taxonomies: { - required: true, - }, + required: true + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, - }, + } + } }; diff --git a/src/views/collections/events/Create.vue b/src/views/collections/events/Create.vue index a9e7cc2c..bc82b25c 100644 --- a/src/views/collections/events/Create.vue +++ b/src/views/collections/events/Create.vue @@ -60,15 +60,15 @@ export default { order: 1, enabled: true, sideboxes: [], - category_taxonomies: [], - }), + category_taxonomies: [] + }) }; }, methods: { async onSubmit() { await this.form.post("/collections/organisation-events"); this.$router.push({ name: "admin-index-collections-events" }); - }, - }, + } + } }; diff --git a/src/views/collections/events/Edit.vue b/src/views/collections/events/Edit.vue index 21e84a4b..25e273ed 100644 --- a/src/views/collections/events/Edit.vue +++ b/src/views/collections/events/Edit.vue @@ -49,7 +49,9 @@ @@ -71,7 +73,7 @@ export default { return { loading: false, collection: null, - form: null, + form: null }; }, methods: { @@ -90,8 +92,8 @@ export default { enabled: this.collection.enabled, sideboxes: this.collection.sideboxes, category_taxonomies: this.collection.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }); this.loading = false; @@ -104,10 +106,10 @@ export default { }, onDelete() { this.$router.push({ name: "admin-index-collections-events" }); - }, + } }, created() { this.fetchCollection(); - }, + } }; diff --git a/src/views/collections/events/forms/CollectionForm.vue b/src/views/collections/events/forms/CollectionForm.vue index ef3d5023..58b8b31d 100644 --- a/src/views/collections/events/forms/CollectionForm.vue +++ b/src/views/collections/events/forms/CollectionForm.vue @@ -89,41 +89,41 @@ export default { CollectionEnabledInput, CkTaxonomyInput, CkSideboxesInput, - CkImageInput, + CkImageInput }, props: { errors: { required: true, - type: Object, + type: Object }, id: { required: false, - type: String, + type: String }, name: { - required: true, + required: true }, intro: { - required: true, + required: true }, order: { - required: true, + required: true }, enabled: { - required: true, + required: true }, sideboxes: { - required: true, + required: true }, category_taxonomies: { - required: true, - }, + required: true + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, - }, + } + } }; diff --git a/src/views/collections/inputs/CollectionEnabledInput.vue b/src/views/collections/inputs/CollectionEnabledInput.vue index bc43d7ac..9c6f0c35 100644 --- a/src/views/collections/inputs/CollectionEnabledInput.vue +++ b/src/views/collections/inputs/CollectionEnabledInput.vue @@ -31,31 +31,31 @@ export default { props: { value: { - required: true, + required: true }, error: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, type: { type: String, required: true, - validator: function (value) { + validator: function(value) { return ["category", "persona"].indexOf(value) !== -1; - }, + } }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, - }, - }, + type: String + } + } }; diff --git a/src/views/collections/inputs/CollectionHomepageInput.vue b/src/views/collections/inputs/CollectionHomepageInput.vue index da492a48..6ffbcbe2 100644 --- a/src/views/collections/inputs/CollectionHomepageInput.vue +++ b/src/views/collections/inputs/CollectionHomepageInput.vue @@ -33,24 +33,24 @@ export default { props: { value: { - required: true, + required: true }, error: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, - }, - }, + type: String + } + } }; diff --git a/src/views/collections/inputs/SideboxesInput.vue b/src/views/collections/inputs/SideboxesInput.vue index 85d15f46..4554a7f9 100644 --- a/src/views/collections/inputs/SideboxesInput.vue +++ b/src/views/collections/inputs/SideboxesInput.vue @@ -38,31 +38,31 @@ export default { model: { prop: "sideboxes", - event: "input", + event: "input" }, props: { sideboxes: { required: true, - type: Array, + type: Array }, errors: { required: true, - type: Object, - }, + type: Object + } }, data() { return { index: 1, - extensions: [new Link()], + extensions: [new Link()] }; }, methods: { clone() { - return this.sideboxes.map((sidebox) => ({ ...sidebox })); + return this.sideboxes.map(sidebox => ({ ...sidebox })); }, onAdd() { @@ -70,7 +70,7 @@ export default { sideboxes.push({ title: "", content: "", - index: this.index, + index: this.index }); this.index++; @@ -102,7 +102,7 @@ export default { this.$emit("input", sideboxes); this.$emit("clear", `sideboxes.${index}.content`); - }, - }, + } + } }; diff --git a/src/views/collections/personas/Create.vue b/src/views/collections/personas/Create.vue index 5192a55c..1a62b453 100644 --- a/src/views/collections/personas/Create.vue +++ b/src/views/collections/personas/Create.vue @@ -64,8 +64,8 @@ export default { homepage: false, sideboxes: [], category_taxonomies: [], - image_file_id: null, - }), + image_file_id: null + }) }; }, methods: { @@ -77,7 +77,7 @@ export default { } }); this.$router.push({ name: "admin-index-collections-personas" }); - }, - }, + } + } }; diff --git a/src/views/collections/personas/Edit.vue b/src/views/collections/personas/Edit.vue index 2a5b0ca4..e16f94af 100644 --- a/src/views/collections/personas/Edit.vue +++ b/src/views/collections/personas/Edit.vue @@ -72,7 +72,7 @@ export default { return { loading: false, collection: null, - form: null, + form: null }; }, methods: { @@ -92,9 +92,9 @@ export default { homepage: this.collection.homepage, sideboxes: this.collection.sideboxes, category_taxonomies: this.collection.category_taxonomies.map( - (taxonomy) => taxonomy.id + taxonomy => taxonomy.id ), - image_file_id: null, + image_file_id: null }); this.loading = false; @@ -118,10 +118,10 @@ export default { }, onDelete() { this.$router.push({ name: "admin-index-collections-personas" }); - }, + } }, created() { this.fetchCollection(); - }, + } }; diff --git a/src/views/collections/personas/forms/CollectionForm.vue b/src/views/collections/personas/forms/CollectionForm.vue index 5aacff5d..29c339b2 100644 --- a/src/views/collections/personas/forms/CollectionForm.vue +++ b/src/views/collections/personas/forms/CollectionForm.vue @@ -105,47 +105,47 @@ export default { CollectionHomepageInput, CkImageInput, CkTaxonomyInput, - CkSideboxesInput, + CkSideboxesInput }, props: { errors: { required: true, - type: Object, + type: Object }, name: { - required: true, + required: true }, intro: { - required: true, + required: true }, subtitle: { - required: true, + required: true }, order: { - required: true, + required: true }, enabled: { - required: true, + required: true }, homepage: { - required: true, + required: true }, sideboxes: { - required: true, + required: true }, category_taxonomies: { - required: true, + required: true }, id: { required: false, - type: String, - }, + type: String + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, - }, + } + } }; diff --git a/src/views/errors/404.vue b/src/views/errors/404.vue index e5c7b02b..7b9045e0 100644 --- a/src/views/errors/404.vue +++ b/src/views/errors/404.vue @@ -23,6 +23,6 @@ diff --git a/src/views/events/Create.vue b/src/views/events/Create.vue index c62aa3a8..be4fe6bb 100644 --- a/src/views/events/Create.vue +++ b/src/views/events/Create.vue @@ -144,18 +144,18 @@ export default { organisation_id: null, image_file_id: null, homepage: false, - category_taxonomies: [], + category_taxonomies: [] }), tabs: [ { id: "details", heading: "Details", active: true }, - { id: "taxonomies", heading: "Taxonomies", active: false }, + { id: "taxonomies", heading: "Taxonomies", active: false } ], organisations: [{ text: "Please select", value: null }], updateRequestCreated: false, updateRequestMessage: null, - loading: false, + loading: false }; }, @@ -163,7 +163,7 @@ export default { allowedTabs() { if (!this.auth.isGlobalAdmin) { const taxonomiesTabIndex = this.tabs.findIndex( - (tab) => tab.id === "taxonomies" + tab => tab.id === "taxonomies" ); const tabs = this.tabs.slice(); tabs.splice(taxonomiesTabIndex, 1); @@ -172,16 +172,16 @@ export default { } return this.tabs; - }, + } }, methods: { async fetchOrganisations() { this.loading = true; let fetchedOrganisations = await this.fetchAll("/organisations", { - "filter[has_permission]": true, + "filter[has_permission]": true }); - fetchedOrganisations = fetchedOrganisations.map((organisation) => { + fetchedOrganisations = fetchedOrganisations.map(organisation => { return { text: organisation.name, value: organisation.id }; }); this.organisations = [...this.organisations, ...fetchedOrganisations]; @@ -195,7 +195,7 @@ export default { if (this.auth.isSuperAdmin && eventId) { this.$router.push({ name: "events-show", - params: { event: eventId }, + params: { event: eventId } }); } else if (!this.form.$errors.any()) { this.updateRequestCreated = true; @@ -203,20 +203,20 @@ export default { } }, onTabChange({ index }) { - this.tabs.forEach((tab) => (tab.active = false)); + this.tabs.forEach(tab => (tab.active = false)); const tabId = this.allowedTabs[index].id; - this.tabs.find((tab) => tab.id === tabId).active = true; + this.tabs.find(tab => tab.id === tabId).active = true; }, isTabActive(id) { - const tab = this.allowedTabs.find((tab) => tab.id === id); + const tab = this.allowedTabs.find(tab => tab.id === id); return tab === undefined ? false : tab.active; - }, + } }, created() { this.fetchOrganisations(); - }, + } }; diff --git a/src/views/events/Edit.vue b/src/views/events/Edit.vue index 438983a6..6a3cb4bb 100644 --- a/src/views/events/Edit.vue +++ b/src/views/events/Edit.vue @@ -105,11 +105,11 @@ export default { return { tabs: [ { id: "details", heading: "Details", active: true }, - { id: "taxonomies", heading: "Taxonomies", active: false }, + { id: "taxonomies", heading: "Taxonomies", active: false } ], loading: false, event: null, - form: null, + form: null }; }, @@ -117,7 +117,7 @@ export default { allowedTabs() { if (!this.auth.isGlobalAdmin) { const taxonomiesTabIndex = this.tabs.findIndex( - (tab) => tab.id === "taxonomies" + tab => tab.id === "taxonomies" ); const tabs = this.tabs.slice(); tabs.splice(taxonomiesTabIndex, 1); @@ -129,7 +129,7 @@ export default { }, updateButtonText() { return this.auth.isSuperAdmin ? "Update" : "Request update"; - }, + } }, methods: { @@ -164,8 +164,8 @@ export default { location_id: this.event.location_id, image_file_id: null, category_taxonomies: this.event.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }); this.loading = false; @@ -259,7 +259,7 @@ export default { const updateRequestId = response.id; let next = { name: "events-updated", - params: { event: this.event.id }, + params: { event: this.event.id } }; if (this.auth.isSuperAdmin) { @@ -278,20 +278,20 @@ export default { this.$router.push(next); }, onTabChange({ index }) { - this.tabs.forEach((tab) => (tab.active = false)); + this.tabs.forEach(tab => (tab.active = false)); const tabId = this.allowedTabs[index].id; - this.tabs.find((tab) => tab.id === tabId).active = true; + this.tabs.find(tab => tab.id === tabId).active = true; }, isTabActive(id) { - const tab = this.allowedTabs.find((tab) => tab.id === id); + const tab = this.allowedTabs.find(tab => tab.id === id); return tab === undefined ? false : tab.active; - }, + } }, created() { this.fetchEvent(); - }, + } }; diff --git a/src/views/events/Index.vue b/src/views/events/Index.vue index 8f152cf1..6c5d3979 100644 --- a/src/views/events/Index.vue +++ b/src/views/events/Index.vue @@ -38,34 +38,34 @@ { heading: 'Title', sort: 'title', - render: (event) => event.title, + render: event => event.title }, { heading: 'Start', sort: 'start_date', - render: (event) => startDateTimeStr(event), + render: event => startDateTimeStr(event) }, { heading: 'End', sort: 'end_date', - render: (event) => endDateTimeStr(event), + render: event => endDateTimeStr(event) }, { heading: 'Summary', sort: 'intro', - render: (event) => event.intro, + render: event => event.intro }, { heading: 'Free', sort: 'is_free', - render: (event) => (event.is_free ? 'Yes' : 'No'), - }, + render: event => (event.is_free ? 'Yes' : 'No') + } ]" :view-route=" - (event) => { + event => { return { name: 'events-show', - params: { event: event.id }, + params: { event: event.id } }; } " @@ -87,15 +87,15 @@ export default { data() { return { filters: { - organisation: "", - }, + organisation: "" + } }; }, computed: { params() { let params = { include: "organisation", - "filter[has_permission]": true, + "filter[has_permission]": true }; if (this.filters.organisation !== "") { @@ -103,7 +103,7 @@ export default { } return params; - }, + } }, methods: { onSearch() { @@ -130,8 +130,8 @@ export default { ).padStart(2, "0")}/${endDate.getFullYear()} ${String( endDate.getHours() ).padStart(2, "0")}:${String(endDate.getMinutes()).padStart(2, "0")}`; - }, - }, + } + } }; diff --git a/src/views/events/Show.vue b/src/views/events/Show.vue index 365ad63a..fdd50cc1 100644 --- a/src/views/events/Show.vue +++ b/src/views/events/Show.vue @@ -59,14 +59,14 @@ export default { name: "OrganisationEventShow", components: { - EventDetails, + EventDetails }, data() { return { loading: false, event: null, - updated: false, + updated: false }; }, @@ -88,12 +88,12 @@ export default { }, onDelete() { this.$router.push({ name: "events-index" }); - }, + } }, created() { this.updated = this.$route.query.updated || false; this.fetchEvent(); - }, + } }; diff --git a/src/views/events/Updated.vue b/src/views/events/Updated.vue index b8923c7a..0ae113c9 100644 --- a/src/views/events/Updated.vue +++ b/src/views/events/Updated.vue @@ -19,7 +19,7 @@ Back to event @@ -39,7 +39,7 @@ export default { data() { return { loading: false, - event: null, + event: null }; }, methods: { @@ -50,11 +50,11 @@ export default { ); this.event = response.data.data; this.loading = false; - }, + } }, created() { this.fetchEvent(); - }, + } }; diff --git a/src/views/events/forms/DetailsTab.vue b/src/views/events/forms/DetailsTab.vue index 67a2f063..dca3291a 100644 --- a/src/views/events/forms/DetailsTab.vue +++ b/src/views/events/forms/DetailsTab.vue @@ -66,7 +66,9 @@ @input="onInput('description', $event)" id="description" label="Event description*" - :hint="`Describe the event with any details that attendees will need to decide on, find and attend your event. Use headers, bullets and formatting for the maximum effect.`" + :hint=" + `Describe the event with any details that attendees will need to decide on, find and attend your event. Use headers, bullets and formatting for the maximum effect.` + " :error="errors.get('description')" large :maxlength="3000" @@ -99,7 +101,9 @@ @input="onInput('fees_text', $event)" id="fees_text" label="How much does it cost? (if applicable)" - :hint="`Please indicate the basic cost of the event. If there are multiple price points, please provide an indicative range (eg. "5-10 per session").`" + :hint=" + `Please indicate the basic cost of the event. If there are multiple price points, please provide an indicative range (eg. "5-10 per session").` + " type="text" :error="errors.get('fees_text')" :maxlength="75" @@ -132,7 +136,9 @@ @input="onInput('organiser_name', $event)" id="organiser_name" label="Organiser name" - :hint="`Provide the contact name (First name & Surname) for this event, or a generic entry if this isn’t applicable e.g. ‘Enquiries’, or ‘Helpdesk’.`" + :hint=" + `Provide the contact name (First name & Surname) for this event, or a generic entry if this isn’t applicable e.g. ‘Enquiries’, or ‘Helpdesk’.` + " type="text" :error="errors.get('organiser_name')" /> @@ -291,112 +297,112 @@ export default { CkImageInput, CkLocationInput, CkTimePeriodInput, - EventHomepageInput, + EventHomepageInput }, props: { errors: { required: true, - type: Object, + type: Object }, title: { required: true, - type: String, + type: String }, intro: { required: true, - type: String, + type: String }, description: { required: true, - type: String, + type: String }, start_date: { required: true, - type: String, + type: String }, end_date: { required: true, - type: String, + type: String }, start_time: { required: true, - type: String, + type: String }, end_time: { required: true, - type: String, + type: String }, is_free: { required: true, - type: Boolean, + type: Boolean }, fees_text: { required: false, - type: String, + type: String }, fees_url: { required: false, - type: String, + type: String }, organiser_name: { required: false, - type: String, + type: String }, organiser_phone: { required: false, - type: String, + type: String }, organiser_email: { required: false, - type: String, + type: String }, organiser_url: { required: false, - type: String, + type: String }, booking_title: { required: false, - type: String, + type: String }, booking_summary: { required: false, - type: String, + type: String }, booking_url: { required: false, - type: String, + type: String }, booking_cta: { required: false, - type: String, + type: String }, is_virtual: { required: true, - type: Boolean, + type: Boolean }, organisation_id: { required: false, - default: null, + default: null }, location_id: { - required: false, + required: false }, image_file_id: { - required: false, + required: false }, homepage: { required: true, - type: Boolean, + type: Boolean }, id: { required: false, - type: String, + type: String }, organisations: { type: Array, - required: false, - }, + required: false + } }, computed: { @@ -405,8 +411,8 @@ export default { { value: true, label: `Yes - The event is free` }, { value: false, - label: `No - there are elements of this event that must be paid for`, - }, + label: `No - there are elements of this event that must be paid for` + } ]; }, isVirtualOptions() { @@ -414,8 +420,8 @@ export default { { value: true, label: `Yes - The event is virtual` }, { value: false, - label: `No - the event occurs at a location`, - }, + label: `No - the event occurs at a location` + } ]; }, todayAsDate() { @@ -424,14 +430,14 @@ export default { 2, "0" )}-${String(now.getDate()).padStart(2, "0")}`; - }, + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, + } }, watch: { @@ -440,8 +446,8 @@ export default { this.$emit("update:fees_text", ""); this.$emit("update:fees_url", ""); } - }, - }, + } + } }; diff --git a/src/views/events/forms/TaxonomiesTab.vue b/src/views/events/forms/TaxonomiesTab.vue index c0e9f8fb..f2d582e5 100644 --- a/src/views/events/forms/TaxonomiesTab.vue +++ b/src/views/events/forms/TaxonomiesTab.vue @@ -43,15 +43,15 @@ export default { components: { CkTaxonomyInput }, props: { errors: { - required: true, + required: true }, isGlobalAdmin: { - required: true, + required: true }, category_taxonomies: { required: true, - type: Array, - }, - }, + type: Array + } + } }; diff --git a/src/views/events/inputs/EventHomepageInput.vue b/src/views/events/inputs/EventHomepageInput.vue index 44aba1ee..6c3cc745 100644 --- a/src/views/events/inputs/EventHomepageInput.vue +++ b/src/views/events/inputs/EventHomepageInput.vue @@ -33,24 +33,24 @@ export default { props: { value: { - required: true, + required: true }, error: { - required: true, + required: true }, id: { type: String, - required: true, + required: true }, label: { required: true, - type: String, + type: String }, hint: { required: false, - type: String, - }, - }, + type: String + } + } }; diff --git a/src/views/events/show/EventDetails.vue b/src/views/events/show/EventDetails.vue index 88a1b7cf..bf57f935 100644 --- a/src/views/events/show/EventDetails.vue +++ b/src/views/events/show/EventDetails.vue @@ -124,14 +124,14 @@ export default { name: "OrganisationEventDetails", components: { - LocationDetails, + LocationDetails }, props: { event: { required: true, - type: Object, - }, + type: Object + } }, computed: { @@ -161,8 +161,8 @@ export default { ).padStart(2, "0")}/${endDate.getFullYear()} ${String( endDate.getHours() ).padStart(2, "0")}:${String(endDate.getMinutes()).padStart(2, "0")}`; - }, - }, + } + } }; diff --git a/src/views/help/Index.vue b/src/views/help/Index.vue index 618a02ad..915eb7de 100644 --- a/src/views/help/Index.vue +++ b/src/views/help/Index.vue @@ -42,7 +42,7 @@ export default { name: "Help", components: { - VideoIframe, + VideoIframe }, data() { @@ -52,28 +52,27 @@ export default { height: 315, width: 560, src: "https://www.youtube.com/embed/HALo2I-gdXs", - title: "Introduction the to video training series", + title: "Introduction the to video training series" }, { height: 315, width: 560, src: "https://www.youtube.com/embed/RoeMDBZLJQc", - title: "How to sign up to the platform", + title: "How to sign up to the platform" }, { height: 315, width: 560, src: "https://www.youtube.com/embed/p3-4mlY1pOQ", - title: - "Your first login, managing your organisation and adding users", + title: "Your first login, managing your organisation and adding users" }, { height: 315, width: 560, src: "https://www.youtube.com/embed/Qf421buT6zs", - title: "Adding your service", - }, - ], + title: "Adding your service" + } + ] }; }, @@ -90,8 +89,8 @@ export default { } }); return pairedVideos; - }, - }, + } + } }; diff --git a/src/views/help/components/VideoIframe.vue b/src/views/help/components/VideoIframe.vue index c47ef896..f2ccc177 100644 --- a/src/views/help/components/VideoIframe.vue +++ b/src/views/help/components/VideoIframe.vue @@ -15,33 +15,33 @@ export default { props: { width: { type: Number, - required: true, + required: true }, height: { type: Number, - required: true, + required: true }, src: { type: String, - required: true, + required: true }, title: { type: String, - required: true, - }, + required: true + } }, data() { return { computedWidth: 0, - computedHeight: 0, + computedHeight: 0 }; }, computed: { aspectRatio() { return this.height / this.width; - }, + } }, methods: { computeWidth() { @@ -56,12 +56,12 @@ export default { const bottomPad = parseInt(style.paddingBottom) || 0; this.computedHeight = this.computedWidth * this.aspectRatio - topPad - bottomPad; - }, + } }, mounted() { this.computeWidth(); this.computeHeight(); - }, + } }; diff --git a/src/views/locations/Create.vue b/src/views/locations/Create.vue index e7c4b582..74441234 100644 --- a/src/views/locations/Create.vue +++ b/src/views/locations/Create.vue @@ -63,8 +63,8 @@ export default { has_wheelchair_access: false, has_induction_loop: false, has_accessible_toilet: false, - image_file_id: null, - }), + image_file_id: null + }) }; }, methods: { @@ -72,10 +72,10 @@ export default { this.form.post("/locations").then(({ data }) => this.$router.push({ name: "locations-show", - params: { location: data.id }, + params: { location: data.id } }) ); - }, - }, + } + } }; diff --git a/src/views/locations/Edit.vue b/src/views/locations/Edit.vue index dc20990d..edee758a 100644 --- a/src/views/locations/Edit.vue +++ b/src/views/locations/Edit.vue @@ -68,13 +68,13 @@ export default { return { loading: false, location: null, - form: null, + form: null }; }, computed: { updateButtonText() { return this.auth.isGlobalAdmin ? "Update" : "Request update"; - }, + } }, methods: { async fetchLocation() { @@ -96,7 +96,7 @@ export default { has_wheelchair_access: this.location.has_wheelchair_access, has_induction_loop: this.location.has_induction_loop, has_accessible_toilet: this.location.has_accessible_toilet, - image_file_id: null, + image_file_id: null }); this.loading = false; @@ -157,7 +157,7 @@ export default { const updateRequestId = response.id; let next = { name: "locations-updated", - params: { location: this.location.id }, + params: { location: this.location.id } }; if (this.auth.isGlobalAdmin) { @@ -174,10 +174,10 @@ export default { } } this.$router.push(next); - }, + } }, created() { this.fetchLocation(); - }, + } }; diff --git a/src/views/locations/Index.vue b/src/views/locations/Index.vue index bf1c0486..3571508a 100644 --- a/src/views/locations/Index.vue +++ b/src/views/locations/Index.vue @@ -63,24 +63,24 @@ { heading: 'Address line 1', sort: 'address_line_1', - render: (location) => location.address_line_1, + render: location => location.address_line_1 }, { heading: 'City', sort: 'city', - render: (location) => location.city, + render: location => location.city }, { heading: 'Postcode', sort: 'postcode', - render: (location) => location.postcode, - }, + render: location => location.postcode + } ]" :view-route=" - (location) => { + location => { return { name: 'locations-show', - params: { location: location.id }, + params: { location: location.id } }; } " @@ -103,8 +103,8 @@ export default { filters: { address_line_1: "", city: "", - postcode: "", - }, + postcode: "" + } }; }, computed: { @@ -124,7 +124,7 @@ export default { } return params; - }, + } }, methods: { onSearch() { @@ -133,7 +133,7 @@ export default { }, onAddLocation() { this.$router.push({ name: "locations-create" }); - }, - }, + } + } }; diff --git a/src/views/locations/Show.vue b/src/views/locations/Show.vue index fe7525c2..cbf2c2c8 100644 --- a/src/views/locations/Show.vue +++ b/src/views/locations/Show.vue @@ -61,7 +61,7 @@ export default { return { loading: false, location: null, - updated: false, + updated: false }; }, methods: { @@ -77,11 +77,11 @@ export default { }, onDelete() { this.$router.push({ name: "locations-index" }); - }, + } }, created() { this.updated = this.$route.query.updated || false; this.fetchLocation(); - }, + } }; diff --git a/src/views/locations/Updated.vue b/src/views/locations/Updated.vue index 6e4299b8..31e47252 100644 --- a/src/views/locations/Updated.vue +++ b/src/views/locations/Updated.vue @@ -23,7 +23,7 @@ Back to location @@ -42,7 +42,7 @@ export default { data() { return { loading: false, - location: null, + location: null }; }, methods: { @@ -53,10 +53,10 @@ export default { ); this.location = response.data.data; this.loading = false; - }, + } }, created() { this.fetchLocation(); - }, + } }; diff --git a/src/views/locations/forms/LocationForm.vue b/src/views/locations/forms/LocationForm.vue index ed7866b4..f7a1377d 100644 --- a/src/views/locations/forms/LocationForm.vue +++ b/src/views/locations/forms/LocationForm.vue @@ -145,64 +145,64 @@ export default { components: { CkImageInput }, data() { return { - countries, + countries }; }, props: { errors: { required: true, - type: Object, + type: Object }, address_line_1: { required: true, - type: String, + type: String }, address_line_2: { required: true, - type: String, + type: String }, address_line_3: { required: true, - type: String, + type: String }, city: { required: true, - type: String, + type: String }, county: { required: true, - type: String, + type: String }, postcode: { required: true, - type: String, + type: String }, country: { required: true, - type: String, + type: String }, has_induction_loop: { required: true, - type: Boolean, + type: Boolean }, has_wheelchair_access: { required: true, - type: Boolean, + type: Boolean }, has_accessible_toilet: { required: true, - type: Boolean, + type: Boolean }, id: { required: false, - type: String, - }, + type: String + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, - }, + } + } }; diff --git a/src/views/locations/show/LocationDetails.vue b/src/views/locations/show/LocationDetails.vue index e517d45d..43a0781e 100644 --- a/src/views/locations/show/LocationDetails.vue +++ b/src/views/locations/show/LocationDetails.vue @@ -89,8 +89,8 @@ export default { props: { location: { required: true, - type: Object, - }, - }, + type: Object + } + } }; diff --git a/src/views/notifications/Show.vue b/src/views/notifications/Show.vue index 0a967d98..d64f65c2 100644 --- a/src/views/notifications/Show.vue +++ b/src/views/notifications/Show.vue @@ -7,10 +7,12 @@ @@ -33,7 +35,7 @@ export default { data() { return { loading: false, - notification: null, + notification: null }; }, methods: { @@ -44,10 +46,10 @@ export default { ); this.notification = data.data; this.loading = false; - }, + } }, created() { this.fetchNotification(); - }, + } }; diff --git a/src/views/organisations/Create.vue b/src/views/organisations/Create.vue index 564072a1..48827a7c 100644 --- a/src/views/organisations/Create.vue +++ b/src/views/organisations/Create.vue @@ -109,18 +109,18 @@ export default { phone: "", logo_file_id: null, social_medias: [], - category_taxonomies: [], + category_taxonomies: [] }), tabs: [ { id: "details", heading: "Details", active: true }, - { id: "taxonomies", heading: "Taxonomies", active: false }, - ], + { id: "taxonomies", heading: "Taxonomies", active: false } + ] }; }, watch: { ["form.name"](newName) { this.form.slug = this.slugify(newName); - }, + } }, methods: { async onSubmit() { @@ -128,19 +128,19 @@ export default { const organisationId = response.data.id; this.$router.push({ name: "organisations-show", - params: { organisation: organisationId }, + params: { organisation: organisationId } }); }, onTabChange({ index }) { - this.tabs.forEach((tab) => (tab.active = false)); + this.tabs.forEach(tab => (tab.active = false)); const tabId = this.tabs[index].id; - this.tabs.find((tab) => tab.id === tabId).active = true; + this.tabs.find(tab => tab.id === tabId).active = true; }, isTabActive(id) { - const tab = this.tabs.find((tab) => tab.id === id); + const tab = this.tabs.find(tab => tab.id === id); return tab === undefined ? false : tab.active; - }, - }, + } + } }; diff --git a/src/views/organisations/Edit.vue b/src/views/organisations/Edit.vue index 9a288ade..f952334c 100644 --- a/src/views/organisations/Edit.vue +++ b/src/views/organisations/Edit.vue @@ -9,7 +9,7 @@ Back to organisation @@ -127,14 +127,14 @@ export default { form: null, tabs: [ { id: "details", heading: "Details", active: true }, - { id: "taxonomies", heading: "Taxonomies", active: false }, - ], + { id: "taxonomies", heading: "Taxonomies", active: false } + ] }; }, computed: { updateButtonText() { return this.auth.isGlobalAdmin ? "Update" : "Request update"; - }, + } }, methods: { async fetchOrganisation() { @@ -154,8 +154,8 @@ export default { logo_file_id: null, social_medias: this.organisation.social_medias, category_taxonomies: this.organisation.category_taxonomies.map( - (taxonomy) => taxonomy.id - ), + taxonomy => taxonomy.id + ) }); this.loading = false; @@ -201,9 +201,7 @@ export default { if ( JSON.stringify(data.category_taxonomies) === JSON.stringify( - this.organisation.category_taxonomies.map( - (taxonomy) => taxonomy.id - ) + this.organisation.category_taxonomies.map(taxonomy => taxonomy.id) ) ) { delete data.category_taxonomies; @@ -213,7 +211,7 @@ export default { const updateRequestId = response.id; let next = { name: "organisations-updated", - params: { organisation: this.organisation.id }, + params: { organisation: this.organisation.id } }; if (this.auth.isGlobalAdmin) { @@ -233,18 +231,18 @@ export default { this.$router.push(next); }, onTabChange({ index }) { - this.tabs.forEach((tab) => (tab.active = false)); + this.tabs.forEach(tab => (tab.active = false)); const tabId = this.tabs[index].id; - this.tabs.find((tab) => tab.id === tabId).active = true; + this.tabs.find(tab => tab.id === tabId).active = true; }, isTabActive(id) { - const tab = this.tabs.find((tab) => tab.id === id); + const tab = this.tabs.find(tab => tab.id === id); return tab === undefined ? false : tab.active; - }, + } }, created() { this.fetchOrganisation(); - }, + } }; diff --git a/src/views/organisations/Import.vue b/src/views/organisations/Import.vue index 7b1a34f7..fbd1c8b0 100644 --- a/src/views/organisations/Import.vue +++ b/src/views/organisations/Import.vue @@ -75,7 +75,7 @@ export default { components: { Form, SpreadsheetImportForm, - SpreadsheetImportErrors, + SpreadsheetImportErrors }, data() { @@ -92,7 +92,7 @@ export default { form: new Form({ spreadsheet: null, - ignore_duplicates: null, + ignore_duplicates: null }), fields: { @@ -102,8 +102,8 @@ export default { description: "Description", email: "Email", phone: "Phone", - url: "Url", - }, + url: "Url" + } }; }, @@ -117,7 +117,7 @@ export default { }, exampleSpreadsheetDownloadLink() { return `${this.appApiUri}/downloads/organisations_import_example.xls`; - }, + } }, methods: { @@ -130,10 +130,10 @@ export default { (duplicateIds, duplicateRow) => { return duplicateIds.concat( duplicateRow.originals - .filter((original) => { + .filter(original => { return original.ignored; }) - .map((original) => { + .map(original => { return original.id; }) ); @@ -146,16 +146,16 @@ export default { this.form .post("/organisations/import") - .then((response) => { + .then(response => { this.uploadRows = response.data.imported_row_count; this.file = null; }) - .catch((error) => { + .catch(error => { this.invalidRows = error.data.errors ? error.data.errors.spreadsheet : []; this.duplicateRows = - error.data.duplicates.map((duplicateRow) => { + error.data.duplicates.map(duplicateRow => { for (let i = 0; i < duplicateRow.originals.length; i++) { duplicateRow.originals[i].ignored = false; } @@ -168,14 +168,14 @@ export default { for (let i = 0; i < this.duplicateRows.length; i++) { for (let j = 0; j < this.duplicateRows[i].originals.length; j++) { if (this.duplicateRows[i].originals[j].id === duplicateId) { - this.duplicateRows[i].originals[j].ignored = - !this.duplicateRows[i].originals[j].ignored; + this.duplicateRows[i].originals[j].ignored = !this.duplicateRows[i] + .originals[j].ignored; return; } } } - }, - }, + } + } }; diff --git a/src/views/organisations/Index.vue b/src/views/organisations/Index.vue index f44060d8..07f07478 100644 --- a/src/views/organisations/Index.vue +++ b/src/views/organisations/Index.vue @@ -53,26 +53,26 @@ { heading: 'Organisation name', sort: 'name', - render: (organisation) => organisation.name, + render: organisation => organisation.name }, { heading: 'Web address URL', - render: (organisation) => organisation.url, + render: organisation => organisation.url }, { heading: 'Phone number', - render: (organisation) => organisation.phone || '-', + render: organisation => organisation.phone || '-' }, { heading: 'Email', - render: (organisation) => organisation.email || '-', - }, + render: organisation => organisation.email || '-' + } ]" :view-route=" - (organisation) => { + organisation => { return { name: 'organisations-show', - params: { organisation: organisation.id }, + params: { organisation: organisation.id } }; } " @@ -93,14 +93,14 @@ export default { data() { return { filters: { - name: "", - }, + name: "" + } }; }, computed: { params() { const params = { - "filter[has_permission]": true, + "filter[has_permission]": true }; if (this.filters.name !== "") { @@ -108,7 +108,7 @@ export default { } return params; - }, + } }, methods: { onSearch() { @@ -117,7 +117,7 @@ export default { }, onAddOrganisation() { this.$router.push({ name: "organisations-create" }); - }, - }, + } + } }; diff --git a/src/views/organisations/OrganisationTab.vue b/src/views/organisations/OrganisationTab.vue index 46511a56..0c09ea8c 100644 --- a/src/views/organisations/OrganisationTab.vue +++ b/src/views/organisations/OrganisationTab.vue @@ -19,13 +19,13 @@ export default { props: { title: { type: String, - required: true, + required: true }, active: { type: Boolean, - default: false, - }, - }, + default: false + } + } }; diff --git a/src/views/organisations/Show.vue b/src/views/organisations/Show.vue index f00f66b7..bc3bef29 100644 --- a/src/views/organisations/Show.vue +++ b/src/views/organisations/Show.vue @@ -43,7 +43,7 @@ Edit organisation @@ -63,7 +63,7 @@ export default { return { loading: false, updated: false, - organisation: null, + organisation: null }; }, methods: { @@ -78,11 +78,11 @@ export default { }, onDelete() { this.$router.push({ name: "organisations-index" }); - }, + } }, created() { this.updated = this.$route.query.updated || false; this.fetchOrganisation(); - }, + } }; diff --git a/src/views/organisations/Updated.vue b/src/views/organisations/Updated.vue index d78b3f81..2c635f37 100644 --- a/src/views/organisations/Updated.vue +++ b/src/views/organisations/Updated.vue @@ -9,7 +9,7 @@ Back to organisation @@ -26,7 +26,7 @@ Back to organisation @@ -45,7 +45,7 @@ export default { data() { return { loading: false, - organisation: null, + organisation: null }; }, methods: { @@ -56,10 +56,10 @@ export default { ); this.organisation = response.data.data; this.loading = false; - }, + } }, created() { this.fetchOrganisation(); - }, + } }; diff --git a/src/views/organisations/forms/OrganisationForm.vue b/src/views/organisations/forms/OrganisationForm.vue index b999b737..a879c089 100644 --- a/src/views/organisations/forms/OrganisationForm.vue +++ b/src/views/organisations/forms/OrganisationForm.vue @@ -95,50 +95,50 @@ export default { name: "OrganisationForm", components: { CkImageInput, - CkSocialMediasInput, + CkSocialMediasInput }, props: { errors: { required: true, - type: Object, + type: Object }, name: { required: true, - type: String, + type: String }, slug: { required: true, - type: String, + type: String }, description: { required: true, - type: String, + type: String }, url: { required: true, - type: String, + type: String }, phone: { required: true, - type: String, + type: String }, email: { required: true, - type: String, + type: String }, id: { required: false, - type: String, + type: String }, social_medias: { - required: true, - }, + required: true + } }, methods: { onInput(field, value) { this.$emit(`update:${field}`, value); this.$emit("clear", field); - }, - }, + } + } }; diff --git a/src/views/page-feedbacks/Show.vue b/src/views/page-feedbacks/Show.vue index 656185d3..c716eeb4 100644 --- a/src/views/page-feedbacks/Show.vue +++ b/src/views/page-feedbacks/Show.vue @@ -7,10 +7,12 @@ @@ -33,7 +35,7 @@ export default { data() { return { loading: false, - pageFeedback: null, + pageFeedback: null }; }, methods: { @@ -44,10 +46,10 @@ export default { ); this.pageFeedback = data.data; this.loading = false; - }, + } }, created() { this.fetchPageFeedback(); - }, + } }; diff --git a/src/views/pages/Create.vue b/src/views/pages/Create.vue index 0fc784ca..ac8b1c4e 100644 --- a/src/views/pages/Create.vue +++ b/src/views/pages/Create.vue @@ -40,14 +40,14 @@ export default { name: "CreatePage", components: { - PageForm, + PageForm }, props: { type: { type: String, - required: true, - }, + required: true + } }, data() { @@ -61,7 +61,7 @@ export default { page_type: this.type, image_file_id: null, collections: [], - enabled: false, + enabled: false }), contentTypes: { @@ -73,9 +73,9 @@ export default { content: [ { type: "copy", - value: "", - }, - ], + value: "" + } + ] }, about: { order: 2, @@ -84,9 +84,9 @@ export default { content: [ { type: "copy", - value: "", - }, - ], + value: "" + } + ] }, info_pages: { order: 3, @@ -96,9 +96,9 @@ export default { content: [ { type: "copy", - value: "", - }, - ], + value: "" + } + ] }, collections: { order: 4, @@ -108,25 +108,26 @@ export default { content: [ { type: "copy", - value: "", - }, - ], - }, + value: "" + } + ] + } }, information: { introduction: { order: 1, label: "Page content", - hint: "This is the largest content of the page. Use formatting to improve readability and impact.", + hint: + "This is the largest content of the page. Use formatting to improve readability and impact.", content: [ { type: "copy", - value: "", - }, - ], - }, - }, - }, + value: "" + } + ] + } + } + } }; }, @@ -138,23 +139,23 @@ export default { if (this.auth.isSuperAdmin && pageId) { this.$router.push({ name: "pages-show", - params: { page: pageId }, + params: { page: pageId } }); } else if (!this.form.$errors.any()) { this.$router.push({ - name: "pages-updated", + name: "pages-updated" }); } }, onUpdateTitle(title) { this.form.title = title; this.form.slug = this.slugify(title); - }, + } }, created() { this.form.content = this.contentTypes[this.form.page_type]; - }, + } }; diff --git a/src/views/pages/Edit.vue b/src/views/pages/Edit.vue index dbcbda82..88c9bb94 100644 --- a/src/views/pages/Edit.vue +++ b/src/views/pages/Edit.vue @@ -47,14 +47,14 @@ export default { name: "EditPage", components: { - PageForm, + PageForm }, data() { return { loading: false, page: null, - form: null, + form: null }; }, computed: { @@ -63,7 +63,7 @@ export default { }, canDelete() { return this.auth.canDelete("page") && this.page.children.length === 0; - }, + } }, methods: { async fetchPage() { @@ -80,7 +80,7 @@ export default { parent_id: this.page.parent ? this.page.parent.id : null, enabled: this.page.enabled, image_file_id: this.page.image ? this.page.image.id : null, - collections: this.page.collections, + collections: this.page.collections }); this.loading = false; @@ -134,7 +134,7 @@ export default { const updateRequestId = response.id; let next = { name: "pages-updated", - params: { page: this.page.id }, + params: { page: this.page.id } }; if (this.auth.isSuperAdmin) { @@ -151,11 +151,11 @@ export default { } } this.$router.push(next); - }, + } }, created() { this.fetchPage(); - }, + } }; diff --git a/src/views/pages/Index.vue b/src/views/pages/Index.vue index a454a6de..cd8dadba 100644 --- a/src/views/pages/Index.vue +++ b/src/views/pages/Index.vue @@ -14,7 +14,7 @@ diff --git a/src/views/pages/List.vue b/src/views/pages/List.vue index 260a3ede..42d1f94c 100644 --- a/src/views/pages/List.vue +++ b/src/views/pages/List.vue @@ -68,7 +68,7 @@ View View @@ -124,7 +124,7 @@ export default { name: "ListPages", components: { CkTreeList, - CkTableFilters, + CkTableFilters }, data() { return { @@ -133,22 +133,22 @@ export default { pages: [], filters: { title: "", - page_type: null, + page_type: null }, minSearchPhraseLength: 3, pageTypes: [ { value: "", text: "All" }, { value: "information", text: "Information page" }, - { value: "landing", text: "Landing page" }, + { value: "landing", text: "Landing page" } ], updated: false, - orderChangedMessage: null, + orderChangedMessage: null }; }, computed: { pagesTree() { return this.buildPagesTree( - this.pages.filter((page) => { + this.pages.filter(page => { return !page.parent; }) ); @@ -168,21 +168,21 @@ export default { }, updatedPage() { return this.updated - ? this.pages.find((page) => page.id === this.updated) + ? this.pages.find(page => page.id === this.updated) : null; - }, + } }, methods: { async fetchPages() { this.loading = true; this.searching = Object.keys(this.params).length > 0; const { data } = await http.get("/pages/index", { - params: this.params, + params: this.params }); - this.pages = data.data.map((page) => { + this.pages = data.data.map(page => { return { label: page.title, - ...page, + ...page }; }); @@ -194,7 +194,7 @@ export default { page.order--; await http.put(`/pages/${page.id}`, { id: page.id, - order: page.order, + order: page.order }); if (!this.auth.isSuperAdmin) { this.orderChangedMessage = this.orderUpdateRequestMessage( @@ -210,7 +210,7 @@ export default { page.order++; await http.put(`/pages/${page.id}`, { id: page.id, - order: page.order, + order: page.order }); if (!this.auth.isSuperAdmin) { this.orderChangedMessage = this.orderUpdateRequestMessage( @@ -232,9 +232,9 @@ export default { .sort((page1, page2) => { return page1.order - page2.order; }) - .forEach((page) => { + .forEach(page => { page.children = this.pages.filter( - (child) => child.parent && child.parent.id === page.id + child => child.parent && child.parent.id === page.id ); if (depth === 0) { @@ -250,12 +250,12 @@ export default { }, orderUpdateRequestMessage(orderWas, page) { return `An update request has been created to change the order of page ${page.title} from ${orderWas} to ${page.order}`; - }, + } }, created() { this.updated = this.$route.query.updated || false; this.fetchPages(); - }, + } }; diff --git a/src/views/pages/Show.vue b/src/views/pages/Show.vue index 5439f8d2..39569c64 100644 --- a/src/views/pages/Show.vue +++ b/src/views/pages/Show.vue @@ -99,7 +99,7 @@ export default { name: "ShowPage", components: { - PageContent, + PageContent }, data() { @@ -109,8 +109,8 @@ export default { updated: false, pageTypes: { information: "Information page", - landing: "Landing page", - }, + landing: "Landing page" + } }; }, @@ -125,14 +125,14 @@ export default { }, onDelete() { this.$router.push({ - name: "pages-index", + name: "pages-index" }); - }, + } }, created() { this.fetchPage(); - }, + } }; diff --git a/src/views/pages/Updated.vue b/src/views/pages/Updated.vue index 227f2ecf..89c40025 100644 --- a/src/views/pages/Updated.vue +++ b/src/views/pages/Updated.vue @@ -31,14 +31,14 @@ v-if="page" :to="{ name: 'pages-show', - params: { page: page.id }, + params: { page: page.id } }" >Back to page Back to pages @@ -58,7 +58,7 @@ export default { data() { return { loading: false, - page: null, + page: null }; }, methods: { @@ -67,13 +67,13 @@ export default { const response = await http.get(`/pages/${this.$route.params.page}`); this.page = response.data.data; this.loading = false; - }, + } }, created() { if (this.$route.params.page) { this.fetchPage(); } - }, + } }; diff --git a/src/views/pages/forms/PageForm.vue b/src/views/pages/forms/PageForm.vue index 62d620f0..b08eb398 100644 --- a/src/views/pages/forms/PageForm.vue +++ b/src/views/pages/forms/PageForm.vue @@ -95,48 +95,48 @@ export default { components: { CkImageInput, CkPageContent, - CkCollectionInput, + CkCollectionInput }, props: { errors: { type: Object, - required: true, + required: true }, parent_id: { - required: true, + required: true }, title: { type: String, - required: true, + required: true }, slug: { type: String, - required: true, + required: true }, excerpt: { type: String, - default: "", + default: "" }, content: { type: Object, - required: true, + required: true }, enabled: { type: Boolean, - required: true, + required: true }, page_type: { type: String, - default: "information", + default: "information" }, page: { type: Object, - default: null, + default: null }, image_file_id: { - default: null, - }, + default: null + } }, data() { @@ -145,12 +145,12 @@ export default { pages: [], enabledOptions: [ { label: "Enabled", value: true }, - { label: "Disabled", value: false }, + { label: "Disabled", value: false } ], pageTypes: { information: "Information page", - landing: "Landing page", - }, + landing: "Landing page" + } }; }, @@ -159,10 +159,10 @@ export default { return [ { text: "No parent (top level)", value: null }, ...this.parsePages( - this.pages.filter((page) => { + this.pages.filter(page => { return !page.parent; }) - ), + ) ]; }, imageFileSuffix() { @@ -170,7 +170,7 @@ export default { ? { "image/jpeg": "jpg", "image/png": "png", - "image/svg+xml": "svg", + "image/svg+xml": "svg" }[this.page.image.mime_type] : null; }, @@ -184,10 +184,10 @@ export default { contentErrors() { let errors = {}; Object.keys(this.errors) - .filter((key) => { + .filter(key => { return key.startsWith("content_"); }) - .forEach((errorKey) => { + .forEach(errorKey => { errors[errorKey] = this.errors[errorKey]; }); return errors; @@ -195,12 +195,12 @@ export default { pageCollectionIds() { return this.page ? this.page.collection_categories - .map((collection) => collection.id) + .map(collection => collection.id) .concat( - this.page.collection_personas.map((collection) => collection.id) + this.page.collection_personas.map(collection => collection.id) ) : []; - }, + } }, methods: { @@ -218,12 +218,12 @@ export default { }, parsePages(pages, parsed = [], depth = 0) { pages - .filter((page) => !this.page || page.id !== this.page.id) - .forEach((page) => { + .filter(page => !this.page || page.id !== this.page.id) + .forEach(page => { const text = "-".repeat(depth) + " " + page.title; parsed.push({ text, value: page.id }); const children = this.pages.filter( - (child) => child.parent && child.parent.id === page.id + child => child.parent && child.parent.id === page.id ); if (children.length > 0 && depth < 4) { parsed = this.parsePages(children, parsed, depth + 1); @@ -231,12 +231,12 @@ export default { }); return parsed; - }, + } }, created() { this.fetchPages(); - }, + } }; diff --git a/src/views/pages/show/PageContent.vue b/src/views/pages/show/PageContent.vue index f9719a52..aa9ba677 100644 --- a/src/views/pages/show/PageContent.vue +++ b/src/views/pages/show/PageContent.vue @@ -42,8 +42,8 @@ export default { props: { content: { type: Object, - required: true, - }, + required: true + } }, computed: { @@ -55,9 +55,9 @@ export default { } return page1[1].order < page2[1].order ? -1 : 1; }) - .map((contentItem) => contentItem[1]); - }, - }, + .map(contentItem => contentItem[1]); + } + } }; diff --git a/src/views/referrals/Confirmation.vue b/src/views/referrals/Confirmation.vue index 3f6c61a3..4493d4d3 100644 --- a/src/views/referrals/Confirmation.vue +++ b/src/views/referrals/Confirmation.vue @@ -26,9 +26,9 @@ export default { onContinue() { this.$router.push({ name: "referrals-show", - params: { referral: this.$route.params.referral }, + params: { referral: this.$route.params.referral } }); - }, - }, + } + } }; diff --git a/src/views/referrals/Index.vue b/src/views/referrals/Index.vue index a2d5b15d..57702d21 100644 --- a/src/views/referrals/Index.vue +++ b/src/views/referrals/Index.vue @@ -51,7 +51,9 @@ referral.reference, + render: referral => referral.reference }, { heading: 'Service', sort: 'service_name', - render: (referral) => referral.service.name, + render: referral => referral.service.name }, { heading: 'Referred by', - render: (referral) => referral.referee_name || '-', + render: referral => referral.referee_name || '-' }, { heading: 'Status', - render: (referral) => $options.filters.status(referral.status), + render: referral => $options.filters.status(referral.status) }, { heading: 'Date submitted', sort: 'created_at', - render: (referral) => { + render: referral => { return ` ${formatDateTime(referral.created_at)}
${statusLastUpdated(referral)} days remaining `; - }, - }, + } + } ]" :view-route=" - (referral) => { + referral => { return { name: 'referrals-confirmation', - params: { referral: referral.id }, + params: { referral: referral.id } }; } " @@ -132,15 +134,15 @@ export default { { value: "new", text: "New", enabled: true }, { value: "in_progress", text: "In progress", enabled: true }, { value: "completed", text: "Completed", enabled: true }, - { value: "incompleted", text: "Incomplete", enabled: true }, - ], - }, + { value: "incompleted", text: "Incomplete", enabled: true } + ] + } }; }, computed: { params() { const params = { - include: "service.organisation", + include: "service.organisation" }; if (this.filters.reference !== "") { @@ -156,8 +158,8 @@ export default { } const status = this.filters.status - .filter((status) => status.enabled) - .map((status) => status.value) + .filter(status => status.enabled) + .map(status => status.value) .join(","); if (status !== "") { @@ -165,7 +167,7 @@ export default { } return params; - }, + } }, methods: { onSearch() { @@ -179,7 +181,10 @@ export default { let businessDays = 0; for (var i = 0; i < duration; i++) { - const day = start.clone().add(i, "days").isoWeekday(); + const day = start + .clone() + .add(i, "days") + .isoWeekday(); if (day < 6) { businessDays += 1; @@ -196,7 +201,7 @@ export default { const workingDays = this.diffInBusinessDays(referral.created_at); return workingDays >= 10 ? "Due" : 10 - workingDays; - }, + } }, filters: { status(status) { @@ -212,7 +217,7 @@ export default { default: return "Invalid status"; } - }, - }, + } + } }; diff --git a/src/views/referrals/Show.vue b/src/views/referrals/Show.vue index 7c734a17..81d39a0b 100644 --- a/src/views/referrals/Show.vue +++ b/src/views/referrals/Show.vue @@ -139,12 +139,12 @@ export default { { text: "New", value: "new" }, { text: "In progress", value: "in_progress" }, { text: "Completed", value: "completed" }, - { text: "Incomplete", value: "incompleted" }, + { text: "Incomplete", value: "incompleted" } ], form: new Form({ status: null, - comments: "", - }), + comments: "" + }) }; }, methods: { @@ -154,8 +154,8 @@ export default { http .get(`/referrals/${this.$route.params.referral}`, { params: { - include: "service", - }, + include: "service" + } }) .then(({ data }) => { this.referral = data.data; @@ -169,8 +169,8 @@ export default { const config = { params: { "filter[referral_id]": this.$route.params.referral, - include: "user", - }, + include: "user" + } }; http.get("/status-updates", config).then(({ data }) => { @@ -198,7 +198,7 @@ export default { }, onDelete() { this.$router.push({ name: "referrals-index" }); - }, + } }, filters: { status(status) { @@ -214,11 +214,11 @@ export default { default: return "Invalid status"; } - }, + } }, created() { this.fetchReferral(); this.fetchStatusUpdates(); - }, + } }; diff --git a/src/views/register/Index.vue b/src/views/register/Index.vue index a2935fdb..6308e225 100644 --- a/src/views/register/Index.vue +++ b/src/views/register/Index.vue @@ -18,7 +18,7 @@ import Form from "@/classes/Form"; import axios from "axios"; const http = axios.create({ - baseURL: `${process.env.VUE_APP_API_URI}/core/v1`, + baseURL: `${this.appApiUri}/core/v1` }); http.defaults.headers.post["Content-Type"] = "application/json"; @@ -33,7 +33,7 @@ export default { last_name: "", email: "", phone: "", - password: "", + password: "" }, organisation: { id: "", @@ -42,12 +42,12 @@ export default { description: "", url: "", email: "", - phone: "", - }, + phone: "" + } }, {}, http - ), + ) }; }, methods: { @@ -62,13 +62,13 @@ export default { this.$router.push({ name: "register-index" }); } else if ( !this.form.organisation.id && - formErrors.some((error) => error.startsWith("user")) + formErrors.some(error => error.startsWith("user")) ) { this.$router.push({ name: "register-new-step4" }); } } - }, - }, + } + } }; diff --git a/src/views/register/Search.vue b/src/views/register/Search.vue index 9992a793..16a5811f 100644 --- a/src/views/register/Search.vue +++ b/src/views/register/Search.vue @@ -42,22 +42,22 @@ import OrganisationSearch from "./forms/OrganisationSearch.vue"; export default { components: { - OrganisationSearch, + OrganisationSearch }, model: { prop: "form", - event: "update", + event: "update" }, props: { form: { type: Object, - required: true, - }, + required: true + } }, computed: { organisationSelected() { return this.form.organisation.id !== ""; - }, + } }, methods: { onSelected({ id }) { @@ -66,8 +66,8 @@ export default { resetOrganisation() { this.form.organisation.id = ""; this.$router.push({ name: "register-new-step2" }); - }, - }, + } + } }; diff --git a/src/views/register/existing/Information.vue b/src/views/register/existing/Information.vue index b32d9987..16fa7094 100644 --- a/src/views/register/existing/Information.vue +++ b/src/views/register/existing/Information.vue @@ -14,8 +14,8 @@ import InformationCopy from "../components/InformationCopy"; export default { components: { - InformationCopy, - }, + InformationCopy + } }; diff --git a/src/views/register/existing/User.vue b/src/views/register/existing/User.vue index 33928a82..4eff9373 100644 --- a/src/views/register/existing/User.vue +++ b/src/views/register/existing/User.vue @@ -18,26 +18,26 @@ import UserAccount from "../forms/UserAccount"; export default { components: { - UserAccount, + UserAccount }, model: { prop: "form", - event: "update", + event: "update" }, props: { form: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, computed: { fieldsEmpty() { - return Object.values(this.form.user).some((field) => field == ""); - }, - }, + return Object.values(this.form.user).some(field => field == ""); + } + } }; diff --git a/src/views/register/forms/AdditionalInfoTab.vue b/src/views/register/forms/AdditionalInfoTab.vue index d6915426..54b9b962 100644 --- a/src/views/register/forms/AdditionalInfoTab.vue +++ b/src/views/register/forms/AdditionalInfoTab.vue @@ -66,7 +66,9 @@ @input="$emit('input', { field: 'fees_text', value: $event })" id="fees_text" label="How much does it cost? (if applicable)" - :hint="`Please indicate the basic cost of the ${service.type}. If there are multiple price points, please provide an indicative range (eg. "5-10 per session").`" + :hint=" + `Please indicate the basic cost of the ${service.type}. If there are multiple price points, please provide an indicative range (eg. "5-10 per session").` + " type="text" :error="errors.get('service.fees_text')" :maxlength="75" @@ -150,7 +152,9 @@ @input="$emit('input', { field: 'contact_name', value: $event })" id="contact_name" label="Contact name" - :hint="`Provide the contact name (First name & Surname) for this ${service.type}, or a generic entry if this isn’t applicable e.g. ‘Enquiries’, or ‘Helpdesk’.`" + :hint=" + `Provide the contact name (First name & Surname) for this ${service.type}, or a generic entry if this isn’t applicable e.g. ‘Enquiries’, or ‘Helpdesk’.` + " type="text" :error="errors.get('service.contact_name')" /> @@ -182,7 +186,9 @@ @input="$emit('input', { field: 'contact_email', value: $event })" id="contact_email" :label="`Public ${service.type} email address`" - :hint="`Please provide the contact email address for the ${service.type}.`" + :hint=" + `Please provide the contact email address for the ${service.type}.` + " type="email" :error="errors.get('service.contact_email')" /> @@ -218,19 +224,19 @@ import SocialMediasInput from "@/views/services/inputs/SocialMediasInput"; export default { components: { - SocialMediasInput, + SocialMediasInput }, props: { service: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, computed: { @@ -241,7 +247,7 @@ export default { { text: "Two weeks", value: "two_weeks" }, { text: "Three weeks", value: "three_weeks" }, { text: "One month", value: "month" }, - { text: "Longer than a month", value: "longer" }, + { text: "Longer than a month", value: "longer" } ]; }, @@ -250,8 +256,8 @@ export default { { value: true, label: `Yes - The ${this.service.type} is free` }, { value: false, - label: `No - there are elements of this ${this.service.type} that must be paid for`, - }, + label: `No - there are elements of this ${this.service.type} that must be paid for` + } ]; }, @@ -263,7 +269,7 @@ export default { return `mailto:${to}?subject=${encodeURIComponent( subject )}&body=${encodeURIComponent(body)}`; - }, - }, + } + } }; diff --git a/src/views/register/forms/DescriptionTab.vue b/src/views/register/forms/DescriptionTab.vue index 36c65105..da576c0b 100644 --- a/src/views/register/forms/DescriptionTab.vue +++ b/src/views/register/forms/DescriptionTab.vue @@ -42,7 +42,9 @@ @input="$emit('input', { field: 'description', value: $event })" id="description" label="Long description" - :hint="`This is the largest body of text on your page. Fill it with everything else someone should know about your ${service.type}. Use headers, bullets and formatting for the maximum effect.`" + :hint=" + `This is the largest body of text on your page. Fill it with everything else someone should know about your ${service.type}. Use headers, bullets and formatting for the maximum effect.` + " :error="errors.get('service.description')" large :maxlength="3000" @@ -59,19 +61,19 @@ import CkOfferingsInput from "@/views/services/inputs/OfferingsInput.vue"; export default { components: { - CkOfferingsInput, + CkOfferingsInput }, props: { service: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, - }, + required: true + } + } }; diff --git a/src/views/register/forms/DetailsTab.vue b/src/views/register/forms/DetailsTab.vue index 80e0dfb7..03605d65 100644 --- a/src/views/register/forms/DetailsTab.vue +++ b/src/views/register/forms/DetailsTab.vue @@ -41,7 +41,9 @@ @input="$emit('input', { field: 'url', value: $event })" id="url" :label="`What is the web address of your ${service.type}?`" - :hint="`This must start with 'http://' or 'https://'. You can use your organisation's website address if the ${service.type} doesn't have its own.`" + :hint=" + `This must start with 'http://' or 'https://'. You can use your organisation's website address if the ${service.type} doesn't have its own.` + " type="url" :error="errors.get('service.url')" /> @@ -57,13 +59,13 @@ export default { props: { service: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, data() { @@ -72,9 +74,9 @@ export default { { text: "It is a Service", value: "service" }, { text: "It is an Activity", value: "activity" }, { text: "It is a Club", value: "club" }, - { text: "It is a Group", value: "group" }, - ], + { text: "It is a Group", value: "group" } + ] }; - }, + } }; diff --git a/src/views/register/forms/OrganisationSearch.vue b/src/views/register/forms/OrganisationSearch.vue index cb43b5a8..4ae56afe 100644 --- a/src/views/register/forms/OrganisationSearch.vue +++ b/src/views/register/forms/OrganisationSearch.vue @@ -37,7 +37,7 @@ import axios from "axios"; const http = axios.create({ - baseURL: `${process.env.VUE_APP_API_URI}/core/v1`, + baseURL: `${this.appApiUri}/core/v1` }); http.defaults.headers.post["Content-Type"] = "application/json"; @@ -45,17 +45,17 @@ export default { data() { return { filters: { - name: "", + name: "" }, loading: false, organisations: [], - organisationId: null, + organisationId: null }; }, computed: { params() { const params = { - per_page: 20, + per_page: 20 }; if (this.filters.name !== "") { @@ -63,14 +63,14 @@ export default { } return params; - }, + } }, methods: { async fetchOrganisations() { this.loading = true; const response = await http.get("/organisations", { - params: this.params, + params: this.params }); this.organisations = response.data.data; @@ -82,8 +82,8 @@ export default { onSelect(organisationId) { this.$emit("selected", { id: organisationId }); this.organisationId = organisationId; - }, - }, + } + } }; diff --git a/src/views/register/forms/UsefulInfoTab.vue b/src/views/register/forms/UsefulInfoTab.vue index ead12055..2f31586b 100644 --- a/src/views/register/forms/UsefulInfoTab.vue +++ b/src/views/register/forms/UsefulInfoTab.vue @@ -24,19 +24,19 @@ import UsefulInfosInput from "@/views/services/inputs/UsefulInfosInput"; export default { components: { - UsefulInfosInput, + UsefulInfosInput }, props: { service: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, - }, + required: true + } + } }; diff --git a/src/views/register/forms/UserAccount.vue b/src/views/register/forms/UserAccount.vue index 76526bed..eb647221 100644 --- a/src/views/register/forms/UserAccount.vue +++ b/src/views/register/forms/UserAccount.vue @@ -62,13 +62,13 @@ export default { props: { form: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, computed: { @@ -77,8 +77,8 @@ export default { }, privacyPolicyUrl() { return `${this.appFrontendUri}/privacy-policy`; - }, - }, + } + } }; diff --git a/src/views/register/forms/WhoForTab.vue b/src/views/register/forms/WhoForTab.vue index dc538845..b237e364 100644 --- a/src/views/register/forms/WhoForTab.vue +++ b/src/views/register/forms/WhoForTab.vue @@ -17,13 +17,15 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { age_group: $event }), + value: Object.assign(service.criteria, { age_group: $event }) }) " :error="errors.get('service.criteria.age_group')" id="criteria.age_group" label="Age of service user (if applicable)" - :hint="`E.g “This ${service.type} is for people 16+” or “This ${service.type} is aimed at people nearing retirement”`" + :hint=" + `E.g “This ${service.type} is for people 16+” or “This ${service.type} is aimed at people nearing retirement”` + " /> @@ -33,13 +35,15 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { disability: $event }), + value: Object.assign(service.criteria, { disability: $event }) }) " :error="errors.get('service.criteria.disability')" id="criteria.disability" label="Disability Requirements / Restrictions (if applicable)" - :hint="`e.g. "This ${service.type} is for those with MS and their carers", or "For all people with disabilities and their carers"`" + :hint=" + `e.g. "This ${service.type} is for those with MS and their carers", or "For all people with disabilities and their carers"` + " /> @@ -49,7 +53,7 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { gender: $event }), + value: Object.assign(service.criteria, { gender: $event }) }) " :error="errors.get('service.criteria.gender')" @@ -65,7 +69,7 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { housing: $event }), + value: Object.assign(service.criteria, { housing: $event }) }) " :error="errors.get('service.criteria.housing')" @@ -81,13 +85,15 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { income: $event }), + value: Object.assign(service.criteria, { income: $event }) }) " :error="errors.get('service.criteria.income')" id="criteria.income" label="Income level (if applicable)" - :hint="`e.g. "This ${service.type} is aimed at people claiming benefits or with Income support"`" + :hint=" + `e.g. "This ${service.type} is aimed at people claiming benefits or with Income support"` + " /> @@ -97,13 +103,15 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { language: $event }), + value: Object.assign(service.criteria, { language: $event }) }) " :error="errors.get('service.criteria.language')" id="criteria.language" label="Language accessability (if applicable)" - :hint="`E.g. “Instructors speak English, but open to all”, or “This ${service.type} is available in a number of languages - please contact for more information”`" + :hint=" + `E.g. “Instructors speak English, but open to all”, or “This ${service.type} is available in a number of languages - please contact for more information”` + " /> @@ -113,13 +121,17 @@ @input=" $emit('input', { field: 'criteria', - value: Object.assign(service.criteria, { other: $event }), + value: Object.assign(service.criteria, { other: $event }) }) " :error="errors.get('service.criteria.other')" id="criteria.other" - :label="`Any other notes as to who the ${service.type} is aimed at/not appropriate for?`" - :hint="`E.g. “This ${service.type} is open to all”, or “This ${service.type} is aimed at people living in Chessington”`" + :label=" + `Any other notes as to who the ${service.type} is aimed at/not appropriate for?` + " + :hint=" + `E.g. “This ${service.type} is open to all”, or “This ${service.type} is aimed at people living in Chessington”` + " /> @@ -134,19 +146,19 @@ import CriteriaInput from "@/views/services/inputs/CriteriaInput"; export default { components: { - CriteriaInput, + CriteriaInput }, props: { service: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, - }, + required: true + } + } }; diff --git a/src/views/register/new/Criteria.vue b/src/views/register/new/Criteria.vue index 98c5c9f7..5acebb04 100644 --- a/src/views/register/new/Criteria.vue +++ b/src/views/register/new/Criteria.vue @@ -70,31 +70,31 @@ export default { model: { prop: "form", - event: "update", + event: "update" }, props: { form: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, methods: { onInput(organisationType) { if (this.form.organisation_types.includes(organisationType)) { this.form.organisation_types = this.form.organisation_types.filter( - (type) => type !== organisationType + type => type !== organisationType ); } else { const organisationTypes = this.form.organisation_types.slice(); organisationTypes.push(organisationType); this.form.organisation_types = organisationTypes; } - }, - }, + } + } }; diff --git a/src/views/register/new/Information.vue b/src/views/register/new/Information.vue index 06523a39..7906ea7e 100644 --- a/src/views/register/new/Information.vue +++ b/src/views/register/new/Information.vue @@ -14,8 +14,8 @@ import InformationCopy from "../components/InformationCopy"; export default { components: { - InformationCopy, - }, + InformationCopy + } }; diff --git a/src/views/register/new/Organisation.vue b/src/views/register/new/Organisation.vue index 09a82e6c..6b7574cf 100644 --- a/src/views/register/new/Organisation.vue +++ b/src/views/register/new/Organisation.vue @@ -67,24 +67,24 @@ export default { model: { prop: "form", - event: "update", + event: "update" }, props: { form: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, computed: { fieldsEmpty() { return Object.entries(this.form.organisation).some(([field, value]) => { return !["id", "slug"].includes(field) && value == ""; }); - }, - }, + } + } }; diff --git a/src/views/register/new/Register.vue b/src/views/register/new/Register.vue index 5eecb757..f3f4570d 100644 --- a/src/views/register/new/Register.vue +++ b/src/views/register/new/Register.vue @@ -27,7 +27,7 @@ import Form from "@/classes/Form"; import axios from "axios"; const http = axios.create({ - baseURL: `${this.appApiUri}/core/v1`, + baseURL: `${this.appApiUri}/core/v1` }); http.defaults.headers.post["Content-Type"] = "application/json"; @@ -42,7 +42,7 @@ export default { last_name: "", email: "", phone: "", - password: "", + password: "" }, organisation: { name: "", @@ -50,7 +50,7 @@ export default { description: "", url: "", email: "", - phone: "", + phone: "" }, service: { name: "", @@ -76,16 +76,16 @@ export default { housing: "", income: "", language: "", - other: "", + other: "" }, useful_infos: [], offerings: [], - social_medias: [], - }, + social_medias: [] + } }, {}, http - ), + ) }; }, @@ -103,7 +103,7 @@ export default { this.form.service.fees_text = ""; this.form.service.fees_url = ""; } - }, + } }, methods: { @@ -120,7 +120,7 @@ export default { } catch (exception) { // } - }, - }, + } + } }; diff --git a/src/views/register/new/Service.vue b/src/views/register/new/Service.vue index 909449a9..1bcf9c3d 100644 --- a/src/views/register/new/Service.vue +++ b/src/views/register/new/Service.vue @@ -85,19 +85,19 @@ export default { DescriptionTab, AdditionalInfoTab, UsefulInfoTab, - WhoForTab, + WhoForTab }, props: { form: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, data() { @@ -107,8 +107,8 @@ export default { { id: "additional-info", heading: "Additional info", active: false }, { id: "useful-info", heading: "Good to know", active: false }, { id: "who-for", heading: "Who is it for?", active: false }, - { id: "description", heading: "Description", active: false }, - ], + { id: "description", heading: "Description", active: false } + ] }; }, @@ -119,24 +119,24 @@ export default { Object.assign(this.form, { service: { ...this.form.service, - [field]: value, - }, + [field]: value + } }) ); this.$emit("clear", `service.${field}`); }, onTabChange({ index }) { - this.tabs.forEach((tab) => (tab.active = false)); + this.tabs.forEach(tab => (tab.active = false)); const tabId = this.tabs[index].id; - this.tabs.find((tab) => tab.id === tabId).active = true; + this.tabs.find(tab => tab.id === tabId).active = true; }, onNext() { - const currentTabIndex = this.tabs.findIndex((tab) => tab.active === true); - this.tabs.forEach((tab) => (tab.active = false)); + const currentTabIndex = this.tabs.findIndex(tab => tab.active === true); + this.tabs.forEach(tab => (tab.active = false)); const newTabId = this.tabs[currentTabIndex + 1].id; - this.tabs.find((tab) => tab.id === newTabId).active = true; + this.tabs.find(tab => tab.id === newTabId).active = true; this.scrollToTop(); }, @@ -145,10 +145,10 @@ export default { }, isTabActive(id) { - const tab = this.tabs.find((tab) => tab.id === id); + const tab = this.tabs.find(tab => tab.id === id); return tab === undefined ? false : tab.active; - }, - }, + } + } }; diff --git a/src/views/register/new/User.vue b/src/views/register/new/User.vue index 7c3b3918..bf8a256e 100644 --- a/src/views/register/new/User.vue +++ b/src/views/register/new/User.vue @@ -20,26 +20,26 @@ import UserAccount from "../forms/UserAccount"; export default { components: { - UserAccount, + UserAccount }, model: { prop: "form", - event: "update", + event: "update" }, props: { form: { type: Object, - required: true, + required: true }, errors: { type: Object, - required: true, - }, + required: true + } }, computed: { fieldsEmpty() { - return Object.values(this.form.user).some((field) => field == ""); - }, - }, + return Object.values(this.form.user).some(field => field == ""); + } + } }; diff --git a/src/views/reports/Edit.vue b/src/views/reports/Edit.vue index a34306af..b6ae182c 100644 --- a/src/views/reports/Edit.vue +++ b/src/views/reports/Edit.vue @@ -89,13 +89,13 @@ export default { "logs between certain times.", scheduleForm: new Form({ report_type: "Audit Logs Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Audit Logs Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Feedback Export", @@ -104,39 +104,39 @@ export default { "the inbuilt feedback feature between certain times. ", scheduleForm: new Form({ report_type: "Feedback Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Feedback Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Locations Export", description: `Generate a report with all the locations of services on ${this.appName}, and the number of services delivered at each.`, scheduleForm: new Form({ report_type: "Locations Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Locations Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Organisations Export", description: `Generate a report of all the organisations on ${this.appName} with the number of services and attributed accounts.`, scheduleForm: new Form({ report_type: "Organisations Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Organisations Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Referrals Export", @@ -145,13 +145,13 @@ export default { "period. The report contains no personal information.", scheduleForm: new Form({ report_type: "Referrals Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Referrals Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Search Histories Export", @@ -160,13 +160,13 @@ export default { "the site, between a certain time period.", scheduleForm: new Form({ report_type: "Search Histories Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Search Histories Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Services Export", @@ -176,46 +176,46 @@ export default { "updated, contact details etc.", scheduleForm: new Form({ report_type: "Services Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Services Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Users Export", description: `Generate a report of all users on the site, contact details, and last login times.`, scheduleForm: new Form({ report_type: "Users Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Users Export", starts_at: "", - ends_at: "", - }), + ends_at: "" + }) }, { type: "Historic Update Requests Export", description: `Generate a report of all approved/rejected update requests.`, scheduleForm: new Form({ report_type: "Historic Update Requests Export", - repeat_type: null, + repeat_type: null }), generateForm: new Form({ report_type: "Historic Update Requests Export", starts_at: "", - ends_at: "", - }), - }, + ends_at: "" + }) + } ], repeatTypeOptions: [ { label: "Not scheduled", value: null }, { label: "Weekly", value: "weekly" }, - { label: "Monthly", value: "monthly" }, - ], + { label: "Monthly", value: "monthly" } + ] }; }, methods: { @@ -223,9 +223,9 @@ export default { this.loadingReportSchedules = true; const reportSchedules = await this.fetchAll("/report-schedules"); - reportSchedules.forEach((reportSchedule) => { + reportSchedules.forEach(reportSchedule => { const reportType = this.reportTypes.find( - (reportType) => reportType.type === reportSchedule.report_type + reportType => reportType.type === reportSchedule.report_type ); reportType.scheduleForm = new Form(reportSchedule); @@ -238,8 +238,7 @@ export default { const reportId = data.data.id; const file = await http.get(`/reports/${reportId}/download`); - const regex = - /filename[^;=\n]*=(?:(\\?['"])(.*?)\1|(?:[^\s]+'.*?')?([^;\n]*))/; + const regex = /filename[^;=\n]*=(?:(\\?['"])(.*?)\1|(?:[^\s]+'.*?')?([^;\n]*))/; const filename = regex.exec( file.request.getResponseHeader("Content-Disposition") )[2]; @@ -261,7 +260,7 @@ export default { ); reportType.scheduleForm = new Form({ report_type: reportType.scheduleForm.report_type, - repeat_type: null, + repeat_type: null }); return; @@ -305,10 +304,10 @@ export default { case "Historic Update Requests Export": return true; } - }, + } }, created() { this.fetchReportSchedules(); - }, + } }; diff --git a/src/views/reports/Index.vue b/src/views/reports/Index.vue index 4b7cbc69..3d2020bf 100644 --- a/src/views/reports/Index.vue +++ b/src/views/reports/Index.vue @@ -31,17 +31,17 @@ export default { if (this.auth.canView("reports")) { tabs[0] = { heading: "View all", - to: { name: "reports-index" }, + to: { name: "reports-index" } }; } if (this.auth.canAdd("report") || this.auth.canEdit("report")) { tabs[1] = { heading: "Manage", - to: { name: "reports-edit" }, + to: { name: "reports-edit" } }; } return tabs; - }, - }, + } + } }; diff --git a/src/views/reports/View.vue b/src/views/reports/View.vue index 778663ae..b3da8b7f 100644 --- a/src/views/reports/View.vue +++ b/src/views/reports/View.vue @@ -6,21 +6,21 @@ ref="reportsTable" uri="/reports" :columns="[ - { heading: 'Type', render: (report) => report.report_type }, + { heading: 'Type', render: report => report.report_type }, { heading: 'From', - render: (report) => - report.starts_at ? formatDate(report.starts_at) : 'N/A', + render: report => + report.starts_at ? formatDate(report.starts_at) : 'N/A' }, { heading: 'To', - render: (report) => - report.ends_at ? formatDate(report.ends_at) : 'N/A', + render: report => + report.ends_at ? formatDate(report.ends_at) : 'N/A' }, { heading: 'Date / Time', - render: (report) => formatDateTime(report.created_at), - }, + render: report => formatDateTime(report.created_at) + } ]" action-text="Download" @action="onDownload" @@ -39,8 +39,7 @@ export default { async onDownload(report) { const file = await http.get(`/reports/${report.id}/download`); - const regex = - /filename[^;=\n]*=(?:(\\?['"])(.*?)\1|(?:[^\s]+'.*?')?([^;\n]*))/; + const regex = /filename[^;=\n]*=(?:(\\?['"])(.*?)\1|(?:[^\s]+'.*?')?([^;\n]*))/; const filename = regex.exec( file.request.getResponseHeader("Content-Disposition") )[2]; @@ -50,7 +49,7 @@ export default { link.setAttribute("download", filename); document.body.appendChild(link); link.click(); - }, - }, + } + } }; diff --git a/src/views/service-locations/Create.vue b/src/views/service-locations/Create.vue index 75923316..de11a517 100644 --- a/src/views/service-locations/Create.vue +++ b/src/views/service-locations/Create.vue @@ -9,7 +9,7 @@ Back to service @@ -77,7 +77,7 @@ export default { name: "", regular_opening_hours: [], holiday_opening_hours: [], - image_file_id: null, + image_file_id: null }), locationForm: new Form({ address_line_1: "", @@ -90,11 +90,11 @@ export default { accessibility_info: "", has_wheelchair_access: false, has_induction_loop: false, - has_accessible_toilet: false, + has_accessible_toilet: false }), service: null, loading: false, - submitting: false, + submitting: false }; }, methods: { @@ -122,15 +122,15 @@ export default { const { data: service } = await this.form.post("/service-locations"); this.$router.push({ name: "service-locations-show", - params: { serviceLocation: service.id }, + params: { serviceLocation: service.id } }); } catch (error) { this.submitting = false; } - }, + } }, created() { this.fetchService(); - }, + } }; diff --git a/src/views/service-locations/Edit.vue b/src/views/service-locations/Edit.vue index 92a4d1e3..d1c67ab4 100644 --- a/src/views/service-locations/Edit.vue +++ b/src/views/service-locations/Edit.vue @@ -3,15 +3,15 @@