dev_local
jasder 6 years ago
parent cd0d8d9a35
commit 367b3a6197

@ -1174,7 +1174,7 @@ end
def partners def partners
@menu_type = 6 @menu_type = 6
@sub_type = 3 @sub_type = 3
@partners = Partner.includes(:school) @partners = Partner.includes(:school).order("created_at desc")
end end
def all_partners def all_partners
@ -1219,6 +1219,7 @@ end
school.save school.save
end end
render :json => {status: 1, message: "创建成功!"} render :json => {status: 1, message: "创建成功!"}
redirects_to partners_path
end end
end end
@ -1265,6 +1266,10 @@ end
@members = paginateHelper @members, 8 @members = paginateHelper @members, 8
end end
def add_partner_member
end
# check 部门 identifier是否重复 # check 部门 identifier是否重复
def check_depart_identifier def check_depart_identifier
logger.info("###############{params}") logger.info("###############{params}")

@ -34,7 +34,7 @@
</p> </p>
<div class="edu-back-skyblue clearfix pl10 over280" id="serch_user_list"> <div class="edu-back-skyblue clearfix pl10 over280" id="serch_user_list">
<%= form_for @partner, :url => add_depart_member_managements_path,:html => {:id => 'add_depart_member_form', :remote => true, :method => :post} do |f| %> <%= form_for "", :url => add_partner_member_managements_path,:html => {:id => 'add_partner_member_form', :remote => true, :method => :post} do |f| %>
<% @members.each do |member| %> <% @members.each do |member| %>
<p class="clearfix"> <p class="clearfix">
<span class="fl edu-txt-w90"> <span class="fl edu-txt-w90">

@ -21,7 +21,9 @@
<div class="clearfix"> <div class="clearfix">
<span class="mr45 color-grey-9 fl">管理员</span> <span class="mr45 color-grey-9 fl">管理员</span>
<ul class="manageList"> <ul class="manageList">
<li><a href="javascript:void(0)" class="addManage">+</a></li> <li>
<%= link_to '+', add_partner_member_box_managements_path(:partner => 1), :remote => true, :class => "addManage" %>
</li>
<li><img src="https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=105293018,2500805440&fm=27&gp=0.jpg"/><a href="javascript:void(0)" class="removeImg"><i class="iconfont icon-htmal5icon19 color-grey-9"></i></a></li> <li><img src="https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=105293018,2500805440&fm=27&gp=0.jpg"/><a href="javascript:void(0)" class="removeImg"><i class="iconfont icon-htmal5icon19 color-grey-9"></i></a></li>
</ul> </ul>
</div> </div>
@ -65,10 +67,6 @@
pop_box_new(html,572,500); pop_box_new(html,572,500);
}) })
$(".manageList").on("click",".addManage",function(){
var html="<%= escape_javascript(render :partial => "managements/partner_addManage") %>";
pop_box_new(html,572,500);
})
}) })
</script> </script>

@ -555,6 +555,7 @@ RedmineApp::Application.routes.draw do ## oauth相关
match 'departments', :via => [:get, :post] match 'departments', :via => [:get, :post]
get 'partners' get 'partners'
get 'add_partner_member_box' get 'add_partner_member_box'
post 'add_partner_member'
get 'all_partners' get 'all_partners'
post 'add_partner' post 'add_partner'
delete 'delete_depart_member' delete 'delete_depart_member'

Loading…
Cancel
Save