From 5c6b6f4c957d8c7464204d1176f4a3ab6faca9a2 Mon Sep 17 00:00:00 2001 From: jingquan huang Date: Fri, 26 Apr 2019 17:48:56 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E8=BF=90=E8=90=A5=E5=AE=9A?= =?UTF-8?q?=E5=88=B6=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/managements_controller.rb | 1 + app/views/managements/update_user.html.erb | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/app/controllers/managements_controller.rb b/app/controllers/managements_controller.rb index 07381e57..74560941 100644 --- a/app/controllers/managements_controller.rb +++ b/app/controllers/managements_controller.rb @@ -196,6 +196,7 @@ class ManagementsController < ApplicationController if request.post? @user.nickname = params[:nickname] @user.lastname = params[:lastname] + @user.business = params[:business].to_i @user.firstname = "" @user.mail = params[:mail].strip == "" ? nil : params[:mail] @user.phone = params[:phone].strip == "" ? nil : params[:phone] diff --git a/app/views/managements/update_user.html.erb b/app/views/managements/update_user.html.erb index 05b6e7f1..232275ce 100644 --- a/app/views/managements/update_user.html.erb +++ b/app/views/managements/update_user.html.erb @@ -184,6 +184,13 @@ <% end %>
+
  • + + + name="business" value="<%= @user.business? ? 1 : 0 %>" id="person_9" class="magic-checkbox" style="float:left; margin-top: 8px;"> + + +