加入班级,项目弹框定位js重写

This commit is contained in:
Tim 2016-08-01 15:21:23 +08:00
parent 1eff394498
commit 08b8e3f1cb
5 changed files with 2328 additions and 2305 deletions

View File

@ -1,3 +1,3 @@
var htmlvalue = "<%= escape_javascript(render :partial => 'applied_join_project', locals: {:project_id => (@project.nil? ? nil : @project.id)}) %>";
pop_box_new(htmlvalue,460,40,50);
pop_box_new(htmlvalue,460,190);

View File

@ -2,4 +2,4 @@
$("#join_in_project_applied").html('<%= escape_javascript( render :partial => 'projects/applied_status') %>');
<% end %>
var htmlvalue = "<%= escape_javascript(render :partial => 'applied_project/applied_project_tip') %>";
pop_box_new(htmlvalue,380,40,50);
pop_box_new(htmlvalue,380,166);

View File

@ -1,2 +1,2 @@
var htmlvalue = "<%= escape_javascript(render :partial => 'join_private_course') %>";
pop_box_new(htmlvalue,460,40,50);
pop_box_new(htmlvalue,460,220);

File diff suppressed because it is too large Load Diff

View File

@ -1493,13 +1493,18 @@ function pop_up_box(value,tWidth,tTop,tLeft){
}
// 公共弹框样式
function pop_box_new(value, Width, Top, Left){
function pop_box_new(value, Width, Height){
w = ($(window).width() - Width)/2;
h = ($(window).height() - Height)/2;
$("#ajax-modal").html(value);
showModal('ajax-modal', Width + 'px');
$('#ajax-modal').siblings().remove();
$('#ajax-modal').parent().css({"top": Top+"%","left": Left+"%","transform":"translate(-50%,-50%)","padding":"0","border":"none"});
$('#ajax-modal').parent().css({"top": h+"px","left": w+"px","padding":"0","border":"none","position":"fixed"});
$('#ajax-modal').css({"padding":"0"});
//拖拽
$
}
// 公共提示弹框样式