Skip to Content
author's profile photo Former Member
Former Member

How to make the Draggable element to get visible on top of all the element in the screen while dragging?

Hi All,

I am having a requirement to implement the drag and drop feature in SAPUI5 Table and Tree Table.

I am having a table with set of names which should be able to drag and a Tree Table which should accept the dragging object, so it is defined as a drop area.

I Used JqueryUI to make the controls as drag and drop which is working fine.

Ques 1.jpg

Ques 2.jpg

Ques 3.jpg

The problem is when I drag the name towards the Tree Table it is getting hide behind the table which makes the user confused.

When I go through the code, I found out that this issue occurs due to the position related to CSS, which is applied default in SAPUI5.

Ques 4.jpg

Ques 5.jpg

Ques 6.jpg

code for drag and drop is below


var oMemberId;
$(".selector Table").draggable({
helper: "clone",
cursor: "pointer",
revert: "invalid",
zIndex: 9999,
start: function(event) {
oSelectedId = this.parentNode.previousSibling.firstChild.childNodes[0].value;
}
}).disableSelection();

$(".selector treetable").droppable({
drop: function(event){
var dataLevel=(this.attributes["data-sap-ui-level"].value);
var oDropAreaId = this.childNodes[2].textContent;
}
}).disableSelection();


Please provide me an alternative solution.

Thanks in advance,

Aravindh

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on May 13, 2014 at 09:39 AM

    var oMemberId;
    $(".selector Table").draggable({
    helper: "clone",
    cursor: "pointer",
    revert: "invalid",
    zIndex: 9999,
    start: function(event) {
    oSelectedId =this.parentNode.previousSibling.firstChild.childNodes[0].value;
    },

    drag: function(event) {
    $(".selector Table div.sapUiTableCnt,.selector Table div.sapUiTableCtrlScr").css("overflow","visible");
    },


    }).disableSelection();

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on May 06, 2014 at 11:50 AM

    zIndex of table is 9999 which might be causing this problem. The zIndex value of what you drag must be greater than that of the table so that it appears above the table.

    Regards

    Sakthivel

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.