- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
local_db_session.query(Account).filter(
Account.id == acc.id).update({
'account_name': post_args['account_name']
if 'account_name' in post_args and
post_args['account_name'] else acc.account_name,
'account_class': post_args['account_class']
if 'account_class' in post_args and
post_args['account_class'] else acc.account_class,
'remaining_search_count':
post_args['remaining_search_count']
if 'remaining_search_count' in post_args and
post_args['remaining_search_count'] else
acc.remaining_search_count,
'remaining_save_count': post_args['remaining_save_count']
if 'remaining_save_count' in post_args and
post_args['remaining_save_count'] else
acc.remaining_save_count,
'remaining_view_count': post_args['remaining_view_count']
if 'remaining_view_count' in post_args and
post_args['remaining_view_count'] else
acc.remaining_view_count,
'remaining_roll_times': post_args['remaining_roll_times']
if 'remaining_roll_times' in post_args and
post_args['remaining_roll_times'] else
acc.remaining_roll_times,
})
local_db_session.commit()