"BUGFIX: No double staff update"
This commit is contained in:
parent
83063d67b3
commit
4ff620e51a
@ -509,18 +509,18 @@ def save_staff_slot(turn_id, slot_id, user_id):
|
|||||||
slot = Tetawebapp_staffs(user_id=user_id,
|
slot = Tetawebapp_staffs(user_id=user_id,
|
||||||
turn_id=turn_id,
|
turn_id=turn_id,
|
||||||
slot_num=slot_id)
|
slot_num=slot_id)
|
||||||
try:
|
try:
|
||||||
db.session.add(slot)
|
db.session.add(slot)
|
||||||
commit = db.session.commit()
|
commit = db.session.commit()
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
db.session.rollback()
|
db.session.rollback()
|
||||||
print "[+] Error at save_staff_slot:"
|
print "[+] Error at save_staff_slot:"
|
||||||
print "------------------------------"
|
print "------------------------------"
|
||||||
print "%s" % e.message
|
print "%s" % e.message
|
||||||
print "------------------------------"
|
print "------------------------------"
|
||||||
return False
|
return False
|
||||||
if commit != None:
|
if commit != None:
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
def get_roles():
|
def get_roles():
|
||||||
|
Loading…
Reference in New Issue
Block a user