diff options
author | jessib <jessib@riseup.net> | 2013-11-18 15:44:54 -0800 |
---|---|---|
committer | jessib <jessib@riseup.net> | 2013-11-18 15:44:54 -0800 |
commit | 8e9b65b01bbd9d44d4077d94f2dc4ac375cf8e85 (patch) | |
tree | c6e59e7a1e837b8cf759948acd8874594e54e19d /users/app/views | |
parent | d2eaffde87286c0cc9c0658503a60706759f7f51 (diff) |
Start of service level code, which will be tweaked
* stores desired & effective service level
* whenever desired level is changed, effective level will be updated
* allows user to set their desired service level
* allow admin to update desired & effective service level
Diffstat (limited to 'users/app/views')
-rw-r--r-- | users/app/views/users/_edit.html.haml | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/users/app/views/users/_edit.html.haml b/users/app/views/users/_edit.html.haml index b86172e..d5a0ff1 100644 --- a/users/app/views/users/_edit.html.haml +++ b/users/app/views/users/_edit.html.haml @@ -37,6 +37,24 @@ .controls = f.submit t(:save), :class => 'btn', :data => {"loading-text" => "Saving..."} + +-# TODO: probably won't want here, but here for now. Also, we will need way to ensure payment if they pick a non-free plan. +-# +-# SERVICE LEVEL +-# +- form_options = {:html => {:class => user_form_class('form-horizontal'), :id => 'update_service_level', :data => {token: session[:token]}}, :validate => true} += simple_form_for @user, form_options do |f| + %legend= t(:service_level) + - if @user != current_user + = t(:desired_service_level) + = f.select :desired_service_level, [[APP_CONFIG[:service_levels][1][:description], 1],[APP_CONFIG[:service_levels][2][:description], 2]], :selected => @user.desired_service_level || APP_CONFIG[:default_service_level] + - if @user != current_user + %p + = t(:effective_service_level) + = f.select :effective_service_level, [[APP_CONFIG[:service_levels][1][:description], 1],[APP_CONFIG[:service_levels][2][:description], 2]], :selected => @user.effective_service_level || APP_CONFIG[:default_service_level] + .control-group + .controls + = f.submit t(:save), :class => 'btn', :data => {"loading-text" => "Saving..."} -# -# DESTROY ACCOUNT -# |