diff options
author | zhangab <zhanganbing@chinamobile.com> | 2018-04-18 09:11:56 +0800 |
---|---|---|
committer | zhangab <zhanganbing@chinamobile.com> | 2018-04-18 09:12:03 +0800 |
commit | d698af153772ca4351ad3b23fbb987fc749890af (patch) | |
tree | 8fa49f10523134f9596814ef7a30528e298ac660 /usecaseui-common/src/main/webapp/static/fusion/raptor/js/persist_table_header.js | |
parent | ffffd8a35ae5fcea703a7427844037c07c232b92 (diff) |
Fix Security/Vulnerability problems
Change-Id: Ie0f2c9e0794941d9b9a7f00a6c3d349269d98ed1
Issue-ID: USECASEUI-104
Signed-off-by: zhangab <zhanganbing@chinamobile.com>
Diffstat (limited to 'usecaseui-common/src/main/webapp/static/fusion/raptor/js/persist_table_header.js')
-rw-r--r-- | usecaseui-common/src/main/webapp/static/fusion/raptor/js/persist_table_header.js | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/usecaseui-common/src/main/webapp/static/fusion/raptor/js/persist_table_header.js b/usecaseui-common/src/main/webapp/static/fusion/raptor/js/persist_table_header.js deleted file mode 100644 index 2c90306f..00000000 --- a/usecaseui-common/src/main/webapp/static/fusion/raptor/js/persist_table_header.js +++ /dev/null @@ -1,47 +0,0 @@ - function UpdateTableHeaders() { - $("div.divTableWithFloatingHeader").each(function() { - var originalHeaderRow = $(".tableFloatingHeaderOriginal", this); - var floatingHeaderRow = $(".tableFloatingHeader", this); - var offset = $(this).offset(); - var scrollTop = $(window).scrollTop(); - if ((scrollTop > offset.top) && (scrollTop < offset.top + $(this).height())) { - floatingHeaderRow.css("visibility", "visible"); - floatingHeaderRow.css("top", Math.min(scrollTop - offset.top, $(this).height() - floatingHeaderRow.height()) + "px"); - floatingHeaderRow.css("z-index", "20"); - - // Copy cell widths from original header - $("th", floatingHeaderRow).each(function(index) { - var cellWidth = $("th", originalHeaderRow).eq(index).css('width'); - $(this).css('width', cellWidth); - }); - - // Copy row width from whole table - floatingHeaderRow.css("width", $(this).css("width")); - } - else { - floatingHeaderRow.css("visibility", "hidden"); - floatingHeaderRow.css("top", "0px"); - } - }); - } - - $(document).ready(function() { - $("table.tableWithFloatingHeader").each(function() { - $(this).wrap("<div class=\"divTableWithFloatingHeader\" style=\"position:relative\"></div>"); - - var originalHeaderRow = $("tr:first", this) - originalHeaderRow.before(originalHeaderRow.clone()); - var clonedHeaderRow = $("tr:first", this) - - clonedHeaderRow.addClass("tableFloatingHeader"); - clonedHeaderRow.css("position", "absolute"); - clonedHeaderRow.css("top", "0px"); - clonedHeaderRow.css("left", $(this).css("margin-left")); - clonedHeaderRow.css("visibility", "hidden"); - - originalHeaderRow.addClass("tableFloatingHeaderOriginal"); - }); - UpdateTableHeaders(); - $(window.parent).scroll(UpdateTableHeaders); - $(window.parent).resize(UpdateTableHeaders); - });
\ No newline at end of file |