Adding PurchaseOrder(view only)

This commit is contained in:
Nikitha
2026-02-23 16:09:53 -07:00
parent 4fcaa7f2eb
commit 287995b22c
6 changed files with 168 additions and 0 deletions

View File

@@ -106,6 +106,21 @@
<Insets bottom="12.0" left="12.0" right="45.0" top="12.0" />
</padding>
</Button>
<Button fx:id="btnPurchaseOrders"
mnemonicParsing="false"
onAction="#btnPurchaseOrdersClicked"
prefWidth="250.0"
style="-fx-background-color: transparent; -fx-background-radius: 8; -fx-cursor: hand;"
text="🧾 Purchase Orders"
textFill="#cccccc">
<font>
<Font name="Comic Sans MS Bold" size="14.0" />
</font>
<padding>
<Insets bottom="12.0" left="12.0" right="40.0" top="12.0" />
</padding>
</Button>
<Button fx:id="btnLogout" mnemonicParsing="false" onAction="#btnLogoutClicked" prefWidth="250.0" style="-fx-background-color: #34495E; -fx-background-radius: 8; -fx-cursor: hand;" text="🚪 Logout" textFill="#cccccc">
<font>
<Font name="Comic Sans MS Bold" size="14.0" />

View File

@@ -0,0 +1,71 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<?import javafx.scene.text.Font?>
<VBox spacing="20.0"
style="-fx-font-size: 14px;"
xmlns="http://javafx.com/javafx/25"
xmlns:fx="http://javafx.com/fxml/1"
fx:controller="org.example.petshopdesktop.controllers.PurchaseOrderController">
<padding>
<Insets bottom="20" left="20" right="20" top="20"/>
</padding>
<!-- HEADER -->
<HBox spacing="20" alignment="CENTER_LEFT">
<Label text="Purchase Orders" textFill="#2c3e50">
<font>
<Font name="System Bold" size="30"/>
</font>
</Label>
<Label text="(View Only)" textFill="#7f8c8d">
<font>
<Font name="System Bold" size="16"/>
</font>
<padding>
<Insets top="10"/>
</padding>
</Label>
<Region HBox.hgrow="ALWAYS"/>
<Button fx:id="btnRefresh"
text="Refresh"
onAction="#btnRefresh"
style="-fx-background-color:#4ECDC4; -fx-background-radius:8;"
textFill="WHITE"/>
</HBox>
<!-- SEARCH -->
<HBox spacing="10"
style="-fx-background-color:white; -fx-background-radius:14; -fx-border-width:2; -fx-border-radius:14;">
<padding>
<Insets bottom="10" left="15" right="15" top="10"/>
</padding>
<TextField fx:id="txtSearch"
promptText="Search Purchase Orders..."
style="-fx-border-width:0; -fx-background-color:transparent;"
HBox.hgrow="ALWAYS"/>
</HBox>
<!-- TABLE -->
<TableView fx:id="tvPurchaseOrders"
style="-fx-background-color:white; -fx-background-radius:12;"
VBox.vgrow="ALWAYS">
<columns>
<TableColumn fx:id="colOrderId" text="Order ID" prefWidth="80"/>
<TableColumn fx:id="colSupplier" text="Supplier" prefWidth="200"/>
<TableColumn fx:id="colOrderDate" text="Order Date" prefWidth="150"/>
<TableColumn fx:id="colStatus" text="Status" prefWidth="120"/>
</columns>
</TableView>
</VBox>