This commit is contained in:
Aritra Banik 2024-05-25 16:19:10 +05:30
parent aef880dea5
commit b29f2a76ff
4 changed files with 46 additions and 1 deletions

View file

@ -1,3 +1,9 @@
module main
import vweb
import vweb
@['/faculty/login'; get]
pub fn (mut app App) faculty_login() vweb.Result {
return $vweb.html()
}

9
src/student_view.v Normal file
View file

@ -0,0 +1,9 @@
// module main
// import vweb
// @[get]
// pub fn student_view() !vweb.Result {
// return $vweb.html()
// }

View file

@ -0,0 +1,30 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Student Attendance</title>
@css '/templates/style.css'
</head>
<body>
<header>
<h1>Check Attendance</h1>
</header>
<main>
<section>
<p>Enter your Student ID:</p>
<input type="text" id="student_id">
<button onclick="checkAttendance()">Check</button>
<p id="attendance_message"></p>
</section>
</main>
<script>
function checkAttendance() {
// Simulate attendance check (replace with actual logic)
const studentId = document.getElementById('student_id').value;
const attendanceMessage = document.getElementById('attendance_message');
attendanceMessage.textContent = `Attendance data for student ID ${studentId} is not available in this demo.`;
}
</script>
</body>
</html>