From 16c26e32732a59696f561d585856b9be04a003ff Mon Sep 17 00:00:00 2001 From: Manson Wang Date: Thu, 26 Sep 2013 15:56:43 +0800 Subject: [PATCH 1/6] Fix path of jquery.cycle.all.latest.js --- app/views/front/show_banner.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/front/show_banner.html.erb b/app/views/front/show_banner.html.erb index e5626148e..f06e505b6 100644 --- a/app/views/front/show_banner.html.erb +++ b/app/views/front/show_banner.html.erb @@ -1,4 +1,4 @@ - +<%= javascript_include_tag "lib/jquery.cycle.all.latest.js"%>
@@ -24,4 +24,4 @@ $(document).ready(function(){ }); }); }); - \ No newline at end of file + From dc3593c1625e39507772dbd631399ba34618a06b Mon Sep 17 00:00:00 2001 From: Manson Wang Date: Thu, 26 Sep 2013 17:11:56 +0800 Subject: [PATCH 2/6] zh-tw for new ui --- config/locales/new_ui.zh_tw.yml | 71 +++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 config/locales/new_ui.zh_tw.yml diff --git a/config/locales/new_ui.zh_tw.yml b/config/locales/new_ui.zh_tw.yml new file mode 100644 index 000000000..bb4ee69b4 --- /dev/null +++ b/config/locales/new_ui.zh_tw.yml @@ -0,0 +1,71 @@ +zh_tw: + add_category: 新增類別 + add_link: 新增連結 + add_page: 新增頁面 + add_to_default: 加入預設 + alternative: 註解 + approval_setting: 審核設定 + authorization_: 授權 + change: 更換 + change_file: 更換檔案 + create: + error: + category: 建立類別時發生錯誤 + tag: 建立標籤時發生錯誤 + delete_warning: 刪除後無法還原,您確定要刪除嗎? + deselect_all: 取消全選 + detail: 細節 + edit_category: 編輯類別 + editing: + tag: 編輯標籤 + file: + name: 檔案名稱 + front_page: + name_language: 網站標題 + select_template: 選擇樣版 + select_themes: 選擇主題 + select_module: 選擇模組 + language: 語言 + login_orbit: 登入 Orbit + merge: 合併 + new: + tag: 新增標籤 + next: 下一頁 + no_app: 無模組 + no_category: 無可用類別 + no_data: 無資料 + no_date: 無日期 + no_file: 無檔案 + path: 路徑 + previous: 上一頁 + remove: 移除 + remove_default: 移除預設 + restful_actions: + create: 建立 + delete: 刪除 + edit: 編輯 + index: Index + new: 新增 + show: Show + update: 更新 + search: + tags: 搜尋標籤 + select_all: 全選 + select_file: 選擇檔案 + select_image: 選擇圖片 + sort_number: 排序數 + tag: + add: 新增標籤 + delete: 刪除標籤 + new_name: 新標籤名稱 + merge_help: 自訂新標籤名稱或點選下方標籤 + merger: 合併標籤 + remove_default: 移除預設標籤 + warning: + delete: 刪除後無法還原,您確定要刪除嗎? + remove_default: 您確定要移除此預設標籤嗎? + update: + error: + tag: 更新類別時發生錯誤 + tag: 更新標籤時發生錯誤 + url_alt: 註解 From f81894af90048a0178dc71387d4a54beb9afc48d Mon Sep 17 00:00:00 2001 From: chris Date: Thu, 26 Sep 2013 18:59:23 +0800 Subject: [PATCH 3/6] User ordering Run the task new_ui:save_users --- .../admin/users_new_interface_controller.rb | 26 +++++++++ app/models/user/user.rb | 2 + .../_index_paginator.html.erb | 25 +++++---- .../_user_edit_order.html.erb | 15 +++++ .../users_new_interface/edit_order.html.erb | 56 +++++++++++++++++++ .../users_new_interface/update_order.js.erb | 1 + config/locales/new_ui.en.yml | 2 + config/locales/new_ui.zh_tw.yml | 2 + config/routes.rb | 4 ++ lib/tasks/new_ui.rake | 4 ++ 10 files changed, 125 insertions(+), 12 deletions(-) create mode 100644 app/views/admin/users_new_interface/_user_edit_order.html.erb create mode 100644 app/views/admin/users_new_interface/edit_order.html.erb create mode 100644 app/views/admin/users_new_interface/update_order.js.erb diff --git a/app/controllers/admin/users_new_interface_controller.rb b/app/controllers/admin/users_new_interface_controller.rb index f7a1bdf45..d484dae52 100644 --- a/app/controllers/admin/users_new_interface_controller.rb +++ b/app/controllers/admin/users_new_interface_controller.rb @@ -240,6 +240,32 @@ class Admin::UsersNewInterfaceController < OrbitMemberController end end + + def edit_order + @users = User.all + end + + def update_order + if params[:users].present? + params[:users].values.sort.each do |pair| + to_go = pair[0].to_i + if to_go > 0 + user_at_position = User.where(position: to_go - 1).first + user = User.find(pair[1]) + if user_at_position && !user_at_position == user + if user.position > user_at_position.position + user.move_above(user_at_position) + else + user.move_below(user_at_position) + end + elsif to_go > User.count + user.move_to_bottom + end + end + end + end + @users = User.all + end protected def get_tags diff --git a/app/models/user/user.rb b/app/models/user/user.rb index b726c0f3b..90b61f6d4 100644 --- a/app/models/user/user.rb +++ b/app/models/user/user.rb @@ -1,6 +1,8 @@ class User include Mongoid::Document + include Mongoid::Tree + include Mongoid::Tree::Ordering # use mongoid-tree because mongoid-ordering needs mongoid(~>3.0) include Mongoid::Timestamps devise :database_authenticatable, :recoverable, :rememberable, :trackable, :registerable, :validatable #, :timeoutable diff --git a/app/views/admin/users_new_interface/_index_paginator.html.erb b/app/views/admin/users_new_interface/_index_paginator.html.erb index ef2228410..058d8f278 100644 --- a/app/views/admin/users_new_interface/_index_paginator.html.erb +++ b/app/views/admin/users_new_interface/_index_paginator.html.erb @@ -1,12 +1,13 @@ -
-
- <% if is_admin? %> - <%= link_to(new_admin_users_new_interface_path,:class=> "btn btn-primary pull-right") do%> - <%= t(:add)%> - <% end -%> - <%end -%> -
- -
+
+
+ <% if is_admin? %> + <%= link_to t(:edit_order), edit_order_admin_users_new_interface_index_path, :class => "btn btn-primary" %> + <%= link_to(new_admin_users_new_interface_path,:class=> "btn btn-primary") do %> + <%= t(:add) %> + <% end -%> + <% end -%> +
+ +
diff --git a/app/views/admin/users_new_interface/_user_edit_order.html.erb b/app/views/admin/users_new_interface/_user_edit_order.html.erb new file mode 100644 index 000000000..35150b5af --- /dev/null +++ b/app/views/admin/users_new_interface/_user_edit_order.html.erb @@ -0,0 +1,15 @@ +<% + if user_edit_order.sex == 'male' + @user_sex = 'gender-man' + elsif user_edit_order.sex == 'female' + @user_sex = 'gender-woman' + else + @user_sex = 'gender-none' + end +%> + + + <%= link_to user_edit_order.position + 1, '#', class: 'edit_position', 'data-user-id' => user_edit_order.id %> + <%= link_to user_edit_order.name, admin_users_new_interface_path(user_edit_order) %> + <%= user_edit_order.email %> + \ No newline at end of file diff --git a/app/views/admin/users_new_interface/edit_order.html.erb b/app/views/admin/users_new_interface/edit_order.html.erb new file mode 100644 index 000000000..3ea93f075 --- /dev/null +++ b/app/views/admin/users_new_interface/edit_order.html.erb @@ -0,0 +1,56 @@ +<% content_for :side_bar do %> + <%= render :partial => 'admin/users_new_interface/side_bar' %> +<% end %> + +
+ + + + + + + + + + + <%= render partial: "user_edit_order", collection: @users %> + +
<%= t(:position) %><%= t(:name) %><%= t(:email) %>
+
+ +
+
+ <%= link_to t(:update_), '#', class: "btn btn-primary pull-right" %> +
+
+ +<% content_for :page_specific_javascript do %> + +<% end %> \ No newline at end of file diff --git a/app/views/admin/users_new_interface/update_order.js.erb b/app/views/admin/users_new_interface/update_order.js.erb new file mode 100644 index 000000000..e9de95668 --- /dev/null +++ b/app/views/admin/users_new_interface/update_order.js.erb @@ -0,0 +1 @@ +$('#list-view table tbody').html("<%= j render partial: 'user_edit_order', collection: @users %>") \ No newline at end of file diff --git a/config/locales/new_ui.en.yml b/config/locales/new_ui.en.yml index b6f072b3c..c064a8836 100644 --- a/config/locales/new_ui.en.yml +++ b/config/locales/new_ui.en.yml @@ -16,6 +16,7 @@ en: deselect_all: Deselect all detail: Detail edit_category: Edit Categorie + edit_order: Edit order editing: tag: Editing tag file: @@ -37,6 +38,7 @@ en: no_date: No date no_file: No file path: Path + position: Position previous: Previous remove: Remove remove_default: Remove default diff --git a/config/locales/new_ui.zh_tw.yml b/config/locales/new_ui.zh_tw.yml index bb4ee69b4..b6bdfd4ea 100644 --- a/config/locales/new_ui.zh_tw.yml +++ b/config/locales/new_ui.zh_tw.yml @@ -16,6 +16,7 @@ zh_tw: deselect_all: 取消全選 detail: 細節 edit_category: 編輯類別 + edit_order: 編輯排序 editing: tag: 編輯標籤 file: @@ -37,6 +38,7 @@ zh_tw: no_date: 無日期 no_file: 無檔案 path: 路徑 + position: 排序 previous: 上一頁 remove: 移除 remove_default: 移除預設 diff --git a/config/routes.rb b/config/routes.rb index 2263b3c77..843cff3be 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -214,6 +214,10 @@ Orbit::Application.routes.draw do member do get 'temp_edit' end + collection do + get 'edit_order' + post 'update_order' + end match "edit_passwd" => "users_new_interface#edit_passwd" ,:as => :edit_passwd end diff --git a/lib/tasks/new_ui.rake b/lib/tasks/new_ui.rake index 70584a8db..84ed715c7 100644 --- a/lib/tasks/new_ui.rake +++ b/lib/tasks/new_ui.rake @@ -91,4 +91,8 @@ namespace :new_ui do end end + task :save_users => :environment do + User.all.each(&:save) + end + end From 028c689739ecf2a5d629cc3adaea05fcc3341286 Mon Sep 17 00:00:00 2001 From: Spen Date: Thu, 26 Sep 2013 19:46:14 +0800 Subject: [PATCH 4/6] Change User.all to User.not_guest_user --- app/controllers/admin/users_new_interface_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/admin/users_new_interface_controller.rb b/app/controllers/admin/users_new_interface_controller.rb index d484dae52..f05f2ae5f 100644 --- a/app/controllers/admin/users_new_interface_controller.rb +++ b/app/controllers/admin/users_new_interface_controller.rb @@ -242,7 +242,7 @@ class Admin::UsersNewInterfaceController < OrbitMemberController end def edit_order - @users = User.all + @users = User.not_guest_user end def update_order @@ -264,7 +264,7 @@ class Admin::UsersNewInterfaceController < OrbitMemberController end end end - @users = User.all + @users = User.not_guest_user end protected From 52c896d8c5fbf6a1b4e7e4827645d1aa1f44cbb0 Mon Sep 17 00:00:00 2001 From: Harry Bomrah Date: Thu, 26 Sep 2013 19:36:54 +0800 Subject: [PATCH 5/6] some backend code change for sharing personal plugin module content. Added sharing in desktop for all the modules. --- .../javascripts/desktop/orbitdesktop.js | 32 +++++++++++++++ app/assets/javascripts/lib/list-check.js | 39 ++++++++++--------- .../desktop/desktop-component.scss | 8 ++++ .../stylesheets/desktop/desktop-main.css | 29 +++++++++++++- .../admin/users_new_interface/show.html.erb | 1 - .../personal_book/desktop/personal_books.js | 1 + .../back_end/writing_books_controller.rb | 1 + .../desktop/personal_books_helper.rb | 9 +++-- .../desktop/personal_books/index.html.erb | 21 ++-------- .../desktop/conference_pages.js | 1 + .../writing_conferences_controller.rb | 2 +- .../desktop/conference_pages_helper.rb | 16 +++++--- .../desktop/conference_pages/index.html.erb | 15 ++++--- .../desktop/personal_diploma.js | 1 + .../back_end/diplomas_controller.rb | 2 +- .../desktop/personal_diplomas_helper.rb | 9 +++-- .../desktop/personal_diplomas/index.html.erb | 23 ++--------- .../desktop/personal_experiences.js | 1 + .../back_end/experiences_controller.rb | 2 +- .../desktop/personal_experiences_helper.rb | 9 +++-- .../personal_experiences/index.html.erb | 21 ++-------- .../personal_honor/desktop/personal_honors.js | 1 + .../back_end/honors_controller.rb | 2 +- .../desktop/personal_honors_helper.rb | 9 +++-- .../desktop/personal_honors/index.html.erb | 23 ++--------- .../personal_journal/desktop/journal_pages.js | 1 + .../back_end/writing_journals_controller.rb | 2 +- .../desktop/journal_pages_helper.rb | 17 +++++--- .../desktop/journal_pages/_form.html.erb | 9 +++-- .../desktop/journal_pages/index.html.erb | 21 ++-------- .../personal_lab/desktop/personal_lab.js | 1 + .../personal_lab/back_end/labs_controller.rb | 2 +- .../desktop/personal_labs_helper.rb | 9 +++-- .../desktop/personal_labs/index.html.erb | 23 ++--------- .../desktop/personal_patent.js | 1 + .../back_end/writing_patents_controller.rb | 2 +- .../desktop/personal_patents_helper.rb | 9 +++-- .../desktop/personal_patents/index.html.erb | 23 ++--------- .../desktop/personal_project.js | 1 + .../back_end/projects_controller.rb | 2 +- .../desktop/personal_projects_helper.rb | 10 +++-- .../desktop/personal_projects/index.html.erb | 23 ++--------- .../desktop/personal_research.js | 1 + .../back_end/researchs_controller.rb | 2 +- .../desktop/personal_researchs_helper.rb | 10 +++-- .../desktop/personal_researchs/index.html.erb | 21 ++-------- 46 files changed, 224 insertions(+), 244 deletions(-) diff --git a/app/assets/javascripts/desktop/orbitdesktop.js b/app/assets/javascripts/desktop/orbitdesktop.js index 81579d99b..0d6ed59fd 100755 --- a/app/assets/javascripts/desktop/orbitdesktop.js +++ b/app/assets/javascripts/desktop/orbitdesktop.js @@ -29,6 +29,9 @@ //column="true" this option is only for column layout... the columns will be formed on this column=true attribute and it should be a div //item=true this attribute should be present in the li tag. li with this attribute are considered as a separate item. +//enableLanguageSelect( dom ) children will be binded with language, data-lang = string ex "en"|"zh_tw" will toggle all data-langunage throughout the page +//enableSharing( dom ) children will be binded with share, data-mode = string ex "public"|"private" will change the mode for all the selected items. the dom with class should have data-link = url data-var = vaiable_name, default will be mode + $.extend($.expr[':'], { 'containsi': function (elem, i, match, array) { @@ -1881,6 +1884,35 @@ var orbitDesktop = function(dom){ return false; }); } + + this.enableSharing = function( dom ){ + var el = $( dom ), + variable = ( el.data( 'var' ) ? el.data( "var" ) : "mode"), + _url = el.data( 'link' ) + "?" + variable + "=", + classes = []; + + el.find( "a" ).each( function(){ + classes.push( $( this ).attr( "item-class" ) ? $( this ).attr( "item-class" ) : $( this ).data( 'mode' ) ); + }) + + el.find( "a" ).click( function(){ + var ids = [], + mode = $( this ).data( 'mode' ), + inject_class = $( this ).attr( 'item-class' ) ? $( this ).attr( 'item-class' ) : mode; + + $( ".overview li[item=true] a.icon-check" ).each( function(){ + ids.push( $( this ).data( 'id' ) ); + $( "li[data-id="+ $( this ).data( 'id' ) +"]").removeClass( classes.join( " " ) ).addClass( inject_class ); + }) + $.ajax({ + url : _url + mode, + data : {"ids" : ids}, + datatype : "json", + }) + return false; + }) + } + this.minimizeBarManager = function(){ var minimizedApps = [], minimizeBar = $("#minimizebar"); diff --git a/app/assets/javascripts/lib/list-check.js b/app/assets/javascripts/lib/list-check.js index c21899fda..74f75f9e7 100644 --- a/app/assets/javascripts/lib/list-check.js +++ b/app/assets/javascripts/lib/list-check.js @@ -81,25 +81,26 @@ $(function() { e.preventDefault(); }); - $("#dialog").on('show', function (e) { - $(this).find('.delete-item').on(clickEvent, function() { - var _v = []; - $("tbody .list-check").each(function() { - this.checked && _v.push("ids[]="+this.value) - }); - var _t = $t.attr("rel"); - if(_t.indexOf("?") > -1) { - $.ajax(_t + "&" + _v.join("&")).done(function() { - actionSuccess(_data.checkAction) - }); - } else { - $.ajax(_t + "?" + _v.join("&")).done(function() { - actionSuccess(_data.checkAction) - }); + $("#dialog").on(clickEvent, '.delete-item', function() { + var _v = [], + _t = $t.attr("rel"); + + $("tbody .list-check:checked").each(function() { + _v.push(this.value); + }); + + $.ajax({ + url : _t, + type:"get", + data : {"ids":_v}, + dataType : "json", + success : function(){ + actionSuccess(_data.checkAction); } - $('#dialog').modal('hide'); - $('.list-active-btn').addClass('disabled').data('actionable', false); - e.preventDefault(); }) - }); + + $('#dialog').modal('hide'); + $('.list-active-btn').addClass('disabled').data('actionable', false); + }) + }); \ No newline at end of file diff --git a/app/assets/stylesheets/desktop/desktop-component.scss b/app/assets/stylesheets/desktop/desktop-component.scss index 8dd99e876..e41c424c8 100644 --- a/app/assets/stylesheets/desktop/desktop-component.scss +++ b/app/assets/stylesheets/desktop/desktop-component.scss @@ -19,6 +19,14 @@ margin-left: 0; } } + .form_fix { + textarea { + margin-bottom: 12px; + } + input { + margin-left: 0; + } + } // fixed width column with 12px gutter // 276px width for 8 columns // 420px width for 12 columns diff --git a/app/assets/stylesheets/desktop/desktop-main.css b/app/assets/stylesheets/desktop/desktop-main.css index e9298769f..15a437ac3 100644 --- a/app/assets/stylesheets/desktop/desktop-main.css +++ b/app/assets/stylesheets/desktop/desktop-main.css @@ -323,6 +323,29 @@ a.admtxt.admbg2:hover { float: left; } .docklist .d_cate:hover .dock_child { display: block; } +.disable { + opacity: .3; +} +.disable a { + cursor: not-allowed; +} +.private { + position: relative; + padding-right: 10px; + width: 300px; + opacity: .3 !important; +} +.private:after { + content: "\e073"; + display: inline-block; + font-family: 'entypo'; + font-size: 1.5em; + position: absolute; + right: 0; + text-align: center; + text-decoration: inherit; + top: 5px; +} .fn_des.admtxt { line-height: 60px; @@ -714,7 +737,8 @@ a.admtxt.admbg2:hover { /* list item */ .list_t_item { - overflow: hidden; } + overflow: hidden; + height: 100px; } .list_t_title { padding-bottom: 6px; @@ -748,7 +772,8 @@ a.admtxt.admbg2:hover { -webkit-text-size-adjust: none; } .list_item_function a :first-child { margin-left: 0; } - .datalist_item:hover .list_item_function { + .datalist_item:hover .list_item_function, + .list_t_item:hover .list_item_function { bottom: 0; } /* App */ diff --git a/app/views/admin/users_new_interface/show.html.erb b/app/views/admin/users_new_interface/show.html.erb index bcdc4be1b..07be2bf1a 100644 --- a/app/views/admin/users_new_interface/show.html.erb +++ b/app/views/admin/users_new_interface/show.html.erb @@ -5,7 +5,6 @@ <%= render :partial => "js_and_css"%> <% content_for :page_specific_javascript do -%> - <%= javascript_include_tag "lib/jquery.lite.image.resize.js" %> <%= javascript_include_tag "lib/member/member.js" %> <%= javascript_include_tag "lib/footable-0.1.js" %> <% end -%> diff --git a/vendor/built_in_modules/personal_book/app/assets/javascripts/personal_book/desktop/personal_books.js b/vendor/built_in_modules/personal_book/app/assets/javascripts/personal_book/desktop/personal_books.js index 08a63fdb4..b744239ed 100644 --- a/vendor/built_in_modules/personal_book/app/assets/javascripts/personal_book/desktop/personal_books.js +++ b/vendor/built_in_modules/personal_book/app/assets/javascripts/personal_book/desktop/personal_books.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalBook = function(target,url,cache){ // t return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalBook.bookDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_book/app/controllers/panel/personal_book/back_end/writing_books_controller.rb b/vendor/built_in_modules/personal_book/app/controllers/panel/personal_book/back_end/writing_books_controller.rb index 60ba0c274..a2b13336a 100644 --- a/vendor/built_in_modules/personal_book/app/controllers/panel/personal_book/back_end/writing_books_controller.rb +++ b/vendor/built_in_modules/personal_book/app/controllers/panel/personal_book/back_end/writing_books_controller.rb @@ -282,6 +282,7 @@ class Panel::PersonalBook::BackEnd::WritingBooksController < OrbitBackendControl respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"WritingBook")) } + format.json { render json: {"success"=>true}.to_json} end diff --git a/vendor/built_in_modules/personal_book/app/helpers/panel/personal_book/desktop/personal_books_helper.rb b/vendor/built_in_modules/personal_book/app/helpers/panel/personal_book/desktop/personal_books_helper.rb index 186b2d594..3c4b5fcb0 100644 --- a/vendor/built_in_modules/personal_book/app/helpers/panel/personal_book/desktop/personal_books_helper.rb +++ b/vendor/built_in_modules/personal_book/app/helpers/panel/personal_book/desktop/personal_books_helper.rb @@ -2,23 +2,26 @@ module Panel::PersonalBook::Desktop::PersonalBooksHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_book/app/views/panel/personal_book/desktop/personal_books/index.html.erb b/vendor/built_in_modules/personal_book/app/views/panel/personal_book/desktop/personal_books/index.html.erb index f79d1d30c..9096e25f6 100644 --- a/vendor/built_in_modules/personal_book/app/views/panel/personal_book/desktop/personal_books/index.html.erb +++ b/vendor/built_in_modules/personal_book/app/views/panel/personal_book/desktop/personal_books/index.html.erb @@ -50,25 +50,10 @@
Share
-
-
-
New Share
-
diff --git a/vendor/built_in_modules/personal_conference/app/assets/javascripts/personal_conference/desktop/conference_pages.js b/vendor/built_in_modules/personal_conference/app/assets/javascripts/personal_conference/desktop/conference_pages.js index 6955dedb3..613a9dd20 100644 --- a/vendor/built_in_modules/personal_conference/app/assets/javascripts/personal_conference/desktop/conference_pages.js +++ b/vendor/built_in_modules/personal_conference/app/assets/javascripts/personal_conference/desktop/conference_pages.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializeConferencePapers = function(target,url,cache){ return false; }) } + o.enableSharing("div.share_mode"); } this.initializeConferencePapers.paperDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_conference/app/controllers/panel/personal_conference/back_end/writing_conferences_controller.rb b/vendor/built_in_modules/personal_conference/app/controllers/panel/personal_conference/back_end/writing_conferences_controller.rb index a6ae1f9ff..0ef42ba31 100644 --- a/vendor/built_in_modules/personal_conference/app/controllers/panel/personal_conference/back_end/writing_conferences_controller.rb +++ b/vendor/built_in_modules/personal_conference/app/controllers/panel/personal_conference/back_end/writing_conferences_controller.rb @@ -277,7 +277,7 @@ class Panel::PersonalConference::BackEnd::WritingConferencesController < OrbitBa respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"WritingConference")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_conference/app/helpers/panel/personal_conference/desktop/conference_pages_helper.rb b/vendor/built_in_modules/personal_conference/app/helpers/panel/personal_conference/desktop/conference_pages_helper.rb index d22bfc18f..c09f6b2a3 100644 --- a/vendor/built_in_modules/personal_conference/app/helpers/panel/personal_conference/desktop/conference_pages_helper.rb +++ b/vendor/built_in_modules/personal_conference/app/helpers/panel/personal_conference/desktop/conference_pages_helper.rb @@ -2,23 +2,29 @@ module Panel::PersonalConference::Desktop::ConferencePagesHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ - content(publication, view) + \ - edit_or_delete(publication) + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + content_tag :div, + :class => "inner" do + marker(publication.id) + \ + content(publication, view) + \ + edit_or_delete(publication) + end end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_conference/app/views/panel/personal_conference/desktop/conference_pages/index.html.erb b/vendor/built_in_modules/personal_conference/app/views/panel/personal_conference/desktop/conference_pages/index.html.erb index 79229ec1f..d61d3bf3b 100644 --- a/vendor/built_in_modules/personal_conference/app/views/panel/personal_conference/desktop/conference_pages/index.html.erb +++ b/vendor/built_in_modules/personal_conference/app/views/panel/personal_conference/desktop/conference_pages/index.html.erb @@ -51,13 +51,10 @@
Share
- @@ -69,13 +66,15 @@
--> <% if @view_by.eql?"abstract" %> -
+
<% else %> -
+
<% end %> +
    <% @writing_conferences.each do |w| %> <%= publication_record w, @view_by%> <% end %> +
diff --git a/vendor/built_in_modules/personal_diploma/app/assets/javascripts/personal_diploma/desktop/personal_diploma.js b/vendor/built_in_modules/personal_diploma/app/assets/javascripts/personal_diploma/desktop/personal_diploma.js index 70ba7d794..756b437e5 100644 --- a/vendor/built_in_modules/personal_diploma/app/assets/javascripts/personal_diploma/desktop/personal_diploma.js +++ b/vendor/built_in_modules/personal_diploma/app/assets/javascripts/personal_diploma/desktop/personal_diploma.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalDiploma = function(target,url,cache){ / return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalDiploma.diplomaDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_diploma/app/controllers/panel/personal_diploma/back_end/diplomas_controller.rb b/vendor/built_in_modules/personal_diploma/app/controllers/panel/personal_diploma/back_end/diplomas_controller.rb index cfbaae98c..09541dfbc 100644 --- a/vendor/built_in_modules/personal_diploma/app/controllers/panel/personal_diploma/back_end/diplomas_controller.rb +++ b/vendor/built_in_modules/personal_diploma/app/controllers/panel/personal_diploma/back_end/diplomas_controller.rb @@ -159,7 +159,7 @@ class Panel::PersonalDiploma::BackEnd::DiplomasController < OrbitBackendControll respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Diploma")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_diploma/app/helpers/panel/personal_diploma/desktop/personal_diplomas_helper.rb b/vendor/built_in_modules/personal_diploma/app/helpers/panel/personal_diploma/desktop/personal_diplomas_helper.rb index 6ca260616..b0e3eedff 100644 --- a/vendor/built_in_modules/personal_diploma/app/helpers/panel/personal_diploma/desktop/personal_diplomas_helper.rb +++ b/vendor/built_in_modules/personal_diploma/app/helpers/panel/personal_diploma/desktop/personal_diplomas_helper.rb @@ -2,23 +2,26 @@ module Panel::PersonalDiploma::Desktop::PersonalDiplomasHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_diploma/app/views/panel/personal_diploma/desktop/personal_diplomas/index.html.erb b/vendor/built_in_modules/personal_diploma/app/views/panel/personal_diploma/desktop/personal_diplomas/index.html.erb index a53e048c7..b35f9457a 100644 --- a/vendor/built_in_modules/personal_diploma/app/views/panel/personal_diploma/desktop/personal_diplomas/index.html.erb +++ b/vendor/built_in_modules/personal_diploma/app/views/panel/personal_diploma/desktop/personal_diplomas/index.html.erb @@ -47,27 +47,12 @@
-
+
Share
-
+ -
-
-
New Share
-
diff --git a/vendor/built_in_modules/personal_experience/app/assets/javascripts/personal_experience/desktop/personal_experiences.js b/vendor/built_in_modules/personal_experience/app/assets/javascripts/personal_experience/desktop/personal_experiences.js index 8a089d902..4ea54b77e 100644 --- a/vendor/built_in_modules/personal_experience/app/assets/javascripts/personal_experience/desktop/personal_experiences.js +++ b/vendor/built_in_modules/personal_experience/app/assets/javascripts/personal_experience/desktop/personal_experiences.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalExperience = function(target,url,cache) return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalExperience.experienceDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_experience/app/controllers/panel/personal_experience/back_end/experiences_controller.rb b/vendor/built_in_modules/personal_experience/app/controllers/panel/personal_experience/back_end/experiences_controller.rb index fd2470ac8..615847780 100644 --- a/vendor/built_in_modules/personal_experience/app/controllers/panel/personal_experience/back_end/experiences_controller.rb +++ b/vendor/built_in_modules/personal_experience/app/controllers/panel/personal_experience/back_end/experiences_controller.rb @@ -225,7 +225,7 @@ class Panel::PersonalExperience::BackEnd::ExperiencesController < OrbitBackendCo respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Experience")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_experience/app/helpers/panel/personal_experience/desktop/personal_experiences_helper.rb b/vendor/built_in_modules/personal_experience/app/helpers/panel/personal_experience/desktop/personal_experiences_helper.rb index f78c6948f..b5d91e7e9 100644 --- a/vendor/built_in_modules/personal_experience/app/helpers/panel/personal_experience/desktop/personal_experiences_helper.rb +++ b/vendor/built_in_modules/personal_experience/app/helpers/panel/personal_experience/desktop/personal_experiences_helper.rb @@ -2,22 +2,25 @@ module Panel::PersonalExperience::Desktop::PersonalExperiencesHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", + "data-id" => id.to_s, "toggle-onclick"=>"icon-check-empty icon-check", "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", + "data-id" => id.to_s, "toggle-onclick"=>"icon-star-empty icon-star", "ajax-remote"=>"false") end diff --git a/vendor/built_in_modules/personal_experience/app/views/panel/personal_experience/desktop/personal_experiences/index.html.erb b/vendor/built_in_modules/personal_experience/app/views/panel/personal_experience/desktop/personal_experiences/index.html.erb index 419211199..bbcaf1f30 100644 --- a/vendor/built_in_modules/personal_experience/app/views/panel/personal_experience/desktop/personal_experiences/index.html.erb +++ b/vendor/built_in_modules/personal_experience/app/views/panel/personal_experience/desktop/personal_experiences/index.html.erb @@ -50,25 +50,10 @@
Share
-
+ -
-
-
New Share
-
diff --git a/vendor/built_in_modules/personal_honor/app/assets/javascripts/personal_honor/desktop/personal_honors.js b/vendor/built_in_modules/personal_honor/app/assets/javascripts/personal_honor/desktop/personal_honors.js index 608f0a357..18d17acb4 100644 --- a/vendor/built_in_modules/personal_honor/app/assets/javascripts/personal_honor/desktop/personal_honors.js +++ b/vendor/built_in_modules/personal_honor/app/assets/javascripts/personal_honor/desktop/personal_honors.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalHonor = function(target,url,cache){ // return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalHonor.honorDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_honor/app/controllers/panel/personal_honor/back_end/honors_controller.rb b/vendor/built_in_modules/personal_honor/app/controllers/panel/personal_honor/back_end/honors_controller.rb index 210a2396f..025708240 100644 --- a/vendor/built_in_modules/personal_honor/app/controllers/panel/personal_honor/back_end/honors_controller.rb +++ b/vendor/built_in_modules/personal_honor/app/controllers/panel/personal_honor/back_end/honors_controller.rb @@ -226,7 +226,7 @@ class Panel::PersonalHonor::BackEnd::HonorsController < OrbitBackendController respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Honor")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_honor/app/helpers/panel/personal_honor/desktop/personal_honors_helper.rb b/vendor/built_in_modules/personal_honor/app/helpers/panel/personal_honor/desktop/personal_honors_helper.rb index 3cdccddc7..bee7a81b0 100644 --- a/vendor/built_in_modules/personal_honor/app/helpers/panel/personal_honor/desktop/personal_honors_helper.rb +++ b/vendor/built_in_modules/personal_honor/app/helpers/panel/personal_honor/desktop/personal_honors_helper.rb @@ -2,23 +2,26 @@ module Panel::PersonalHonor::Desktop::PersonalHonorsHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_honor/app/views/panel/personal_honor/desktop/personal_honors/index.html.erb b/vendor/built_in_modules/personal_honor/app/views/panel/personal_honor/desktop/personal_honors/index.html.erb index 88502ffb0..5c4175dfd 100644 --- a/vendor/built_in_modules/personal_honor/app/views/panel/personal_honor/desktop/personal_honors/index.html.erb +++ b/vendor/built_in_modules/personal_honor/app/views/panel/personal_honor/desktop/personal_honors/index.html.erb @@ -46,27 +46,12 @@
-
+
Share
-
+ -
-
-
New Share
-
diff --git a/vendor/built_in_modules/personal_journal/app/assets/javascripts/personal_journal/desktop/journal_pages.js b/vendor/built_in_modules/personal_journal/app/assets/javascripts/personal_journal/desktop/journal_pages.js index cdbce8cbe..5da6a9dfc 100644 --- a/vendor/built_in_modules/personal_journal/app/assets/javascripts/personal_journal/desktop/journal_pages.js +++ b/vendor/built_in_modules/personal_journal/app/assets/javascripts/personal_journal/desktop/journal_pages.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializeJournalPapers = function(target,url,cache){ // return false; }) } + o.enableSharing("div.share_mode"); } this.initializeJournalPapers.paperDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_journal/app/controllers/panel/personal_journal/back_end/writing_journals_controller.rb b/vendor/built_in_modules/personal_journal/app/controllers/panel/personal_journal/back_end/writing_journals_controller.rb index da0e76050..1c3998fd0 100644 --- a/vendor/built_in_modules/personal_journal/app/controllers/panel/personal_journal/back_end/writing_journals_controller.rb +++ b/vendor/built_in_modules/personal_journal/app/controllers/panel/personal_journal/back_end/writing_journals_controller.rb @@ -327,7 +327,7 @@ class Panel::PersonalJournal::BackEnd::WritingJournalsController < OrbitBackendC respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"WritingJournal")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_journal/app/helpers/panel/personal_journal/desktop/journal_pages_helper.rb b/vendor/built_in_modules/personal_journal/app/helpers/panel/personal_journal/desktop/journal_pages_helper.rb index 490d77797..b7915faf4 100644 --- a/vendor/built_in_modules/personal_journal/app/helpers/panel/personal_journal/desktop/journal_pages_helper.rb +++ b/vendor/built_in_modules/personal_journal/app/helpers/panel/personal_journal/desktop/journal_pages_helper.rb @@ -2,10 +2,15 @@ module Panel::PersonalJournal::Desktop::JournalPagesHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ - content(publication, view) + \ - edit_or_delete(publication) + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + + content_tag :div, + :class => "inner" do + marker(publication.id) + \ + content(publication, view) + \ + edit_or_delete(publication) + end end end @@ -25,16 +30,18 @@ module Panel::PersonalJournal::Desktop::JournalPagesHelper height end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/_form.html.erb b/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/_form.html.erb index 140974fed..3c2f5e7de 100644 --- a/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/_form.html.erb +++ b/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/_form.html.erb @@ -32,10 +32,11 @@
-->
    +
  • <% @site_valid_locales.each_with_index do |locale, i| %> <% style = locale != I18n.locale.to_s ? 'style=display:none;' : "" %> <% data = "data-language=" + locale %> -
  • <%= data %>> +
    <%= data %>> <%= f.fields_for :paper_title_translations do |f| %> <%= f.text_area locale, class: "s_grid_12 s_grid s_grid_h_3", @@ -43,8 +44,7 @@ placeholder: t("personal_journal.paper_title")+ "("+I18nVariable.from_locale(locale)+")", value: (@writing_journal.paper_title_translations[locale.to_s] rescue nil) %> <% end %> -
  • -
  • <%= data %>> +

    <%= f.fields_for :journal_title_translations do |f| %> <%= f.text_field locale, size: "20", @@ -53,8 +53,9 @@ value: (@writing_journal.journal_title_translations[locale.to_s] rescue nil) %> <% end %> -
  • +
<% end %> +
  • <%= label_tag("", t("personal_journal.level_type"), :class => 's_grid s_grid_4') %>
    diff --git a/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/index.html.erb b/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/index.html.erb index 35d7c2d1a..07007f472 100644 --- a/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/index.html.erb +++ b/vendor/built_in_modules/personal_journal/app/views/panel/personal_journal/desktop/journal_pages/index.html.erb @@ -51,25 +51,10 @@
    Share
    -
    + -
    -
    -
    New Share
    -
    diff --git a/vendor/built_in_modules/personal_lab/app/assets/javascripts/personal_lab/desktop/personal_lab.js b/vendor/built_in_modules/personal_lab/app/assets/javascripts/personal_lab/desktop/personal_lab.js index 87e7415ac..e279f8312 100644 --- a/vendor/built_in_modules/personal_lab/app/assets/javascripts/personal_lab/desktop/personal_lab.js +++ b/vendor/built_in_modules/personal_lab/app/assets/javascripts/personal_lab/desktop/personal_lab.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalLab = function(target,url,cache){ // th return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalLab.labDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_lab/app/controllers/panel/personal_lab/back_end/labs_controller.rb b/vendor/built_in_modules/personal_lab/app/controllers/panel/personal_lab/back_end/labs_controller.rb index e1954e59d..e704e7184 100644 --- a/vendor/built_in_modules/personal_lab/app/controllers/panel/personal_lab/back_end/labs_controller.rb +++ b/vendor/built_in_modules/personal_lab/app/controllers/panel/personal_lab/back_end/labs_controller.rb @@ -161,7 +161,7 @@ class Panel::PersonalLab::BackEnd::LabsController < OrbitBackendController respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Lab")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_lab/app/helpers/panel/personal_lab/desktop/personal_labs_helper.rb b/vendor/built_in_modules/personal_lab/app/helpers/panel/personal_lab/desktop/personal_labs_helper.rb index 087d4bcdb..7269457f5 100644 --- a/vendor/built_in_modules/personal_lab/app/helpers/panel/personal_lab/desktop/personal_labs_helper.rb +++ b/vendor/built_in_modules/personal_lab/app/helpers/panel/personal_lab/desktop/personal_labs_helper.rb @@ -2,23 +2,26 @@ module Panel::PersonalLab::Desktop::PersonalLabsHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_lab/app/views/panel/personal_lab/desktop/personal_labs/index.html.erb b/vendor/built_in_modules/personal_lab/app/views/panel/personal_lab/desktop/personal_labs/index.html.erb index 2a2f9a18f..46037cd5c 100644 --- a/vendor/built_in_modules/personal_lab/app/views/panel/personal_lab/desktop/personal_labs/index.html.erb +++ b/vendor/built_in_modules/personal_lab/app/views/panel/personal_lab/desktop/personal_labs/index.html.erb @@ -48,27 +48,12 @@
  • -
    +
    Share
    -
    + -
    -
    -
    New Share
    -
    diff --git a/vendor/built_in_modules/personal_patent/app/assets/javascripts/personal_patent/desktop/personal_patent.js b/vendor/built_in_modules/personal_patent/app/assets/javascripts/personal_patent/desktop/personal_patent.js index 4ea27d3d9..4313da15b 100644 --- a/vendor/built_in_modules/personal_patent/app/assets/javascripts/personal_patent/desktop/personal_patent.js +++ b/vendor/built_in_modules/personal_patent/app/assets/javascripts/personal_patent/desktop/personal_patent.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalPatent = function(target,url,cache){ // return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalPatent.patentDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_patent/app/controllers/panel/personal_patent/back_end/writing_patents_controller.rb b/vendor/built_in_modules/personal_patent/app/controllers/panel/personal_patent/back_end/writing_patents_controller.rb index e83e3649d..62345312a 100644 --- a/vendor/built_in_modules/personal_patent/app/controllers/panel/personal_patent/back_end/writing_patents_controller.rb +++ b/vendor/built_in_modules/personal_patent/app/controllers/panel/personal_patent/back_end/writing_patents_controller.rb @@ -226,7 +226,7 @@ class Panel::PersonalPatent::BackEnd::WritingPatentsController < OrbitBackendCon respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"WritingPatent")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_patent/app/helpers/panel/personal_patent/desktop/personal_patents_helper.rb b/vendor/built_in_modules/personal_patent/app/helpers/panel/personal_patent/desktop/personal_patents_helper.rb index 024b8d648..b77c60c03 100644 --- a/vendor/built_in_modules/personal_patent/app/helpers/panel/personal_patent/desktop/personal_patents_helper.rb +++ b/vendor/built_in_modules/personal_patent/app/helpers/panel/personal_patent/desktop/personal_patents_helper.rb @@ -2,23 +2,26 @@ module Panel::PersonalPatent::Desktop::PersonalPatentsHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_patent/app/views/panel/personal_patent/desktop/personal_patents/index.html.erb b/vendor/built_in_modules/personal_patent/app/views/panel/personal_patent/desktop/personal_patents/index.html.erb index ef1202667..6c6b01141 100644 --- a/vendor/built_in_modules/personal_patent/app/views/panel/personal_patent/desktop/personal_patents/index.html.erb +++ b/vendor/built_in_modules/personal_patent/app/views/panel/personal_patent/desktop/personal_patents/index.html.erb @@ -47,27 +47,12 @@
    -
    +
    Share
    -
    + -
    -
    -
    New Share
    -
    diff --git a/vendor/built_in_modules/personal_project/app/assets/javascripts/personal_project/desktop/personal_project.js b/vendor/built_in_modules/personal_project/app/assets/javascripts/personal_project/desktop/personal_project.js index 3ae6097fd..419e07e0a 100644 --- a/vendor/built_in_modules/personal_project/app/assets/javascripts/personal_project/desktop/personal_project.js +++ b/vendor/built_in_modules/personal_project/app/assets/javascripts/personal_project/desktop/personal_project.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalProject = function(target,url,cache){ / return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalProject.projectDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_project/app/controllers/panel/personal_project/back_end/projects_controller.rb b/vendor/built_in_modules/personal_project/app/controllers/panel/personal_project/back_end/projects_controller.rb index 5042c78d6..d5ae12eb7 100644 --- a/vendor/built_in_modules/personal_project/app/controllers/panel/personal_project/back_end/projects_controller.rb +++ b/vendor/built_in_modules/personal_project/app/controllers/panel/personal_project/back_end/projects_controller.rb @@ -224,7 +224,7 @@ class Panel::PersonalProject::BackEnd::ProjectsController < OrbitBackendControll respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Project")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_project/app/helpers/panel/personal_project/desktop/personal_projects_helper.rb b/vendor/built_in_modules/personal_project/app/helpers/panel/personal_project/desktop/personal_projects_helper.rb index 1b47e9f54..9dce677e2 100644 --- a/vendor/built_in_modules/personal_project/app/helpers/panel/personal_project/desktop/personal_projects_helper.rb +++ b/vendor/built_in_modules/personal_project/app/helpers/panel/personal_project/desktop/personal_projects_helper.rb @@ -2,23 +2,27 @@ module Panel::PersonalProject::Desktop::PersonalProjectsHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "item" => "true", + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_project/app/views/panel/personal_project/desktop/personal_projects/index.html.erb b/vendor/built_in_modules/personal_project/app/views/panel/personal_project/desktop/personal_projects/index.html.erb index fcc007afb..216ad74e7 100644 --- a/vendor/built_in_modules/personal_project/app/views/panel/personal_project/desktop/personal_projects/index.html.erb +++ b/vendor/built_in_modules/personal_project/app/views/panel/personal_project/desktop/personal_projects/index.html.erb @@ -48,27 +48,12 @@
    -
    +
    Share
    -
    + -
    -
    -
    New Share
    -
    diff --git a/vendor/built_in_modules/personal_research/app/assets/javascripts/personal_research/desktop/personal_research.js b/vendor/built_in_modules/personal_research/app/assets/javascripts/personal_research/desktop/personal_research.js index a64bc13f5..aba31ba45 100644 --- a/vendor/built_in_modules/personal_research/app/assets/javascripts/personal_research/desktop/personal_research.js +++ b/vendor/built_in_modules/personal_research/app/assets/javascripts/personal_research/desktop/personal_research.js @@ -29,6 +29,7 @@ orbitDesktop.prototype.initializePersonalResearch = function(target,url,cache){ return false; }) } + o.enableSharing("div.share_mode"); } this.initializePersonalResearch.researchDelete = function(data,dom){ var parent = dom.parent().parent().parent(); diff --git a/vendor/built_in_modules/personal_research/app/controllers/panel/personal_research/back_end/researchs_controller.rb b/vendor/built_in_modules/personal_research/app/controllers/panel/personal_research/back_end/researchs_controller.rb index b7c12ae8c..0460a0729 100644 --- a/vendor/built_in_modules/personal_research/app/controllers/panel/personal_research/back_end/researchs_controller.rb +++ b/vendor/built_in_modules/personal_research/app/controllers/panel/personal_research/back_end/researchs_controller.rb @@ -150,7 +150,7 @@ class Panel::PersonalResearch::BackEnd::ResearchsController < OrbitBackendContro respond_to do |format| format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Research")) } - + format.json { render json: {"success"=>true}.to_json} end end diff --git a/vendor/built_in_modules/personal_research/app/helpers/panel/personal_research/desktop/personal_researchs_helper.rb b/vendor/built_in_modules/personal_research/app/helpers/panel/personal_research/desktop/personal_researchs_helper.rb index 4327faa66..0f86c564d 100644 --- a/vendor/built_in_modules/personal_research/app/helpers/panel/personal_research/desktop/personal_researchs_helper.rb +++ b/vendor/built_in_modules/personal_research/app/helpers/panel/personal_research/desktop/personal_researchs_helper.rb @@ -2,23 +2,27 @@ module Panel::PersonalResearch::Desktop::PersonalResearchsHelper def publication_record publication, view content_tag :li, "item" => "true", - :class => "list_t_item #{view.blank? ? '' : "#{view}_view" }" do - marker + \ + "item" => "true", + "data-id" => publication.id.to_s, + :class => "list_t_item #{view.blank? ? '' : "#{view}_view" } #{publication.is_hidden? ? "private" : "public" }" do + marker(publication.id) + \ content(publication, view) + \ edit_or_delete(publication) end end - def marker + def marker id content_tag :div, :class => "list_item_action" do content_tag(:a, "",:href=>"", :class => "icon-check-empty", "toggle-onclick"=>"icon-check-empty icon-check", + "data-id" => id.to_s, "ajax-remote"=>"false") + \ content_tag(:a, "",:href=>"", :class => "icon-star-empty", "toggle-onclick"=>"icon-star-empty icon-star", + "data-id" => id.to_s, "ajax-remote"=>"false") end end diff --git a/vendor/built_in_modules/personal_research/app/views/panel/personal_research/desktop/personal_researchs/index.html.erb b/vendor/built_in_modules/personal_research/app/views/panel/personal_research/desktop/personal_researchs/index.html.erb index fbd3de4af..3da2fcb64 100644 --- a/vendor/built_in_modules/personal_research/app/views/panel/personal_research/desktop/personal_researchs/index.html.erb +++ b/vendor/built_in_modules/personal_research/app/views/panel/personal_research/desktop/personal_researchs/index.html.erb @@ -50,25 +50,10 @@
    Share
    -
    + -
    -
    -
    New Share
    -
    From 622534e5db41bf60e5cc86c1a474114a859c7522 Mon Sep 17 00:00:00 2001 From: chris Date: Thu, 26 Sep 2013 20:18:34 +0800 Subject: [PATCH 6/6] Fix user order: - gender color - add cancel button for input --- app/assets/stylesheets/lib/main-list.css | 7 +++++++ .../admin/users_new_interface/edit_order.html.erb | 11 ++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/app/assets/stylesheets/lib/main-list.css b/app/assets/stylesheets/lib/main-list.css index 0d56d37f1..057fb2d93 100644 --- a/app/assets/stylesheets/lib/main-list.css +++ b/app/assets/stylesheets/lib/main-list.css @@ -39,6 +39,13 @@ .main-list td { background-color: #FFFFFF; } +.main-list td input[type="text"] { + margin-bottom: 0; + margin-left: -.4em; + margin-right: 3px; + padding: 0 .3em; + width: 4em; +} .main-list td.action { vertical-align: middle; text-align: right; diff --git a/app/views/admin/users_new_interface/edit_order.html.erb b/app/views/admin/users_new_interface/edit_order.html.erb index 3ea93f075..078eb8f2f 100644 --- a/app/views/admin/users_new_interface/edit_order.html.erb +++ b/app/views/admin/users_new_interface/edit_order.html.erb @@ -1,13 +1,16 @@ <% content_for :side_bar do %> <%= render :partial => 'admin/users_new_interface/side_bar' %> <% end %> +<% content_for :page_specific_css do -%> + <%= stylesheet_link_tag "lib/member" %> +<% end -%>
    - + @@ -30,10 +33,16 @@ var _userPosition = []; $('#member-list').on(clickEvent, '.edit_position', function(e){ var $input = $(''); + var $cross = $(''); + $(this).after($cross); $(this).after($input); $(this).hide(); $input.val($(this).text()).attr('id', $(this).data('user-id')); e.preventDefault(); + $cross.click(function(event) { + $input.remove(); + $(this).siblings('a').show().end().remove(); + }); }); $('.bottomnav').on(clickEvent, '.btn', function(e) {
    <%= t(:position) %><%= t(:position) %> <%= t(:name) %> <%= t(:email) %>