mapper new
This commit is contained in:
1 parent
3a289dd776
commit
c5118a4fd0
12 files changed
+94
-119
No files matched your search
@@ -1,16 +1,32 @@
|
||||
<li class="cursor-grab drag-and-drop__item" x-data="{ moveoverright: false }" id={{ $record->event_id }}
|
||||
<li class="cursor-grab drag-and-drop__item p-3 flex flex-1 gap-3 justify-between"
|
||||
id="{{ $record->event_id }}"
|
||||
x-data="{ moveoverright: false }"
|
||||
x-on:dragstart.self="
|
||||
dragging = true;
|
||||
event.dataTransfer.effectAllowed = 'move';
|
||||
event.dataTransfer.setData('text/plain', event.target.id);"
|
||||
x-on:dragover.prevent="moveoverright = true" x-on:dragleave.prevent="moveoverright = false"
|
||||
x-on:drop="moveoverright = false" :class="moveoverright ? 'bg-primary-500/20!' : ''"
|
||||
x-on:dragover.prevent="moveoverright = true"
|
||||
x-on:dragleave.prevent="moveoverright = false"
|
||||
x-on:drop="moveoverright = false" :class="moveoverright ? 'bg-blue-600/20! rounded':''"
|
||||
x-on:drop.prevent="
|
||||
const id = event.dataTransfer.getData('text/plain');
|
||||
const target = event.target.closest('li');
|
||||
if(document.getElementById(id).getAttribute('mapper') !=target.getAttribute('mapper'))
|
||||
$wire.mountAction('right', { id: id, event_id: target.id });"
|
||||
draggable="true" mapper="right">
|
||||
$wire.mountAction('right', { id: id, event_id: target.id, mover:'right' });"
|
||||
draggable="true"
|
||||
mapper="right">
|
||||
|
||||
@include('filament.tables.columns.parts.move-botton')
|
||||
<div class="grid grid-cols-3 gap-4">
|
||||
@include('filament.tables.columns.parts.move-botton')
|
||||
|
||||
@include('filament.tables.columns.parts.search-right', ['find' => $record->away, 'color' => 'home'])
|
||||
|
||||
@include('filament.tables.columns.parts.search-right', ['find' => $record->home, 'color' => 'away'])
|
||||
</div>
|
||||
|
||||
<div class="flex justify-center gap-4 w-full">
|
||||
<div class="text-sky-500 text-wrap text-right">{{ $record->home }}</div>
|
||||
<div>-</div>
|
||||
<div class="text-lime-500 text-wrap">{{ $record->away }}</div>
|
||||
</div>
|
||||
</li>
|
||||
Reference in new issue
Block a user