Merge branch 'finn-master' of https://dev.finn.de/git/redmine-backlogs into finn-master

pull/6827/head
Stephan Eckardt 14 years ago
commit 2caca36e6a
  1. 2
      app/controllers/rb_statistics_controller.rb
  2. 15
      app/helpers/rb_common_helper.rb
  3. 10
      app/views/rb_burndown_charts/_burndown.html.erb
  4. 3
      app/views/rb_statistics/show.html.erb
  5. 11
      app/views/shared/_backlogs_header.html.erb
  6. 2
      app/views/shared/_settings.html.erb
  7. 6
      assets/javascripts/app/model.js
  8. 2
      assets/javascripts/app/taskboard.js
  9. 5
      lib/backlogs_hooks.rb

@ -1,4 +1,4 @@
class RbStatisticsController < ApplicationController
class RbStatisticsController < RbApplicationController
unloadable
before_filter :authorize_global

@ -101,4 +101,19 @@ module RbCommonHelper
def remaining_hours(item)
item.remaining_hours.blank? || item.remaining_hours==0 ? "" : item.remaining_hours
end
def javascript_include_tag_backlogs(*args)
min = RAILS_ENV == 'development' ? "" : ".min"
args.each do |jsfile|
jsfile.gsub!('jquery.js', "jquery-1.5.1#{min}.js")
jsfile.gsub!('jquery-ui.js', "jquery-ui-1.8.11.custom.min.js")
jsfile.gsub!('jquery.jeditable.js', "jquery.jeditable.mini.js")
jsfile.gsub!('excanvas.js', "excanvas#{min}.js")
jsfile.gsub!('jquery.jqplot.js', "jquery.jqplot#{min}.js")
end
args.push(:plugin => 'redmine_backlogs')
javascript_include_tag *args
end
end

@ -3,11 +3,11 @@
<%= stylesheet_link_tag 'jqplot.css', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag 'jquery-1.4.2.min.js', :plugin => 'redmine_backlogs' %>
<!--[if IE]><%= javascript_include_tag 'jquery.jqplot/excanvas.js', :plugin => 'redmine_backlogs' %><![endif]-->
<%= javascript_include_tag 'jquery.jqplot/jquery.jqplot.js', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag 'jquery.jqplot/plugins/jqplot.highlighter.js', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag 'jquery.cookies.2.2.0.min.js', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag_backlogs 'lib/jquery.js' %>
<!--[if IE]><%= javascript_include_tag_backlogs 'jquery.jqplot/excanvas.js' %><![endif]-->
<%= javascript_include_tag_backlogs 'lib/jquery.cookies.js',
'lib/jquery.jqplot/jquery.jqplot.js',
'lib/jquery.jqplot/plugins/jqplot.highlighter.js' %>
<style type="text/css" media="screen">
.jqplot-axis {

@ -1,6 +1,7 @@
<%- content_for :header_tags do %>
<%= stylesheet_link_tag 'rb_default/statistics', 'rb_default/jquery-ui', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag 'jquery-1.4.2.min.js', 'jquery-ui-1.8rc3.custom.min.js', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag_backlogs 'lib/jquery.js',
'lib/jquery-ui.js' %>
<%- end %>
<script>

@ -2,12 +2,11 @@
<%= stylesheet_link_tag 'global.css', 'jquery-ui.css', :media => 'print,screen', :plugin => 'redmine_backlogs' %>
<%= stylesheet_link_tag 'global_print.css', :media => 'print', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag 'lib/jquery-1.5.1.min.js',
'lib/jquery-ui-1.8.11.custom.min.js',
'lib/jquery.jeditable.mini.js',
'lib/jquery.cookie.js',
'app/common.js',
:plugin => 'redmine_backlogs' %>
<%= javascript_include_tag_backlogs 'lib/jquery.js',
'lib/jquery-ui.js',
'lib/jquery.jeditable.mini.js',
'lib/jquery.cookie.js',
'app/common.js' %>
<%= javascript_tag "jQuery.noConflict();" %>
<% end %>

@ -1,5 +1,5 @@
<% content_for :header_tags do %>
<%= javascript_include_tag 'jquery-1.4.2.min.js', :plugin => 'redmine_backlogs' %>
<%= javascript_include_tag 'lib/jquery-1.5.1.min.js', :plugin => 'redmine_backlogs' %>
<script type="text/javascript">
jQuery.noConflict();

@ -112,9 +112,9 @@ RB.Model = (function ($) {
fieldLabel = field.attr('fieldlabel');
fieldType = field.attr('fieldtype') || 'input';
if (!fieldLabel) {
fieldLabel = fieldName.replace(/_/ig, " ").replace(/ id$/ig, "");
}
if (!fieldLabel) {
fieldLabel = fieldName.replace(/_/ig, " ").replace(/ id$/ig, "");
}
$("<label></label>").text(fieldLabel).appendTo(editor);

@ -19,7 +19,7 @@ RB.Taskboard = (function ($) {
// Initialize column widths
this.colWidthUnit = $(".swimlane").width();
this.defaultColWidth = 2;
this.defaultColWidth = 1;
this.loadColWidthPreference();
this.updateColWidths();

@ -5,6 +5,7 @@ module BacklogsPlugin
# the entire queries toolbar is disabled if you don't have
# custom queries
include RbCommonHelper
def view_issues_sidebar_planning_bottom(context={ })
locals = {}
locals[:sprints] = context[:project] ? Sprint.open_sprints(context[:project]) : []
@ -72,7 +73,7 @@ module BacklogsPlugin
snippet += '</p>'
if issue.descendants.length != 0
snippet += javascript_include_tag 'jquery-1.4.2.min.js', :plugin => 'redmine_backlogs'
snippet += javascript_include_tag_backlogs 'lib/jquery.js'
snippet += <<-generatedscript
<script type="text/javascript">
@ -125,7 +126,7 @@ module BacklogsPlugin
# this wouldn't be necesary if the schedules plugin
# didn't disable the contextual hook
snippet += javascript_include_tag 'jquery-1.4.2.min.js', :plugin => 'redmine_backlogs'
snippet += javascript_include_tag_backlogs 'lib/jquery.js'
snippet += <<-generatedscript
<script type="text/javascript">

Loading…
Cancel
Save