mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
build(dev): rebuild, file formatting, removed console logs
This commit is contained in:
1 parent
734a3fac6c
commit
f69e55859b
34 files changed
+1537
-1177
No files matched your search
@@ -1,75 +1,96 @@
|
||||
<template>
|
||||
<v-dialog v-model="visible" :width="modalWidth" :height="modalHeight" persistent :retain-focus="false">
|
||||
<v-card style="position: relative">
|
||||
<div class="d-flex justify-space-between align-center">
|
||||
<h1>Ste si istý, že chcete zmazať <b>{{ mastertask.name }}</b>?</h1>
|
||||
<v-dialog
|
||||
v-model="visible"
|
||||
:width="modalWidth"
|
||||
:height="modalHeight"
|
||||
persistent
|
||||
:retain-focus="false"
|
||||
>
|
||||
<v-card style="position: relative">
|
||||
<div class="d-flex justify-space-between align-center">
|
||||
<h1>
|
||||
Ste si istý, že chcete zmazať <b>{{ mastertask.name }}</b
|
||||
>?
|
||||
</h1>
|
||||
|
||||
<div class="d-flex align-center">
|
||||
<a-reset-size-button @reset="resetModalSize" />
|
||||
<a-close-button class="mb-15" @close="closeModal()" />
|
||||
</div>
|
||||
</div>
|
||||
<v-card-actions class="mt-10 d-flex justify-start align-center mobile-view">
|
||||
<v-btn class="button primary half" variant="flat" :disabled="isDeleting" @click="deleteMasterTask()">ÁNO</v-btn>
|
||||
<v-btn class="button primary half outline" @click.stop="closeModal()">ZRUŠIŤ</v-btn>
|
||||
</v-card-actions>
|
||||
<a-resize-handle :current-width="modalWidthPx" :current-height="modalHeightPx" @resize="handleModalResize" @resize-end="handleResizeEnd" />
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
<div class="d-flex align-center">
|
||||
<a-reset-size-button @reset="resetModalSize" />
|
||||
<a-close-button class="mb-15" @close="closeModal()" />
|
||||
</div>
|
||||
</div>
|
||||
<v-card-actions
|
||||
class="mt-10 d-flex justify-start align-center mobile-view"
|
||||
>
|
||||
<v-btn
|
||||
class="button primary half"
|
||||
variant="flat"
|
||||
:disabled="isDeleting"
|
||||
@click="deleteMasterTask()"
|
||||
>ÁNO</v-btn
|
||||
>
|
||||
<v-btn class="button primary half outline" @click.stop="closeModal()"
|
||||
>ZRUŠIŤ</v-btn
|
||||
>
|
||||
</v-card-actions>
|
||||
<a-resize-handle
|
||||
:current-width="modalWidthPx"
|
||||
:current-height="modalHeightPx"
|
||||
@resize="handleModalResize"
|
||||
@resize-end="handleResizeEnd"
|
||||
/>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import modalMixin from '@/plugins/tm@modal/_mixins/modal.mixin'
|
||||
import AResizeHandle from '@/plugins/tm@modal/_components/a-resize-handle.vue'
|
||||
import AResetSizeButton from '@/plugins/tm@modal/_components/a-reset-size-button.vue'
|
||||
import ACloseButton from '@/plugins/tm@modal/_components/a-close-button.vue'
|
||||
import modalMixin from '@/plugins/tm@modal/_mixins/modal.mixin';
|
||||
import AResizeHandle from '@/plugins/tm@modal/_components/a-resize-handle.vue';
|
||||
import AResetSizeButton from '@/plugins/tm@modal/_components/a-reset-size-button.vue';
|
||||
import ACloseButton from '@/plugins/tm@modal/_components/a-close-button.vue';
|
||||
|
||||
export default {
|
||||
components: {
|
||||
AResizeHandle,
|
||||
AResetSizeButton,
|
||||
ACloseButton,
|
||||
},
|
||||
mixins: [modalMixin],
|
||||
emits: ['on-mastertask-deleted'],
|
||||
|
||||
components: {
|
||||
AResizeHandle,
|
||||
AResetSizeButton, ACloseButton,
|
||||
},
|
||||
mixins: [ modalMixin ],
|
||||
emits: ['on-mastertask-deleted'],
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
mastertask: null,
|
||||
isDeleting: false,
|
||||
modalName: 'z-delete-master-task-modal',
|
||||
};
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
mastertask: null,
|
||||
isDeleting: false,
|
||||
modalName: 'z-delete-master-task-modal',
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async showModal({ mastertask }) {
|
||||
this.mastertask = mastertask;
|
||||
this.visible = true;
|
||||
},
|
||||
|
||||
methods: {
|
||||
async showModal({ mastertask }) {
|
||||
this.mastertask = mastertask
|
||||
this.visible = true
|
||||
},
|
||||
closeModal() {
|
||||
this.visible = false;
|
||||
},
|
||||
|
||||
closeModal() {
|
||||
this.visible = false
|
||||
},
|
||||
async deleteMasterTask() {
|
||||
if (this.isDeleting) return;
|
||||
|
||||
async deleteMasterTask() {
|
||||
if (this.isDeleting) return
|
||||
this.isDeleting = true;
|
||||
|
||||
this.isDeleting = true
|
||||
|
||||
try {
|
||||
await this.$axios.delete_auth(`v1/mastertasks/${this.mastertask.id}`)
|
||||
this.$emit('on-mastertask-deleted', this.mastertask)
|
||||
this.closeModal()
|
||||
} catch (error) {
|
||||
this.$toast.error(this.$parseError(error))
|
||||
|
||||
if (process.env.NODE_ENV === 'development')
|
||||
/* eslint-disable *//* eslint-disable */console.log(...oo_oo(`940139120_68_25_68_123_4`,...oo_oo(`2911006425_60_5_60_67_4`,'[z-delete-master-task-modal.vue] Error: ', error)))
|
||||
} finally {
|
||||
this.isDeleting = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
try {
|
||||
await this.$axios.delete_auth(`v1/mastertasks/${this.mastertask.id}`);
|
||||
this.$emit('on-mastertask-deleted', this.mastertask);
|
||||
this.closeModal();
|
||||
} catch (error) {
|
||||
this.$toast.error(this.$parseError(error));
|
||||
} finally {
|
||||
this.isDeleting = false;
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
Reference in new issue
Block a user