From 92dc520924179857bd98e0c0f1f1b400129ad55b Mon Sep 17 00:00:00 2001 From: Kenneth Jao Date: Fri, 12 Aug 2016 17:35:29 -0400 Subject: [PATCH 1/2] Form clears only when check is clicked, fixed display issues --- hourglass/client/profile/profile.css | 14 ++++-- hourglass/client/profile/profile.html | 64 ++++++++++++++------------- hourglass/client/profile/profile.js | 4 ++ 3 files changed, 48 insertions(+), 34 deletions(-) diff --git a/hourglass/client/profile/profile.css b/hourglass/client/profile/profile.css index 95860fc..af3382b 100644 --- a/hourglass/client/profile/profile.css +++ b/hourglass/client/profile/profile.css @@ -20,6 +20,7 @@ font-weight: 400; margin: 0; margin-bottom: 1%; + margin-right: 10%; } .profHea { @@ -301,15 +302,22 @@ padding-top: 1%; } +#formContainer { + margin-left: 5% !important; + margin-right: 5% !important; + margin-bottom: 0 !important; + position: relative; + +} + #create div { - margin: 2%; - margin-left: 11%; - margin-bottom: 5%; + margin: 3% 6% 5% 6%; display: inline-block; } .creInput { font-size: 120%; + width: 100%; padding: 3%; } diff --git a/hourglass/client/profile/profile.html b/hourglass/client/profile/profile.html index 8128d04..1f4682e 100644 --- a/hourglass/client/profile/profile.html +++ b/hourglass/client/profile/profile.html @@ -91,40 +91,42 @@ {{#if profClassTab "creClass"}}

Insert description and rules of create a class --Will style later--

-
-

School:

- {{> inputAutocomplete settings=schoolcomplete class="form-control creInput" type="text" name="school" placeholder="Example: International Academy" }} -
-
-

Hour:

- -
-
-

Teacher:

- {{> inputAutocomplete settings=teachercomplete class="form-control creInput" type="text" name="teacher" placeholder="Example: Woods" }} -
-
-

Class Name:

- -
-
-

Privacy:

- -
-

Public

-

Private

+
+
+

School:

+ {{> inputAutocomplete settings=schoolcomplete class="form-control creInput" type="text" name="school" placeholder="Example: International Academy" }}
-
-
-

Category:

- -
-

Class

-

Club

-

Other

+
+

Hour:

+ +
+
+

Teacher:

+ {{> inputAutocomplete settings=teachercomplete class="form-control creInput" type="text" name="teacher" placeholder="Example: Woods" }} +
+
+

Class Name:

+ +
+
+

Privacy:

+ +
+

Public

+

Private

+
+
+

Category:

+ +
+

Class

+

Club

+

Other

+
+
-

Submit Request

+

Submit Request

{{/if}}
diff --git a/hourglass/client/profile/profile.js b/hourglass/client/profile/profile.js index bd18a29..8a4a0f1 100644 --- a/hourglass/client/profile/profile.js +++ b/hourglass/client/profile/profile.js @@ -384,6 +384,10 @@ Template.profile.events({ 'click .fa-check-circle-o' () { sendData(Session.get("confirm")); closeDivFade(document.getElementsByClassName("overlay")[0]); + if(Session.get("confirm") === "createClass") { + var form = document.getElementById("create"); + for(var i = 0; i < form.length; i++) form[i].value = ""; + } Session.set("serverData", null); Session.set("confirm", null); }, From 4a8d06311a2342c36c80c17b3762a6b19d9dc869 Mon Sep 17 00:00:00 2001 From: Kenneth Jao Date: Fri, 12 Aug 2016 17:38:22 -0400 Subject: [PATCH 2/2] moved autocomplete templates --- hourglass/client/main/main.html | 8 -------- hourglass/client/profile/profile.html | 8 ++++++++ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/hourglass/client/main/main.html b/hourglass/client/main/main.html index 5139925..c014bb9 100644 --- a/hourglass/client/main/main.html +++ b/hourglass/client/main/main.html @@ -53,12 +53,4 @@
- - - - - \ No newline at end of file diff --git a/hourglass/client/profile/profile.html b/hourglass/client/profile/profile.html index 1f4682e..4efef97 100644 --- a/hourglass/client/profile/profile.html +++ b/hourglass/client/profile/profile.html @@ -151,4 +151,12 @@ {{hour}} {{subscribers}} + + + + + \ No newline at end of file