aboutsummaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorHumairAK <humair88@hotmail.com>2016-07-22 01:57:36 +0000
committerHumairAK <humair88@hotmail.com>2016-07-22 01:57:36 +0000
commit49d11776dc2b96cf93e04d15c11a02f880fa8941 (patch)
tree52574598d74525b8595eca82510b4b422fed104f /views
parent797b4fe83ed4ebbed47930c7d0d0a34cd37703c6 (diff)
made further changes to admin panel and index.js
Diffstat (limited to 'views')
-rw-r--r--views/admin.hbs161
-rw-r--r--views/layouts/layout.hbs2
2 files changed, 98 insertions, 65 deletions
diff --git a/views/admin.hbs b/views/admin.hbs
index ecbd46e..da33f41 100644
--- a/views/admin.hbs
+++ b/views/admin.hbs
@@ -1,69 +1,102 @@
<main id="solutions-main">
-<div class="col-md-4 col-md-offset-4 col-sm-6 col-sm-offset-3">
-<h4>Add Exam</h4>
-<form action="/admin/update" method="post">
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="course code"
- name="course_code">
+<div class="row signup">
+ <div class="col-md-3 col-md-offset-1 admin-form">
+ <h4>Add Exam</h4>
+ <form action="/admin/update/exam" method="post">
+ <div class="form-group">
+ Course Code: <input type="text"
+ class="form-control"
+ placeholder="course code"
+ name="course_code">
+ </div>
+ <div class="form-group">
+ Year of Exam:
+ <input type="text"
+ class="form-control"
+ placeholder="year"
+ name="year">
+ </div>
+ <div class="form-group">
+ Term: <input type="text"
+ class="form-control"
+ placeholder="term"
+ name="term">
+ </div>
+ <div class="form-group">
+ Type of test:
+ <input type="radio" name="type" value="Midterm"> Midterm
+ <input type="radio" name="type" value="Final"> Final
+ </div>
+ <div class="form-group">
+ List all instructors separated by comma:
+ <input type="text"
+ class="form-control"
+ placeholder="instructor1,instructor2,.."
+ name="instructors">
+ </div>
+ <div class="form-group">
+ Page Count:
+ <input type="text"
+ class="form-control"
+ placeholder="page count"
+ name="page_count">
+ </div>
+ <div class="form-group">
+ Questions count:
+ <input type="text"
+ class="form-control"
+ placeholder="questions count"
+ name="questions_count">
+ </div>
+ <div class="form-group">
+ Questions Seperated by Comma
+ <input type="text"
+ class="form-control"
+ placeholder="q1,q2,q3,.."
+ name="questions_list">
+ </div>
+
+ <div class="form-group">
+ Upload Date:
+ <input type="text"
+ class="form-control"
+ placeholder="yyyy-mm-dd"
+ name="upload_date">
+ </div>
+ <div class="form-group">
+ Your username:
+ <input type="text"
+ class="form-control"
+ placeholder="uploader"
+ name="uploaded_by">
+ </div>
+
+ <input type="hidden" name="_csrf" value="{{ csrfToken }}">
+ <button type="submit" class="btn btn-primary">Submit</button>
+ </form>
</div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="year"
- name="year">
+
+ <div class="col-md-3 admin-form">
+ <h4>Add Course</h4>
+ <form action="/admin/update/course" method="post">
+ <div class="form-group">
+ Course Code: <input type="text"
+ class="form-control"
+ placeholder="e.g. CSC240"
+ name="course_code">
+ </div>
+ <div class="form-group">
+ Title: <input type="text"
+ class="form-control"
+ placeholder="e.g. Theory of Computation"
+ name="title">
+ </div>
+ <input type="hidden" name="_csrf" value="{{ csrfToken }}">
+ <button type="submit" class="btn btn-primary">Submit</button>
+ </form>
+
</div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="term"
- name="term">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="type"
- name="type">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="instructor1,instructor2,.."
- name="instructors">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="page count"
- name="page_count">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="questions count"
- name="questions_count">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="q1,q2,q3,.."
- name="questions_list">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="upload date"
- name="upload_date">
- </div>
- <div class="form-group">
- <input type="text"
- class="form-control"
- placeholder="uploader"
- name="uploaded_by">
- </div>
- <input type="hidden" name="_csrf" value="{{ csrfToken }}">
- <button type="submit" class="btn btn-primary">Submit</button>
-</form>
+
+
</div>
</main> \ No newline at end of file
diff --git a/views/layouts/layout.hbs b/views/layouts/layout.hbs
index 667860c..62e9134 100644
--- a/views/layouts/layout.hbs
+++ b/views/layouts/layout.hbs
@@ -1,4 +1,4 @@
-!doctype html>
+<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">