Name

global.ScrumAjaxDragCheckerProduct

Description

ScrumAjaxDragCheckerProduct

Script

var ScrumAjaxDragCheckerProduct = Class.create();
ScrumAjaxDragCheckerProduct.prototype = Object.extendsObject(AbstractAjaxListDragChecker, {
 draft_state: -6,

 isDragEnabledForItem: function(record){ 
    if (!this.hasPermission(record))
       return false;    
    //else if (record.state == this.draft_state)
       //return false;
    else
       return true;
 },

 hasPermission: function(record){
    return ScrumSecurityManager.canWriteStoryDotRelease(record);
 },

 getDisabledMessageForItem: function(record){
    if (!this.hasPermission(record))
       return gs.getMessage("Cannot move because you do not have permission");
    //else if (record.state == this.draft_state)
       //return gs.getMessage("Cannot move because this Story is in 'Draft' state");
    else
       return "";
 },

 getTableName: function(){
    return "rm_story";
 }
});

Sys ID

3a439a48ff301000dadaefff0efe1e68

Offical Documentation

Official Docs: