Don't display admin in any premission select. Fix not necessary header for UT data
This commit is contained in:
parent
87ebcc48e7
commit
4f1e47bb82
|
@ -6,7 +6,7 @@ class Admin::NewInterfaceModuleAppsController < ApplicationController
|
|||
layout "new_admin"
|
||||
|
||||
def setting
|
||||
@sys_users = User.all
|
||||
@sys_users = User.all(conditions: {admin: false})
|
||||
@module_app = ModuleApp.find(params[:module_app_id])
|
||||
@options_from_collection_for_select_bulletin_categorys = [@module_app].collect{|ma| [ma.title,ma.id] }
|
||||
# if params.has_key? :category
|
||||
|
|
|
@ -12,6 +12,7 @@ class Panel::Announcement::BackEnd::ApprovalsController < OrbitBackendControlle
|
|||
# end
|
||||
|
||||
def setting
|
||||
@sys_users = User.all(conditions: {admin: false})
|
||||
@bulletin_categorys = BulletinCategory.all
|
||||
@options_from_collection_for_select_bulletin_categorys = @bulletin_categorys.collect{|bc| [bc.i18n_variable[I18n.locale],bc.id] }
|
||||
if params.has_key? :category
|
||||
|
|
|
@ -12,6 +12,7 @@ class Panel::Announcement::BackEnd::BulletinCategorySettingController < OrbitBac
|
|||
# end
|
||||
|
||||
def setting
|
||||
@sys_users = User.all(conditions: {admin: false})
|
||||
@bulletin_categorys = []
|
||||
@bulletin_categorys << BulletinCategory.find(params[:bulletin_category_id])
|
||||
@options_from_collection_for_select_bulletin_categorys = @bulletin_categorys.collect{|bc| [bc.i18n_variable[I18n.locale],bc.id] }
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<%= content_tag :div ,:id => "users_checkbox_ary",:class => 'clear' do -%>
|
||||
<% sys_users = User.all -%>
|
||||
<% sys_users.each do |sys_user| -%>
|
||||
<% @sys_users.each do |sys_user| -%>
|
||||
|
||||
<div class="checkblock">
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<%= content_tag :div ,:id => "users_checkbox_ary",:class => 'clear' do -%>
|
||||
<% sys_users = User.all -%>
|
||||
<% sys_users.each do |sys_user| -%>
|
||||
<% @sys_users.each do |sys_user| -%>
|
||||
|
||||
<div class="checkblock">
|
||||
|
||||
|
|
|
@ -4,9 +4,9 @@ namespace :nccu_data do
|
|||
desc "load nccu data from csv"
|
||||
task :setup_ut_list => :environment do
|
||||
require 'csv'
|
||||
|
||||
CSV.foreach("vendor/built_in_modules/announcement/lib/ut_list_from_nccu_2012feb.csv") do |row|
|
||||
new_unit = UnitListForAnc.new(:order => row[0], :ut_code => row[1], :up_ut_code => row[2], :created_at => Time.now,:updated_at => Time.now)
|
||||
# order,ut_code,up_tu_code,ut_zh_tw,ut_en
|
||||
new_unit.build_title :en => row[4], :zh_tw => row[3]
|
||||
new_unit.save
|
||||
end
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
order,ut_code,up_tu_code,ut_zh_tw,ut_en
|
||||
0100,H00,H00,校長室,Office of the President
|
||||
0110,H01,H01,副校長室一,Office of the Vice President
|
||||
0110,H03,H03,副校長室二,Office of the Vice President
|
||||
|
|
|
|
@ -12,6 +12,7 @@ class Panel::News::BackEnd::NewsApprovalsController < OrbitBackendController
|
|||
end
|
||||
|
||||
def setting
|
||||
@sys_users = User.all(conditions: {admin: false})
|
||||
@news_bulletin_categorys = NewsBulletinCategory.all
|
||||
if params.has_key?(:category_id)
|
||||
first_category = NewsBulletinCategory.find params[:category_id]
|
||||
|
|
|
@ -12,6 +12,7 @@ class Panel::News::BackEnd::NewsBulletinCategorySettingController < OrbitBackend
|
|||
# end
|
||||
|
||||
def setting
|
||||
@sys_users = User.all(conditions: {admin: false})
|
||||
@bulletin_categorys = []
|
||||
@bulletin_categorys << NewsBulletinCategory.find(params[:news_bulletin_category_id])
|
||||
@options_from_collection_for_select_bulletin_categorys = @bulletin_categorys.collect{|bc| [bc.i18n_variable[I18n.locale],bc.id] }
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<%= content_tag :div ,:id => "users_checkbox_ary",:class => 'clear' do -%>
|
||||
<% sys_users = User.all -%>
|
||||
<% sys_users.each do |user| -%>
|
||||
<% @sys_users.each do |user| -%>
|
||||
|
||||
<div class="checkblock">
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<%= content_tag :div ,:id => "users_checkbox_ary",:class => 'clear' do -%>
|
||||
<% sys_users = User.all -%>
|
||||
<% sys_users.each do |sys_user| -%>
|
||||
<% @sys_users.each do |sys_user| -%>
|
||||
|
||||
<div class="checkblock">
|
||||
|
||||
|
|
Loading…
Reference in New Issue