RsForm Logic amendment

Job ID: 34703569

Budget: $8 – $15 USD

job 1. when duplicate keys happened change Trashed value -=1
- if "state" drop down field is trashed (state = -2) check if there is any duplicate key (date, room_id, time, state)
if yes, state = -2-1
e.g. date, room_id, time, state
record 1234 : 2022-09-20, 1, 09:30:00, - 2
record 2234 : 2022-09-20, 1, 09:30:00, - 2 <--- duplicate key with record 1234) so state = -2 -1
record 2234 : 2022-09-20, 1, 09:30:00, - 3 save succeed
record 3334 : 2022-09-20, 1, 09:30:00, - 2 <-- duplicate key so state = -2-1
record 3334 : 2022-09-20, 1, 09:30:00, - 3 <-- duplicate key with record 2234 so state = -3-1
record 3334 : 2022-09-20, 1, 09:30:00, - 4 <-- save succeed

Job 2.
if rsform field : duration2book is empty
and or rsform fields : time == time_end
turn submit button to blur (css)
pop up warning "duration must not be empty" or
"start time must not equal to time_end"

job 3. rsform drop down field "timeslot_id"
show label and available time

job 4 : mysql logic
show available time exclude time booked or blocked
Related categories: PHP Joomla CSS MySQL HTML