名师默认创建

This commit is contained in:
huang 2016-05-13 11:11:09 +08:00
parent 61803aa696
commit f7a888ac3d
2 changed files with 7 additions and 1 deletions

View File

@ -15,6 +15,12 @@ class OrgSubfieldsController < ApplicationController
end
end
@subfield.update_attributes(:field_type => params[:field_type])
# 如果栏目是教师,不参入类型的配置,定义为右三模式
# 新增模块命名规则左边1开头右边2开头以前的不变
# eg23 右三
if params[:field_type] == "Comptec"
@subfield.update_attributes(:status => 23)
end
else
@res = false
end

View File

@ -57,7 +57,7 @@
</li>
<li class="orgListStatus">新增</li>
<li class="orgListStatusList">
<% if field.field_type == "Resource" %>
<% if field.field_type == "Resource" || field.field_type == "Comptec" %>
默认
<% else %>
<%= form_tag({:controller => 'org_subfields', :action => 'update_status', :id => field.id,},:remote=>'true', :method => 'post', :id=>"update_status_form_#{field.id}", :class => 'query_form') do %>