Fixes issue #2274 - Datepicker in bulk action not usable in bulk action if ticket list is longer the one page.
This commit is contained in:
parent
265d60a65f
commit
149a086aab
3 changed files with 15 additions and 6 deletions
|
@ -37,6 +37,8 @@ class App.UiElement.basedate
|
|||
rtl: App.i18n.dir() is 'rtl'
|
||||
container: item
|
||||
language: 'custom'
|
||||
orientation: attribute.orientation
|
||||
disableScroll: attribute.disableScroll
|
||||
)
|
||||
|
||||
@setNewTimeInitial(item, attribute)
|
||||
|
|
|
@ -1357,6 +1357,10 @@ class BulkForm extends App.Controller
|
|||
localAttribute.null = true
|
||||
@configure_attributes_ticket.push localAttribute
|
||||
|
||||
time_attribute = _.findWhere(@configure_attributes_ticket, {'name': 'pending_time'})
|
||||
time_attribute.orientation = 'top'
|
||||
time_attribute.disableScroll = true
|
||||
|
||||
@holder = @options.holder
|
||||
@visible = false
|
||||
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
- added rerender method to show correct today if task is longer open the 24 hours
|
||||
- scroll into view
|
||||
- fix vertical auto position
|
||||
- disableScroll flag to
|
||||
*/
|
||||
|
||||
(function(factory){
|
||||
|
@ -767,13 +768,15 @@
|
|||
});
|
||||
}
|
||||
|
||||
// adjust scroll of scrollParent
|
||||
var scrollParent = this.picker.scrollParent();
|
||||
var bottomEdge = offset.top + height + this.picker.outerHeight();
|
||||
var scrollBottomEdge = scrollParent.scrollTop() + scrollParent.height();
|
||||
if(!this.o.disableScroll) {
|
||||
// adjust scroll of scrollParent
|
||||
var scrollParent = this.picker.scrollParent();
|
||||
var bottomEdge = offset.top + height + this.picker.outerHeight();
|
||||
var scrollBottomEdge = scrollParent.scrollTop() + scrollParent.height();
|
||||
|
||||
if(bottomEdge > scrollBottomEdge){
|
||||
scrollParent.scrollTop(scrollParent.scrollTop() + (bottomEdge - scrollBottomEdge) + 10);
|
||||
if(bottomEdge > scrollBottomEdge){
|
||||
scrollParent.scrollTop(scrollParent.scrollTop() + (bottomEdge - scrollBottomEdge) + 10);
|
||||
}
|
||||
}
|
||||
|
||||
return this;
|
||||
|
|
Loading…
Reference in a new issue