eslint corrections in mainbundle

This commit is contained in:
Julie Lenaerts 2024-11-14 16:46:07 +01:00
parent 2d6d2a1f58
commit 0454e5d758
14 changed files with 26 additions and 22 deletions

View File

@ -19,7 +19,7 @@ const addAddressInput = (inputs) => {
if (container === null) {
throw Error("no container");
}
/* exported app */
const app = createApp({
template: `<app v-bind:addAddress="this.addAddress" @address-created="associateToInput"></app>`,
data() {
@ -90,4 +90,4 @@ document.addEventListener('DOMContentLoaded', (_e) =>
window.addEventListener('collection-add-entry', (e) =>
addAddressInput(e.detail.entry.querySelectorAll('input[type="hidden"][data-input-address]'))
);
);

View File

@ -114,8 +114,6 @@ import MyNotifications from './MyNotifications';
import MyWorkflows from './MyWorkflows.vue';
import TabCounter from './TabCounter';
import { mapState } from "vuex";
import { makeFetch } from "ChillMainAssets/lib/api/apiMethods";
export default {
name: "App",

View File

@ -12,7 +12,6 @@
<script setup lang="ts">
import { onMounted, ref } from 'vue'
import { fetchResults } from '../../../lib/api/apiMethods';
import Modal from '../../_components/Modal.vue';
import { NewsItemType } from '../../../types';
import NewsItem from './NewsItem.vue';

View File

@ -30,7 +30,7 @@
import Modal from "ChillMainAssets/vuejs/_components/Modal.vue";
import { marked } from 'marked';
import DOMPurify from 'dompurify';
import { DateTime, NewsItemType } from "../../../types";
import { NewsItemType } from "../../../types";
import type { PropType } from 'vue'
import { ref } from "vue";
import {ISOToDatetime} from '../../../chill/js/date';

View File

@ -28,7 +28,8 @@
<td>{{ $d(c.openingDate.datetime, 'short') }}</td>
<td>
<span
v-for="i in c.socialIssues"
v-for="(i, index) in c.socialIssues"
:key="index"
class="chill-entity entity-social-issue"
>
<span class="badge bg-chill-l-gray text-dark">
@ -112,4 +113,4 @@ export default {
span.badge.rounded-pill.bg-danger {
text-transform: uppercase;
}
</style>
</style>

View File

@ -89,7 +89,7 @@
</div>
<template v-if="this.hasDashboardItems">
<template v-for="dashboardItem in this.dashboardItems">
<template v-for="(dashboardItem, index) in this.dashboardItems" :key="index">
<div
class="mbloc col-xs-12 col-sm-8 news"
v-if="dashboardItem.type === 'news'"

View File

@ -127,7 +127,6 @@ import Modal from 'ChillMainAssets/vuejs/_components/Modal.vue';
import OnTheFlyCreate from './Create.vue';
import OnTheFlyPerson from 'ChillPersonAssets/vuejs/_components/OnTheFly/Person.vue';
import OnTheFlyThirdparty from 'ChillThirdPartyAssets/vuejs/_components/OnTheFly/ThirdParty.vue';
import { postThirdparty } from "ChillThirdPartyAssets/vuejs/_api/OnTheFly";
export default {
name: 'OnTheFly',
@ -165,6 +164,8 @@ export default {
return 'btn-create';
case 'addContact':
return 'btn-tpchild';
default:
return '';
}
},
titleAction() {
@ -177,6 +178,8 @@ export default {
return 'action.create';
case 'addContact':
return 'action.addContact';
default:
return '';
}
},
titleCreate() {
@ -199,6 +202,8 @@ export default {
return this.titleCreate;
case 'addContact':
return 'onthefly.addContact.title';
default:
return '';
}
},
titleMessage() {
@ -207,6 +212,8 @@ export default {
return 'action.redirect.' + this.type;
case 'thirdparty':
return 'action.redirect.' + this.type;
default:
return '';
}
},
buttonMessage() {

View File

@ -8,7 +8,7 @@ const i18n = _createI18n( ontheflyMessages );
let containers = document.querySelectorAll('.onthefly-container');
containers.forEach((container) => {
/*exported app */
const app = createApp({
template: `<app :onTheFly="this.onTheFly" ></app>`,
data() {

View File

@ -27,8 +27,7 @@
<script lang="js">
import VueMultiselect from "vue-multiselect";
import {reactive, defineProps, onMounted} from "vue";
import {fetchCities, searchCities} from "./api";
import { searchCities} from "./api";
export default {
components: {

View File

@ -1,4 +1,4 @@
import {makeFetch, fetchResults} from 'ChillMainAssets/lib/api/apiMethods';
import {makeFetch} from 'ChillMainAssets/lib/api/apiMethods';
/**
* Endpoint chill_api_single_postal_code__index

View File

@ -12,7 +12,7 @@
</template>
<script lang="ts" setup>
import {reactive, ref} from "vue";
import {reactive} from "vue";
import Modal from 'ChillMainAssets/vuejs/_components/Modal.vue';
import {Address} from "../../../types";
import AddressDetailsContent from "./AddressDetailsContent.vue";

View File

@ -1,8 +1,8 @@
<template>
<template v-for="container in data.containers">
<template v-for="(container, index) in data.containers" :key="index">
<h4>{{ container.layer.name.fr }}</h4>
<ul>
<li v-for="unit in container.units">{{ unit.unitName }} ({{ unit.unitRefId }})</li>
<li v-for="(unit, index) in container.units" :key="index">{{ unit.unitName }} ({{ unit.unitRefId }})</li>
</ul>
</template>
</template>

View File

@ -125,11 +125,11 @@ export default {
formatDate(datetime) {
return datetime.split('T')[0] +' '+ datetime.split('T')[1].substring(0,5)
},
isUserSubscribedToStep(w) {
isUserSubscribedToStep() {
// todo
return false;
},
isUserSubscribedToFinal(w) {
isUserSubscribedToFinal() {
// todo
return false;
},

View File

@ -118,7 +118,7 @@ export default {
"POST",
`/api/1.0/main/notification/${this.notificationId}/mark/unread`,
[]
).then((response) => {
).then(() => {
this.$emit("markRead", {notificationId: this.notificationId});
});
},
@ -127,7 +127,7 @@ export default {
"POST",
`/api/1.0/main/notification/${this.notificationId}/mark/read`,
[]
).then((response) => {
).then(() => {
this.$emit("markUnread", {
notificationId: this.notificationId,
});
@ -138,7 +138,7 @@ export default {
"POST",
`/api/1.0/main/notification/markallread`,
[]
).then((response) => {
).then(() => {
this.$emit("markAllRead");
});
},