This commit is contained in:
2024-04-24 19:39:33 +10:00
parent 4c9d1667b6
commit 988dbd4edc
20 changed files with 89 additions and 101 deletions

View File

@@ -23,7 +23,7 @@
</div>
<div class="flex-1">
<div class="flex-1">
<x-ui.input type="datetime-local" label="Publish Date" name="published_at" value="{{ \App\Helpers::timestampNoSeconds($post->published_at ?? '') }}" onchange="updateStatus(event)" />
<x-ui.input type="datetime-local" label="Publish Date" name="published_at" id="published_at" value="{{ \App\Helpers::timestampNoSeconds($post->published_at ?? '') }}" />
</div>
</div>
</div>
@@ -71,4 +71,11 @@
}
}
}
document.addEventListener('DOMContentLoaded', function() {
const publishedAt = document.getElementById('published_at');
if(publishedAt) {
publishedAt.addEventListener('change', updateStatus);
}
});
</script>