jmccarth / mad-booking

MAD booking system v2
4 stars 1 forks source link

Equipment status in tree and booking don't always match #81

Closed jmccarth closed 10 years ago

jmccarth commented 10 years ago

We have a case where a piece of equipment shows as signed out in a booking, but the item is signed in according to it's equipment status. I'm betting it was mistakenly flagged as signed in when another piece of equipment attached to the same booking was signed in. And since the booking bases its status on the sign_in_times hash rather than the status in the equipment table, they get out of sync.

Example: Booking has two items, A and B. Both get signed out. A gets returned and signed in but B isn't returned yet. In the equipment table both A and B get set as "In", but B does not have an entry in the sign_in_times hash and so shows (correctly) as "Out" in the booking.

jmccarth commented 10 years ago

Turns out the fix was simple. The label for items that are out was set to "In". Whoops.