Commit Graph

12 Commits

Author SHA1 Message Date
00c382e1cc
Avoiding issues and refactoring code
I made the code more passive, avoiding issued at taking, returning,
storing alerts or removing alerts from an item.

Now they all check if it is with you before returning/deleting
alert etc. I am not sure if all cases are covered, but they are
better than before. I had one only issued on this on that time,
but I prefer to prioritize safety/security.

I took the opportunitie to move some code from Controllers to
the model itself, as they were changing with the DB.
2018-10-21 13:09:06 -03:00
2bc2792a24
Bug Fixed: avoiding item waiting_user across take/return
It happend once: a user asked to be added to the waiting
list at the same time other user was returning the item.

So the user ended up waiting for the user he was already
using.
2018-10-21 11:57:23 -03:00
52223676dc
Trying to fix an 500 error on production 2018-10-16 20:18:10 -03:00
8c4fe0a489
Refactoring
Including some use for classes;
REfactoring the HomeController, to make it cleaner
and avoid repeating code.
2018-10-10 00:46:28 -03:00
528d3b4caf
Refactoring: TakeController returned item Mail moved to a listener
The TakeController was manually sending the email message
as well as dealing with item return, so I moved the email message
to it's own listener, I created an event for it and moved the
return part to the item model.
2018-09-30 21:37:44 -03:00
f6ab437889
Added PTB Translation of emails and some pages
Now the main page, item page and e-mails are translated
into Brazilian Portuguese
2018-09-27 20:13:14 -03:00
092281a228
Including authenticaed user on models: Items, Product and User 2018-09-19 15:00:49 -03:00
3b03b400c8
Fixed: 2 people were able to Take the same item at the same time
Now there is a verification before take an item.
2018-09-17 11:45:05 -03:00
c2907c3a0f
Including Alert me! 2018-09-15 02:09:07 -03:00
6fd0164197
Joining Take and Return controllers on just Take (store and delete) 2018-09-15 00:22:57 -03:00
882609fed0
Including occupied username and renaming DB field
Now it shows the username of who is using an item.
Item db field 'usedBy' was renamed to 'used_by' to keep consistence.
2018-09-14 12:52:07 -03:00
842976c77f
Adding Take and Return controllers 2018-09-12 21:27:35 -03:00