#48 A wrong project static link
This commit is contained in:
parent
c2f9b9f117
commit
446c38d83d
@ -24,6 +24,7 @@ var linksSpan = $("#dmsf_links_fields");
|
||||
var linkId = "<%= @dmsf_link.id %>";
|
||||
var linkName = "<%= @dmsf_link.name %>";
|
||||
var title = "<%= l(:label_dmsf_wokflow_action_assign) %>";
|
||||
var project = "<%= @project.identifier %>"
|
||||
var awf = false;
|
||||
|
||||
<% file = @dmsf_link.target_file %>
|
||||
@ -34,4 +35,4 @@ var awf = false;
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
dmsfAddLink(linksSpan, linkId, linkName, title, awf);
|
||||
dmsfAddLink(linksSpan, linkId, linkName, title, project, awf);
|
||||
|
||||
@ -52,10 +52,11 @@
|
||||
:data => {
|
||||
:max_file_size => Setting.attachment_max_size.to_i.kilobytes,
|
||||
:max_file_size_message => l(:error_attachment_too_big,
|
||||
:max_size => number_to_human_size(Setting.attachment_max_size.to_i.kilobytes)),
|
||||
:max_size => number_to_human_size(Setting.attachment_max_size.to_i.kilobytes)),
|
||||
:max_concurrent_uploads => Redmine::Configuration['max_concurrent_ajax_uploads'].to_i,
|
||||
:upload_path => dmsf_uploads_path(:format => 'js'),
|
||||
:description_placeholder => l(:label_optional_description)
|
||||
:description_placeholder => l(:label_optional_description),
|
||||
:project => "#{@project.identifier}"
|
||||
} %>
|
||||
(<%= l(:label_max_size) %>: <%= number_to_human_size(Setting.attachment_max_size.to_i.kilobytes) %>)
|
||||
</span>
|
||||
|
||||
@ -18,6 +18,6 @@
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
%>
|
||||
|
||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'assign', :locals => {:workflow => @dmsf_workflow}) %>');
|
||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'assign') %>');
|
||||
showModal('ajax-modal', '30%');
|
||||
$('#ajax-modal').addClass('assignment');
|
||||
@ -19,7 +19,7 @@
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
function dmsfAddLink(linksSpan, linkId, linkName, title, awf) {
|
||||
function dmsfAddLink(linksSpan, linkId, linkName, title, project, awf) {
|
||||
|
||||
if (linksSpan.children().length < 10) {
|
||||
|
||||
@ -35,7 +35,7 @@ function dmsfAddLink(linksSpan, linkId, linkName, title, awf) {
|
||||
if(awf) {
|
||||
|
||||
linkSpan.append($('<a> </a>').attr({
|
||||
href: "/dmsf_workflows/c1/assign?dmsf_link_id=" + linkId,
|
||||
href: "/dmsf_workflows/" + project + "/assign?dmsf_link_id=" + linkId,
|
||||
'class': 'icon icon-wf-none', 'data-remote': 'true', 'title': title
|
||||
}));
|
||||
}
|
||||
@ -70,7 +70,7 @@ function dmsfAddFile(inputEl, file, eagerUpload) {
|
||||
placeholder: $(inputEl).data('description-placeholder')
|
||||
}).toggle(!eagerUpload),
|
||||
$('<a> </a>').attr({href: "#", 'class': 'remove-upload icon icon-del'}).click(dmsfRemoveFile).toggle(!eagerUpload),
|
||||
$('<a> </a>').attr({href: "/dmsf_workflows/c1/assign?attachment_id=" + attachmentId,
|
||||
$('<a> </a>').attr({href: "/dmsf_workflows/" + $(inputEl).attr('data-project') + "/assign?attachment_id=" + attachmentId,
|
||||
'class': 'icon icon-wf-none', 'data-remote': 'true'})
|
||||
).appendTo('#dmsf_attachments_fields');
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user