Subversion Repositories DevTools

Rev

Rev 6697 | Rev 6971 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6697 Rev 6873
Line 118... Line 118...
118
}
118
}
119
 
119
 
120
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
120
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
121
// Compatability function
121
// Compatability function
122
//      Confirm Deletion of an item
122
//      Confirm Deletion of an item
-
 
123
//      Assumes that the item is within an 
123
//      Assumes that the item is within an 'anchor' and that an href can be located
124
//          - 'anchor' and that an href can be located
-
 
125
//          - other and that a 'data-href' will specify the 'url'
-
 
126
//  
124
//      Uses VixConfirm to do the heavy lifting
127
//      Uses VixConfirm to do the heavy lifting
125
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
128
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
126
function vixConfirmDelete (txt)
129
function vixConfirmDelete (txt)
127
{
130
{
128
    var href = window.event.currentTarget.href;
131
    var href = window.event.currentTarget.href;
-
 
132
    if ( !href ) {
-
 
133
        href = $(event.currentTarget).data('href');
-
 
134
    }
129
    vixConfirm('Are you sure you want to delete '+ txt +'?', {url : href})
135
    vixConfirm('Are you sure you want to delete ' + txt + '?', { url: href })
130
    return false;
136
    return false;
131
}
137
}
132
 
138
 
133
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
139
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
134
//  Similar to 'alert', but uses the jquery dialog mechnaism
140
//  Similar to 'alert', but uses the jquery dialog mechnaism