Skip to content

Commit

Permalink
Release: v1.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
XPH0816 committed Jun 21, 2024
1 parent b0ad176 commit fdc8167
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "libraryroombookingsystem",
"private": true,
"version": "1.0.3",
"version": "1.0.4",
"type": "module",
"scripts": {
"dev": "vite",
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "LibraryRoomBookingSystem"
version = "1.0.3"
version = "1.0.4"
description = "A Library Room Booking System built with Tauri and Rust"
authors = ["Lim Shi Song limshisong123@gmail.com"]
edition = "2021"
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
},
"package": {
"productName": "LibraryRoomBookingSystem",
"version": "1.0.3"
"version": "1.0.4"
},
"tauri": {
"allowlist": {
Expand Down
7 changes: 6 additions & 1 deletion src/routes/(admin)/manage/feedback/form/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
let submit;
let success = false;
let failure = false;
let msg;
let view = false;
let reply;
let close;
Expand All @@ -39,7 +41,7 @@
submit = async () => {
success = failure = false;
try {
if (reply.comment === "") throw new Error("Reply is Required");
if (!reply.comment) throw new Error("Please enter your reply");
data.feedback.content = content;
data.feedback.admin_id = $user.id;
data.feedback.comment = reply.comment;
Expand All @@ -50,6 +52,8 @@
} else throw new Error("Failed to Submit Feedback");
} catch (e) {
failure = true;
if(e.message) msg = e.message;
else msg = "Failed to Submit Feedback";
}
};
});
Expand All @@ -61,6 +65,7 @@
bind:content
bind:success
bind:failure
bind:msg
feedback={data.feedback}
bind:data={reply}
button="Reply"
Expand Down
2 changes: 2 additions & 0 deletions src/routes/(authed)/booking/room/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@
"Room is not available for the selected time period",
);
}
if (roomId === undefined) throw new Error("Please select a room");
if (!reason) throw new Error("Please enter a reason");
let booking = new Booking({
room_id: roomId,
user_id: $user.id,
Expand Down

0 comments on commit fdc8167

Please sign in to comment.