[fix] perbaikan padding dan title yang tidak serasih

This commit is contained in:
dhilanradya 2025-09-08 14:17:42 +07:00
parent 7766fd8938
commit 86f3e101c8
6 changed files with 26 additions and 26 deletions

View File

@ -20,22 +20,22 @@ class DatabaseSeeder extends Seeder
public function run(): void public function run(): void
{ {
User::factory()->create([ User::factory()->create([
'nama' => 'Owner', 'nama' => 'iwan',
'role' => 'owner', 'role' => 'owner',
'password' => bcrypt('123123'), 'password' => bcrypt('123123'),
]); ]);
User::factory()->create([ User::factory()->create([
'nama' => 'Kasir', 'nama' => 'luis',
'role' => 'kasir', 'role' => 'kasir',
'password' => bcrypt('123123'), 'password' => bcrypt('123123'),
]); ]);
User::factory(2)->create(); User::factory(2)->create();
Sales::factory(5)->create(); Sales::factory(5)->create();
$kodeNampan = ['A', 'B']; $kodeNampan = ['A', 'B'];
foreach ($kodeNampan as $kode) { foreach ($kodeNampan as $kode) {
for ($i=0; $i < 4; $i++) { for ($i=0; $i < 4; $i++) {
Nampan::factory()->create([ Nampan::factory()->create([
'nama' => $kode . ($i + 1) // A1, A2, ... B4 'nama' => $kode . ($i + 1) // A1, A2, ... B4
]); ]);
@ -48,7 +48,7 @@ class DatabaseSeeder extends Seeder
'nama' => $kategori 'nama' => $kategori
]); ]);
} }
Produk::factory(10)->create()->each(function ($produk) { Produk::factory(10)->create()->each(function ($produk) {
// setiap produk punya 1-3 foto // setiap produk punya 1-3 foto
$jumlah_foto = rand(1, 3); $jumlah_foto = rand(1, 3);
@ -60,7 +60,7 @@ class DatabaseSeeder extends Seeder
]; ];
} }
$produk->foto()->createMany($fotoData); $produk->foto()->createMany($fotoData);
$jumlah_item = rand(1, 20); $jumlah_item = rand(1, 20);
Item::factory($jumlah_item)->create([ Item::factory($jumlah_item)->create([
'id_produk' => $produk->id, 'id_produk' => $produk->id,

View File

@ -1,11 +1,13 @@
<template> <template>
<mainLayout> <mainLayout>
<p style="font-family: 'IM FELL Great Primer', serif; font-style: italic;font-size: 25px;">BRANKAS</p> <div class="p-6">
<searchbar v-model:search="searchQuery" /> <p class="font-serif italic text-[25px] text-D">BRANKAS</p>
<BrankasList :search="searchQuery" /> <searchbar v-model:search="searchQuery" />
<BrankasList :search="searchQuery" />
</div>
</mainLayout> </mainLayout>
</template> </template>
<script setup> <script setup>
import { ref } from 'vue'; import { ref } from 'vue';
@ -13,4 +15,4 @@ import mainLayout from '../layouts/mainLayout.vue'
import searchbar from '../components/searchbar.vue'; import searchbar from '../components/searchbar.vue';
import BrankasList from '../components/BrankasList.vue'; import BrankasList from '../components/BrankasList.vue';
const searchQuery = ref(""); const searchQuery = ref("");
</script> </script>

View File

@ -5,9 +5,9 @@
<ConfirmDeleteModal :isOpen="confirmDeleteOpen" :item="kategoriToDelete" title="Hapus Kategori" <ConfirmDeleteModal :isOpen="confirmDeleteOpen" :item="kategoriToDelete" title="Hapus Kategori"
message="Apakah Anda yakin ingin menghapus kategori ini?" @confirm="confirmDelete" @cancel="closeDeleteModal" /> message="Apakah Anda yakin ingin menghapus kategori ini?" @confirm="confirmDelete" @cancel="closeDeleteModal" />
<div class="p-6 min-h-[75vh]" > <div class="p-6 min-h-[75vh]" >
<!-- Header Section --> <p class="font-serif italic text-[25px] text-D">KATEGORI</p>
<div class="flex justify-between items-center mb-6"> <div class="flex justify-between items-center mb-6">
<h1 class="text-2xl font-bold text-gray-800">Kategori</h1>
<button @click="tambahKategori" <button @click="tambahKategori"
class="px-4 py-2 bg-C text-black rounded-md hover:bg-B transition duration-200 flex items-center gap-2"> class="px-4 py-2 bg-C text-black rounded-md hover:bg-B transition duration-200 flex items-center gap-2">
<svg class="w-4 h-4" fill="none" stroke="currentColor" viewBox="0 0 24 24"> <svg class="w-4 h-4" fill="none" stroke="currentColor" viewBox="0 0 24 24">

View File

@ -25,9 +25,9 @@
/> />
<div class="p-6 min-h-[75vh]"> <div class="p-6 min-h-[75vh]">
<!-- Header Section --> <p class="font-serif italic text-[25px] text-D">SALES</p>
<div class="flex justify-between items-center mb-6"> <div class="flex justify-between items-center mb-6">
<h1 class="text-2xl font-bold text-D">Sales</h1>
<button <button
@click="tambahSales" @click="tambahSales"
class="px-4 py-2 bg-C text-D rounded-md hover:bg-C/80 transition duration-200 flex items-center gap-2" class="px-4 py-2 bg-C text-D rounded-md hover:bg-C/80 transition duration-200 flex items-center gap-2"

View File

@ -1,17 +1,9 @@
<template> <template>
<mainLayout> <mainLayout>
<!-- Header --> <!-- Header -->
<div class="mb-4"> <div class="p-6">
<!-- Judul --> <!-- Judul -->
<p <p class="font-serif italic text-[25px] text-D">NAMPAN</p>
style="
font-family: 'IM FELL Great Primer', serif;
font-style: italic;
font-size: 25px;
"
>
NAMPAN
</p>
<!-- Searchbar --> <!-- Searchbar -->
<div class="flex justify-end mt-2"> <div class="flex justify-end mt-2">

View File

@ -15,6 +15,7 @@ import Akun from "../pages/Akun.vue";
import auth from "../middlewares/auth"; import auth from "../middlewares/auth";
import guest from "../middlewares/guest"; import guest from "../middlewares/guest";
import owner from "../middlewares/owner"; import owner from "../middlewares/owner";
import StrukOverlay from "../components/StrukOverlay.vue";
const middlewareMap = { auth, guest, owner }; const middlewareMap = { auth, guest, owner };
@ -50,6 +51,11 @@ const routes = [
component: Brankas, component: Brankas,
meta: { middleware: "auth" }, meta: { middleware: "auth" },
}, },
{
path: "/home",
name: "Home",
meta: { middleware: "auth" },
},
{ {
path: "/nampan", path: "/nampan",
name: "Nampan", name: "Nampan",
@ -108,7 +114,7 @@ router.beforeEach((to, from, next) => {
if (!mw) return next(); if (!mw) return next();
mw(to, from, (redirect) => { mw(to, from, (redirect) => {
if (redirect) return next(redirect); if (redirect) return next(redirect);
index++; index++;
if (index < middlewares.length) { if (index < middlewares.length) {
run(); run();