fixed login/out bug

This commit is contained in:
10001shh
2018-08-24 12:16:39 -05:00
parent ae88f8013c
commit 9b7763af4b
3 changed files with 28 additions and 11 deletions

View File

@@ -22,6 +22,7 @@
}
/* The Close Button */
.close {
color: #aaaaaa;
float: right;
@@ -37,6 +38,7 @@
padding-left: 5px;
margin: 5px 0px 5px 0px;
}
.description {
padding: 5px;
font-size: 15px;
@@ -58,7 +60,7 @@
#chart {
min-width: auto;
max-width: 800px;
max-width: 100%;
height: 250px;
margin: 0 auto;
z-index: 1;
@@ -67,13 +69,11 @@
.card {
transition: 0.3s;
margin-bottom: 10px;
box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.16),
0 2px 10px 0 rgba(0, 0, 0, 0.12);
box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.16), 0 2px 10px 0 rgba(0, 0, 0, 0.12);
}
.card:hover {
box-shadow: 0 4px 10px 0 rgba(0, 0, 0, 0.2),
0 4px 20px 0 rgba(0, 0, 0, 0.19);
box-shadow: 0 4px 10px 0 rgba(0, 0, 0, 0.2), 0 4px 20px 0 rgba(0, 0, 0, 0.19);
}
.cardcontainer {
@@ -164,7 +164,6 @@
#snackbar.show {
visibility: visible;
-webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s;
animation: fadein 0.5s, fadeout 0.5s 2.5s;
}

View File

@@ -12,6 +12,8 @@ var datetimearr = [];
var chart;
var description;
var status;
var semesterCode;
var isIndividual = false;
const days = new Map([
["M", "Monday"],
@@ -174,6 +176,7 @@ function Course(coursename, unique, profname, datetimearr, status, link) {
/*For a row, get all the course information and add the date-time-lines*/
function getCourseInfo(row) {
semesterCode = new URL(window.location.href).pathname.split('/')[4];
$(".dateTimePlace").remove();
$('table').find('tr').each(function () {
if ($(this).find('td').hasClass("course_header")) {
@@ -199,11 +202,13 @@ function getCourseInfo(row) {
return false;
}
});
/*Handle if on the individual course page*/
if (typeof coursename == 'undefined') {
/*Handle if on the individual course page, ie if the textbook button exists*/
console.log($("#textbook_button").length);
if ($("#textbook_button").length) {
coursename = $("#details h2").text();
profinit = $("table").find("td[data-th='Instructor']").text().split(", ")[1].substring(0, 1);
profurl = document.URL;
console.log(profurl);
}
getDescription();
department = coursename.substring(0, coursename.search(/\d/) - 2);
@@ -471,6 +476,8 @@ function prettifyName() {
/*Get the course description from the profurl and highlight the important elements, as well as set the eCIS, and rmp links.*/
function getDescription() {
console.log(window.location.href);
console.log(profurl);
chrome.runtime.sendMessage({
method: "GET",
action: "xhttp",
@@ -524,9 +531,7 @@ function getDescription() {
eCISLink = "http://utdirect.utexas.edu/ctl/ecis/results/index.WBX?";
}
});
}
/* Load the database*/
function loadDataBase() {
sql = window.SQL;

13
todo Normal file
View File

@@ -0,0 +1,13 @@
TODO as of 8/24/18
FEATURES:
- Textbook button (amber)
- Calendar popup
- something to fill the space to the rght of the main popup window
BUGS TO FIX:
- RMP not working on individual course pages
DONE/FIXED:
- unneeded Logout message on individual course pages