解决上传图片问题
This commit is contained in:
parent
c83eefbbaa
commit
320ed07b31
|
@ -62,9 +62,9 @@
|
||||||
|
|
||||||
<!--add by huang-->
|
<!--add by huang-->
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function orge_new_files_upload()
|
function org_new_files_upload()
|
||||||
{
|
{
|
||||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'files/upload_org_new_files',:locals => {:org => @organization, :org_attachment_type => 1}) %>');
|
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'files/upload_org_new_files',:locals => {:org => @organization, :org_attachment_type => 0}) %>');
|
||||||
showModal('ajax-modal', '513px');
|
showModal('ajax-modal', '513px');
|
||||||
$('#ajax-modal').siblings().remove();
|
$('#ajax-modal').siblings().remove();
|
||||||
$('#ajax-modal').before("<a href='javascript:void(0)' onclick='hideModal()' style='margin-left: 480px;'><img src='/images/bid/close.png' width='26px' height='26px' /></a>");
|
$('#ajax-modal').before("<a href='javascript:void(0)' onclick='hideModal()' style='margin-left: 480px;'><img src='/images/bid/close.png' width='26px' height='26px' /></a>");
|
||||||
|
@ -72,7 +72,7 @@
|
||||||
$('#ajax-modal').parent().addClass("popbox_polls");
|
$('#ajax-modal').parent().addClass("popbox_polls");
|
||||||
}
|
}
|
||||||
|
|
||||||
function orge_new_files_banner_upload()
|
function org_new_files_banner_upload()
|
||||||
{
|
{
|
||||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'files/upload_org_new_files_banner',:locals => {:org => @organization, :org_attachment_type => 1}) %>');
|
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'files/upload_org_new_files_banner',:locals => {:org => @organization, :org_attachment_type => 1}) %>');
|
||||||
showModal('ajax-modal', '513px');
|
showModal('ajax-modal', '513px');
|
||||||
|
@ -89,12 +89,20 @@
|
||||||
<div class="header-con">
|
<div class="header-con">
|
||||||
<% if User.current.admin_of_org?(@organization) %>
|
<% if User.current.admin_of_org?(@organization) %>
|
||||||
<div class="logo fl">
|
<div class="logo fl">
|
||||||
|
<% if @org_logo_attchment.blank? %>
|
||||||
<a class="logo-img"><img src="/images/org_new_style/logo.jpg" alt=""/></a>
|
<a class="logo-img"><img src="/images/org_new_style/logo.jpg" alt=""/></a>
|
||||||
<a href="" class="logo-add" title="点击替换LOGO" onclick="orge_new_files_upload();"></a>
|
<% else %>
|
||||||
|
<img src="/attachments/<%= @org_logo_attchment.id %>/<%= @org_logo_attchment.filename %>" class="logo-img">
|
||||||
|
<% end %>
|
||||||
|
<a href="#" class="logo-add" title="点击替换LOGO" onclick="org_new_files_upload();"></a>
|
||||||
</div>
|
</div>
|
||||||
<% else %>
|
<% else %>
|
||||||
<div class="logo fl">
|
<div class="logo fl">
|
||||||
|
<% if @org_logo_attchment.blank? %>
|
||||||
<a class="logo-img"><img src="/images/org_new_style/logo.jpg" alt=""/></a>
|
<a class="logo-img"><img src="/images/org_new_style/logo.jpg" alt=""/></a>
|
||||||
|
<% else %>
|
||||||
|
<img src="/attachments/<%= @org_logo_attchment.id %>/<%= @org_logo_attchment.filename %>" class="logo-img">
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= render :partial => 'organizations/org_logined_header' %>
|
<%= render :partial => 'organizations/org_logined_header' %>
|
||||||
|
@ -140,7 +148,7 @@
|
||||||
<% else %>
|
<% else %>
|
||||||
<img src="/attachments/<%= @org_banner_attchment.id %>/<%= @org_banner_attchment.filename %>" class="banner-img">
|
<img src="/attachments/<%= @org_banner_attchment.id %>/<%= @org_banner_attchment.filename %>" class="banner-img">
|
||||||
<% end %>
|
<% end %>
|
||||||
<a href="#" class="banner-add" title="点击替换图片" onclick="orge_new_files_banner_upload();"></a>
|
<a href="#" class="banner-add" title="点击替换图片" onclick="org_new_files_banner_upload();"></a>
|
||||||
<div class="banner-txt">
|
<div class="banner-txt">
|
||||||
<p ><%= @organization.name %></p>
|
<p ><%= @organization.name %></p>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue