zmena stavu 3 z DONE na BLOCKED,

stav 4 bude DONE
This commit is contained in:
Igor Miňo 2025-05-05 00:21:45 +02:00
parent 88cc225e4d
commit 1eda8f80bf

View File

@ -87,12 +87,12 @@
</template>
</draggable>
</div>
<div id="done">
<h2>Hotové</h2>
<div id="blocked">
<h2>Blokované</h2>
<draggable
v-model="itemsDone"
v-model="itemsBlocked"
item-key="report_id"
:group="{ name: 'itemsDone', pull: true, put: true }"
:group="{ name: 'itemsBlocked', pull: true, put: true }"
@change="onDragChange"
@start="onDragStart"
@end="onDragEnd"
@ -149,7 +149,7 @@ export default {
itemsUncategorized: [],
itemsWaiting: [],
itemsInProgress: [],
itemsDone: [],
itemsBlocked: [],
};
},
methods: {
@ -158,7 +158,7 @@ export default {
this.itemsUncategorized = all_grouped[0];
this.itemsWaiting = all_grouped[1];
this.itemsInProgress = all_grouped[2];
this.itemsDone = all_grouped[3];
this.itemsBlocked = all_grouped[3];
});
},
getDataByStatus(report_status) {
@ -174,7 +174,7 @@ export default {
for_reorder = this.itemsInProgress;
break;
case 3:
for_reorder = this.itemsDone;
for_reorder = this.itemsBlocked;
break;
}
return for_reorder;
@ -189,8 +189,8 @@ export default {
for (let i = 0; i < this.itemsInProgress.length; i++) {
if (this.itemsInProgress[i].report_id === report_id) return 2;
}
for (let i = 0; i < this.itemsDone.length; i++) {
if (this.itemsDone[i].report_id === report_id) return 3;
for (let i = 0; i < this.itemsBlocked.length; i++) {
if (this.itemsBlocked[i].report_id === report_id) return 3;
}
},
onDragChange(event) {