forked from saurabh/personal-book
fix layout and member list
This commit is contained in:
parent
266ee87fc5
commit
00ec7b9177
|
@ -1,5 +1,6 @@
|
|||
class Admin::BooksController < OrbitMemberController
|
||||
include Admin::JournalPapersHelper
|
||||
layout "member_plugin"
|
||||
|
||||
before_action :set_book, only: [:show, :edit , :update, :destroy]
|
||||
before_action :get_plugins, only: [:index, :book_setting, :new, :create, :edit, :update]
|
||||
|
|
|
@ -58,7 +58,11 @@ class Book
|
|||
members = MemberProfile.all
|
||||
member_data = []
|
||||
members.each do |m|
|
||||
member_data << {"memberId" => m.id.to_s, "memberName" => m.name}
|
||||
if (m.first_name || m.last_name)
|
||||
member_data << {"memberId" => m.id.to_s, "memberName" => m.name}
|
||||
else
|
||||
member_data << {"memberId" => m.id.to_s, "memberName" => "No Name"}
|
||||
end
|
||||
end
|
||||
member_data.to_json
|
||||
end
|
||||
|
|
|
@ -1,15 +1,4 @@
|
|||
<% # encoding: utf-8 %>
|
||||
|
||||
<% content_for :side_bar do %>
|
||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:user), :link_url => admin_site_site_info_path(site_id: current_site.id), :icon => 'icons-users', :side_bar_content => 'admin/members/side_bar'} %>
|
||||
<% end %>
|
||||
|
||||
<div class="subnav">
|
||||
|
||||
<%= render :partial => 'admin/personal_plugins/plugin_list' %>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="isotope">
|
||||
<div class="item element">
|
||||
<div class="detail w-a h-a">
|
||||
|
|
|
@ -1,13 +1,3 @@
|
|||
<% content_for :side_bar do %>
|
||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:user), :link_url => admin_site_site_info_path(current_site), :icon => 'icons-users', :side_bar_content => 'admin/members/side_bar'} %>
|
||||
<% end %>
|
||||
|
||||
<div class="subnav">
|
||||
|
||||
<%= render :partial => 'admin/personal_plugins/plugin_list' %>
|
||||
|
||||
</div>
|
||||
|
||||
<%= form_for @book, url: admin_book_path(@book), html: {class: "form-horizontal main-forms previewable"} do |f| %>
|
||||
<fieldset>
|
||||
<%= render partial: 'form', locals: {f: f} %>
|
||||
|
|
|
@ -1,11 +1,3 @@
|
|||
<% content_for :side_bar do %>
|
||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:user), :link_url => admin_site_site_info_path(current_site), :icon => 'icons-users', :side_bar_content => 'admin/members/side_bar'} %>
|
||||
<% end %>
|
||||
|
||||
<div class="subnav">
|
||||
<%= render :partial => 'admin/personal_plugins/plugin_list' %>
|
||||
</div>
|
||||
|
||||
<table class="table main-list">
|
||||
<thead>
|
||||
<tr>
|
||||
|
|
|
@ -1,13 +1,3 @@
|
|||
<% content_for :side_bar do %>
|
||||
<%= render :partial => 'layouts/side_bar', :locals => {:link_name => t(:user), :link_url => admin_site_site_info_path(current_site), :icon => 'icons-users', :side_bar_content => 'admin/members/side_bar'} %>
|
||||
<% end %>
|
||||
|
||||
<div class="subnav">
|
||||
|
||||
<%= render :partial => 'admin/personal_plugins/plugin_list' %>
|
||||
|
||||
</div>
|
||||
|
||||
<%= form_for @book, url: admin_books_path, html: {class: "form-horizontal main-forms previewable"} do |f| %>
|
||||
<fieldset>
|
||||
<%= render partial: 'form', locals: {f: f} %>
|
||||
|
|
Loading…
Reference in New Issue