brianmaissy / wsma Goto Github PK
View Code? Open in Web Editor NEWWorkshift Manager's Assistant
Home Page: http://cs169-wsma.wikispaces.com/
Workshift Manager's Assistant
Home Page: http://cs169-wsma.wikispaces.com/
======================================== Workshift Manager's Assistant (WSMA) ======================================== CS169 Fall 2011 Professor George Necula GSI Sharada Prasad UC Berkeley Brian Maissy ([email protected]) Ben Lui Travis Cheng Tai Schuller Cat Callaghan ======================================== Running the application on the EC2 ======================================== Please use Chrome. We have not yet tackled cross-browser compatibility, so we cannot guarantee correct functionality if you use any other browser. Navigate to: http://107.20.135.212:8092 To login with admin privileges: [email protected]//password To login with workshift manager privileges: [email protected]//password To login with user privileges: [email protected]//password ======================================== Issue Tracker ======================================== Issues can be opened here: https://github.com/brianmaissy/WSMA/issues Anyone can create issues, but you need a github account. ======================================== Running the application locally ======================================== Clone the git repository from: https://github.com/brianmaissy/WSMA To run the server: bundle install rake bootstrap rake assets:precompile (optional) rails server -e production (The rake bootstrap task sets up the database and loads it with some sample data) (Currently the setting is to fall back to the asset pipeline if the precompiled assets are unavailable. We should change this in the production.rb config file when deploying. This will require configuration of nginx to serve our files in public/assets.) Navigate to: localhost:3000/ To login with admin privileges: admin//password To login with workshift manager privileges: wsm//password To login with user privileges: user//password Requirements and design documents are available in the doc/ directory of the repository. To run the tests: rake test
Testing setup seems to be erroneous - running rake test yielded errors that related to setup of variables used in the controller.
fail nicely to an error page on errors, including routing errors to a 404 or similar
AJAX calls get made twice. Could be because jquery is included twice.
I was logged in as an administrator and tried creating a new chore, but wasn't successful. I didn’t see it in the “Manage Shifts” section, or in the “Allocate Shifts” -- both logical places for the new chore to appear at. I would categorize this error as a blocker since creating a new chore is of immense importance.
I did some really stupid manual validation by overriding setters and throwing exceptions.
I don't know what I was thinking. I probably did it because they are validations that depend on the old value of the attribute, but that can be done simply with attribute_changed? and attribute_was.
They need to be replaced with normal activerecord validations.
display multiline textarea contents with multiple lines when using best-in-place
now, any wsm can access the wsm areas for any house; we don't want that to be so. give the user acounts a foreign key for the house they are the wsm of, if any, and change permissions to reflect this.
The problem reported in issue 18 (manage shift page not loading) persists even if you log out and log in as an admin (even though i tried creating a new chore as msw when the bug first appeared).
So I'm thinking that both the Shift and Assignment models would have methods "start_date" and "end_date", and each would return a DateTime object.
For Shift, "start_date" would return the date and time the shift starts in the current week. This will only be called if the shift is unassigned.
"end_date" would also return a DateTime for the current week, but would have the time the shift will end (can be calculated based on number of hours a chore has).
The way I've dealt with DateTimes in the view is like this:
<% start_time = TimeProvider.now %>
<% start_time = start_time.change(:hour => shift.time.hour) %>
<% start_time = start_time.change(:minute => shift.time.min) %>
<% start_time = start_time.change(:day => base-1+shift.day_of_week) %> // base is the mday for the sunday at the beginning of the week.
<% end_time = start_time.change(:hour => shift.time.hour + chore.hours) %>
<% end_time = end_time.change(:minute => shift.time.min) %>
I've found the "change" method to be useful in manipulating DateTimes. It may or may not be useful, but I'd just like to point it out.
Assignment "start_date" and "end_date", would be similar to shift.start_date/end_date, but except of dealing with the current week, the Assignments week variable will be used
to get the exact date the assignment occurs on.
there is significant code duplication, plus this will make it simpler to call from javascript
it will be educational, fun, and improve the app.
reference this issue in their commits to keep track, just for fun!
deploy the app to engine yard for further user testing. this will require creating a new environment config file which uses mysql; they don't support sqlite.
If I have a chore x with associated shift y on Sunday, on the shift allocation page, I can drag a name into chore x for any day of the week, but a shift only exists for Sunday. What does it mean to drag it onto the Monday square?
(Logged in as a wsm) When you create a shift/chore you enter a day and time, but in “Allocate Shift” you can drag and drop that shift/chore to any slot... Why the inconsistency? might as will not as for a time when creating a chore if you are going to drag and drop it into any time slot. I will categorize this as trivial as it is more or less a cosmetic problem.
once the best_in_place gem updates itself, we can do this. or manually make our own gem.
If a shift is set to a specific day, why can you assign it to a person an any day of the week? what happens if you assign a person to do something Monday for a shift that is only on Sunday?
it's a security risk. only allow through the designated controller method change_password
When more than 4 users are assigned to one shift, the users fall outside the box.
“Shift Allocation” how can I allocate multiple shifts to one person? Currently, I can drag a user's name on a the schedule to assign them for a shift, but what if i want them to do multiple shifts in a week? There doesn't seem to be a way for that now. I will list this problem as critical as well since allocating multiple shifts for a chore per week seems like a pretty important functionality.
It would be nice if the names were still draggable once they have been dragged into a box, so I could, for example, drag a name out of one chore and into another, instead of clicking the x and re-dragging it to the new chore.
On the manage shifts page, weeks start on a Sunday, but on the "Shift Allocation" and "My Shifts" pages, the week starts on a Monday. We might want to have these calendars start on the same day to maintain consistency.
In the Shift Allocation Table, if you have two (or more) shifts and you highlight one of the boxes on the bottom row (ie. not the first shift), and then click on a user, it will go to the top row box (ie. the first shift).
Unclear where new chore appears - must scroll down to see chore.
This error is thrown when editing a date using a date selector on the houses page
There are some operations that are never performed during normal operation but must be performed occasionally to set up the application. This includes managing houses and such, and usually needs to be done before each semester. To this end, there is an admin panel with the following tools. Access to the admin panel is restricted to accounts with access level 3. If no admin accounts exist, anyone can access the admin panel, to allow bootstrapping.
this field needs to be validated as well; should be a simple fix
sending emails takes a while and the page takes several seconds to load while it is happening. processing should be moved to a separate job using rufus-scheduler.
but we need to make sure the email is valid before, so we can give instant feedback if the email is invalid. i'm sure validating an email with a regex is easy.
I am logged in as admin. The link to the “Create an Assignment” brings me to this URL: http://107.20.135.212:8092/quickassign, but there is nothing on this page.
(Just a note: I tried clicking on this url before and it only once showed me the correct assignment page, all other times it gave me this blank page. So sometimes it seems to work, but most of the time I get a blank page.)
There are a lot of time allocations required but it is unclear what each refers to - what is a sign-out dealine?
error "insertBtn is null"
in chore_add_fields.js line 86: insertBtn.onclick = function()
replicate by loading the root page, watch using firebug
There seems to be no way to delete shifts, or reschedule shifts in “Manage Shifts”? Whats the point of it then? From a user's perspective i would want to be able to do both these tasks from the manage shifts section. I would rate this bug as critical as i think this functionality is very important.
The time is displayed differently when you are editing a shift and when you create a shift. When you create a shift you show an AM/PM clock, while in editing the shift you show a 24hour clock. Why the inconsistency.
I am not certain if the shift will turn red only if it is assigned and not completed by the deadline.
In either event, assuming shift allocation works, once I allocated the shift, the calendar event is still grey, and if I advance time past the due date, the shift does not turn red.
This issue is mild as it is a question of UI changes rather than framework.
As a suggestion, I think a submit button to allocate shifts would be useful, since it would notify the user as to when the shift allocation was successful.
On the home page, select the “My Shifts” tab. If you then click on any button (say the sign off button) it will give you a routing error.
tabs don’t work reliably
when I'm signed in as admin - clicking the manage shifts tab links to an empty page
when signed in as wsm - Allocate shifts tab not always rendering the calendar used to allocate shifts.
Whether I am logged in as admin or as wsm, if I create a chore and go back to the shift allocation page it does not render the calendar.
User is viewing page A without being logged in. User tries to go to page B which requires authentication. User gets redirected to login page, logs in, and gets redirected to B. User clicks back button and returns to login page, but should return to A.
On the home page, select the “My Shifts” tab. If you then click on the profile tab, it will no longer bring you to the profile page (it returns you to the same my shift page.)
When logged in as admin, selecting the “Allocate Shifts” tab and dragging names to columns does not create a new assignment
After attempting to create a new chore, I was directed to the following URL http://107.20.135.212:8092/chores, which didn't quite load. When i tried to navigate to manage shifts to see if the new chore had possibly appeared there, that page wouldn't load either, though it was trying to go to the following url http://107.20.135.212:8092/manageshifts. I will categorize this error as critical.
chore creation sends you away to the scaffolding if you input values which fail validation. it should display the errors on the same page
need to surround with rescue and give a message about invalid email, like we did with password reset
the flash flashes for a second, even if it is empty. stop it.
In the Shift Allocation Table, the date for the shift is always “Sat Jan 01 06:00:00 UTC 2000”
Without logging in, if you click on the “Create an Assignment” tab you get an Active Record :: RecordNotFound -- cannot find User without an ID.
Create chore button gives an error:
undefined local variable or method `choress_path' for #<#Class:0xb5ffd8e4:0xb5f80524>
Trace
app/views/chores/new.html.erb:5:in _app_views_chores_new_html_erb__877850650__621020008' app/controllers/chores_controller.rb:60:in
block (2 levels) in create'
app/controllers/chores_controller.rb:53:in `create'
Request
Parameters:
{"utf8"=>"✓",
"authenticity_token"=>"wLEz+uxlzxcchhR03B2etBrcerR6/A5xhLPU/G7vq34=",
"chore"=>{"name"=>"dsihes",
"description"=>"lnfadfnan",
"hours"=>"11",
"sign_out_by_hours_before"=>"3",
"due_hours_after"=>"4",
"house_id"=>1},
"commit"=>"Create Chore"}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.