Many supplier features and style upgrades and fixes
This commit is contained in:
@@ -91,15 +91,6 @@ private
|
||||
end
|
||||
end
|
||||
|
||||
def check_active_list_state
|
||||
if current_user.try(:active_list_id)
|
||||
unless active_list.active?
|
||||
current_user.list_is_closed!
|
||||
redirect_to user_root_path, alert: t('messages.the_list_has_been_closed', list: List.model_name.human)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def active_list
|
||||
return nil unless current_user.try(:active_list_id).present?
|
||||
@active_list ||= List.find(current_user.active_list_id)
|
||||
@@ -113,6 +104,7 @@ private
|
||||
{ok: false, message: message}.merge(options).to_json
|
||||
end
|
||||
alias json_alert js_alert
|
||||
|
||||
def js_notice(*args)
|
||||
options = args.extract_options!
|
||||
message = args.first || ''
|
||||
|
||||
Reference in New Issue
Block a user