diff --git a/app/assets/images/Jobs.jpg b/app/assets/images/Jobs.jpg new file mode 100644 index 00000000..6d6627e4 Binary files /dev/null and b/app/assets/images/Jobs.jpg differ diff --git a/app/assets/images/Thumbs.db b/app/assets/images/Thumbs.db new file mode 100644 index 00000000..a91692c5 Binary files /dev/null and b/app/assets/images/Thumbs.db differ diff --git a/app/assets/images/add_mamber.png b/app/assets/images/add_mamber.png new file mode 100644 index 00000000..1af41590 Binary files /dev/null and b/app/assets/images/add_mamber.png differ diff --git a/app/assets/images/h1_bg.jpg b/app/assets/images/h1_bg.jpg new file mode 100644 index 00000000..edf2a0a3 Binary files /dev/null and b/app/assets/images/h1_bg.jpg differ diff --git a/app/assets/images/h1_bg.png b/app/assets/images/h1_bg.png new file mode 100644 index 00000000..d6e90160 Binary files /dev/null and b/app/assets/images/h1_bg.png differ diff --git a/app/assets/images/icon.png b/app/assets/images/icon.png new file mode 100644 index 00000000..fc8a40ce Binary files /dev/null and b/app/assets/images/icon.png differ diff --git a/app/assets/images/line.png b/app/assets/images/line.png new file mode 100644 index 00000000..6b16a949 Binary files /dev/null and b/app/assets/images/line.png differ diff --git a/app/assets/images/preview.png b/app/assets/images/preview.png new file mode 100644 index 00000000..0bab69db Binary files /dev/null and b/app/assets/images/preview.png differ diff --git a/app/assets/images/roles_type.jpg b/app/assets/images/roles_type.jpg new file mode 100644 index 00000000..97791f3b Binary files /dev/null and b/app/assets/images/roles_type.jpg differ diff --git a/app/assets/images/search_bg.png b/app/assets/images/search_bg.png new file mode 100644 index 00000000..c00c431b Binary files /dev/null and b/app/assets/images/search_bg.png differ diff --git a/app/assets/images/search_block_bg.jpg b/app/assets/images/search_block_bg.jpg new file mode 100644 index 00000000..19e8e30e Binary files /dev/null and b/app/assets/images/search_block_bg.jpg differ diff --git a/app/assets/images/sidebar_li.jpg b/app/assets/images/sidebar_li.jpg new file mode 100644 index 00000000..a3aaeb98 Binary files /dev/null and b/app/assets/images/sidebar_li.jpg differ diff --git a/app/assets/images/wood_floor.jpg b/app/assets/images/wood_floor.jpg new file mode 100644 index 00000000..5d1c2362 Binary files /dev/null and b/app/assets/images/wood_floor.jpg differ diff --git a/app/assets/stylesheets/admin.css.erb b/app/assets/stylesheets/admin.css.erb index 6b89d771..9e318b68 100644 --- a/app/assets/stylesheets/admin.css.erb +++ b/app/assets/stylesheets/admin.css.erb @@ -297,7 +297,7 @@ p{ background: none repeat scroll 0 0 #FFFFFF; border-radius: 5px 5px 5px 5px; box-shadow: 0 0 5px #000000; - height: 289px; +/* height: 289px;*/ margin: 0 0 20px; overflow: hidden; width: 600px; diff --git a/app/assets/stylesheets/member.css.erb b/app/assets/stylesheets/member.css.erb new file mode 100644 index 00000000..669e571f --- /dev/null +++ b/app/assets/stylesheets/member.css.erb @@ -0,0 +1,244 @@ +/* + *This is a manifest file that'll automatically include all the stylesheets available in this directory + *and any sub-directories. You're free to add application-wide styles to this file and they'll appear at + *the top of the compiled file, but it's generally better to create a new file per style scope. + *= require_self + +*/ +a, a:hover { + text-decoration: none; + outline:none; +} +html,body { + height:100%; + margin:0; + font-family: Helvetica, '微軟正黑體'; +} +ul { + list-style:none; + list-style-image:none; + margin:0; + padding:0; +} +.clear:after { + content:"."; + clear:both; + height:0; + display:block; + visibility:hidden; +} +#content{ + height:100%; +} +#sidebar { + position:fixed; + top:0; + left:0; + height: 100%; + width:220px; + /*background-color:rgba(245,245,245,1);*/ + background-color:rgba(0,0,0,0.75); + -moz-box-shadow: 3px 0px 4px #472a12; /* Firefox */ + -webkit-box-shadow: 3px 0px 4px #472a12;/* Safari 和 Chrome */ + box-shadow: 3px 0px 4px #472a12; /* Opera 10.5 + */ +} +#search { + background:url(<%= asset_path 'search_block_bg.jpg' %>) repeat-x left top; + margin-top:43px; + padding:15px 12px; + height:20px; +} +#search input { + background:url(<%= asset_path 'search_bg.png' %>) no-repeat left top; + border:none; + width:174px; + height:20px; + padding-left:20px; +} +h1 { + background:url(<%= asset_path 'h1_bg.png' %>) repeat-x left top; + margin:0; + line-height:21px; + height:21px; + font-size:12px; + padding-left:10px; + font-weight:normal; + text-shadow:0px -1px 0px #000; + color:#FFF; + border-top:1px solid #424344; + border-bottom:1px solid #1b1b1b; +} +#user_list .member_setup ul li.set_1 { + background-position:left bottom; + border-top:1px solid #406cc3; + border-bottom:1px solid #242628; +} +#roles_list .member_setup ul li.set_2 { + background-position:left bottom; + border-top:1px solid #406cc3; + border-bottom:1px solid #242628; +} +#user_list .member_setup ul li.set_1 a span { + background-position:left bottom; + color:#eeeeee; +} +#roles_list .member_setup ul li.set_2 a span { + background-position:left bottom; + color:#eeeeee; +} +.member_setup ul { + color:#fff; + font-size:12px; + background:url(<%= asset_path 'line.png' %>) repeat-x left bottom; +} +.member_setup ul li { + background:url(<%= asset_path 'sidebar_li.jpg' %>) repeat-x left top; +/* line-height:31px;*/ + border-top:1px solid #424344; + border-bottom:1px solid #000000; +} +.member_setup ul li:hover { + background-position:left bottom; + border-top:1px solid #406cc3; + border-bottom:1px solid #242628; +} +.member_setup ul li a { + display: block; + padding: 7px 0 6px 12px; + color:#c4c4c4; +} +.member_setup ul li a span { + background:url(<%= asset_path 'add_mamber.png' %>) left top no-repeat; + text-shadow: 0px 1px 0px #000; + line-height: 18px; + padding: 2px 0 1px 35px; +} +.member_setup ul li a:hover span { + background-position:left bottom; + color:#eeeeee; +} +#main{ + position: relative; + margin-left: 260px; + padding-right: 40px; + height:100%; +} +.main_list { + padding-top:70px; +} +.main_list li { + background-color:rgba(0,0,0,0.75); + margin-bottom:20px; +} +.main_list li span { + display:inline-block; + float:left; + padding-left:20px; + color:#fff; + font-size:14px; + line-height:40px; + width:18%; +} +.main_list li.list_head { + background-color:inherit; + margin-bottom:10px; +} +.main_list li.list_head span { + font-size:16px; + line-height:inherit; + text-shadow: 0px 1px 1px #3e2914; +} +.main_list li.list_item { + position:relative; + border-radius: 5px; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + -moz-box-shadow: 0px 0px 6px #291508; /* Firefox */ + -webkit-box-shadow: 0px 0px 6px #291508;/* Safari 和 Chrome */ + box-shadow: 0px 0px 6px #291508; /* Opera 10.5 + */ +} +.main_list li.list_item:hover { + border:1px solid #3699dd; +} +.main_list li.list_item:hover span { + line-height:38px; +} +.main_list li .roles { +} +.main_list li .name { +} +.main_list li .email { +} +.main_list li .admin{ +} +.main_list li .action{ + float: right; + width:10%; +} +.main_list li .action a{ + background-image:url(<%= asset_path 'icon.png' %>); + text-indent:-9999px; + display:inline-block; + width:19px; + height:19px; + margin-top:8px; + margin-right:10px; +} +.main_list li .action a.show{ + background-position:left top; +} +.main_list li .action a.edit{ + background-position:-19px top; +} +.main_list li .action a.delete{ + background-position:-38px top; +} +.main_list li .action a.show:hover{ + background-position:left bottom; +} +.main_list li .action a.edit:hover{ + background-position:-19px bottom; +} +.main_list li .action a.delete:hover{ + background-position:-38px bottom; +} +.main_list li.list_item .roles { + background-image:url(<%= asset_path 'roles_type.jpg' %>); + background-repeat:repeat-x; + border-radius: 5px 0 0 5px; + -moz-border-radius: 5px 0 0 5px; + -webkit-border-radius: 5px 0 0 5px; +} +.student { + background-position:0 -5px; +} +.teacher { + background-position:0 -54px; +} +#add_new { + margin-bottom: 20px; +} +#add_new a { + background-image:url(<%= asset_path 'icon.png' %>); + background-position:-54px -17px; + background-repeat:no-repeat; + font-size:12px; + color:#FFF; + float:right; + display:inline-block; + padding:0 10px 0 25px; + background-color: rgba(0, 0, 0, 0.75); + line-height:24px; + border-radius: 5px; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + -moz-box-shadow: 3px 0px 4px #180902; /* Firefox */ + -webkit-box-shadow: 3px 0px 4px #180902;/* Safari 和 Chrome */ + box-shadow: 3px 0px 4px #180902; /* Opera 10.5 + */ +} +#add_new a:hover { + background-position: -54px 3px; + color:#000; + font-weight:bold; + background-color: rgba(255, 255, 255, 1); +} \ No newline at end of file diff --git a/app/assets/stylesheets/messy.css.erb b/app/assets/stylesheets/messy.css.erb new file mode 100644 index 00000000..6646b7ca --- /dev/null +++ b/app/assets/stylesheets/messy.css.erb @@ -0,0 +1,305 @@ +body{ + background:url(<%= asset_path 'wood_floor.jpg' %>) fixed center 0; + /*background:url(images/jobs.jpg) fixed center bottom;*/ + -moz-background-size:cover; + background-size:cover; + color: #000000; + margin: 0; + padding: 0; +} +#hmenu{ + background:url(<%= asset_path 'orbitbar.png' %>) repeat-x 0 0; + height: 50px; + position:fixed; + top:0; + left:0; + width:100%; + z-index: 5; +} +#orbit_icon { + margin-left: 10px; +} +#orbit_icon a { + background:url(<%= asset_path 'bar_orbit.png' %>) no-repeat scroll left top transparent; + height: 43px; + width: 41px; + display:block; + text-indent:-9999px; +} +#orbit_icon a:hover { + background:url(<%= asset_path 'bar_orbit.png' %>) no-repeat scroll left 50% transparent; +} +#hmenu #left{ + left: 51px; + position: absolute; + top: 1px; +} +#hmenu #left a{ + border-left: 1px solid #000000; + border-right: 1px solid #7F8488; + color: #FFFFFF; + display: block; + font-size: 17px; + height: 40px; + line-height: 40px; + padding: 0 10px; + text-align: center; + text-decoration: none; +} +#hmenu #left a:hover{ + background:#000; + color: #FFFFFF; +} +#hmenu #right{ + position: absolute; + right: 10px; + top: 1px; + width: 393px; +} +#hmenu #right a{ + border-left: 1px solid #7F8488; + border-right: 1px solid #7F8488; + color: #FFFFFF; + display: block; + font-size: 17px; + height: 40px; + line-height: 40px; + padding: 0 10px; + text-align: center; + text-decoration: none; + width: 65px; +} +#hmenu #right a:hover{ + background:#000; + color: #FFFFFF; +} +#hmenu form{ + left: 27px; + position: absolute; + top: 8px; +} +#login_id{ + background:url(<%= asset_path 'bar_id.png' %>) no-repeat scroll 0 0 transparent; + border: medium none; + color: #818181; + font-family: arial,sans-serif; + height: 26px; + left: 70px; + position: absolute; + top: 0; + width: 119px; +} +#login_id input { + background: none repeat scroll 0 0 transparent; + border: medium none; + font-family: arial,sans-serif; + height: 15px; + left: 21px; + position: absolute; + top: 4px; + width: 92px; +} + +#login_pw { + background:url(<%= asset_path 'bar_pw.png' %>) no-repeat scroll 0 0 transparent; + border: medium none; + color: #818181; + font-family: arial,sans-serif; + height: 26px; + left: 193px; + position: absolute; + top: 0; + width: 119px; +} + +#login_pw input { + background: none repeat scroll 0 0 transparent; + border: medium none; + font-family: arial,sans-serif; + height: 15px; + left: 21px; + position: absolute; + top: 4px; + width: 92px; +} +#login_btn input { + background:url(<%= asset_path 'bar_btn.png' %>) no-repeat scroll 0 0 transparent; + border: medium none; + color: #FFFFFF; + cursor: pointer; + font-family: arial,sans-serif; + height: 26px; + left: 316px; + margin: 0; + padding: 0 0 2px; + position: absolute; + top: 0; + width: 50px; +} + +#log_out a{ + background:url(<%= asset_path 'service_btn.png' %>) no-repeat scroll right 0 transparent; + border: medium none !important; + display: block !important; + height: 40px !important; + line-height: normal !important; + padding: 0 !important; + position: absolute; +/* right: -9px;*/ + text-indent: -10000px; + top: 0px; + width: 43px !important; +} +#log_out a:hover{ + background:url(<%= asset_path 'service_btn.png' %>) no-repeat scroll right bottom transparent !important; +} + +#hmenu #right select{ + font-family: helvetica,arial,sans-serif; + left: 97px; + position: absolute; + top: 10px; + width: 120px; +} +.content{ + padding: 10px; +} + +#user_info{ + background: none repeat scroll 0 0 #FEFEFE; + border: 1px solid #818181; + border-radius: 5px 5px 5px 5px; + margin: 0 0 20px; + padding: 10px; + width: 250px; +} + +#user_info table{ + border-collapse: collapse; + width: 100%; +} +#user_info table td{ + padding: 3px; +} + +#sites_info{ + background: -webkit-gradient(linear, left top, left bottom, from(white), to(#F8F8F8)); + border: 1px solid #818181; + border-radius: 5px 5px 5px 5px; + float: left; + margin: 0 20px 20px 0; + width: 30%; + min-width: 320px; +} +#sites_info h3{ + background: none repeat scroll 0 0 #EEEEEE; + border: 1px solid #DDDDDD; + border-radius: 5px 5px 5px 5px; + font: 24px/100% helvetica,arial,sans-serif; + margin: 2% 2% 0; + padding: 1%; +} +#sites_info table{ + background: none repeat scroll 0 0 #fff; + border: 1px solid #DDDDDD; + border-radius: 5px 5px 5px 5px; + margin: 2%; + width: 96%; +} +#sites_info table td{ + padding: 10px 5px; +} +#sites_info table th{ + border-right: 1px solid #DDDDDD; + color: #808080; + font-size: 18px; + font-weight: normal; + padding: 10px 5px; + text-align: right; + width: 20%; +} + + +#purchases{ + background: -webkit-gradient(linear, left top, left bottom, from(white), to(#F8F8F8)); + border: 1px solid #818181; + border-radius: 5px 5px 5px 5px; + float: left; + width: 30%; + min-width: 320px; +} +#purchases h3{ + background: none repeat scroll 0 0 #EEEEEE; + border: 1px solid #DDDDDD; + border-radius: 5px 5px 5px 5px; + font: 24px/100% helvetica,arial,sans-serif; + margin: 2% 2% 0; + padding: 1%; +} +#purchases table{ + background: none repeat scroll 0 0 #fff; + border: 1px solid #DDDDDD; + border-radius: 5px 5px 5px 5px; + margin: 2%; + width: 96%; +} +#purchases table th{ + border-right: 1px solid #DDDDDD; + color: #808080; + font-size: 18px; + font-weight: normal; + padding: 10px 5px; + text-align: right; + width: 20%; +} +#purchases table td{ + padding: 10px 5px; +} +.design_page{ +} +.style_list{ + background:url(<%= asset_path 'preview.png' %>) no-repeat 0 0; + height:246px; + margin: 20px 0; + padding: 0 0 0 236px; +} +.style_list ul{ + margin:0; + padding:0; +} +.style_list li{ + color: #EDA330; + font-size: 20px; + list-style: none outside none; + margin: 0 0 20px; +} +.list_title{ + color: #818181; + display: block; + font: 24px/100% ·L³n¥¿¶ÂÅé,sans-serif; +} +.buy_btn a{ + background:url(<%= asset_path "buy_btn.png" %>) no-repeat scroll 0 0 transparent; + color: #000000; + display: block; + font-size: 22px; + height: 37px; + line-height: 37px; + text-align: center; + text-decoration: none; + text-shadow: 0 1px 0 #FFFFFF; + width: 170px; +} +.buy_btn a:hover{ + background-position:0 bottom; +} +.bought_btn{ + background:url(<%= asset_path "bought_btn.png" %>) no-repeat scroll 0 0 transparent; + color: #FFFFFF; + font-size: 22px; + height: 37px; + line-height: 37px; + text-align: center; + text-shadow: 0 1px 0 #C06408; + width: 170px; +} \ No newline at end of file diff --git a/app/controllers/admin/user_attributes_controller.rb b/app/controllers/admin/user_attributes_controller.rb index c7021c74..127f4c7f 100644 --- a/app/controllers/admin/user_attributes_controller.rb +++ b/app/controllers/admin/user_attributes_controller.rb @@ -1,6 +1,6 @@ class Admin::UserAttributesController < ApplicationController - layout "admin" + layout "member" before_filter :authenticate_user! def index diff --git a/app/controllers/admin/user_info_models_controller.rb b/app/controllers/admin/user_info_models_controller.rb index 7660d699..29a26dba 100644 --- a/app/controllers/admin/user_info_models_controller.rb +++ b/app/controllers/admin/user_info_models_controller.rb @@ -1,6 +1,6 @@ class Admin::UserInfoModelsController < ApplicationController - layout "admin" + layout "member" before_filter :authenticate_user! before_filter :is_admin? before_filter :set_attribute, :only => [:index, :show, :new, :edit] diff --git a/app/controllers/admin/user_role_models_controller.rb b/app/controllers/admin/user_role_models_controller.rb index b4145a8f..ecb8b5a2 100644 --- a/app/controllers/admin/user_role_models_controller.rb +++ b/app/controllers/admin/user_role_models_controller.rb @@ -1,6 +1,6 @@ class Admin::UserRoleModelsController < ApplicationController - layout "admin" + layout "member" before_filter :authenticate_user! before_filter :is_admin? before_filter :set_attribute, :only => [:index, :show, :new, :edit] diff --git a/app/controllers/panel/users_controller.rb b/app/controllers/admin/users_controller.rb similarity index 85% rename from app/controllers/panel/users_controller.rb rename to app/controllers/admin/users_controller.rb index 7abf6e1f..46d7ed96 100644 --- a/app/controllers/panel/users_controller.rb +++ b/app/controllers/admin/users_controller.rb @@ -1,6 +1,6 @@ -class Panel::UsersController < ApplicationController +class Admin::UsersController < ApplicationController - layout "panel" + layout "member" before_filter :authenticate_user! def index @@ -28,7 +28,7 @@ class Panel::UsersController < ApplicationController user_role.save user_role.attribute_values.each(&:save) end - flash[:notice] = t('panel.create_success_user') + flash[:notice] = t('admin.create_success_user') redirect_to :action => :index else render :action => :new @@ -48,10 +48,10 @@ class Panel::UsersController < ApplicationController @user.avatar = params[:file] if params[:file] if @user.id.to_s.eql?(session['warden.user.user.key'][1].to_s) && @user.admin != params[:user][:admin].to_i.to_b - flash.now[:error] = t('panel.cant_revoke_self_admin') + flash.now[:error] = t('admin.cant_revoke_self_admin') end if !flash[:error] && @user.update_attributes(params[:user]) - flash[:notice] = t('panel.update_success_user') + flash[:notice] = t('admin.update_success_user') redirect_to :action => :index else get_info_role_models @@ -61,7 +61,7 @@ class Panel::UsersController < ApplicationController def destroy if params[:id].eql?(session['warden.user.user.key'][1].to_s) - flash[:error] = t('panel.cant_delete_self') + flash[:error] = t('admin.cant_delete_self') else @user = User.find(params[:id]) @user.destroy diff --git a/app/helpers/panel/user_helper.rb b/app/helpers/admin/user_helper.rb similarity index 93% rename from app/helpers/panel/user_helper.rb rename to app/helpers/admin/user_helper.rb index b536f959..6ebd056f 100644 --- a/app/helpers/panel/user_helper.rb +++ b/app/helpers/admin/user_helper.rb @@ -1,4 +1,4 @@ -module Panel::UserHelper +module Admin::UserHelper def show_user_attribute(object, key, locale = '') attribute = object.attribute_values.detect {|av| av.key.to_s.eql?(key.to_s) || av[locale.to_s].eql?(locale.to_s) } rescue nil diff --git a/app/models/user/user.rb b/app/models/user/user.rb index f7171723..7eec8145 100644 --- a/app/models/user/user.rb +++ b/app/models/user/user.rb @@ -64,6 +64,17 @@ class User (self.active_roles.nil? || self.active_roles.empty?) ? '-' : self.active_roles.map{|role| I18nVariable.first(:conditions => {:key => role})[I18n.locale] rescue role}.join(' / ') end + def name + infos = self.user_infos.detect {|info| info.key.to_s.eql?('profile') } + if infos + first_name = infos.attribute_values.detect {|value| value.key.to_s.eql?('first_name') }[I18n.locale.to_s] rescue nil + last_name = infos.attribute_values.detect {|value| value.key.to_s.eql?('last_name') }[I18n.locale.to_s] rescue nil + return "#{first_name} #{last_name}" + else + return nil + end + end + protected # Remove empty values diff --git a/app/views/admin/sites/index.html.erb b/app/views/admin/sites/index.html.erb index 7f5c6a7c..6739cbe5 100644 --- a/app/views/admin/sites/index.html.erb +++ b/app/views/admin/sites/index.html.erb @@ -7,7 +7,7 @@ Department - Design Deptartment + Computer Science Version @@ -19,14 +19,15 @@ Visitor Counter - 1112201 + 2,201 - Site Status - Available + Registration Status + <%= render 'registration' %> + + + Updates + <%= render 'update' %> - -<%= render 'registration' %> - -<%= render 'update' %> \ No newline at end of file + \ No newline at end of file diff --git a/app/views/admin/user_attribute_models/index.html.erb b/app/views/admin/user_attribute_models/index.html.erb index fed40700..eb3c68c3 100644 --- a/app/views/admin/user_attribute_models/index.html.erb +++ b/app/views/admin/user_attribute_models/index.html.erb @@ -1,12 +1,16 @@ <% content_for :secondary do %> - +
+
+

Member Setup

+ +
+
<% end -%> -

<%= t("admin.list_user_#{@attribute}s") %>

- - + + +
+<%= link_to t('admin.new_user_role'), new_admin_user_role_model_path %> +
+ +
+ <%= link_to t('admin.new_user_role'), new_admin_user_role_model_path %> +
diff --git a/app/views/panel/users/_form.html.erb b/app/views/admin/users/_form.html.erb similarity index 92% rename from app/views/panel/users/_form.html.erb rename to app/views/admin/users/_form.html.erb index 1deeb445..3509bf9f 100644 --- a/app/views/panel/users/_form.html.erb +++ b/app/views/admin/users/_form.html.erb @@ -6,7 +6,7 @@
- + <%= image_tag(@user.avatar.thumb.url) if @user.avatar? %> <%= file_field_tag 'file' %> <%= hidden_field_tag :avatar_cache %> @@ -18,14 +18,14 @@ <%= f.text_field :email %>

- <%= t('panel.admin') %> + <%= t('admin.admin') %> <%= f.check_box :admin %>

<% if @user_info_models %>
- <%= t('panel.infos') %> + <%= t('admin.info') %> <% @user_info_models.each do |ua| %>
<%= render :partial => 'user_attribute', @@ -38,7 +38,7 @@ <% if @user_role_models %>
- - - - - - - - - <% @users.each do |user| %> - - - - - - - - <% end %> -
<%= t('panel.roles') %><%= t('panel.name') %><%= t('panel.email') %><%= t('panel.admin') %><%= t('panel.action') %>
<%= user.get_roles %><%= user[:name] %><%= user.email %><%= user.admin ? t(:yes_) : t(:no_) %> - <%= link_to t(:show), panel_user_path(user) %> | - <%= link_to t(:edit), edit_panel_user_path(user) %> | - <%= link_to t(:delete), panel_user_path(user), :confirm => t('sure?'), :method => :delete %> -
diff --git a/config/locales/en.yml b/config/locales/en.yml index 6ebc7e39..65bdb4ef 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -24,13 +24,17 @@ en: yes_: "Yes" admin: + action: Action add_language: Add language admin: Admin action: Action announcement: Announcement asset: Asset attributes: Attributes + cant_delete_self: You can not delete yourself. + cant_revoke_self_admin: You can not revoke your admin role yourself. class: Class + content: Content create_error_link: Error when creating link. create_error_page: Error when creating page. create_success_home: Homepage was successfully created. @@ -38,7 +42,7 @@ en: create_success_link: Link was successfully created. create_success_page: Page was successfully created. create_success_snippet: Snippet was successfully created. - content: Content + create_success_user: User was successfully created. data: Data delete_language: Delete language description: Description @@ -51,11 +55,14 @@ en: editing_snippet: Editing snippet editing_user_info: Editing user information editing_user_role: Editing user role + email: Email enable_language: Enable language file_name: Filename file_size: File size format: Format + home: Home id: ID + info: Information is_published: Is published item: Item key: Key @@ -67,11 +74,14 @@ en: list_items: Items list list_puchases: Purchases list list_snippets: Snippets list + list_users: Users list list_user_infos: User information list list_user_roles: User roles list + member: Member move_down: Move down move_up: Move up multilingual: Multilingual + my_avatar: My Avatar no_home_page: You don't have a homepage no_layout: You don't have a layout name: Name @@ -82,6 +92,7 @@ en: new_link: New link new_page: New page new_snippet: New snippet + new_user: New user new_user_info: New user information new_user_role: New user role non_multilingual: Non multilingual @@ -90,13 +101,13 @@ en: position: Position published?: Published? purchase: Purchase - info: Information registered: Registered role: Role + roles: Roles title: Title translation: Translation type: Type - up_to_date: Up-do-date + up_to_date: Up-to-date update_error_link: Error when updating link. update_error_page: Error when updating page. update_success_content: Content was successfully updated. @@ -105,24 +116,11 @@ en: update_success_link: Link was successfully updated. update_success_page: Page was successfully updated. update_success_snippet: Snippet was successfully updated. + update_success_user: User was successfully updated. url: URL + user: User user_info: User information + user_panel: User panel user_role: User role panel: - action: Action - admin: Admin - cant_delete_self: You can not delete yourself. - cant_revoke_self_admin: You can not revoke your admin role yourself. - create_success_user: User was successfully created. - email: Email - home: Home - list_users: Users list - my_avatar: My Avatar - name: Name - new_user: New user - infos: Information - roles: Roles - update_success_user: User was successfully updated. - user: User - user_panel: User panel diff --git a/config/locales/zh_tw.yml b/config/locales/zh_tw.yml index 694d38eb..9d046612 100644 --- a/config/locales/zh_tw.yml +++ b/config/locales/zh_tw.yml @@ -19,12 +19,15 @@ zh_tw: yes_: "Yes" admin: + action: 行動 add_language: 新增語言 admin: 管理 action: 行動 announcement: 公告 asset: 資產 attributes: 屬性 + cant_delete_self: 您不可以刪除自己。 + cant_revoke_self_admin: 您不可以撤銷自己的管理作用。 class: 階級 content: 內容 create_error_link: 創建連接時出錯。 @@ -33,7 +36,8 @@ zh_tw: create_success_layout: 樣板已成功創建。 create_success_link: 連結已成功創建。 create_success_page: 頁面已成功創建。 - create_success_snippet: 片段已成功創建。 + create_success_snippet: 片段已成功創建 + create_success_user: 用戶已成功創建。。 data: 數據 delete_language: 刪除語言 description: 描述 @@ -45,11 +49,14 @@ zh_tw: editing_snippet: 編輯片段 editing_user_info: 編輯用戶資料 editing_user_role: 編輯用戶角色 + email: Email enable_language: 啟用語言 file_name: 檔名 file_size: 檔案大小 format: 格式 + home: 首頁 id: ID + info: 資料 is_published: 被出版 item: 項目 key: 關鍵 @@ -60,11 +67,14 @@ zh_tw: list_items: 項目清單 list_layouts: 佈局清單 list_snippets: 斷片清單 + list_users: 使用清單 list_user_infos: 用戶資料清單 list_user_roles: 用戶角色清單 + member: 會員 move_down: 往下移 move_up: 往上移 multilingual: 多種語言 + my_avatar: 我的頭像 no_home_page: 您沒有首頁 no_layout: 您沒有佈局 name: 名稱 @@ -75,6 +85,7 @@ zh_tw: new_link: 新增連結 new_page: 新增頁面 new_snippet: 新增片段 + new_user: 新增使用 new_user_info: 新增用戶資料 new_user_role: 新增用戶角色 non_multilingual: 非多種語言 @@ -82,8 +93,8 @@ zh_tw: orig_upload_file: 原上傳檔名 position: 位置 published?: 發布? - info: 資料 role: 角色 + roles: 角色。 title: 標題 translation: 翻譯 type: 類型 @@ -95,27 +106,14 @@ zh_tw: update_success_link: 連結已成功更新。 update_success_page: 頁面已成功更新。 update_success_snippet: 片段已成功更新。 + update_success_user: 用戶已成功更新 url: URL + user: 用戶 user_info: 用戶資料 + user_panel: 用戶面板 user_role: 用戶角色 panel: - action: 行動 - admin: 管理 - cant_delete_self: 您不可以刪除自己。 - cant_revoke_self_admin: 您不可以撤銷自己的管理作用。 - create_success_user: 用戶已成功創建。 - email: Email - home: 首頁 - list_users: 使用清單 - my_avatar: 我的頭像 - name: 名稱 - new_user: 新增使用 - infos: 資料 - roles: 角色 - update_success_user: 用戶已成功更新。 - user: 用戶 - user_panel: 用戶面板 diff --git a/config/routes.rb b/config/routes.rb index 55b5b29f..fba21f02 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -46,6 +46,7 @@ PrototypeR4::Application.routes.draw do resources :sites resources :snippets resources :translations + resources :users resources :user_info_models resources :user_role_models end