Skip to content
Browse files

#542 warn user if tasks workflow has no states

  • Loading branch information...
1 parent 8cb083e commit 43934d302d10fae26d8f29d7de2ca0ff092aa1d0 @patrickatamaniuk patrickatamaniuk committed May 19, 2012
Showing with 6 additions and 1 deletion.
  1. +6 −1 assets/javascripts/taskboard.js
View
7 assets/javascripts/taskboard.js
@@ -21,8 +21,13 @@ RB.Taskboard = RB.Object.create(RB.Model, {
self.updateColWidths();
RB.$("#col_width input").bind('keyup', function(e){ if(e.which==13) self.updateColWidths() });
+ var tasks_lists = j.find("#tasks .list");
+ if (!tasks_lists || !tasks_lists.length) {
+ alert("There are no task states. Please check the workflow of your tasks tracker in the administration section.");
+ return;
+ }
// Initialize task lists
- j.find("#tasks .list").sortable({
+ tasks_lists.sortable({
connectWith: '#tasks .list',
placeholder: 'placeholder',
start: self.dragStart,

0 comments on commit 43934d3

Please sign in to comment.
Something went wrong with that request. Please try again.