Skip to content

Instantly share code, notes, and snippets.

@ashwinky
Last active February 28, 2023 14:12
Show Gist options
  • Save ashwinky/7ebf228703caf71c995bbbddce27e9b5 to your computer and use it in GitHub Desktop.
Save ashwinky/7ebf228703caf71c995bbbddce27e9b5 to your computer and use it in GitHub Desktop.
Too lazy to fill the faculty feedback form? Just add this script as a bookmark

Amizone Faculty Feedback Script

Too lazy to fill the faculty feedback form? Just add this script as a bookmark.

To fill the form automatically, just go to the feedback form page of the teacher and click on the bookmark you just created.


How does this work?

javascript: (() => {
const score = Number(prompt('How would you rate this teacher? (1-5)', '3'));
console.debug({ score });
const items = document.querySelectorAll(`input[value="${score}"]`);
for (let i = 0; i < items.length; i++) {
items[i].click();
}
const yn = score >= 3 ? 0 : 1;
document.querySelectorAll('input[id="rdbQuestion1"]')[yn].click();
document.querySelectorAll('input[id="rdbQuestion2"]')[yn].click();
document.querySelectorAll('input[id="rdbQuestion3"]')[yn].click();
document.querySelector("#FeedbackRating_Comments").value = score >= 3 ? 'ok' : 'meh';
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment