Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ jobs:
- name: Build project
run: npm run build

# - name: Run D1 Migrations
# env:
# CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
# CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
# run: npx wrangler d1 migrations apply pos_database --remote
- name: Run D1 Migrations
env:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
run: npx wrangler d1 migrations apply pos_database --remote

- name: Deploy to Cloudflare Pages
uses: cloudflare/pages-action@v1
Expand Down
2 changes: 1 addition & 1 deletion .version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.0.16
0.0.15
1 change: 0 additions & 1 deletion functions/api/borrowed-items/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ export async function onRequestGet(context) {
.bind(...params)
.all();


return Response.json(results);
} catch (e) {
return Response.json({ error: e.message }, { status: 500 });
Expand Down
1 change: 0 additions & 1 deletion functions/api/loans/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ export async function onRequestGet(context) {
.bind(...loanParams)
.all();


if (loans.length === 0) {
return Response.json([]);
}
Expand Down
1 change: 0 additions & 1 deletion src/stores/loanStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ export const useLoanStore = defineStore("loan", () => {
}
}


async function createLoan(loanData) {
loading.value = true;
try {
Expand Down
1 change: 0 additions & 1 deletion src/stores/productStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ export const useProductStore = defineStore("product", () => {
queryParams.append("search", params.search);
}


const queryString = queryParams.toString();
if (queryString) {
url += `?${queryString}`;
Expand Down
58 changes: 38 additions & 20 deletions src/views/Inventory.vue
Original file line number Diff line number Diff line change
Expand Up @@ -115,26 +115,6 @@
</div>
</div>

<!-- Mobile Search Bar (Only shown on small screens) -->
<div class="search-bar-container mobile-search">
<div class="search-input-wrapper">
<Search class="search-icon" />
<input
v-model="searchQuery"
type="text"
placeholder="Search by name or barcode..."
class="search-input"
/>
<button
v-if="searchQuery"
@click="searchQuery = ''"
class="clear-search"
>
</button>
</div>
</div>

<div class="table-container">
<table>
<thead>
Expand Down Expand Up @@ -213,6 +193,44 @@
<div v-if="activeTab === 'borrowed'" class="content-section">
<div class="section-header">
<h2>Borrowed Inventory</h2>
<div class="header-actions">
<div class="search-input-wrapper desktop-search">
<Search class="icon-sm search-icon" />
<input
v-model="searchQuery"
type="text"
placeholder="Search borrowed items..."
class="search-input"
/>
<button
v-if="searchQuery"
@click="searchQuery = ''"
class="clear-search"
>
</button>
</div>
</div>
</div>

<!-- Mobile Search Bar -->
<div class="search-bar-container mobile-search">
<div class="search-input-wrapper">
<Search class="search-icon" />
<input
v-model="searchQuery"
type="text"
placeholder="Search by name, barcode or source..."
class="search-input"
/>
<button
v-if="searchQuery"
@click="searchQuery = ''"
class="clear-search"
>
</button>
</div>
<div class="header-actions">
<div class="search-input-wrapper desktop-search">
<Search class="icon-sm search-icon" />
Expand Down
Loading