webdav portal filter + detail view added
|
@ -7,9 +7,14 @@ namespace WebsitePanel.WebDavPortal
|
|||
// For more information on bundling, visit http://go.microsoft.com/fwlink/?LinkId=301862
|
||||
public static void RegisterBundles(BundleCollection bundles)
|
||||
{
|
||||
bundles.Add(new ScriptBundle("~/bundles/jquery").Include(
|
||||
var jQueryBundle = new ScriptBundle("~/bundles/jquery").Include(
|
||||
"~/Scripts/jquery-{version}.js",
|
||||
"~/Scripts/jquery.cookie.js"));
|
||||
"~/Scripts/jquery.cookie.js");
|
||||
|
||||
jQueryBundle.IncludeDirectory("~/Scripts", "jquery.dataTables.min.js", true);
|
||||
jQueryBundle.IncludeDirectory("~/Scripts", "dataTables.bootstrap.js", true);
|
||||
|
||||
bundles.Add(jQueryBundle);
|
||||
|
||||
bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include(
|
||||
"~/Scripts/jquery.validate*"));
|
||||
|
@ -24,21 +29,34 @@ namespace WebsitePanel.WebDavPortal
|
|||
"~/Scripts/respond.js"));
|
||||
|
||||
bundles.Add(new ScriptBundle("~/bundles/appScripts").Include(
|
||||
"~/Scripts/appScripts/recalculateResourseHeight.js",
|
||||
"~/Scripts/appScripts/uploadingData2.js",
|
||||
"~/Scripts/appScripts/authentication.js",
|
||||
"~/Scripts/appScripts/messages.js",
|
||||
"~/Scripts/appScripts/fileBrowsing.js",
|
||||
"~/Scripts/appScripts/fileBrowsing.js",
|
||||
"~/Scripts/appScripts/dialogs.js",
|
||||
"~/Scripts/appScripts/wsp.js"
|
||||
));
|
||||
|
||||
bundles.Add(new ScriptBundle("~/bundles/appScripts/storage/bigIcons").Include(
|
||||
"~/Scripts/appScripts/recalculateResourseHeight.js",
|
||||
"~/Scripts/appScripts/uploadingData2.js"
|
||||
));
|
||||
|
||||
//bundles.Add(new ScriptBundle("~/bundles/appScripts/storage/table-view").Include(
|
||||
// ));
|
||||
|
||||
bundles.Add(new ScriptBundle("~/bundles/authScripts").Include(
|
||||
"~/Scripts/appScripts/authentication.js"));
|
||||
|
||||
bundles.Add(new StyleBundle("~/Content/css").Include(
|
||||
var styleBundle = new StyleBundle("~/Content/css");
|
||||
|
||||
styleBundle.Include(
|
||||
"~/Content/bootstrap.css",
|
||||
"~/Content/site.css"));
|
||||
"~/Content/site.css");
|
||||
|
||||
styleBundle.IncludeDirectory("~/Content", "jquery.datatables.css", true);
|
||||
styleBundle.IncludeDirectory("~/Content", "dataTables.bootstrap.css", true);
|
||||
|
||||
bundles.Add(styleBundle);
|
||||
|
||||
// Set EnableOptimizations to false for debugging. For more information,
|
||||
// visit http://go.microsoft.com/fwlink/?LinkId=301862
|
||||
|
|
|
@ -26,53 +26,68 @@ namespace WebsitePanel.WebDavPortal
|
|||
|
||||
#endregion
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.DeleteFiles,
|
||||
url: "files-group-action/delete",
|
||||
defaults: new { controller = "FileSystem", action = "DeleteFiles" }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.UploadFile,
|
||||
url: "upload-file/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "UploadFile" }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.DownloadFile,
|
||||
url: "download-file/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "DownloadFile" }
|
||||
);
|
||||
#region Owa
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.ViewOfficeOnline,
|
||||
url: "office365/view/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "ViewOfficeDocument", pathPart = UrlParameter.Optional }
|
||||
defaults:
|
||||
new {controller = "FileSystem", action = "ViewOfficeDocument", pathPart = UrlParameter.Optional}
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.EditOfficeOnline,
|
||||
url: "office365/edit/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "EditOfficeDocument", pathPart = UrlParameter.Optional }
|
||||
defaults:
|
||||
new {controller = "FileSystem", action = "EditOfficeDocument", pathPart = UrlParameter.Optional}
|
||||
);
|
||||
|
||||
//routes.MapRoute(
|
||||
// name: FileSystemRouteNames.ShowOfficeOnlinePath,
|
||||
// url: "office365/{org}/{*pathPart}",
|
||||
// defaults: new { controller = "FileSystem", action = "ShowOfficeDocument", pathPart = UrlParameter.Optional }
|
||||
// );
|
||||
#endregion
|
||||
|
||||
#region Enterprise storage
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.ChangeWebDavViewType,
|
||||
url: "storage/change-view-type/{viewType}",
|
||||
defaults: new { controller = "FileSystem", action = "ChangeViewType" }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.DeleteFiles,
|
||||
url: "storage/files-group-action/delete",
|
||||
defaults: new { controller = "FileSystem", action = "DeleteFiles" }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.UploadFile,
|
||||
url: "storage/upload-file/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "UploadFile" }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.DownloadFile,
|
||||
url: "storage/download-file/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "DownloadFile" }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.ShowAdditionalContent,
|
||||
url: "show-additional-content/{*path}",
|
||||
url: "storage/show-additional-content/{*path}",
|
||||
defaults: new { controller = "FileSystem", action = "ShowAdditionalContent", path = UrlParameter.Optional }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.ShowContentDetails,
|
||||
url: "storage/details/{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "GetContentDetails", pathPart = UrlParameter.Optional }
|
||||
);
|
||||
|
||||
routes.MapRoute(
|
||||
name: FileSystemRouteNames.ShowContentPath,
|
||||
url: "{org}/{*pathPart}",
|
||||
defaults: new { controller = "FileSystem", action = "ShowContent", pathPart = UrlParameter.Optional }
|
||||
);
|
||||
);
|
||||
#endregion
|
||||
|
||||
routes.MapRoute(
|
||||
name: "Default",
|
||||
|
|
|
@ -7,7 +7,9 @@ namespace WebsitePanel.WebDavPortal.UI.Routes
|
|||
{
|
||||
public class FileSystemRouteNames
|
||||
{
|
||||
public const string ChangeWebDavViewType = "ChangeWebDavViewTypeRoute";
|
||||
public const string ShowContentPath = "ShowContentRoute";
|
||||
public const string ShowContentDetails = "ShowContentDetailsRoute";
|
||||
public const string ShowOfficeOnlinePath_ = "ShowOfficeOnlineRoute";
|
||||
public const string ViewOfficeOnline = "ViewOfficeOnlineRoute";
|
||||
public const string EditOfficeOnline = "EditOfficeOnlineRoute";
|
|
@ -0,0 +1,24 @@
|
|||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* AutoFill styles
|
||||
*/
|
||||
|
||||
div.AutoFill_filler {
|
||||
display: none;
|
||||
position: absolute;
|
||||
height: 14px;
|
||||
width: 14px;
|
||||
background: url(../images/filler.png) no-repeat center center;
|
||||
z-index: 1002;
|
||||
}
|
||||
|
||||
div.AutoFill_border {
|
||||
display: none;
|
||||
position: absolute;
|
||||
background-color: #0063dc;
|
||||
z-index: 1001;
|
||||
|
||||
box-shadow: 0px 0px 5px #76b4ff;
|
||||
-moz-box-shadow: 0px 0px 5px #76b4ff;
|
||||
-webkit-box-shadow: 0px 0px 5px #76b4ff;
|
||||
}
|
||||
|
|
@ -0,0 +1 @@
|
|||
div.AutoFill_filler{display:none;position:absolute;height:14px;width:14px;background:url(../images/filler.png) no-repeat center center;z-index:1002}div.AutoFill_border{display:none;position:absolute;background-color:#0063dc;z-index:1001;box-shadow:0px 0px 5px #76b4ff;-moz-box-shadow:0px 0px 5px #76b4ff;-webkit-box-shadow:0px 0px 5px #76b4ff}
|
|
@ -0,0 +1,204 @@
|
|||
|
||||
div.dataTables_length label {
|
||||
font-weight: normal;
|
||||
float: left;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
div.dataTables_length select {
|
||||
width: 75px;
|
||||
}
|
||||
|
||||
div.dataTables_filter label {
|
||||
font-weight: normal;
|
||||
float: right;
|
||||
}
|
||||
|
||||
div.dataTables_filter input {
|
||||
width: 16em;
|
||||
}
|
||||
|
||||
div.dataTables_info {
|
||||
padding-top: 8px;
|
||||
}
|
||||
|
||||
div.dataTables_paginate {
|
||||
float: right;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
div.dataTables_paginate ul.pagination {
|
||||
margin: 2px;
|
||||
}
|
||||
|
||||
table.table {
|
||||
clear: both;
|
||||
margin-top: 6px !important;
|
||||
margin-bottom: 6px !important;
|
||||
max-width: none !important;
|
||||
}
|
||||
|
||||
table.table thead .sorting,
|
||||
table.table thead .sorting_asc,
|
||||
table.table thead .sorting_desc,
|
||||
table.table thead .sorting_asc_disabled,
|
||||
table.table thead .sorting_desc_disabled {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
table.table thead .sorting { background: url('../images/sort_both.png') no-repeat center right; }
|
||||
table.table thead .sorting_asc { background: url('../images/sort_asc.png') no-repeat center right; }
|
||||
table.table thead .sorting_desc { background: url('../images/sort_desc.png') no-repeat center right; }
|
||||
|
||||
table.table thead .sorting_asc_disabled { background: url('../images/sort_asc_disabled.png') no-repeat center right; }
|
||||
table.table thead .sorting_desc_disabled { background: url('../images/sort_desc_disabled.png') no-repeat center right; }
|
||||
|
||||
table.dataTable th:active {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
/* Scrolling */
|
||||
div.dataTables_scrollHead table {
|
||||
margin-bottom: 0 !important;
|
||||
border-bottom-left-radius: 0;
|
||||
border-bottom-right-radius: 0;
|
||||
}
|
||||
|
||||
div.dataTables_scrollHead table thead tr:last-child th:first-child,
|
||||
div.dataTables_scrollHead table thead tr:last-child td:first-child {
|
||||
border-bottom-left-radius: 0 !important;
|
||||
border-bottom-right-radius: 0 !important;
|
||||
}
|
||||
|
||||
div.dataTables_scrollBody table {
|
||||
border-top: none;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
div.dataTables_scrollBody tbody tr:first-child th,
|
||||
div.dataTables_scrollBody tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
div.dataTables_scrollFoot table {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* TableTools styles
|
||||
*/
|
||||
.table tbody tr.active td,
|
||||
.table tbody tr.active th {
|
||||
background-color: #08C;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.table tbody tr.active:hover td,
|
||||
.table tbody tr.active:hover th {
|
||||
background-color: #0075b0 !important;
|
||||
}
|
||||
|
||||
.table-striped tbody tr.active:nth-child(odd) td,
|
||||
.table-striped tbody tr.active:nth-child(odd) th {
|
||||
background-color: #017ebc;
|
||||
}
|
||||
|
||||
table.DTTT_selectable tbody tr {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
div.DTTT .btn {
|
||||
color: #333 !important;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
div.DTTT .btn:hover {
|
||||
text-decoration: none !important;
|
||||
}
|
||||
|
||||
ul.DTTT_dropdown.dropdown-menu {
|
||||
z-index: 2003;
|
||||
}
|
||||
|
||||
ul.DTTT_dropdown.dropdown-menu a {
|
||||
color: #333 !important; /* needed only when demo_page.css is included */
|
||||
}
|
||||
|
||||
ul.DTTT_dropdown.dropdown-menu li {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
ul.DTTT_dropdown.dropdown-menu li:hover a {
|
||||
background-color: #0088cc;
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
/* TableTools information display */
|
||||
div.DTTT_print_info.modal {
|
||||
height: 150px;
|
||||
margin-top: -75px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
div.DTTT_print_info h6 {
|
||||
font-weight: normal;
|
||||
font-size: 28px;
|
||||
line-height: 28px;
|
||||
margin: 1em;
|
||||
}
|
||||
|
||||
div.DTTT_print_info p {
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* FixedColumns styles
|
||||
*/
|
||||
div.DTFC_LeftHeadWrapper table,
|
||||
div.DTFC_LeftFootWrapper table,
|
||||
div.DTFC_RightHeadWrapper table,
|
||||
div.DTFC_RightFootWrapper table,
|
||||
table.DTFC_Cloned tr.even {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
div.DTFC_RightHeadWrapper table ,
|
||||
div.DTFC_LeftHeadWrapper table {
|
||||
margin-bottom: 0 !important;
|
||||
border-top-right-radius: 0 !important;
|
||||
border-bottom-left-radius: 0 !important;
|
||||
border-bottom-right-radius: 0 !important;
|
||||
}
|
||||
|
||||
div.DTFC_RightHeadWrapper table thead tr:last-child th:first-child,
|
||||
div.DTFC_RightHeadWrapper table thead tr:last-child td:first-child,
|
||||
div.DTFC_LeftHeadWrapper table thead tr:last-child th:first-child,
|
||||
div.DTFC_LeftHeadWrapper table thead tr:last-child td:first-child {
|
||||
border-bottom-left-radius: 0 !important;
|
||||
border-bottom-right-radius: 0 !important;
|
||||
}
|
||||
|
||||
div.DTFC_RightBodyWrapper table,
|
||||
div.DTFC_LeftBodyWrapper table {
|
||||
border-top: none;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
div.DTFC_RightBodyWrapper tbody tr:first-child th,
|
||||
div.DTFC_RightBodyWrapper tbody tr:first-child td,
|
||||
div.DTFC_LeftBodyWrapper tbody tr:first-child th,
|
||||
div.DTFC_LeftBodyWrapper tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
div.DTFC_RightFootWrapper table,
|
||||
div.DTFC_LeftFootWrapper table {
|
||||
border-top: none;
|
||||
}
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
/*
|
||||
* Namespace DTCR - "DataTables ColReorder" plug-in
|
||||
*/
|
||||
|
||||
table.DTCR_clonedTable {
|
||||
background-color: rgba(255, 255, 255, 0.7);
|
||||
z-index: 202;
|
||||
}
|
||||
|
||||
div.DTCR_pointer {
|
||||
width: 1px;
|
||||
background-color: #0259C4;
|
||||
z-index: 201;
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
table.DTCR_clonedTable{background-color:rgba(255,255,255,0.7);z-index:202}div.DTCR_pointer{width:1px;background-color:#0259C4;z-index:201}
|
|
@ -0,0 +1,185 @@
|
|||
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* ColVis styles
|
||||
*/
|
||||
div.ColVis {
|
||||
float: right;
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
|
||||
button.ColVis_Button,
|
||||
ul.ColVis_collection li {
|
||||
position: relative;
|
||||
float: left;
|
||||
margin-right: 3px;
|
||||
padding: 5px 8px;
|
||||
border: 1px solid #999;
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
font-size: 0.88em;
|
||||
color: black !important;
|
||||
white-space: nowrap;
|
||||
|
||||
-webkit-border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
-ms-border-radius: 2px;
|
||||
-o-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
|
||||
-webkit-box-shadow: 1px 1px 3px #ccc;
|
||||
-moz-box-shadow: 1px 1px 3px #ccc;
|
||||
-ms-box-shadow: 1px 1px 3px #ccc;
|
||||
-o-box-shadow: 1px 1px 3px #ccc;
|
||||
box-shadow: 1px 1px 3px #ccc;
|
||||
|
||||
/* Generated by http://www.colorzilla.com/gradient-editor/ */
|
||||
background: #ffffff; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#f9f9f9',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
.ColVis_Button:hover,
|
||||
ul.ColVis_collection li:hover {
|
||||
border: 1px solid #666;
|
||||
text-decoration: none !important;
|
||||
|
||||
-webkit-box-shadow: 1px 1px 3px #999;
|
||||
-moz-box-shadow: 1px 1px 3px #999;
|
||||
-ms-box-shadow: 1px 1px 3px #999;
|
||||
-o-box-shadow: 1px 1px 3px #999;
|
||||
box-shadow: 1px 1px 3px #999;
|
||||
|
||||
background: #f3f3f3; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f3f3f3', endColorstr='#f4f4f4',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
button.ColVis_Button {
|
||||
height: 30px;
|
||||
padding: 3px 8px;
|
||||
}
|
||||
|
||||
button.ColVis_Button::-moz-focus-inner {
|
||||
border: none !important;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
button.ColVis_Button:active {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
|
||||
div.ColVis_collectionBackground {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
background-color: black;
|
||||
z-index: 1100;
|
||||
}
|
||||
|
||||
ul.ColVis_collection {
|
||||
list-style: none;
|
||||
width: 150px;
|
||||
padding: 8px 8px 4px 8px;
|
||||
margin: 0;
|
||||
border: 1px solid #ccc;
|
||||
border: 1px solid rgba( 0, 0, 0, 0.4 );
|
||||
background-color: #f3f3f3;
|
||||
background-color: rgba( 255, 255, 255, 0.3 );
|
||||
overflow: hidden;
|
||||
z-index: 2002;
|
||||
|
||||
-webkit-border-radius: 5px;
|
||||
-moz-border-radius: 5px;
|
||||
-ms-border-radius: 5px;
|
||||
-o-border-radius: 5px;
|
||||
border-radius: 5px;
|
||||
|
||||
-webkit-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
-moz-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
-ms-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
-o-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
ul.ColVis_collection li {
|
||||
position: relative;
|
||||
height: auto;
|
||||
left: 0;
|
||||
right: 0;
|
||||
padding: 0.5em;
|
||||
|
||||
display: block;
|
||||
float: none;
|
||||
margin-bottom: 4px;
|
||||
|
||||
-webkit-box-shadow: 1px 1px 3px #999;
|
||||
-moz-box-shadow: 1px 1px 3px #999;
|
||||
-ms-box-shadow: 1px 1px 3px #999;
|
||||
-o-box-shadow: 1px 1px 3px #999;
|
||||
box-shadow: 1px 1px 3px #999;
|
||||
}
|
||||
|
||||
ul.ColVis_collection li {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
ul.ColVis_collection li.ColVis_Button:hover {
|
||||
border: 1px solid #999;
|
||||
background-color: #f0f0f0;
|
||||
}
|
||||
|
||||
ul.ColVis_collection li span {
|
||||
display: inline-block;
|
||||
padding-left: 0.5em;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
||||
ul.ColVis_collection li.ColVis_Special {
|
||||
border-color: #555;
|
||||
background: rgb(237,237,237); /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, rgba(237,237,237,1) 0%,rgba(214,214,214,1) 77%,rgba(232,232,232,1) 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, rgba(237,237,237,1) 0%, rgba(214,214,214,1) 77%, rgba(232,232,232,1) 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, rgba(237,237,237,1) 0%,rgba(214,214,214,1) 77%,rgba(232,232,232,1) 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, rgba(237,237,237,1) 0%,rgba(214,214,214,1) 77%,rgba(232,232,232,1) 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(to bottom, rgba(237,237,237,1) 0%,rgba(214,214,214,1) 77%,rgba(232,232,232,1) 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ededed', endColorstr='#e8e8e8',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
ul.ColVis_collection li.ColVis_Special:hover {
|
||||
background: #e2e2e2; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #d0d0d0 0%,#d5d5d5 89%,#e2e2e2 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #d0d0d0 0%,#d5d5d5 89%,#e2e2e2 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #d0d0d0 0%,#d5d5d5 89%,#e2e2e2 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #d0d0d0 0%,#d5d5d5 89%,#e2e2e2 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #d0d0d0 0%,#d5d5d5 89%,#e2e2e2 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f3f3f3', endColorstr='#e2e2e2',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
|
||||
span.ColVis_radio {
|
||||
display: inline-block;
|
||||
width: 20px;
|
||||
}
|
||||
|
||||
div.ColVis_catcher {
|
||||
position: absolute;
|
||||
z-index: 1101;
|
||||
}
|
||||
|
||||
.disabled {
|
||||
color: #999;
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1 @@
|
|||
div.ColVis{float:right;margin-bottom:1em}button.ColVis_Button,ul.ColVis_collection li{position:relative;float:left;margin-right:3px;padding:5px 8px;border:1px solid #999;cursor:pointer;*cursor:hand;font-size:0.88em;color:black !important;white-space:nowrap;-webkit-border-radius:2px;-moz-border-radius:2px;-ms-border-radius:2px;-o-border-radius:2px;border-radius:2px;-webkit-box-shadow:1px 1px 3px #ccc;-moz-box-shadow:1px 1px 3px #ccc;-ms-box-shadow:1px 1px 3px #ccc;-o-box-shadow:1px 1px 3px #ccc;box-shadow:1px 1px 3px #ccc;background:#ffffff;background:-webkit-linear-gradient(top, #fff 0%, #f3f3f3 89%, #f9f9f9 100%);background:-moz-linear-gradient(top, #fff 0%, #f3f3f3 89%, #f9f9f9 100%);background:-ms-linear-gradient(top, #fff 0%, #f3f3f3 89%, #f9f9f9 100%);background:-o-linear-gradient(top, #fff 0%, #f3f3f3 89%, #f9f9f9 100%);background:linear-gradient(top, #fff 0%, #f3f3f3 89%, #f9f9f9 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#f9f9f9',GradientType=0 )}.ColVis_Button:hover,ul.ColVis_collection li:hover{border:1px solid #666;text-decoration:none !important;-webkit-box-shadow:1px 1px 3px #999;-moz-box-shadow:1px 1px 3px #999;-ms-box-shadow:1px 1px 3px #999;-o-box-shadow:1px 1px 3px #999;box-shadow:1px 1px 3px #999;background:#f3f3f3;background:-webkit-linear-gradient(top, #f3f3f3 0%, #e2e2e2 89%, #f4f4f4 100%);background:-moz-linear-gradient(top, #f3f3f3 0%, #e2e2e2 89%, #f4f4f4 100%);background:-ms-linear-gradient(top, #f3f3f3 0%, #e2e2e2 89%, #f4f4f4 100%);background:-o-linear-gradient(top, #f3f3f3 0%, #e2e2e2 89%, #f4f4f4 100%);background:linear-gradient(top, #f3f3f3 0%, #e2e2e2 89%, #f4f4f4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#f3f3f3', endColorstr='#f4f4f4',GradientType=0 )}button.ColVis_Button{height:30px;padding:3px 8px}button.ColVis_Button::-moz-focus-inner{border:none !important;padding:0}button.ColVis_Button:active{outline:none}div.ColVis_collectionBackground{position:fixed;top:0;left:0;height:100%;width:100%;background-color:black;z-index:1100}ul.ColVis_collection{list-style:none;width:150px;padding:8px 8px 4px 8px;margin:0;border:1px solid #ccc;border:1px solid rgba(0,0,0,0.4);background-color:#f3f3f3;background-color:rgba(255,255,255,0.3);overflow:hidden;z-index:2002;-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;-o-border-radius:5px;border-radius:5px;-webkit-box-shadow:3px 3px 5px rgba(0,0,0,0.3);-moz-box-shadow:3px 3px 5px rgba(0,0,0,0.3);-ms-box-shadow:3px 3px 5px rgba(0,0,0,0.3);-o-box-shadow:3px 3px 5px rgba(0,0,0,0.3);box-shadow:3px 3px 5px rgba(0,0,0,0.3)}ul.ColVis_collection li{position:relative;height:auto;left:0;right:0;padding:0.5em;display:block;float:none;margin-bottom:4px;-webkit-box-shadow:1px 1px 3px #999;-moz-box-shadow:1px 1px 3px #999;-ms-box-shadow:1px 1px 3px #999;-o-box-shadow:1px 1px 3px #999;box-shadow:1px 1px 3px #999}ul.ColVis_collection li{text-align:left}ul.ColVis_collection li.ColVis_Button:hover{border:1px solid #999;background-color:#f0f0f0}ul.ColVis_collection li span{display:inline-block;padding-left:0.5em;cursor:pointer}ul.ColVis_collection li.ColVis_Special{border-color:#555;background:#ededed;background:-webkit-linear-gradient(top, #ededed 0%, #d6d6d6 77%, #e8e8e8 100%);background:-moz-linear-gradient(top, #ededed 0%, #d6d6d6 77%, #e8e8e8 100%);background:-ms-linear-gradient(top, #ededed 0%, #d6d6d6 77%, #e8e8e8 100%);background:-o-linear-gradient(top, #ededed 0%, #d6d6d6 77%, #e8e8e8 100%);background:linear-gradient(to bottom, #ededed 0%, #d6d6d6 77%, #e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ededed', endColorstr='#e8e8e8',GradientType=0 )}ul.ColVis_collection li.ColVis_Special:hover{background:#e2e2e2;background:-webkit-linear-gradient(top, #d0d0d0 0%, #d5d5d5 89%, #e2e2e2 100%);background:-moz-linear-gradient(top, #d0d0d0 0%, #d5d5d5 89%, #e2e2e2 100%);background:-ms-linear-gradient(top, #d0d0d0 0%, #d5d5d5 89%, #e2e2e2 100%);background:-o-linear-gradient(top, #d0d0d0 0%, #d5d5d5 89%, #e2e2e2 100%);background:linear-gradient(top, #d0d0d0 0%, #d5d5d5 89%, #e2e2e2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#f3f3f3', endColorstr='#e2e2e2',GradientType=0 )}span.ColVis_radio{display:inline-block;width:20px}div.ColVis_catcher{position:absolute;z-index:1101}.disabled{color:#999}
|
|
@ -0,0 +1,23 @@
|
|||
|
||||
button.ColVis_Button,
|
||||
ul.ColVis_collection li {
|
||||
padding: 0.5em;
|
||||
}
|
||||
|
||||
ul.ColVis_collection {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
ul.ColVis_collection li {
|
||||
clear: both;
|
||||
display: block;
|
||||
text-align: left;
|
||||
margin: -1px 0 0 0;
|
||||
}
|
||||
|
||||
ul.ColVis_collection li span {
|
||||
display: inline-block;
|
||||
padding-left: 0.5em;
|
||||
cursor: pointer;
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
|
||||
|
||||
/* Block out what is behind the fixed column's header and footer */
|
||||
table.DTFC_Cloned thead,
|
||||
table.DTFC_Cloned tfoot {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
/* Block out the gap above the scrollbar on the right, when there is a fixed
|
||||
* right column
|
||||
*/
|
||||
div.DTFC_Blocker {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
div.DTFC_LeftWrapper table.dataTable,
|
||||
div.DTFC_RightWrapper table.dataTable {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
div.DTFC_LeftWrapper table.dataTable.no-footer,
|
||||
div.DTFC_RightWrapper table.dataTable.no-footer {
|
||||
border-bottom: none;
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
table.DTFC_Cloned thead,table.DTFC_Cloned tfoot{background-color:white}div.DTFC_Blocker{background-color:white}div.DTFC_LeftWrapper table.dataTable,div.DTFC_RightWrapper table.dataTable{margin-bottom:0}div.DTFC_LeftWrapper table.dataTable.no-footer,div.DTFC_RightWrapper table.dataTable.no-footer{border-bottom:none}
|
|
@ -0,0 +1,7 @@
|
|||
|
||||
|
||||
div.FixedHeader_Cloned th,
|
||||
div.FixedHeader_Cloned td {
|
||||
background-color: white !important;
|
||||
}
|
||||
|
|
@ -0,0 +1 @@
|
|||
div.FixedHeader_Cloned th,div.FixedHeader_Cloned td{background-color:white !important}
|
|
@ -0,0 +1,213 @@
|
|||
div.dataTables_wrapper {
|
||||
margin-bottom: 1.25em;
|
||||
}
|
||||
|
||||
div.dataTables_length label,
|
||||
div.dataTables_filter label,
|
||||
div.dataTables_info {
|
||||
color: #999;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
div.dataTables_length {
|
||||
padding-top: 6px;
|
||||
}
|
||||
div.dataTables_length label {
|
||||
float: left;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
div.dataTables_length select {
|
||||
width: 75px;
|
||||
}
|
||||
|
||||
div.dataTables_filter label {
|
||||
float: right;
|
||||
}
|
||||
div.dataTables_filter input {
|
||||
display: inline-block !important;
|
||||
width: auto !important;
|
||||
}
|
||||
|
||||
div.dataTables_info {
|
||||
padding-top: 2px;
|
||||
font-size: 0.875em;
|
||||
}
|
||||
|
||||
div.dataTables_paginate {
|
||||
float: right;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
table.dataTable {
|
||||
clear: both;
|
||||
margin-bottom: 0.5em !important;
|
||||
max-width: none !important;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.dataTable thead .sorting,
|
||||
table.dataTable thead .sorting_asc,
|
||||
table.dataTable thead .sorting_desc,
|
||||
table.dataTable thead .sorting_asc_disabled,
|
||||
table.dataTable thead .sorting_desc_disabled {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
|
||||
table.dataTable thead .sorting { background: url('images/sort_both.png') no-repeat center right; }
|
||||
table.dataTable thead .sorting_asc { background: url('images/sort_asc.png') no-repeat center right; }
|
||||
table.dataTable thead .sorting_desc { background: url('images/sort_desc.png') no-repeat center right; }
|
||||
|
||||
table.dataTable thead .sorting_asc_disabled { background: url('images/sort_asc_disabled.png') no-repeat center right; }
|
||||
table.dataTable thead .sorting_desc_disabled { background: url('images/sort_desc_disabled.png') no-repeat center right; }
|
||||
|
||||
table.dataTable th:active {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
/* Scrolling */
|
||||
div.dataTables_scrollHead table {
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
div.dataTables_scrollBody table {
|
||||
border-top: none;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
div.dataTables_scrollBody tbody tr:first-child th,
|
||||
div.dataTables_scrollBody tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
div.dataTables_scrollFoot table {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* TableTools styles
|
||||
*/
|
||||
.table tbody tr.active td,
|
||||
.table tbody tr.active th {
|
||||
background-color: #08C;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.table tbody tr.active:hover td,
|
||||
.table tbody tr.active:hover th {
|
||||
background-color: #0075b0 !important;
|
||||
}
|
||||
|
||||
.table-striped tbody tr.active:nth-child(odd) td,
|
||||
.table-striped tbody tr.active:nth-child(odd) th {
|
||||
background-color: #017ebc;
|
||||
}
|
||||
|
||||
table.DTTT_selectable tbody tr {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
|
||||
div.DTTT {
|
||||
float: left;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
div.DTTT .button:hover {
|
||||
text-decoration: none !important;
|
||||
}
|
||||
|
||||
ul.DTTT_dropdown.dropdown-menu li {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
ul.DTTT_dropdown.dropdown-menu li:hover a {
|
||||
background-color: #0088cc;
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
/* TableTools information display */
|
||||
.DTTT_print_info {
|
||||
position: fixed;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 400px;
|
||||
height: 150px;
|
||||
margin-left: -200px;
|
||||
margin-top: -75px;
|
||||
text-align: center;
|
||||
color: #333;
|
||||
padding: 10px 30px;
|
||||
|
||||
background: #ffffff; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#f9f9f9',GradientType=0 ); /* IE6-9 */
|
||||
|
||||
opacity: 0.95;
|
||||
|
||||
border: 1px solid black;
|
||||
border: 1px solid rgba(0, 0, 0, 0.5);
|
||||
|
||||
-webkit-border-radius: 6px;
|
||||
-moz-border-radius: 6px;
|
||||
-ms-border-radius: 6px;
|
||||
-o-border-radius: 6px;
|
||||
border-radius: 6px;
|
||||
|
||||
-webkit-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
-moz-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
-ms-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
-o-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
div.DTTT_print_info h6 {
|
||||
font-weight: normal;
|
||||
font-size: 28px;
|
||||
line-height: 28px;
|
||||
margin: 1em;
|
||||
}
|
||||
|
||||
div.DTTT_print_info p {
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* FixedColumns styles
|
||||
*/
|
||||
div.DTFC_LeftHeadWrapper table,
|
||||
div.DTFC_LeftFootWrapper table,
|
||||
table.DTFC_Cloned tr.even {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
div.DTFC_LeftHeadWrapper table {
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
div.DTFC_LeftBodyWrapper table {
|
||||
border-top: none;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
div.DTFC_LeftBodyWrapper tbody tr:first-child th,
|
||||
div.DTFC_LeftBodyWrapper tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
div.DTFC_LeftFootWrapper table {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,316 @@
|
|||
/*
|
||||
* Table styles
|
||||
*/
|
||||
table.dataTable {
|
||||
width: 100%;
|
||||
margin: 0 auto;
|
||||
clear: both;
|
||||
border-collapse: separate;
|
||||
border-spacing: 0;
|
||||
/*
|
||||
* Header and footer styles
|
||||
*/
|
||||
/*
|
||||
* Body styles
|
||||
*/
|
||||
}
|
||||
table.dataTable thead th,
|
||||
table.dataTable thead td,
|
||||
table.dataTable tfoot th,
|
||||
table.dataTable tfoot td {
|
||||
padding: 4px 10px;
|
||||
}
|
||||
table.dataTable thead th,
|
||||
table.dataTable tfoot th {
|
||||
font-weight: bold;
|
||||
}
|
||||
table.dataTable thead th:active,
|
||||
table.dataTable thead td:active {
|
||||
outline: none;
|
||||
}
|
||||
table.dataTable thead .sorting_asc,
|
||||
table.dataTable thead .sorting_desc,
|
||||
table.dataTable thead .sorting {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
table.dataTable thead th div.DataTables_sort_wrapper {
|
||||
position: relative;
|
||||
padding-right: 10px;
|
||||
}
|
||||
table.dataTable thead th div.DataTables_sort_wrapper span {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
margin-top: -8px;
|
||||
right: -5px;
|
||||
}
|
||||
table.dataTable thead th.ui-state-default {
|
||||
border-right-width: 0;
|
||||
}
|
||||
table.dataTable thead th.ui-state-default:last-child {
|
||||
border-right-width: 1px;
|
||||
}
|
||||
table.dataTable tbody tr {
|
||||
background-color: white;
|
||||
}
|
||||
table.dataTable tbody tr.selected {
|
||||
background-color: #b0bed9;
|
||||
}
|
||||
table.dataTable tbody th,
|
||||
table.dataTable tbody td {
|
||||
padding: 8px 10px;
|
||||
}
|
||||
table.dataTable th.center,
|
||||
table.dataTable td.center,
|
||||
table.dataTable td.dataTables_empty {
|
||||
text-align: center;
|
||||
}
|
||||
table.dataTable th.right,
|
||||
table.dataTable td.right {
|
||||
text-align: right;
|
||||
}
|
||||
table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
|
||||
border-top: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.row-border tbody tr:first-child th,
|
||||
table.dataTable.row-border tbody tr:first-child td, table.dataTable.display tbody tr:first-child th,
|
||||
table.dataTable.display tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
table.dataTable.cell-border tbody th, table.dataTable.cell-border tbody td {
|
||||
border-top: 1px solid #dddddd;
|
||||
border-right: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.cell-border tbody tr th:first-child,
|
||||
table.dataTable.cell-border tbody tr td:first-child {
|
||||
border-left: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.cell-border tbody tr:first-child th,
|
||||
table.dataTable.cell-border tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
table.dataTable.stripe tbody tr.odd, table.dataTable.display tbody tr.odd {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.stripe tbody tr.odd.selected, table.dataTable.display tbody tr.odd.selected {
|
||||
background-color: #abb9d3;
|
||||
}
|
||||
table.dataTable.hover tbody tr:hover,
|
||||
table.dataTable.hover tbody tr.odd:hover,
|
||||
table.dataTable.hover tbody tr.even:hover, table.dataTable.display tbody tr:hover,
|
||||
table.dataTable.display tbody tr.odd:hover,
|
||||
table.dataTable.display tbody tr.even:hover {
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
table.dataTable.hover tbody tr:hover.selected,
|
||||
table.dataTable.hover tbody tr.odd:hover.selected,
|
||||
table.dataTable.hover tbody tr.even:hover.selected, table.dataTable.display tbody tr:hover.selected,
|
||||
table.dataTable.display tbody tr.odd:hover.selected,
|
||||
table.dataTable.display tbody tr.even:hover.selected {
|
||||
background-color: #a9b7d1;
|
||||
}
|
||||
table.dataTable.order-column tbody tr > .sorting_1,
|
||||
table.dataTable.order-column tbody tr > .sorting_2,
|
||||
table.dataTable.order-column tbody tr > .sorting_3, table.dataTable.display tbody tr > .sorting_1,
|
||||
table.dataTable.display tbody tr > .sorting_2,
|
||||
table.dataTable.display tbody tr > .sorting_3 {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_3, table.dataTable.display tbody tr.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.selected > .sorting_3 {
|
||||
background-color: #acbad4;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
||||
background-color: #f1f1f1;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
||||
background-color: #f3f3f3;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
||||
background-color: #a6b3cd;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
||||
background-color: #a7b5ce;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
||||
background-color: #a9b6d0;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_2, table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
||||
background-color: #fbfbfb;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_3, table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
||||
background-color: #fdfdfd;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
||||
background-color: #acbad4;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
||||
background-color: #adbbd6;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
||||
background-color: #afbdd8;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_1,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_1,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_1, table.dataTable.order-column.hover tbody tr:hover > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_1 {
|
||||
background-color: #eaeaea;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_2,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_2,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_2, table.dataTable.order-column.hover tbody tr:hover > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_2 {
|
||||
background-color: #ebebeb;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_3,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_3,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_3, table.dataTable.order-column.hover tbody tr:hover > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_3 {
|
||||
background-color: #eeeeee;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_1, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_1 {
|
||||
background-color: #a1aec7;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_2, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_2 {
|
||||
background-color: #a2afc8;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_3,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_3,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_3, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_3 {
|
||||
background-color: #a4b2cb;
|
||||
}
|
||||
|
||||
table.dataTable,
|
||||
table.dataTable th,
|
||||
table.dataTable td {
|
||||
-webkit-box-sizing: content-box;
|
||||
-moz-box-sizing: content-box;
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
/*
|
||||
* Control feature layout
|
||||
*/
|
||||
.dataTables_wrapper {
|
||||
position: relative;
|
||||
clear: both;
|
||||
*zoom: 1;
|
||||
zoom: 1;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_length {
|
||||
float: left;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter {
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter input {
|
||||
margin-left: 0.5em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_info {
|
||||
clear: both;
|
||||
float: left;
|
||||
padding-top: 0.55em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
min-width: 1.5em;
|
||||
padding: 0.5em;
|
||||
margin-left: 2px;
|
||||
text-align: center;
|
||||
text-decoration: none !important;
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
color: #333333 !important;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button:active {
|
||||
outline: none;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button:first-child {
|
||||
border-top-left-radius: 3px;
|
||||
border-bottom-left-radius: 3px;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button:last-child {
|
||||
border-top-right-radius: 3px;
|
||||
border-bottom-right-radius: 3px;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_processing {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
margin-left: -50%;
|
||||
margin-top: -25px;
|
||||
padding-top: 20px;
|
||||
text-align: center;
|
||||
font-size: 1.2em;
|
||||
background-color: white;
|
||||
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0)), color-stop(25%, rgba(255, 255, 255, 0.9)), color-stop(75%, rgba(255, 255, 255, 0.9)), color-stop(100%, rgba(255, 255, 255, 0)));
|
||||
/* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* FF3.6+ */
|
||||
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* IE10+ */
|
||||
background: -o-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* Opera 11.10+ */
|
||||
background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* W3C */
|
||||
}
|
||||
.dataTables_wrapper .dataTables_length,
|
||||
.dataTables_wrapper .dataTables_filter,
|
||||
.dataTables_wrapper .dataTables_info,
|
||||
.dataTables_wrapper .dataTables_processing,
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
color: #333333;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scroll {
|
||||
clear: both;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scrollBody {
|
||||
*margin-top: -1px;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
.dataTables_wrapper .ui-widget-header {
|
||||
font-weight: normal;
|
||||
}
|
||||
.dataTables_wrapper .ui-toolbar {
|
||||
padding: 8px;
|
||||
}
|
||||
.dataTables_wrapper:after {
|
||||
visibility: hidden;
|
||||
display: block;
|
||||
content: "";
|
||||
clear: both;
|
||||
height: 0;
|
||||
}
|
|
@ -0,0 +1,408 @@
|
|||
|
||||
|
||||
//
|
||||
// Colour customisation
|
||||
//
|
||||
|
||||
// Border between the header (and footer) and the table body
|
||||
$table-header-border: 1px solid #111;
|
||||
|
||||
// Border of rows / cells
|
||||
$table-body-border: 1px solid #ddd;
|
||||
|
||||
// Row background colour (hover, striping etc are all based on this colour and
|
||||
// calculated automatically)
|
||||
$table-row-background: #ffffff;
|
||||
|
||||
// Row colour, when selected (tr.selected)
|
||||
$table-row-selected: #B0BED9;
|
||||
|
||||
// Text colour of the interaction control elements (info, filter, paging etc)
|
||||
$table-control-color: #333;
|
||||
|
||||
// Highlight colour of the paging button for the current page
|
||||
$table-paging-button-active: #dcdcdc;
|
||||
|
||||
// Hover colour of paging buttons on mouse over
|
||||
$table-paging-button-hover: #111;
|
||||
|
||||
|
||||
|
||||
//
|
||||
// Functions / mixins
|
||||
//
|
||||
@function tint( $color, $percent ) {
|
||||
@return mix(white, $color, $percent);
|
||||
}
|
||||
|
||||
@function shade( $color, $percent ) {
|
||||
@return mix(black, $color, $percent);
|
||||
}
|
||||
|
||||
@mixin gradient( $from, $to ) {
|
||||
background-color: $from;
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,$from), color-stop(100%,$to)); /* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(top, $from 0%, $to 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, $from 0%, $to 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, $from 0%, $to 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, $from 0%, $to 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(to bottom, $from 0%, $to 100%); /* W3C */
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Table styles
|
||||
*/
|
||||
table.dataTable {
|
||||
width: 100%;
|
||||
margin: 0 auto;
|
||||
clear: both;
|
||||
border-collapse: separate;
|
||||
border-spacing: 0;
|
||||
|
||||
/*
|
||||
* Header and footer styles
|
||||
*/
|
||||
thead,
|
||||
tfoot {
|
||||
th,
|
||||
td {
|
||||
padding: 4px 10px;
|
||||
}
|
||||
|
||||
th {
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
|
||||
thead th,
|
||||
thead td {
|
||||
&:active {
|
||||
outline: none;
|
||||
}
|
||||
}
|
||||
|
||||
// Sorting
|
||||
thead {
|
||||
.sorting_asc,
|
||||
.sorting_desc,
|
||||
.sorting {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
|
||||
th div.DataTables_sort_wrapper {
|
||||
position: relative;
|
||||
padding-right: 10px;
|
||||
|
||||
span {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
margin-top: -8px;
|
||||
right: -5px;
|
||||
}
|
||||
}
|
||||
|
||||
th.ui-state-default {
|
||||
border-right-width: 0;
|
||||
|
||||
&:last-child {
|
||||
border-right-width: 1px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Body styles
|
||||
*/
|
||||
tbody {
|
||||
tr {
|
||||
background-color: $table-row-background;
|
||||
|
||||
&.selected {
|
||||
background-color: $table-row-selected;
|
||||
}
|
||||
}
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 8px 10px;
|
||||
}
|
||||
}
|
||||
|
||||
th.center,
|
||||
td.center,
|
||||
td.dataTables_empty {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
th.right,
|
||||
td.right {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
|
||||
// Stripe classes - add "row-border" class to the table to activate
|
||||
&.row-border tbody,
|
||||
&.display tbody {
|
||||
th, td {
|
||||
border-top: $table-body-border;
|
||||
}
|
||||
|
||||
tr:first-child th,
|
||||
tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Stripe classes - add "cell-border" class to the table to activate
|
||||
&.cell-border tbody {
|
||||
th, td {
|
||||
border-top: $table-body-border;
|
||||
border-right: $table-body-border;
|
||||
}
|
||||
|
||||
tr th:first-child,
|
||||
tr td:first-child {
|
||||
border-left: $table-body-border;
|
||||
}
|
||||
|
||||
tr:first-child th,
|
||||
tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Stripe classes - add "stripe" class to the table to activate
|
||||
&.stripe tbody,
|
||||
&.display tbody {
|
||||
tr.odd {
|
||||
background-color: shade($table-row-background, 2.35%); // shade by f9
|
||||
|
||||
&.selected {
|
||||
background-color: shade($table-row-selected, 2.35%);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Hover classes - add "hover" class to the table to activate
|
||||
&.hover tbody,
|
||||
&.display tbody {
|
||||
tr:hover,
|
||||
tr.odd:hover,
|
||||
tr.even:hover {
|
||||
background-color: shade($table-row-background, 3.6%); // shade by f5
|
||||
|
||||
&.selected {
|
||||
background-color: shade($table-row-selected, 3.6%);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Sort column highlighting - add "hover" class to the table to activate
|
||||
&.order-column,
|
||||
&.display {
|
||||
tbody {
|
||||
tr>.sorting_1,
|
||||
tr>.sorting_2,
|
||||
tr>.sorting_3 {
|
||||
background-color: shade($table-row-background, 2%); // shade by fa
|
||||
}
|
||||
|
||||
tr.selected>.sorting_1,
|
||||
tr.selected>.sorting_2,
|
||||
tr.selected>.sorting_3 {
|
||||
background-color: shade($table-row-selected, 2%);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.display tbody,
|
||||
&.order-column.stripe tbody {
|
||||
tr.odd {
|
||||
>.sorting_1 { background-color: shade($table-row-background, 5.4%); } // shade by f1
|
||||
>.sorting_2 { background-color: shade($table-row-background, 4.7%); } // shade by f3
|
||||
>.sorting_3 { background-color: shade($table-row-background, 3.9%); } // shade by f5
|
||||
|
||||
&.selected {
|
||||
>.sorting_1 { background-color: shade($table-row-selected, 5.4%); }
|
||||
>.sorting_2 { background-color: shade($table-row-selected, 4.7%); }
|
||||
>.sorting_3 { background-color: shade($table-row-selected, 3.9%); }
|
||||
}
|
||||
}
|
||||
|
||||
tr.even {
|
||||
>.sorting_1 { background-color: shade($table-row-background, 2%); } // shade by fa
|
||||
>.sorting_2 { background-color: shade($table-row-background, 1.2%); } // shade by fc
|
||||
>.sorting_3 { background-color: shade($table-row-background, 0.4%); } // shade by fe
|
||||
|
||||
&.selected {
|
||||
>.sorting_1 { background-color: shade($table-row-selected, 2%); }
|
||||
>.sorting_2 { background-color: shade($table-row-selected, 1.2%); }
|
||||
>.sorting_3 { background-color: shade($table-row-selected, 0.4%); }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.display tbody,
|
||||
&.order-column.hover tbody {
|
||||
tr:hover,
|
||||
tr.odd:hover,
|
||||
tr.even:hover {
|
||||
>.sorting_1 { background-color: shade($table-row-background, 8.2%); } // shade by ea
|
||||
>.sorting_2 { background-color: shade($table-row-background, 7.5%); } // shade by ec
|
||||
>.sorting_3 { background-color: shade($table-row-background, 6.3%); } // shade by ef
|
||||
|
||||
&.selected {
|
||||
>.sorting_1 { background-color: shade($table-row-selected, 8.2%); }
|
||||
>.sorting_2 { background-color: shade($table-row-selected, 7.5%); }
|
||||
>.sorting_3 { background-color: shade($table-row-selected, 6.3%); }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Its not uncommon to use * {border-box} now, but it messes up the column width
|
||||
// calculations, so use content-box for the table and cells
|
||||
table.dataTable,
|
||||
table.dataTable th,
|
||||
table.dataTable td {
|
||||
-webkit-box-sizing: content-box;
|
||||
-moz-box-sizing: content-box;
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Control feature layout
|
||||
*/
|
||||
.dataTables_wrapper {
|
||||
position: relative;
|
||||
clear: both;
|
||||
*zoom: 1;
|
||||
|
||||
// Page length options
|
||||
.dataTables_length {
|
||||
float: left;
|
||||
}
|
||||
|
||||
// Filtering input
|
||||
.dataTables_filter {
|
||||
float: right;
|
||||
text-align: right;
|
||||
|
||||
input {
|
||||
margin-left: 0.5em;
|
||||
}
|
||||
}
|
||||
|
||||
// Table info
|
||||
.dataTables_info {
|
||||
clear: both;
|
||||
float: left;
|
||||
padding-top: 0.55em;
|
||||
}
|
||||
|
||||
// Paging
|
||||
.dataTables_paginate {
|
||||
float: right;
|
||||
text-align: right;
|
||||
|
||||
.fg-button {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
min-width: 1.5em;
|
||||
padding: 0.5em;
|
||||
margin-left: 2px;
|
||||
text-align: center;
|
||||
text-decoration: none !important;
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
|
||||
color: $table-control-color !important;
|
||||
border: 1px solid transparent;
|
||||
|
||||
&:active {
|
||||
outline: none;
|
||||
}
|
||||
}
|
||||
|
||||
.fg-button:first-child {
|
||||
border-top-left-radius: 3px;
|
||||
border-bottom-left-radius: 3px;
|
||||
}
|
||||
|
||||
.fg-button:last-child {
|
||||
border-top-right-radius: 3px;
|
||||
border-bottom-right-radius: 3px;
|
||||
}
|
||||
}
|
||||
|
||||
// Processing
|
||||
.dataTables_processing {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
margin-left: -50%;
|
||||
margin-top: -25px;
|
||||
padding-top: 20px;
|
||||
|
||||
text-align: center;
|
||||
font-size: 1.2em;
|
||||
|
||||
background-color: white;
|
||||
background: -webkit-gradient(linear, left top, right top, color-stop(0%,rgba($table-row-background, 0)), color-stop(25%,rgba($table-row-background, 0.9)), color-stop(75%,rgba($table-row-background, 0.9)), color-stop(100%,rgba(255,255,255,0))); /* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(left, rgba($table-row-background, 0) 0%, rgba($table-row-background, 0.9) 25%, rgba($table-row-background, 0.9) 75%, rgba($table-row-background, 0) 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(left, rgba($table-row-background, 0) 0%, rgba($table-row-background, 0.9) 25%, rgba($table-row-background, 0.9) 75%, rgba($table-row-background, 0) 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(left, rgba($table-row-background, 0) 0%, rgba($table-row-background, 0.9) 25%, rgba($table-row-background, 0.9) 75%, rgba($table-row-background, 0) 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(left, rgba($table-row-background, 0) 0%, rgba($table-row-background, 0.9) 25%, rgba($table-row-background, 0.9) 75%, rgba($table-row-background, 0) 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(to right, rgba($table-row-background, 0) 0%, rgba($table-row-background, 0.9) 25%, rgba($table-row-background, 0.9) 75%, rgba($table-row-background, 0) 100%); /* W3C */
|
||||
}
|
||||
|
||||
.dataTables_length,
|
||||
.dataTables_filter,
|
||||
.dataTables_info,
|
||||
.dataTables_processing,
|
||||
.dataTables_paginate {
|
||||
color: $table-control-color;
|
||||
}
|
||||
|
||||
// Scrolling
|
||||
.dataTables_scroll {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.dataTables_scrollBody {
|
||||
*margin-top: -1px;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
|
||||
|
||||
.ui-widget-header {
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.ui-toolbar {
|
||||
padding: 8px;
|
||||
}
|
||||
|
||||
// Self clear the wrapper
|
||||
&:after {
|
||||
visibility: hidden;
|
||||
display: block;
|
||||
content: "";
|
||||
clear: both;
|
||||
height: 0;
|
||||
}
|
||||
zoom: 1; // Poor old IE
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
|
||||
|
||||
table.KeyTable th.focus,
|
||||
table.KeyTable td.focus {
|
||||
outline: 3px solid #3366FF;
|
||||
outline-offset: -3px;
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
table.KeyTable th.focus,table.KeyTable td.focus{outline:3px solid #3366FF;outline-offset:-3px}
|
|
@ -0,0 +1,93 @@
|
|||
table.dataTable.dtr-inline.collapsed tbody td:first-child,
|
||||
table.dataTable.dtr-inline.collapsed tbody th:first-child {
|
||||
position: relative;
|
||||
padding-left: 30px;
|
||||
cursor: pointer;
|
||||
}
|
||||
table.dataTable.dtr-inline.collapsed tbody td:first-child:before,
|
||||
table.dataTable.dtr-inline.collapsed tbody th:first-child:before {
|
||||
top: 8px;
|
||||
left: 4px;
|
||||
height: 16px;
|
||||
width: 16px;
|
||||
display: block;
|
||||
position: absolute;
|
||||
color: white;
|
||||
border: 2px solid white;
|
||||
border-radius: 16px;
|
||||
text-align: center;
|
||||
line-height: 14px;
|
||||
box-shadow: 0 0 3px #444;
|
||||
box-sizing: content-box;
|
||||
content: '+';
|
||||
background-color: #31b131;
|
||||
}
|
||||
table.dataTable.dtr-inline.collapsed tbody td:first-child.dataTables_empty:before,
|
||||
table.dataTable.dtr-inline.collapsed tbody th:first-child.dataTables_empty:before {
|
||||
display: none;
|
||||
}
|
||||
table.dataTable.dtr-inline.collapsed tbody tr.parent td:first-child:before,
|
||||
table.dataTable.dtr-inline.collapsed tbody tr.parent th:first-child:before {
|
||||
content: '-';
|
||||
background-color: #d33333;
|
||||
}
|
||||
table.dataTable.dtr-inline.collapsed tbody tr.child td:before {
|
||||
display: none;
|
||||
}
|
||||
table.dataTable.dtr-column tbody td.control,
|
||||
table.dataTable.dtr-column tbody th.control {
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
}
|
||||
table.dataTable.dtr-column tbody td.control:before,
|
||||
table.dataTable.dtr-column tbody th.control:before {
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
height: 16px;
|
||||
width: 16px;
|
||||
margin-top: -10px;
|
||||
margin-left: -10px;
|
||||
display: block;
|
||||
position: absolute;
|
||||
color: white;
|
||||
border: 2px solid white;
|
||||
border-radius: 16px;
|
||||
text-align: center;
|
||||
line-height: 14px;
|
||||
box-shadow: 0 0 3px #444;
|
||||
box-sizing: content-box;
|
||||
content: '+';
|
||||
background-color: #31b131;
|
||||
}
|
||||
table.dataTable.dtr-column tbody tr.parent td.control:before,
|
||||
table.dataTable.dtr-column tbody tr.parent th.control:before {
|
||||
content: '-';
|
||||
background-color: #d33333;
|
||||
}
|
||||
table.dataTable tr.child {
|
||||
padding: 0.5em 1em;
|
||||
}
|
||||
table.dataTable tr.child:hover {
|
||||
background: transparent !important;
|
||||
}
|
||||
table.dataTable tr.child ul {
|
||||
display: inline-block;
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
table.dataTable tr.child ul li {
|
||||
border-bottom: 1px solid #efefef;
|
||||
padding: 0.5em 0;
|
||||
}
|
||||
table.dataTable tr.child ul li:first-child {
|
||||
padding-top: 0;
|
||||
}
|
||||
table.dataTable tr.child ul li:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
table.dataTable tr.child span.dtr-title {
|
||||
display: inline-block;
|
||||
min-width: 75px;
|
||||
font-weight: bold;
|
||||
}
|
|
@ -0,0 +1,132 @@
|
|||
|
||||
//
|
||||
// Mixins
|
||||
//
|
||||
@mixin control() {
|
||||
display: block;
|
||||
position: absolute;
|
||||
color: white;
|
||||
border: 2px solid white;
|
||||
border-radius: 16px;
|
||||
text-align: center;
|
||||
line-height: 14px;
|
||||
box-shadow: 0 0 3px #444;
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
@mixin control-open() {
|
||||
content: '+';
|
||||
background-color: #31b131;
|
||||
}
|
||||
|
||||
@mixin control-close() {
|
||||
content: '-';
|
||||
background-color: #d33333;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Table styles
|
||||
//
|
||||
table.dataTable {
|
||||
// Styling for the `inline` type
|
||||
&.dtr-inline.collapsed tbody {
|
||||
td:first-child,
|
||||
th:first-child {
|
||||
position: relative;
|
||||
padding-left: 30px;
|
||||
cursor: pointer;
|
||||
|
||||
&:before {
|
||||
top: 8px;
|
||||
left: 4px;
|
||||
height: 16px;
|
||||
width: 16px;
|
||||
@include control;
|
||||
@include control-open;
|
||||
}
|
||||
|
||||
&.dataTables_empty:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
tr.parent {
|
||||
td:first-child:before,
|
||||
th:first-child:before {
|
||||
@include control-close;
|
||||
}
|
||||
}
|
||||
|
||||
tr.child td:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Styling for the `column` type
|
||||
&.dtr-column tbody {
|
||||
td.control,
|
||||
th.control {
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
|
||||
&:before {
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
height: 16px;
|
||||
width: 16px;
|
||||
margin-top: -10px;
|
||||
margin-left: -10px;
|
||||
@include control;
|
||||
@include control-open;
|
||||
}
|
||||
}
|
||||
|
||||
tr.parent {
|
||||
td.control:before,
|
||||
th.control:before {
|
||||
@include control-close;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Child row styling
|
||||
tr.child {
|
||||
padding: 0.5em 1em;
|
||||
|
||||
&:hover {
|
||||
background: transparent !important;
|
||||
}
|
||||
|
||||
ul {
|
||||
display: inline-block;
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
li {
|
||||
border-bottom: 1px solid #efefef;
|
||||
padding: 0.5em 0;
|
||||
|
||||
&:first-child {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
&:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
span.dtr-title {
|
||||
display: inline-block;
|
||||
min-width: 75px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
span.dtr-data {}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,44 @@
|
|||
|
||||
/*
|
||||
* Namespace: DTS (DataTables Scroller)
|
||||
*/
|
||||
|
||||
div.DTS tbody th,
|
||||
div.DTS tbody td {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
div.DTS tbody tr.even {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
div.DTS div.DTS_Loading {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 200px;
|
||||
height: 20px;
|
||||
margin-top: -20px;
|
||||
margin-left: -100px;
|
||||
z-index: 1;
|
||||
|
||||
border: 1px solid #999;
|
||||
padding: 20px 0;
|
||||
text-align: center;
|
||||
background-color: white;
|
||||
background-color: rgba(255, 255, 255, 0.5);
|
||||
}
|
||||
|
||||
div.DTS div.dataTables_scrollHead,
|
||||
div.DTS div.dataTables_scrollFoot {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
div.DTS div.dataTables_scrollBody {
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
div.DTS div.dataTables_scroll {
|
||||
background: url('../images/loading-background.png') repeat 0 0;
|
||||
}
|
||||
|
|
@ -0,0 +1 @@
|
|||
div.DTS tbody th,div.DTS tbody td{white-space:nowrap}div.DTS tbody tr.even{background-color:white}div.DTS div.DTS_Loading{position:absolute;top:50%;left:50%;width:200px;height:20px;margin-top:-20px;margin-left:-100px;z-index:1;border:1px solid #999;padding:20px 0;text-align:center;background-color:white;background-color:rgba(255,255,255,0.5)}div.DTS div.dataTables_scrollHead,div.DTS div.dataTables_scrollFoot{background-color:white}div.DTS div.dataTables_scrollBody{z-index:2}div.DTS div.dataTables_scroll{background:url("../images/loading-background.png") repeat 0 0}
|
|
@ -0,0 +1,361 @@
|
|||
/*
|
||||
* File: TableTools.css
|
||||
* Description: Styles for TableTools 2
|
||||
* Author: Allan Jardine (www.sprymedia.co.uk)
|
||||
* Language: Javascript
|
||||
* License: GPL v2 / 3 point BSD
|
||||
* Project: DataTables
|
||||
*
|
||||
* Copyright 2009-2012 Allan Jardine, all rights reserved.
|
||||
*
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
*
|
||||
* CSS name space:
|
||||
* DTTT DataTables TableTools
|
||||
*
|
||||
* Style sheet provides:
|
||||
* CONTAINER TableTools container element and styles applying to all components
|
||||
* BUTTON_STYLES Action specific button styles
|
||||
* SELECTING Row selection styles
|
||||
* COLLECTIONS Drop down list (collection) styles
|
||||
* PRINTING Print display styles
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
* CONTAINER
|
||||
* TableTools container element and styles applying to all components
|
||||
*/
|
||||
div.DTTT_container {
|
||||
position: relative;
|
||||
float: right;
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 640px) {
|
||||
div.DTTT_container {
|
||||
float: none !important;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
div.DTTT_container:after {
|
||||
visibility: hidden;
|
||||
display: block;
|
||||
content: "";
|
||||
clear: both;
|
||||
height: 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
button.DTTT_button,
|
||||
div.DTTT_button,
|
||||
a.DTTT_button {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
margin-right: 3px;
|
||||
padding: 5px 8px;
|
||||
border: 1px solid #999;
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
font-size: 0.88em;
|
||||
color: black !important;
|
||||
|
||||
-webkit-border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
-ms-border-radius: 2px;
|
||||
-o-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
|
||||
-webkit-box-shadow: 1px 1px 3px #ccc;
|
||||
-moz-box-shadow: 1px 1px 3px #ccc;
|
||||
-ms-box-shadow: 1px 1px 3px #ccc;
|
||||
-o-box-shadow: 1px 1px 3px #ccc;
|
||||
box-shadow: 1px 1px 3px #ccc;
|
||||
|
||||
/* Generated by http://www.colorzilla.com/gradient-editor/ */
|
||||
background: #ffffff; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#f9f9f9',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
|
||||
/* Buttons are cunning border-box sizing - we can't just use that for A and DIV due to IE6/7 */
|
||||
button.DTTT_button {
|
||||
height: 30px;
|
||||
padding: 3px 8px;
|
||||
}
|
||||
|
||||
.DTTT_button embed {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
button.DTTT_button:hover,
|
||||
div.DTTT_button:hover,
|
||||
a.DTTT_button:hover {
|
||||
border: 1px solid #666;
|
||||
text-decoration: none !important;
|
||||
|
||||
-webkit-box-shadow: 1px 1px 3px #999;
|
||||
-moz-box-shadow: 1px 1px 3px #999;
|
||||
-ms-box-shadow: 1px 1px 3px #999;
|
||||
-o-box-shadow: 1px 1px 3px #999;
|
||||
box-shadow: 1px 1px 3px #999;
|
||||
|
||||
background: #f3f3f3; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #f3f3f3 0%,#e2e2e2 89%,#f4f4f4 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f3f3f3', endColorstr='#f4f4f4',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
button.DTTT_button:focus,
|
||||
div.DTTT_button:focus,
|
||||
a.DTTT_button:focus {
|
||||
border: 1px solid #426c9e;
|
||||
text-shadow: 0 1px 0 #c4def1;
|
||||
outline: none;
|
||||
|
||||
background-color: #a3d0ef 100%;
|
||||
background-image: -webkit-linear-gradient(top, #a3d0ef 0%, #79ace9 65%, #a3d0ef 100%);
|
||||
background-image: -moz-linear-gradient(top, #a3d0ef 0%, #79ace9 65%, #a3d0ef 100%);
|
||||
background-image: -ms-linear-gradient(top, #a3d0ef 0%, #79ace9 65%, #a3d0ef 100%);
|
||||
background-image: -o-linear-gradient(top, #a3d0ef 0%, #79ace9 65%, #a3d0ef 100%);
|
||||
background-image: linear-gradient(top, #a3d0ef 0%, #79ace9 65%, #a3d0ef 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#a3d0ef', EndColorStr='#a3d0ef');
|
||||
}
|
||||
|
||||
button.DTTT_button:active,
|
||||
div.DTTT_button:active,
|
||||
a.DTTT_button:active {
|
||||
-webkit-box-shadow: inset 1px 1px 3px #999999;
|
||||
-moz-box-shadow: inset 1px 1px 3px #999999;
|
||||
box-shadow: inset 1px 1px 3px #999999;
|
||||
}
|
||||
|
||||
button.DTTT_disabled,
|
||||
div.DTTT_disabled,
|
||||
a.DTTT_disabled {
|
||||
color: #999;
|
||||
border: 1px solid #d0d0d0;
|
||||
|
||||
background: #ffffff; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #ffffff 0%,#f9f9f9 89%,#fafafa 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #ffffff 0%,#f9f9f9 89%,#fafafa 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #ffffff 0%,#f9f9f9 89%,#fafafa 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #ffffff 0%,#f9f9f9 89%,#fafafa 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #ffffff 0%,#f9f9f9 89%,#fafafa 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#fafafa',GradientType=0 ); /* IE6-9 */
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* BUTTON_STYLES
|
||||
* Action specific button styles
|
||||
* If you want images - comment this back in
|
||||
|
||||
a.DTTT_button_csv,
|
||||
a.DTTT_button_xls,
|
||||
a.DTTT_button_copy,
|
||||
a.DTTT_button_pdf,
|
||||
a.DTTT_button_print {
|
||||
padding-right: 0px;
|
||||
}
|
||||
|
||||
a.DTTT_button_csv span,
|
||||
a.DTTT_button_xls span,
|
||||
a.DTTT_button_copy span,
|
||||
a.DTTT_button_pdf span,
|
||||
a.DTTT_button_print span {
|
||||
display: inline-block;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
padding-right: 30px;
|
||||
}
|
||||
|
||||
|
||||
a.DTTT_button_csv span { background: url(../images/csv.png) no-repeat bottom right; }
|
||||
a.DTTT_button_csv:hover span { background: url(../images/csv_hover.png) no-repeat center right; }
|
||||
|
||||
a.DTTT_button_xls span { background: url(../images/xls.png) no-repeat center right; }
|
||||
a.DTTT_button_xls:hover span { background: #f0f0f0 url(../images/xls_hover.png) no-repeat center right; }
|
||||
|
||||
a.DTTT_button_copy span { background: url(../images/copy.png) no-repeat center right; }
|
||||
a.DTTT_button_copy:hover span { background: #f0f0f0 url(../images/copy_hover.png) no-repeat center right; }
|
||||
|
||||
a.DTTT_button_pdf span { background: url(../images/pdf.png) no-repeat center right; }
|
||||
a.DTTT_button_pdf:hover span { background: #f0f0f0 url(../images/pdf_hover.png) no-repeat center right; }
|
||||
|
||||
a.DTTT_button_print span { background: url(../images/print.png) no-repeat center right; }
|
||||
a.DTTT_button_print:hover span { background: #f0f0f0 url(../images/print_hover.png) no-repeat center right; }
|
||||
|
||||
*/
|
||||
|
||||
button.DTTT_button_collection span {
|
||||
padding-right: 17px;
|
||||
background: url(../images/collection.png) no-repeat center right;
|
||||
}
|
||||
|
||||
button.DTTT_button_collection:hover span {
|
||||
padding-right: 17px;
|
||||
background: #f0f0f0 url(../images/collection_hover.png) no-repeat center right;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* SELECTING
|
||||
* Row selection styles
|
||||
*/
|
||||
table.DTTT_selectable tbody tr {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.odd {
|
||||
background-color: #9FAFD1;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.odd td.sorting_1 {
|
||||
background-color: #9FAFD1;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.odd td.sorting_2 {
|
||||
background-color: #9FAFD1;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.odd td.sorting_3 {
|
||||
background-color: #9FAFD1;
|
||||
}
|
||||
|
||||
|
||||
table.dataTable tr.DTTT_selected.even {
|
||||
background-color: #B0BED9;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.even td.sorting_1 {
|
||||
background-color: #B0BED9;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.even td.sorting_2 {
|
||||
background-color: #B0BED9;
|
||||
}
|
||||
|
||||
table.dataTable tr.DTTT_selected.even td.sorting_3 {
|
||||
background-color: #B0BED9;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* COLLECTIONS
|
||||
* Drop down list (collection) styles
|
||||
*/
|
||||
|
||||
div.DTTT_collection {
|
||||
width: 150px;
|
||||
padding: 8px 8px 4px 8px;
|
||||
border: 1px solid #ccc;
|
||||
border: 1px solid rgba( 0, 0, 0, 0.4 );
|
||||
background-color: #f3f3f3;
|
||||
background-color: rgba( 255, 255, 255, 0.3 );
|
||||
overflow: hidden;
|
||||
z-index: 2002;
|
||||
|
||||
-webkit-border-radius: 5px;
|
||||
-moz-border-radius: 5px;
|
||||
-ms-border-radius: 5px;
|
||||
-o-border-radius: 5px;
|
||||
border-radius: 5px;
|
||||
|
||||
-webkit-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
-moz-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
-ms-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
-o-box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
box-shadow: 3px 3px 5px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
div.DTTT_collection_background {
|
||||
background: transparent url(../images/background.png) repeat top left;
|
||||
z-index: 2001;
|
||||
}
|
||||
|
||||
div.DTTT_collection button.DTTT_button,
|
||||
div.DTTT_collection div.DTTT_button,
|
||||
div.DTTT_collection a.DTTT_button {
|
||||
position: relative;
|
||||
left: 0;
|
||||
right: 0;
|
||||
|
||||
display: block;
|
||||
float: none;
|
||||
margin-bottom: 4px;
|
||||
|
||||
-webkit-box-shadow: 1px 1px 3px #999;
|
||||
-moz-box-shadow: 1px 1px 3px #999;
|
||||
-ms-box-shadow: 1px 1px 3px #999;
|
||||
-o-box-shadow: 1px 1px 3px #999;
|
||||
box-shadow: 1px 1px 3px #999;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* PRINTING
|
||||
* Print display styles
|
||||
*/
|
||||
|
||||
.DTTT_print_info {
|
||||
position: fixed;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 400px;
|
||||
height: 150px;
|
||||
margin-left: -200px;
|
||||
margin-top: -75px;
|
||||
text-align: center;
|
||||
color: #333;
|
||||
padding: 10px 30px;
|
||||
|
||||
background: #ffffff; /* Old browsers */
|
||||
background: -webkit-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* IE10+ */
|
||||
background: -o-linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* Opera 11.10+ */
|
||||
background: linear-gradient(top, #ffffff 0%,#f3f3f3 89%,#f9f9f9 100%); /* W3C */
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#f9f9f9',GradientType=0 ); /* IE6-9 */
|
||||
|
||||
opacity: 0.95;
|
||||
|
||||
border: 1px solid black;
|
||||
border: 1px solid rgba(0, 0, 0, 0.5);
|
||||
|
||||
-webkit-border-radius: 6px;
|
||||
-moz-border-radius: 6px;
|
||||
-ms-border-radius: 6px;
|
||||
-o-border-radius: 6px;
|
||||
border-radius: 6px;
|
||||
|
||||
-webkit-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
-moz-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
-ms-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
-o-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
box-shadow: 0 3px 7px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
.DTTT_print_info h6 {
|
||||
font-weight: normal;
|
||||
font-size: 28px;
|
||||
line-height: 28px;
|
||||
margin: 1em;
|
||||
}
|
||||
|
||||
.DTTT_print_info p {
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
|
@ -0,0 +1,476 @@
|
|||
/*
|
||||
* Table styles
|
||||
*/
|
||||
table.dataTable {
|
||||
width: 100%;
|
||||
margin: 0 auto;
|
||||
clear: both;
|
||||
border-collapse: separate;
|
||||
border-spacing: 0;
|
||||
/*
|
||||
* Header and footer styles
|
||||
*/
|
||||
/*
|
||||
* Body styles
|
||||
*/
|
||||
}
|
||||
table.dataTable thead th,
|
||||
table.dataTable tfoot th {
|
||||
font-weight: bold;
|
||||
}
|
||||
table.dataTable thead th,
|
||||
table.dataTable thead td {
|
||||
padding: 10px 18px;
|
||||
border-bottom: 1px solid #111111;
|
||||
}
|
||||
table.dataTable thead th:active,
|
||||
table.dataTable thead td:active {
|
||||
outline: none;
|
||||
}
|
||||
table.dataTable tfoot th,
|
||||
table.dataTable tfoot td {
|
||||
padding: 10px 18px 6px 18px;
|
||||
border-top: 1px solid #111111;
|
||||
}
|
||||
table.dataTable thead .sorting_asc,
|
||||
table.dataTable thead .sorting_desc,
|
||||
table.dataTable thead .sorting {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
table.dataTable thead .sorting {
|
||||
background: url("../images/sort_both.png") no-repeat center right;
|
||||
}
|
||||
table.dataTable thead .sorting_asc {
|
||||
background: url("../images/sort_asc.png") no-repeat center right;
|
||||
}
|
||||
table.dataTable thead .sorting_desc {
|
||||
background: url("../images/sort_desc.png") no-repeat center right;
|
||||
}
|
||||
table.dataTable thead .sorting_asc_disabled {
|
||||
background: url("../images/sort_asc_disabled.png") no-repeat center right;
|
||||
}
|
||||
table.dataTable thead .sorting_desc_disabled {
|
||||
background: url("../images/sort_desc_disabled.png") no-repeat center right;
|
||||
}
|
||||
table.dataTable tbody tr {
|
||||
background-color: white;
|
||||
}
|
||||
table.dataTable tbody tr.selected {
|
||||
background-color: #b0bed9;
|
||||
}
|
||||
table.dataTable tbody th,
|
||||
table.dataTable tbody td {
|
||||
padding: 8px 10px;
|
||||
}
|
||||
table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
|
||||
border-top: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.row-border tbody tr:first-child th,
|
||||
table.dataTable.row-border tbody tr:first-child td, table.dataTable.display tbody tr:first-child th,
|
||||
table.dataTable.display tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
table.dataTable.cell-border tbody th, table.dataTable.cell-border tbody td {
|
||||
border-top: 1px solid #dddddd;
|
||||
border-right: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.cell-border tbody tr th:first-child,
|
||||
table.dataTable.cell-border tbody tr td:first-child {
|
||||
border-left: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.cell-border tbody tr:first-child th,
|
||||
table.dataTable.cell-border tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
table.dataTable.stripe tbody tr.odd, table.dataTable.display tbody tr.odd {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.stripe tbody tr.odd.selected, table.dataTable.display tbody tr.odd.selected {
|
||||
background-color: #abb9d3;
|
||||
}
|
||||
table.dataTable.hover tbody tr:hover,
|
||||
table.dataTable.hover tbody tr.odd:hover,
|
||||
table.dataTable.hover tbody tr.even:hover, table.dataTable.display tbody tr:hover,
|
||||
table.dataTable.display tbody tr.odd:hover,
|
||||
table.dataTable.display tbody tr.even:hover {
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
table.dataTable.hover tbody tr:hover.selected,
|
||||
table.dataTable.hover tbody tr.odd:hover.selected,
|
||||
table.dataTable.hover tbody tr.even:hover.selected, table.dataTable.display tbody tr:hover.selected,
|
||||
table.dataTable.display tbody tr.odd:hover.selected,
|
||||
table.dataTable.display tbody tr.even:hover.selected {
|
||||
background-color: #a9b7d1;
|
||||
}
|
||||
table.dataTable.order-column tbody tr > .sorting_1,
|
||||
table.dataTable.order-column tbody tr > .sorting_2,
|
||||
table.dataTable.order-column tbody tr > .sorting_3, table.dataTable.display tbody tr > .sorting_1,
|
||||
table.dataTable.display tbody tr > .sorting_2,
|
||||
table.dataTable.display tbody tr > .sorting_3 {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_3, table.dataTable.display tbody tr.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.selected > .sorting_3 {
|
||||
background-color: #acbad4;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
||||
background-color: #f1f1f1;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
||||
background-color: #f3f3f3;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
||||
background-color: #a6b3cd;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
||||
background-color: #a7b5ce;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
||||
background-color: #a9b6d0;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_2, table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
||||
background-color: #fbfbfb;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_3, table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
||||
background-color: #fdfdfd;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
||||
background-color: #acbad4;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
||||
background-color: #adbbd6;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
||||
background-color: #afbdd8;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_1,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_1,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_1, table.dataTable.order-column.hover tbody tr:hover > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_1 {
|
||||
background-color: #eaeaea;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_2,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_2,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_2, table.dataTable.order-column.hover tbody tr:hover > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_2 {
|
||||
background-color: #ebebeb;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_3,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_3,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_3, table.dataTable.order-column.hover tbody tr:hover > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_3 {
|
||||
background-color: #eeeeee;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_1, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_1 {
|
||||
background-color: #a1aec7;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_2, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_2 {
|
||||
background-color: #a2afc8;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_3,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_3,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_3, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_3 {
|
||||
background-color: #a4b2cb;
|
||||
}
|
||||
table.dataTable.no-footer {
|
||||
border-bottom: 1px solid #111111;
|
||||
}
|
||||
table.dataTable.nowrap th, table.dataTable.nowrap td {
|
||||
white-space: nowrap;
|
||||
}
|
||||
table.dataTable.compact thead th,
|
||||
table.dataTable.compact thead td {
|
||||
padding: 5px 9px;
|
||||
}
|
||||
table.dataTable.compact tfoot th,
|
||||
table.dataTable.compact tfoot td {
|
||||
padding: 5px 9px 3px 9px;
|
||||
}
|
||||
table.dataTable.compact tbody th,
|
||||
table.dataTable.compact tbody td {
|
||||
padding: 4px 5px;
|
||||
}
|
||||
table.dataTable th.dt-left,
|
||||
table.dataTable td.dt-left {
|
||||
text-align: left;
|
||||
}
|
||||
table.dataTable th.dt-center,
|
||||
table.dataTable td.dt-center,
|
||||
table.dataTable td.dataTables_empty {
|
||||
text-align: center;
|
||||
}
|
||||
table.dataTable th.dt-right,
|
||||
table.dataTable td.dt-right {
|
||||
text-align: right;
|
||||
}
|
||||
table.dataTable th.dt-justify,
|
||||
table.dataTable td.dt-justify {
|
||||
text-align: justify;
|
||||
}
|
||||
table.dataTable th.dt-nowrap,
|
||||
table.dataTable td.dt-nowrap {
|
||||
white-space: nowrap;
|
||||
}
|
||||
table.dataTable thead th.dt-head-left,
|
||||
table.dataTable thead td.dt-head-left,
|
||||
table.dataTable tfoot th.dt-head-left,
|
||||
table.dataTable tfoot td.dt-head-left {
|
||||
text-align: left;
|
||||
}
|
||||
table.dataTable thead th.dt-head-center,
|
||||
table.dataTable thead td.dt-head-center,
|
||||
table.dataTable tfoot th.dt-head-center,
|
||||
table.dataTable tfoot td.dt-head-center {
|
||||
text-align: center;
|
||||
}
|
||||
table.dataTable thead th.dt-head-right,
|
||||
table.dataTable thead td.dt-head-right,
|
||||
table.dataTable tfoot th.dt-head-right,
|
||||
table.dataTable tfoot td.dt-head-right {
|
||||
text-align: right;
|
||||
}
|
||||
table.dataTable thead th.dt-head-justify,
|
||||
table.dataTable thead td.dt-head-justify,
|
||||
table.dataTable tfoot th.dt-head-justify,
|
||||
table.dataTable tfoot td.dt-head-justify {
|
||||
text-align: justify;
|
||||
}
|
||||
table.dataTable thead th.dt-head-nowrap,
|
||||
table.dataTable thead td.dt-head-nowrap,
|
||||
table.dataTable tfoot th.dt-head-nowrap,
|
||||
table.dataTable tfoot td.dt-head-nowrap {
|
||||
white-space: nowrap;
|
||||
}
|
||||
table.dataTable tbody th.dt-body-left,
|
||||
table.dataTable tbody td.dt-body-left {
|
||||
text-align: left;
|
||||
}
|
||||
table.dataTable tbody th.dt-body-center,
|
||||
table.dataTable tbody td.dt-body-center {
|
||||
text-align: center;
|
||||
}
|
||||
table.dataTable tbody th.dt-body-right,
|
||||
table.dataTable tbody td.dt-body-right {
|
||||
text-align: right;
|
||||
}
|
||||
table.dataTable tbody th.dt-body-justify,
|
||||
table.dataTable tbody td.dt-body-justify {
|
||||
text-align: justify;
|
||||
}
|
||||
table.dataTable tbody th.dt-body-nowrap,
|
||||
table.dataTable tbody td.dt-body-nowrap {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
table.dataTable,
|
||||
table.dataTable th,
|
||||
table.dataTable td {
|
||||
-webkit-box-sizing: content-box;
|
||||
-moz-box-sizing: content-box;
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
/*
|
||||
* Control feature layout
|
||||
*/
|
||||
.dataTables_wrapper {
|
||||
position: relative;
|
||||
clear: both;
|
||||
*zoom: 1;
|
||||
zoom: 1;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_length {
|
||||
float: left;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter {
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter input {
|
||||
margin-left: 0.5em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_info {
|
||||
clear: both;
|
||||
float: left;
|
||||
padding-top: 0.755em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
float: right;
|
||||
text-align: right;
|
||||
padding-top: 0.25em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .paginate_button {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
min-width: 1.5em;
|
||||
padding: 0.5em 1em;
|
||||
margin-left: 2px;
|
||||
text-align: center;
|
||||
text-decoration: none !important;
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
color: #333333 !important;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .paginate_button.current, .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
|
||||
color: #333333 !important;
|
||||
border: 1px solid #cacaca;
|
||||
background-color: white;
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, white), color-stop(100%, gainsboro));
|
||||
/* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(top, white 0%, gainsboro 100%);
|
||||
/* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, white 0%, gainsboro 100%);
|
||||
/* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, white 0%, gainsboro 100%);
|
||||
/* IE10+ */
|
||||
background: -o-linear-gradient(top, white 0%, gainsboro 100%);
|
||||
/* Opera 11.10+ */
|
||||
background: linear-gradient(to bottom, white 0%, gainsboro 100%);
|
||||
/* W3C */
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled, .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover, .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active {
|
||||
cursor: default;
|
||||
color: #666 !important;
|
||||
border: 1px solid transparent;
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
|
||||
color: white !important;
|
||||
border: 1px solid #111111;
|
||||
background-color: #585858;
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #585858), color-stop(100%, #111111));
|
||||
/* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(top, #585858 0%, #111111 100%);
|
||||
/* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #585858 0%, #111111 100%);
|
||||
/* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #585858 0%, #111111 100%);
|
||||
/* IE10+ */
|
||||
background: -o-linear-gradient(top, #585858 0%, #111111 100%);
|
||||
/* Opera 11.10+ */
|
||||
background: linear-gradient(to bottom, #585858 0%, #111111 100%);
|
||||
/* W3C */
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .paginate_button:active {
|
||||
outline: none;
|
||||
background-color: #2b2b2b;
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #2b2b2b), color-stop(100%, #0c0c0c));
|
||||
/* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
||||
/* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
||||
/* FF3.6+ */
|
||||
background: -ms-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
||||
/* IE10+ */
|
||||
background: -o-linear-gradient(top, #2b2b2b 0%, #0c0c0c 100%);
|
||||
/* Opera 11.10+ */
|
||||
background: linear-gradient(to bottom, #2b2b2b 0%, #0c0c0c 100%);
|
||||
/* W3C */
|
||||
box-shadow: inset 0 0 3px #111;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_processing {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
margin-left: -50%;
|
||||
margin-top: -25px;
|
||||
padding-top: 20px;
|
||||
text-align: center;
|
||||
font-size: 1.2em;
|
||||
background-color: white;
|
||||
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0)), color-stop(25%, rgba(255, 255, 255, 0.9)), color-stop(75%, rgba(255, 255, 255, 0.9)), color-stop(100%, rgba(255, 255, 255, 0)));
|
||||
/* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* FF3.6+ */
|
||||
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* IE10+ */
|
||||
background: -o-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* Opera 11.10+ */
|
||||
background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* W3C */
|
||||
}
|
||||
.dataTables_wrapper .dataTables_length,
|
||||
.dataTables_wrapper .dataTables_filter,
|
||||
.dataTables_wrapper .dataTables_info,
|
||||
.dataTables_wrapper .dataTables_processing,
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
color: #333333;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scroll {
|
||||
clear: both;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody {
|
||||
*margin-top: -1px;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody th > div.dataTables_sizing,
|
||||
.dataTables_wrapper .dataTables_scroll div.dataTables_scrollBody td > div.dataTables_sizing {
|
||||
height: 0;
|
||||
overflow: hidden;
|
||||
margin: 0 !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
.dataTables_wrapper.no-footer .dataTables_scrollBody {
|
||||
border-bottom: 1px solid #111111;
|
||||
}
|
||||
.dataTables_wrapper.no-footer div.dataTables_scrollHead table,
|
||||
.dataTables_wrapper.no-footer div.dataTables_scrollBody table {
|
||||
border-bottom: none;
|
||||
}
|
||||
.dataTables_wrapper:after {
|
||||
visibility: hidden;
|
||||
display: block;
|
||||
content: "";
|
||||
clear: both;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.dataTables_wrapper .dataTables_info,
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
float: none;
|
||||
text-align: center;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
margin-top: 0.5em;
|
||||
}
|
||||
}
|
||||
@media screen and (max-width: 640px) {
|
||||
.dataTables_wrapper .dataTables_length,
|
||||
.dataTables_wrapper .dataTables_filter {
|
||||
float: none;
|
||||
text-align: center;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter {
|
||||
margin-top: 0.5em;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,330 @@
|
|||
/*
|
||||
* Table styles
|
||||
*/
|
||||
table.dataTable {
|
||||
width: 100%;
|
||||
margin: 0 auto;
|
||||
clear: both;
|
||||
border-collapse: separate;
|
||||
border-spacing: 0;
|
||||
/*
|
||||
* Header and footer styles
|
||||
*/
|
||||
/*
|
||||
* Body styles
|
||||
*/
|
||||
}
|
||||
table.dataTable thead th,
|
||||
table.dataTable thead td,
|
||||
table.dataTable tfoot th,
|
||||
table.dataTable tfoot td {
|
||||
padding: 4px 10px;
|
||||
}
|
||||
table.dataTable thead th,
|
||||
table.dataTable tfoot th {
|
||||
font-weight: bold;
|
||||
}
|
||||
table.dataTable thead th:active,
|
||||
table.dataTable thead td:active {
|
||||
outline: none;
|
||||
}
|
||||
table.dataTable thead .sorting_asc,
|
||||
table.dataTable thead .sorting_desc,
|
||||
table.dataTable thead .sorting {
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
}
|
||||
table.dataTable thead th div.DataTables_sort_wrapper {
|
||||
position: relative;
|
||||
padding-right: 10px;
|
||||
}
|
||||
table.dataTable thead th div.DataTables_sort_wrapper span {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
margin-top: -8px;
|
||||
right: -5px;
|
||||
}
|
||||
table.dataTable thead th.ui-state-default {
|
||||
border-right-width: 0;
|
||||
}
|
||||
table.dataTable thead th.ui-state-default:last-child {
|
||||
border-right-width: 1px;
|
||||
}
|
||||
table.dataTable tbody tr {
|
||||
background-color: white;
|
||||
}
|
||||
table.dataTable tbody tr.selected {
|
||||
background-color: #b0bed9;
|
||||
}
|
||||
table.dataTable tbody th,
|
||||
table.dataTable tbody td {
|
||||
padding: 8px 10px;
|
||||
}
|
||||
table.dataTable th.center,
|
||||
table.dataTable td.center,
|
||||
table.dataTable td.dataTables_empty {
|
||||
text-align: center;
|
||||
}
|
||||
table.dataTable th.right,
|
||||
table.dataTable td.right {
|
||||
text-align: right;
|
||||
}
|
||||
table.dataTable.row-border tbody th, table.dataTable.row-border tbody td, table.dataTable.display tbody th, table.dataTable.display tbody td {
|
||||
border-top: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.row-border tbody tr:first-child th,
|
||||
table.dataTable.row-border tbody tr:first-child td, table.dataTable.display tbody tr:first-child th,
|
||||
table.dataTable.display tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
table.dataTable.cell-border tbody th, table.dataTable.cell-border tbody td {
|
||||
border-top: 1px solid #dddddd;
|
||||
border-right: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.cell-border tbody tr th:first-child,
|
||||
table.dataTable.cell-border tbody tr td:first-child {
|
||||
border-left: 1px solid #dddddd;
|
||||
}
|
||||
table.dataTable.cell-border tbody tr:first-child th,
|
||||
table.dataTable.cell-border tbody tr:first-child td {
|
||||
border-top: none;
|
||||
}
|
||||
table.dataTable.stripe tbody tr.odd, table.dataTable.display tbody tr.odd {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.stripe tbody tr.odd.selected, table.dataTable.display tbody tr.odd.selected {
|
||||
background-color: #abb9d3;
|
||||
}
|
||||
table.dataTable.hover tbody tr:hover,
|
||||
table.dataTable.hover tbody tr.odd:hover,
|
||||
table.dataTable.hover tbody tr.even:hover, table.dataTable.display tbody tr:hover,
|
||||
table.dataTable.display tbody tr.odd:hover,
|
||||
table.dataTable.display tbody tr.even:hover {
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
table.dataTable.hover tbody tr:hover.selected,
|
||||
table.dataTable.hover tbody tr.odd:hover.selected,
|
||||
table.dataTable.hover tbody tr.even:hover.selected, table.dataTable.display tbody tr:hover.selected,
|
||||
table.dataTable.display tbody tr.odd:hover.selected,
|
||||
table.dataTable.display tbody tr.even:hover.selected {
|
||||
background-color: #a9b7d1;
|
||||
}
|
||||
table.dataTable.order-column tbody tr > .sorting_1,
|
||||
table.dataTable.order-column tbody tr > .sorting_2,
|
||||
table.dataTable.order-column tbody tr > .sorting_3, table.dataTable.display tbody tr > .sorting_1,
|
||||
table.dataTable.display tbody tr > .sorting_2,
|
||||
table.dataTable.display tbody tr > .sorting_3 {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
||||
table.dataTable.order-column tbody tr.selected > .sorting_3, table.dataTable.display tbody tr.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.selected > .sorting_3 {
|
||||
background-color: #acbad4;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
||||
background-color: #f1f1f1;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
||||
background-color: #f3f3f3;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
||||
background-color: #a6b3cd;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
||||
background-color: #a7b5ce;
|
||||
}
|
||||
table.dataTable.display tbody tr.odd.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
||||
background-color: #a9b6d0;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_1, table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_2, table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
||||
background-color: #fbfbfb;
|
||||
}
|
||||
table.dataTable.display tbody tr.even > .sorting_3, table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
||||
background-color: #fdfdfd;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_1, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
||||
background-color: #acbad4;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_2, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
||||
background-color: #adbbd6;
|
||||
}
|
||||
table.dataTable.display tbody tr.even.selected > .sorting_3, table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
||||
background-color: #afbdd8;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_1,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_1,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_1, table.dataTable.order-column.hover tbody tr:hover > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_1 {
|
||||
background-color: #eaeaea;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_2,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_2,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_2, table.dataTable.order-column.hover tbody tr:hover > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_2 {
|
||||
background-color: #ebebeb;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover > .sorting_3,
|
||||
table.dataTable.display tbody tr.odd:hover > .sorting_3,
|
||||
table.dataTable.display tbody tr.even:hover > .sorting_3, table.dataTable.order-column.hover tbody tr:hover > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover > .sorting_3 {
|
||||
background-color: #eeeeee;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_1,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_1, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_1,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_1 {
|
||||
background-color: #a1aec7;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_2,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_2, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_2,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_2 {
|
||||
background-color: #a2afc8;
|
||||
}
|
||||
table.dataTable.display tbody tr:hover.selected > .sorting_3,
|
||||
table.dataTable.display tbody tr.odd:hover.selected > .sorting_3,
|
||||
table.dataTable.display tbody tr.even:hover.selected > .sorting_3, table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.odd:hover.selected > .sorting_3,
|
||||
table.dataTable.order-column.hover tbody tr.even:hover.selected > .sorting_3 {
|
||||
background-color: #a4b2cb;
|
||||
}
|
||||
|
||||
table.dataTable,
|
||||
table.dataTable th,
|
||||
table.dataTable td {
|
||||
-webkit-box-sizing: content-box;
|
||||
-moz-box-sizing: content-box;
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
/*
|
||||
* Control feature layout
|
||||
*/
|
||||
.dataTables_wrapper {
|
||||
position: relative;
|
||||
clear: both;
|
||||
*zoom: 1;
|
||||
zoom: 1;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_length {
|
||||
float: left;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter {
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter input {
|
||||
margin-left: 0.5em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_info {
|
||||
clear: both;
|
||||
float: left;
|
||||
padding-top: 0.55em;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
min-width: 1.5em;
|
||||
padding: 0.5em;
|
||||
margin-left: 2px;
|
||||
text-align: center;
|
||||
text-decoration: none !important;
|
||||
cursor: pointer;
|
||||
*cursor: hand;
|
||||
color: #333333 !important;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button:active {
|
||||
outline: none;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button:first-child {
|
||||
border-top-left-radius: 3px;
|
||||
border-bottom-left-radius: 3px;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_paginate .fg-button:last-child {
|
||||
border-top-right-radius: 3px;
|
||||
border-bottom-right-radius: 3px;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_processing {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
margin-left: -50%;
|
||||
margin-top: -25px;
|
||||
padding-top: 20px;
|
||||
text-align: center;
|
||||
font-size: 1.2em;
|
||||
background-color: white;
|
||||
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0)), color-stop(25%, rgba(255, 255, 255, 0.9)), color-stop(75%, rgba(255, 255, 255, 0.9)), color-stop(100%, rgba(255, 255, 255, 0)));
|
||||
/* Chrome,Safari4+ */
|
||||
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* Chrome10+,Safari5.1+ */
|
||||
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* FF3.6+ */
|
||||
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* IE10+ */
|
||||
background: -o-linear-gradient(left, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* Opera 11.10+ */
|
||||
background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.9) 25%, rgba(255, 255, 255, 0.9) 75%, rgba(255, 255, 255, 0) 100%);
|
||||
/* W3C */
|
||||
}
|
||||
.dataTables_wrapper .dataTables_length,
|
||||
.dataTables_wrapper .dataTables_filter,
|
||||
.dataTables_wrapper .dataTables_info,
|
||||
.dataTables_wrapper .dataTables_processing,
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
color: #333333;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scroll {
|
||||
clear: both;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_scrollBody {
|
||||
*margin-top: -1px;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
.dataTables_wrapper .ui-widget-header {
|
||||
font-weight: normal;
|
||||
}
|
||||
.dataTables_wrapper .ui-toolbar {
|
||||
padding: 8px;
|
||||
}
|
||||
.dataTables_wrapper:after {
|
||||
visibility: hidden;
|
||||
display: block;
|
||||
content: "";
|
||||
clear: both;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.dataTables_wrapper .dataTables_length,
|
||||
.dataTables_wrapper .dataTables_filter,
|
||||
.dataTables_wrapper .dataTables_info,
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
float: none;
|
||||
text-align: center;
|
||||
}
|
||||
.dataTables_wrapper .dataTables_filter,
|
||||
.dataTables_wrapper .dataTables_paginate {
|
||||
margin-top: 0.5em;
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 944 B |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 841 B |
After Width: | Height: | Size: 881 B |
After Width: | Height: | Size: 1 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 1,013 B |
After Width: | Height: | Size: 4.2 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 2 KiB |
After Width: | Height: | Size: 6.5 KiB |
|
@ -25,7 +25,7 @@ textarea {
|
|||
|
||||
.element-container {
|
||||
margin-bottom: 15px;
|
||||
text-align:center;
|
||||
/*text-align:center;*/
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
@ -54,6 +54,29 @@ textarea {
|
|||
pointer-events: none;
|
||||
}
|
||||
|
||||
tr.selected-file {
|
||||
background-color:#E7F0FC!important;
|
||||
}
|
||||
|
||||
.table-icon {
|
||||
height: 30px;
|
||||
}
|
||||
|
||||
#webdav-items-table tr td {
|
||||
vertical-align: middle !important;
|
||||
}
|
||||
|
||||
#webdav-items-table .file-link {
|
||||
padding-left: 5px;
|
||||
vertical-align: middle !important;
|
||||
}
|
||||
|
||||
.change-view-block {
|
||||
display: inline-block;
|
||||
vertical-align: bottom;
|
||||
height: 32px;
|
||||
}
|
||||
|
||||
#errorMessage {
|
||||
color: red;
|
||||
font-weight: bold;
|
||||
|
@ -79,8 +102,13 @@ textarea {
|
|||
margin-bottom: 0px;
|
||||
}
|
||||
|
||||
.modal-vertical-centered {
|
||||
margin-top: 25%;
|
||||
|
||||
#processDialog .modal-dialog {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
margin-top: -8px;
|
||||
margin-left: -100px;
|
||||
}
|
||||
|
||||
|
||||
|
@ -97,6 +125,15 @@ textarea {
|
|||
margin-top: 15px;
|
||||
}
|
||||
|
||||
#processDialog .dialog-text {
|
||||
display: inline-block;
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
#processDialog .modal-dialog {
|
||||
width: 200px;
|
||||
}
|
||||
|
||||
/* Theme Mods */
|
||||
|
||||
input,div{border-radius:0px!important;}
|
||||
|
|
|
@ -127,11 +127,11 @@ namespace WebsitePanel.WebDavPortal.Controllers.Api
|
|||
}
|
||||
|
||||
[HttpPost]
|
||||
public async Task<HttpResponseMessage> Put(int accessTokenId)
|
||||
public HttpResponseMessage Put(int accessTokenId)
|
||||
{
|
||||
var token = _tokenManager.GetToken(accessTokenId);
|
||||
|
||||
var bytes = await Request.Content.ReadAsByteArrayAsync();
|
||||
var bytes = Request.Content.ReadAsByteArrayAsync().Result;
|
||||
|
||||
_webDavManager.UploadFile(token.FilePath, bytes);
|
||||
|
||||
|
|
|
@ -8,20 +8,28 @@ using System.Security.Policy;
|
|||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using System.Web.Routing;
|
||||
using AutoMapper;
|
||||
using log4net;
|
||||
using WebsitePanel.WebDav.Core;
|
||||
using WebsitePanel.WebDav.Core.Client;
|
||||
using WebsitePanel.WebDav.Core.Config;
|
||||
using WebsitePanel.WebDav.Core.Entities.Account.Enums;
|
||||
using WebsitePanel.WebDav.Core.Exceptions;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Managers;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Managers.Users;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Security;
|
||||
using WebsitePanel.WebDav.Core.Security.Authorization.Enums;
|
||||
using WebsitePanel.WebDav.Core.Security.Cryptography;
|
||||
using WebsitePanel.WebDav.Core.Wsp.Framework;
|
||||
using WebsitePanel.WebDavPortal.CustomAttributes;
|
||||
using WebsitePanel.WebDavPortal.Extensions;
|
||||
using WebsitePanel.WebDavPortal.FileOperations;
|
||||
using WebsitePanel.WebDavPortal.Helpers;
|
||||
using WebsitePanel.WebDavPortal.ModelBinders.DataTables;
|
||||
using WebsitePanel.WebDavPortal.Models;
|
||||
using System.Net;
|
||||
using WebsitePanel.WebDavPortal.Models.Common;
|
||||
using WebsitePanel.WebDavPortal.Models.Common.DataTable;
|
||||
using WebsitePanel.WebDavPortal.Models.Common.Enums;
|
||||
using WebsitePanel.WebDavPortal.Models.FileSystem;
|
||||
using WebsitePanel.WebDavPortal.UI;
|
||||
|
@ -39,19 +47,29 @@ namespace WebsitePanel.WebDavPortal.Controllers
|
|||
private readonly IAuthenticationService _authenticationService;
|
||||
private readonly IAccessTokenManager _tokenManager;
|
||||
private readonly IWebDavAuthorizationService _webDavAuthorizationService;
|
||||
private readonly IUserSettingsManager _userSettingsManager;
|
||||
private readonly ILog Log;
|
||||
|
||||
public FileSystemController(ICryptography cryptography, IWebDavManager webdavManager, IAuthenticationService authenticationService, IAccessTokenManager tokenManager, IWebDavAuthorizationService webDavAuthorizationService)
|
||||
public FileSystemController(ICryptography cryptography, IWebDavManager webdavManager, IAuthenticationService authenticationService, IAccessTokenManager tokenManager, IWebDavAuthorizationService webDavAuthorizationService, FileOpenerManager openerManager, IUserSettingsManager userSettingsManager)
|
||||
{
|
||||
_cryptography = cryptography;
|
||||
_webdavManager = webdavManager;
|
||||
_authenticationService = authenticationService;
|
||||
_tokenManager = tokenManager;
|
||||
_webDavAuthorizationService = webDavAuthorizationService;
|
||||
_userSettingsManager = userSettingsManager;
|
||||
|
||||
Log = LogManager.GetLogger(this.GetType());
|
||||
}
|
||||
|
||||
[HttpGet]
|
||||
public ActionResult ChangeViewType(FolderViewTypes viewType, string org, string pathPart = "")
|
||||
{
|
||||
_userSettingsManager.ChangeWebDavViewType(WspContext.User.AccountId, viewType);
|
||||
|
||||
return RedirectToRoute(FileSystemRouteNames.ShowContentPath, new { org, pathPart });
|
||||
}
|
||||
|
||||
[HttpGet]
|
||||
public ActionResult ShowContent(string org, string pathPart = "")
|
||||
{
|
||||
|
@ -70,11 +88,12 @@ namespace WebsitePanel.WebDavPortal.Controllers
|
|||
|
||||
try
|
||||
{
|
||||
IEnumerable<IHierarchyItem> children = _webdavManager.OpenFolder(pathPart);
|
||||
|
||||
var permissions = _webDavAuthorizationService.GetPermissions(WspContext.User, pathPart);
|
||||
|
||||
var model = new ModelForWebDav { Items = children.Take(WebDavAppConfigManager.Instance.ElementsRendering.DefaultCount), UrlSuffix = pathPart, Permissions = permissions};
|
||||
var model = new ModelForWebDav
|
||||
{
|
||||
UrlSuffix = pathPart,
|
||||
Permissions =_webDavAuthorizationService.GetPermissions(WspContext.User, pathPart),
|
||||
UserSettings = _userSettingsManager.GetUserSettings(WspContext.User.AccountId)
|
||||
};
|
||||
|
||||
return View(model);
|
||||
}
|
||||
|
@ -84,42 +103,46 @@ namespace WebsitePanel.WebDavPortal.Controllers
|
|||
}
|
||||
}
|
||||
|
||||
public ActionResult ShowOfficeDocument(string org, string pathPart, string owaOpenerUri)
|
||||
[ChildActionOnly]
|
||||
public ActionResult ContentList(string org, FolderViewTypes viewType, string pathPart = "")
|
||||
{
|
||||
string fileUrl = WebDavAppConfigManager.Instance.WebdavRoot+ org + "/" + pathPart.TrimStart('/');
|
||||
var accessToken = _tokenManager.CreateToken(WspContext.User, pathPart);
|
||||
|
||||
var urlPart = Url.HttpRouteUrl(OwaRouteNames.CheckFileInfo, new {accessTokenId = accessToken.Id});
|
||||
var url = new Uri(Request.Url, urlPart).ToString();
|
||||
|
||||
string wopiSrc = Server.UrlDecode(url);
|
||||
|
||||
var uri = string.Format("{0}/{1}WOPISrc={2}&access_token={3}", WebDavAppConfigManager.Instance.OfficeOnline.Url, owaOpenerUri, Server.UrlEncode(wopiSrc), Server.UrlEncode(accessToken.AccessToken.ToString("N")));
|
||||
|
||||
string fileName = fileUrl.Split('/').Last();
|
||||
|
||||
return View("ShowOfficeDocument", new OfficeOnlineModel(uri, fileName));
|
||||
}
|
||||
|
||||
public ActionResult ViewOfficeDocument(string org, string pathPart)
|
||||
{
|
||||
var owaOpener = WebDavAppConfigManager.Instance.OfficeOnline.Single(x => x.Extension == Path.GetExtension(pathPart));
|
||||
|
||||
return ShowOfficeDocument(org, pathPart, owaOpener.OwaView);
|
||||
}
|
||||
|
||||
public ActionResult EditOfficeDocument(string org, string pathPart)
|
||||
{
|
||||
var permissions = _webDavAuthorizationService.GetPermissions(WspContext.User, pathPart);
|
||||
|
||||
if (permissions.HasFlag(WebDavPermissions.Write) == false)
|
||||
try
|
||||
{
|
||||
return new RedirectToRouteResult(FileSystemRouteNames.ViewOfficeOnline, null);
|
||||
IEnumerable<IHierarchyItem> children = _webdavManager.OpenFolder(pathPart);
|
||||
|
||||
var model = new ModelForWebDav
|
||||
{
|
||||
UrlSuffix = pathPart,
|
||||
Permissions = _webDavAuthorizationService.GetPermissions(WspContext.User, pathPart),
|
||||
UserSettings = _userSettingsManager.GetUserSettings(WspContext.User.AccountId)
|
||||
};
|
||||
|
||||
if (Request.Browser.IsMobileDevice == false && model.UserSettings.WebDavViewType == FolderViewTypes.Table)
|
||||
{
|
||||
return View("_ShowContentTable", model);
|
||||
}
|
||||
|
||||
model.Items = children.Take(WebDavAppConfigManager.Instance.ElementsRendering.DefaultCount);
|
||||
|
||||
return View("_ShowContentBigIcons", model);
|
||||
}
|
||||
catch (UnauthorizedException e)
|
||||
{
|
||||
throw new HttpException(404, "Not Found");
|
||||
}
|
||||
}
|
||||
|
||||
var owaOpener = WebDavAppConfigManager.Instance.OfficeOnline.Single(x => x.Extension == Path.GetExtension(pathPart));
|
||||
|
||||
return ShowOfficeDocument(org, pathPart, owaOpener.OwaEditor);
|
||||
[HttpGet]
|
||||
public ActionResult GetContentDetails(string org, string pathPart, [ModelBinder(typeof (JqueryDataTableModelBinder))] JqueryDataTableRequest dtRequest)
|
||||
{
|
||||
var folderItems = _webdavManager.OpenFolder(pathPart);
|
||||
|
||||
var tableItems = Mapper.Map<IEnumerable<IHierarchyItem>, IEnumerable<ResourceTableItemModel>>(folderItems).ToList();
|
||||
|
||||
var dataTableResponse = DataTableHelper.ProcessRequest(tableItems, dtRequest);
|
||||
|
||||
return Json(dataTableResponse, JsonRequestBehavior.AllowGet);
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
|
@ -146,7 +169,7 @@ namespace WebsitePanel.WebDavPortal.Controllers
|
|||
|
||||
if (_webdavManager.IsFile(pathPart) == false)
|
||||
{
|
||||
throw new Exception(Resources.NotAFile);
|
||||
throw new Exception(Resources.UI.NotAFile);
|
||||
}
|
||||
|
||||
var fileBytes = _webdavManager.GetFileBytes(pathPart);
|
||||
|
@ -179,7 +202,7 @@ namespace WebsitePanel.WebDavPortal.Controllers
|
|||
|
||||
if (filePathes == null)
|
||||
{
|
||||
model.AddMessage(MessageType.Error, Resources.NoFilesAreSelected);
|
||||
model.AddMessage(MessageType.Error, Resources.UI.NoFilesAreSelected);
|
||||
|
||||
return Json(model);
|
||||
}
|
||||
|
@ -200,10 +223,52 @@ namespace WebsitePanel.WebDavPortal.Controllers
|
|||
|
||||
if (model.DeletedFiles.Any())
|
||||
{
|
||||
model.AddMessage(MessageType.Success, string.Format(Resources.ItemsWasRemovedFormat, model.DeletedFiles.Count));
|
||||
model.AddMessage(MessageType.Success, string.Format(Resources.UI.ItemsWasRemovedFormat, model.DeletedFiles.Count));
|
||||
}
|
||||
|
||||
return Json(model);
|
||||
}
|
||||
|
||||
#region Owa Actions
|
||||
|
||||
public ActionResult ShowOfficeDocument(string org, string pathPart, string owaOpenerUri)
|
||||
{
|
||||
string fileUrl = WebDavAppConfigManager.Instance.WebdavRoot + org + "/" + pathPart.TrimStart('/');
|
||||
var accessToken = _tokenManager.CreateToken(WspContext.User, pathPart);
|
||||
|
||||
var urlPart = Url.HttpRouteUrl(OwaRouteNames.CheckFileInfo, new { accessTokenId = accessToken.Id });
|
||||
var url = new Uri(Request.Url, urlPart).ToString();
|
||||
|
||||
string wopiSrc = Server.UrlDecode(url);
|
||||
|
||||
var uri = string.Format("{0}/{1}WOPISrc={2}&access_token={3}", WebDavAppConfigManager.Instance.OfficeOnline.Url, owaOpenerUri, Server.UrlEncode(wopiSrc), Server.UrlEncode(accessToken.AccessToken.ToString("N")));
|
||||
|
||||
string fileName = fileUrl.Split('/').Last();
|
||||
|
||||
return View("ShowOfficeDocument", new OfficeOnlineModel(uri, fileName));
|
||||
}
|
||||
|
||||
public ActionResult ViewOfficeDocument(string org, string pathPart)
|
||||
{
|
||||
var owaOpener = WebDavAppConfigManager.Instance.OfficeOnline.Single(x => x.Extension == Path.GetExtension(pathPart));
|
||||
|
||||
return ShowOfficeDocument(org, pathPart, owaOpener.OwaView);
|
||||
}
|
||||
|
||||
public ActionResult EditOfficeDocument(string org, string pathPart)
|
||||
{
|
||||
var permissions = _webDavAuthorizationService.GetPermissions(WspContext.User, pathPart);
|
||||
|
||||
if (permissions.HasFlag(WebDavPermissions.Write) == false)
|
||||
{
|
||||
return new RedirectToRouteResult(FileSystemRouteNames.ViewOfficeOnline, null);
|
||||
}
|
||||
|
||||
var owaOpener = WebDavAppConfigManager.Instance.OfficeOnline.Single(x => x.Extension == Path.GetExtension(pathPart));
|
||||
|
||||
return ShowOfficeDocument(org, pathPart, owaOpener.OwaEditor);
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
|
@ -1,10 +1,12 @@
|
|||
using Ninject;
|
||||
using System.Web.SessionState;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Managers;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Managers.Users;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Owa;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Security;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Storages;
|
||||
using WebsitePanel.WebDav.Core.Managers;
|
||||
using WebsitePanel.WebDav.Core.Managers.Users;
|
||||
using WebsitePanel.WebDav.Core.Owa;
|
||||
using WebsitePanel.WebDav.Core.Security.Authentication;
|
||||
using WebsitePanel.WebDav.Core.Security.Authorization;
|
||||
|
@ -28,6 +30,7 @@ namespace WebsitePanel.WebDavPortal.DependencyInjection
|
|||
kernel.Bind<IWebDavAuthorizationService>().To<WebDavAuthorizationService>();
|
||||
kernel.Bind<ICobaltManager>().To<CobaltManager>();
|
||||
kernel.Bind<ITtlStorage>().To<CacheTtlStorage>();
|
||||
kernel.Bind<IUserSettingsManager>().To<UserSettingsManager>();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,38 +0,0 @@
|
|||
using System.Net;
|
||||
using System.Web.SessionState;
|
||||
using Ninject;
|
||||
using Ninject.Activation;
|
||||
using WebsitePanel.WebDav.Core;
|
||||
using WebsitePanel.WebDav.Core.Config;
|
||||
using WebsitePanel.WebDav.Core.Managers;
|
||||
using WebsitePanel.WebDav.Core.Security.Cryptography;
|
||||
using WebsitePanel.WebDavPortal.Models;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.DependencyInjection.Providers
|
||||
{
|
||||
public class WebDavManagerProvider : Provider<WebDavManager>
|
||||
{
|
||||
protected override WebDavManager CreateInstance(IContext context)
|
||||
{
|
||||
var session = context.Kernel.Get<HttpSessionState>();
|
||||
|
||||
WebDavManager webDavManager = null;
|
||||
|
||||
if (session != null)
|
||||
{
|
||||
webDavManager = session[WebDavAppConfigManager.Instance.SessionKeys.WebDavManager] as WebDavManager;
|
||||
|
||||
if (webDavManager == null)
|
||||
{
|
||||
var cryptography = context.Kernel.Get<ICryptography>();
|
||||
|
||||
webDavManager = new WebDavManager(cryptography);
|
||||
|
||||
session[WebDavAppConfigManager.Instance.SessionKeys.WebDavManager] = webDavManager;
|
||||
}
|
||||
}
|
||||
|
||||
return webDavManager;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,15 +1,21 @@
|
|||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using WebsitePanel.WebDav.Core;
|
||||
using WebsitePanel.WebDav.Core.Client;
|
||||
using WebsitePanel.WebDav.Core.Config;
|
||||
using WebsitePanel.WebDavPortal.Extensions;
|
||||
using WebsitePanel.WebDavPortal.UI.Routes;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.FileOperations
|
||||
{
|
||||
public class FileOpenerManager
|
||||
{
|
||||
private readonly IDictionary<string, FileOpenerType> _operationTypes = new Dictionary<string, FileOpenerType>();
|
||||
private UrlHelper _urlHelper;
|
||||
|
||||
public FileOpenerManager()
|
||||
{
|
||||
|
@ -17,6 +23,44 @@ namespace WebsitePanel.WebDavPortal.FileOperations
|
|||
_operationTypes.AddRange(WebDavAppConfigManager.Instance.OfficeOnline.ToDictionary(x => x.Extension, y => FileOpenerType.OfficeOnline));
|
||||
}
|
||||
|
||||
public string GetUrl(IHierarchyItem item)
|
||||
{
|
||||
_urlHelper =_urlHelper ?? new UrlHelper(HttpContext.Current.Request.RequestContext);
|
||||
|
||||
var opener = this[Path.GetExtension(item.DisplayName)];
|
||||
string href = "/";
|
||||
|
||||
switch (opener)
|
||||
{
|
||||
case FileOpenerType.OfficeOnline:
|
||||
{
|
||||
var pathPart = item.Href.AbsolutePath.Replace("/" + WspContext.User.OrganizationId, "").TrimStart('/');
|
||||
href = string.Concat(_urlHelper.RouteUrl(FileSystemRouteNames.EditOfficeOnline, new { org = WspContext.User.OrganizationId, pathPart = "" }), pathPart);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
href = item.Href.LocalPath;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return href;
|
||||
}
|
||||
|
||||
public bool GetIsTargetBlank(IHierarchyItem item)
|
||||
{
|
||||
var opener = this[Path.GetExtension(item.DisplayName)];
|
||||
|
||||
switch (opener)
|
||||
{
|
||||
case FileOpenerType.OfficeOnline:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public FileOpenerType this[string fileExtension]
|
||||
{
|
||||
get
|
||||
|
|
|
@ -8,6 +8,7 @@ using System.Web.Routing;
|
|||
using System.Web.Script.Serialization;
|
||||
using System.Web.Security;
|
||||
using System.Web.SessionState;
|
||||
using AutoMapper;
|
||||
using WebsitePanel.WebDav.Core.Config;
|
||||
using WebsitePanel.WebDav.Core.Interfaces.Security;
|
||||
using WebsitePanel.WebDav.Core.Security.Authentication.Principals;
|
||||
|
@ -16,6 +17,7 @@ using WebsitePanel.WebDavPortal.App_Start;
|
|||
using WebsitePanel.WebDavPortal.Controllers;
|
||||
using WebsitePanel.WebDavPortal.DependencyInjection;
|
||||
using WebsitePanel.WebDavPortal.HttpHandlers;
|
||||
using WebsitePanel.WebDavPortal.Mapping;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal
|
||||
{
|
||||
|
@ -32,6 +34,10 @@ namespace WebsitePanel.WebDavPortal
|
|||
|
||||
DependencyResolver.SetResolver(new NinjectDependecyResolver());
|
||||
|
||||
AutoMapperPortalConfiguration.Configure();
|
||||
|
||||
Mapper.AssertConfigurationIsValid();
|
||||
|
||||
log4net.Config.XmlConfigurator.Configure();
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,44 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using WebsitePanel.WebDavPortal.Models.Common.DataTable;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Helpers
|
||||
{
|
||||
public class DataTableHelper
|
||||
{
|
||||
public static JqueryDataTablesResponse ProcessRequest<TEntity>(IEnumerable<TEntity> entities, JqueryDataTableRequest request) where TEntity : JqueryDataTableBaseEntity
|
||||
{
|
||||
IOrderedEnumerable<TEntity> orderedEntities = null;
|
||||
|
||||
foreach (var order in request.Orders)
|
||||
{
|
||||
var closure = order;
|
||||
|
||||
if (orderedEntities == null)
|
||||
{
|
||||
orderedEntities = order.Ascending ? entities.OrderBy(x => x[closure.Column]) : entities.OrderByDescending(x => x[closure.Column]);
|
||||
}
|
||||
else
|
||||
{
|
||||
orderedEntities = order.Ascending ? orderedEntities.ThenBy(x => x[closure.Column]) : orderedEntities.ThenByDescending(x => x[closure.Column]);
|
||||
}
|
||||
}
|
||||
|
||||
if (orderedEntities == null)
|
||||
{
|
||||
orderedEntities = entities.OrderBy(x=>x[0]);
|
||||
}
|
||||
|
||||
var itemsPaged = orderedEntities.Skip(request.Start).Take(request.Count).ToList();
|
||||
var totalCount = orderedEntities.Count();
|
||||
|
||||
|
||||
return new JqueryDataTablesResponse(
|
||||
request.Draw,
|
||||
itemsPaged,
|
||||
totalCount,
|
||||
totalCount);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
using AutoMapper;
|
||||
using WebsitePanel.WebDavPortal.Mapping.Profiles.Webdav;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Mapping
|
||||
{
|
||||
public class AutoMapperPortalConfiguration
|
||||
{
|
||||
public static void Configure()
|
||||
{
|
||||
Mapper.Initialize(
|
||||
config =>
|
||||
{
|
||||
config.AddProfile<ResourceTableItemProfile>();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using AutoMapper;
|
||||
using WebsitePanel.WebDav.Core.Client;
|
||||
using WebsitePanel.WebDav.Core.Config;
|
||||
using WebsitePanel.WebDav.Core.Extensions;
|
||||
using WebsitePanel.WebDavPortal.FileOperations;
|
||||
using WebsitePanel.WebDavPortal.Models.FileSystem;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Mapping.Profiles.Webdav
|
||||
{
|
||||
public class ResourceTableItemProfile : Profile
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the name of the profile.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The name of the profile.
|
||||
/// </value>
|
||||
public override string ProfileName
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.GetType().Name;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Override this method in a derived class and call the CreateMap method to associate that map with this profile.
|
||||
/// Avoid calling the <see cref="T:AutoMapper.Mapper" /> class from this method.
|
||||
/// </summary>
|
||||
protected override void Configure()
|
||||
{
|
||||
var openerManager = new FileOpenerManager();
|
||||
|
||||
Mapper.CreateMap<IHierarchyItem, ResourceTableItemModel>()
|
||||
.ForMember(ti => ti.DisplayName, x => x.MapFrom(hi => hi.DisplayName.Trim('/')))
|
||||
.ForMember(ti => ti.Url, x => x.MapFrom(hi => openerManager.GetUrl(hi)))
|
||||
.ForMember(ti => ti.IsTargetBlank, x => x.MapFrom(hi => openerManager.GetIsTargetBlank(hi)))
|
||||
.ForMember(ti => ti.Type, x => x.MapFrom(hi => (new WebDavResource(null, hi)).ItemType.GetDescription().ToLowerInvariant()))
|
||||
.ForMember(ti => ti.IconHref, x => x.MapFrom(hi => (new WebDavResource(null, hi)).ItemType == ItemType.Folder ? WebDavAppConfigManager.Instance.FileIcons.FolderPath.Trim('~') : WebDavAppConfigManager.Instance.FileIcons[Path.GetExtension(hi.DisplayName.Trim('/'))].Trim('~')))
|
||||
.ForMember(ti => ti.LastModified,
|
||||
x => x.MapFrom(hi => (new WebDavResource(null, hi)).LastModified == DateTime.MinValue ? "--" : (new WebDavResource(null, hi)).LastModified.ToString("dd/MM/yyyy hh:mm tt")))
|
||||
.ForMember(ti => ti.Size, x => x.MapFrom(hi => (new WebDavResource(null,hi)).ContentLength));
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,78 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using Microsoft.Ajax.Utilities;
|
||||
using WebsitePanel.WebDavPortal.Models.Common.DataTable;
|
||||
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.ModelBinders.DataTables
|
||||
{
|
||||
public class JqueryDataTableModelBinder : DefaultModelBinder
|
||||
{
|
||||
public override object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext)
|
||||
{
|
||||
base.BindModel(controllerContext, bindingContext);
|
||||
HttpRequestBase request = controllerContext.HttpContext.Request;
|
||||
|
||||
// Retrieve request data
|
||||
int draw = Convert.ToInt32(request["draw"]);
|
||||
int start = Convert.ToInt32(request["start"]);
|
||||
int count = Convert.ToInt32(request["length"]);
|
||||
|
||||
// Search
|
||||
var search = new JqueryDataTableSearch
|
||||
{
|
||||
Value = request["search[value]"],
|
||||
IsRegex = Convert.ToBoolean(request["search[regex]"])
|
||||
};
|
||||
|
||||
var orderIndex = 0;
|
||||
|
||||
var orders = new List<JqueryDataTableOrder>();
|
||||
|
||||
while (request["order[" + orderIndex + "][column]"] != null)
|
||||
{
|
||||
orders.Add(new JqueryDataTableOrder()
|
||||
{
|
||||
Column = Convert.ToInt32(request["order[" + orderIndex + "][column]"]),
|
||||
Ascending = (request["order[" + orderIndex + "][dir]"] == "asc")
|
||||
});
|
||||
|
||||
orderIndex++;
|
||||
}
|
||||
|
||||
// Columns
|
||||
var columnsIndex = 0;
|
||||
var columns = new List<JqueryDataTableColumn>();
|
||||
|
||||
while (request["columns[" + columnsIndex + "][name]"] != null)
|
||||
{
|
||||
columns.Add(new JqueryDataTableColumn
|
||||
{
|
||||
Data = request["columns[" + columnsIndex + "][data]"],
|
||||
Name = request["columns[" + columnsIndex + "][name]"],
|
||||
Orderable = Convert.ToBoolean(request["columns[" + columnsIndex + "][orderable]"]),
|
||||
Search = new JqueryDataTableSearch
|
||||
{
|
||||
Value = request["columns[" + columnsIndex + "][search][value]"],
|
||||
IsRegex = Convert.ToBoolean(request["columns[" + columnsIndex + "][search][regex]"])
|
||||
}
|
||||
});
|
||||
|
||||
columnsIndex++;
|
||||
}
|
||||
|
||||
return new JqueryDataTableRequest
|
||||
{
|
||||
Draw = draw,
|
||||
Start = start,
|
||||
Count = count,
|
||||
Search = search,
|
||||
Orders = orders,
|
||||
Columns = columns
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Models.Common.DataTable
|
||||
{
|
||||
public abstract class JqueryDataTableBaseEntity
|
||||
{
|
||||
public abstract dynamic this[int index]
|
||||
{
|
||||
get;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
namespace WebsitePanel.WebDavPortal.Models.Common.DataTable
|
||||
{
|
||||
public class JqueryDataTableColumn
|
||||
{
|
||||
public string Data { get; set; }
|
||||
|
||||
public string Name { get; set; }
|
||||
|
||||
public bool Orderable { get; set; }
|
||||
|
||||
public JqueryDataTableSearch Search { get; set; }
|
||||
}
|
||||
}
|
|
@ -0,0 +1,8 @@
|
|||
namespace WebsitePanel.WebDavPortal.Models.Common.DataTable
|
||||
{
|
||||
public class JqueryDataTableOrder
|
||||
{
|
||||
public int Column { get; set; }
|
||||
public bool Ascending { get; set; }
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
using System.Collections.Generic;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Models.Common.DataTable
|
||||
{
|
||||
public class JqueryDataTableRequest
|
||||
{
|
||||
public int Draw { get; set; }
|
||||
public int Start { get; set; }
|
||||
public int Count { get; set; }
|
||||
|
||||
|
||||
public JqueryDataTableSearch Search { get; set; }
|
||||
public IEnumerable<JqueryDataTableOrder> Orders { get; set; }
|
||||
public IEnumerable<JqueryDataTableColumn> Columns { get; set; }
|
||||
}
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
namespace WebsitePanel.WebDavPortal.Models.Common.DataTable
|
||||
{
|
||||
public class JqueryDataTableSearch
|
||||
{
|
||||
public string Value { get; set; }
|
||||
|
||||
public bool IsRegex { get; set; }
|
||||
}
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
using System.Collections;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Models.Common.DataTable
|
||||
{
|
||||
public class JqueryDataTablesResponse
|
||||
{
|
||||
public int draw { get; private set; }
|
||||
public IEnumerable data { get; private set; }
|
||||
public int recordsTotal { get; private set; }
|
||||
public int recordsFiltered { get; private set; }
|
||||
|
||||
public JqueryDataTablesResponse(int draw, IEnumerable data, int recordsFilteredCount, int recordsTotalCount)
|
||||
{
|
||||
this.draw = draw;
|
||||
this.data = data;
|
||||
this.recordsFiltered = recordsFilteredCount;
|
||||
this.recordsTotal = recordsTotalCount;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
using WebsitePanel.WebDav.Core.Client;
|
||||
using WebsitePanel.WebDavPortal.Models.Common.DataTable;
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.Models.FileSystem
|
||||
{
|
||||
public class ResourceTableItemModel : JqueryDataTableBaseEntity
|
||||
{
|
||||
public string DisplayName { get; set; }
|
||||
public string Url { get; set; }
|
||||
public bool IsTargetBlank { get; set; }
|
||||
public long Size { get; set; }
|
||||
public string Type { get; set; }
|
||||
public string LastModified { get; set; }
|
||||
public string IconHref { get; set; }
|
||||
|
||||
public override dynamic this[int index]
|
||||
{
|
||||
get
|
||||
{
|
||||
switch (index)
|
||||
{
|
||||
case 1 :
|
||||
{
|
||||
return Size;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return DisplayName;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,5 +1,6 @@
|
|||
using System.Collections.Generic;
|
||||
using WebsitePanel.WebDav.Core.Client;
|
||||
using WebsitePanel.WebDav.Core.Entities.Account;
|
||||
using WebsitePanel.WebDav.Core.Security.Authorization.Enums;
|
||||
using WebsitePanel.WebDavPortal.Models.Common;
|
||||
|
||||
|
@ -11,5 +12,6 @@ namespace WebsitePanel.WebDavPortal.Models
|
|||
public string UrlSuffix { get; set; }
|
||||
public string Error { get; set; }
|
||||
public WebDavPermissions Permissions { get; set; }
|
||||
public UserPortalSettings UserSettings { get; set; }
|
||||
}
|
||||
}
|
|
@ -8,7 +8,7 @@
|
|||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace WebsitePanel.WebDavPortal.UI {
|
||||
namespace WebsitePanel.WebDavPortal.Resources {
|
||||
using System;
|
||||
|
||||
|
||||
|
@ -22,14 +22,14 @@ namespace WebsitePanel.WebDavPortal.UI {
|
|||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
public class Resources {
|
||||
public class UI {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources() {
|
||||
internal UI() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -39,7 +39,7 @@ namespace WebsitePanel.WebDavPortal.UI {
|
|||
public static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WebsitePanel.WebDavPortal.UI.Resources", typeof(Resources).Assembly);
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WebsitePanel.WebDavPortal.Resources.UI", typeof(UI).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
|
@ -114,6 +114,15 @@ namespace WebsitePanel.WebDavPortal.UI {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Details.
|
||||
/// </summary>
|
||||
public static string Details {
|
||||
get {
|
||||
return ResourceManager.GetString("Details", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Are you sure you want to delete {0} item(s)?.
|
||||
/// </summary>
|
||||
|
@ -150,6 +159,24 @@ namespace WebsitePanel.WebDavPortal.UI {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Modified.
|
||||
/// </summary>
|
||||
public static string Modified {
|
||||
get {
|
||||
return ResourceManager.GetString("Modified", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Name.
|
||||
/// </summary>
|
||||
public static string Name {
|
||||
get {
|
||||
return ResourceManager.GetString("Name", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to No files are selected..
|
||||
/// </summary>
|
||||
|
@ -168,6 +195,15 @@ namespace WebsitePanel.WebDavPortal.UI {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Please wait....
|
||||
/// </summary>
|
||||
public static string PleaseWaitWithDots {
|
||||
get {
|
||||
return ResourceManager.GetString("PleaseWaitWithDots", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Processing.
|
||||
/// </summary>
|
||||
|
@ -186,6 +222,33 @@ namespace WebsitePanel.WebDavPortal.UI {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Size.
|
||||
/// </summary>
|
||||
public static string Size {
|
||||
get {
|
||||
return ResourceManager.GetString("Size", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Table.
|
||||
/// </summary>
|
||||
public static string Table {
|
||||
get {
|
||||
return ResourceManager.GetString("Table", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Type.
|
||||
/// </summary>
|
||||
public static string Type {
|
||||
get {
|
||||
return ResourceManager.GetString("Type", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Upload.
|
||||
/// </summary>
|
|
@ -135,6 +135,9 @@
|
|||
<data name="DeleteFileQuestion" xml:space="preserve">
|
||||
<value>Delete File?</value>
|
||||
</data>
|
||||
<data name="Details" xml:space="preserve">
|
||||
<value>Details</value>
|
||||
</data>
|
||||
<data name="DialogsContentConfrimFileDeletion" xml:space="preserve">
|
||||
<value>Are you sure you want to delete {0} item(s)?</value>
|
||||
</data>
|
||||
|
@ -147,18 +150,36 @@
|
|||
<data name="ItemsWasRemovedFormat" xml:space="preserve">
|
||||
<value>{0} items was removed.</value>
|
||||
</data>
|
||||
<data name="Modified" xml:space="preserve">
|
||||
<value>Modified</value>
|
||||
</data>
|
||||
<data name="Name" xml:space="preserve">
|
||||
<value>Name</value>
|
||||
</data>
|
||||
<data name="NoFilesAreSelected" xml:space="preserve">
|
||||
<value>No files are selected.</value>
|
||||
</data>
|
||||
<data name="NotAFile" xml:space="preserve">
|
||||
<value>Not a file.</value>
|
||||
</data>
|
||||
<data name="PleaseWaitWithDots" xml:space="preserve">
|
||||
<value>Please wait...</value>
|
||||
</data>
|
||||
<data name="Processing" xml:space="preserve">
|
||||
<value>Processing</value>
|
||||
</data>
|
||||
<data name="ProcessingWithDots" xml:space="preserve">
|
||||
<value>Processing...</value>
|
||||
</data>
|
||||
<data name="Size" xml:space="preserve">
|
||||
<value>Size</value>
|
||||
</data>
|
||||
<data name="Table" xml:space="preserve">
|
||||
<value>Table</value>
|
||||
</data>
|
||||
<data name="Type" xml:space="preserve">
|
||||
<value>Type</value>
|
||||
</data>
|
||||
<data name="Upload" xml:space="preserve">
|
||||
<value>Upload</value>
|
||||
</data>
|
|
@ -0,0 +1,855 @@
|
|||
/*! AutoFill 1.2.1
|
||||
* ©2008-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
|
||||
/**
|
||||
* @summary AutoFill
|
||||
* @description Add Excel like click and drag auto-fill options to DataTables
|
||||
* @version 1.2.1
|
||||
* @file dataTables.autoFill.js
|
||||
* @author SpryMedia Ltd (www.sprymedia.co.uk)
|
||||
* @contact www.sprymedia.co.uk/contact
|
||||
* @copyright Copyright 2010-2014 SpryMedia Ltd.
|
||||
*
|
||||
* This source file is free software, available under the following license:
|
||||
* MIT license - http://datatables.net/license/mit
|
||||
*
|
||||
* This source file is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
|
||||
*
|
||||
* For details please refer to: http://www.datatables.net
|
||||
*/
|
||||
|
||||
(function( window, document, undefined ) {
|
||||
|
||||
var factory = function( $, DataTable ) {
|
||||
"use strict";
|
||||
|
||||
/**
|
||||
* AutoFill provides Excel like auto-fill features for a DataTable
|
||||
*
|
||||
* @class AutoFill
|
||||
* @constructor
|
||||
* @param {object} oTD DataTables settings object
|
||||
* @param {object} oConfig Configuration object for AutoFill
|
||||
*/
|
||||
var AutoFill = function( oDT, oConfig )
|
||||
{
|
||||
/* Sanity check that we are a new instance */
|
||||
if ( ! (this instanceof AutoFill) ) {
|
||||
throw( "Warning: AutoFill must be initialised with the keyword 'new'" );
|
||||
}
|
||||
|
||||
if ( ! $.fn.dataTableExt.fnVersionCheck('1.7.0') ) {
|
||||
throw( "Warning: AutoFill requires DataTables 1.7 or greater");
|
||||
}
|
||||
|
||||
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Public class variables
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
this.c = {};
|
||||
|
||||
/**
|
||||
* @namespace Settings object which contains customisable information for AutoFill instance
|
||||
*/
|
||||
this.s = {
|
||||
/**
|
||||
* @namespace Cached information about the little dragging icon (the filler)
|
||||
*/
|
||||
"filler": {
|
||||
"height": 0,
|
||||
"width": 0
|
||||
},
|
||||
|
||||
/**
|
||||
* @namespace Cached information about the border display
|
||||
*/
|
||||
"border": {
|
||||
"width": 2
|
||||
},
|
||||
|
||||
/**
|
||||
* @namespace Store for live information for the current drag
|
||||
*/
|
||||
"drag": {
|
||||
"startX": -1,
|
||||
"startY": -1,
|
||||
"startTd": null,
|
||||
"endTd": null,
|
||||
"dragging": false
|
||||
},
|
||||
|
||||
/**
|
||||
* @namespace Data cache for information that we need for scrolling the screen when we near
|
||||
* the edges
|
||||
*/
|
||||
"screen": {
|
||||
"interval": null,
|
||||
"y": 0,
|
||||
"height": 0,
|
||||
"scrollTop": 0
|
||||
},
|
||||
|
||||
/**
|
||||
* @namespace Data cache for the position of the DataTables scrolling element (when scrolling
|
||||
* is enabled)
|
||||
*/
|
||||
"scroller": {
|
||||
"top": 0,
|
||||
"bottom": 0
|
||||
},
|
||||
|
||||
/**
|
||||
* @namespace Information stored for each column. An array of objects
|
||||
*/
|
||||
"columns": []
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @namespace Common and useful DOM elements for the class instance
|
||||
*/
|
||||
this.dom = {
|
||||
"table": null,
|
||||
"filler": null,
|
||||
"borderTop": null,
|
||||
"borderRight": null,
|
||||
"borderBottom": null,
|
||||
"borderLeft": null,
|
||||
"currentTarget": null
|
||||
};
|
||||
|
||||
|
||||
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Public class methods
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
/**
|
||||
* Retreieve the settings object from an instance
|
||||
* @method fnSettings
|
||||
* @returns {object} AutoFill settings object
|
||||
*/
|
||||
this.fnSettings = function () {
|
||||
return this.s;
|
||||
};
|
||||
|
||||
|
||||
/* Constructor logic */
|
||||
this._fnInit( oDT, oConfig );
|
||||
return this;
|
||||
};
|
||||
|
||||
|
||||
|
||||
AutoFill.prototype = {
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Private methods (they are of course public in JS, but recommended as private)
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
/**
|
||||
* Initialisation
|
||||
* @method _fnInit
|
||||
* @param {object} dt DataTables settings object
|
||||
* @param {object} config Configuration object for AutoFill
|
||||
* @returns void
|
||||
*/
|
||||
"_fnInit": function ( dt, config )
|
||||
{
|
||||
var
|
||||
that = this,
|
||||
i, iLen;
|
||||
|
||||
// Use DataTables API to get the settings allowing selectors, instances
|
||||
// etc to be used, or for backwards compatibility get from the old
|
||||
// fnSettings method
|
||||
this.s.dt = DataTable.Api ?
|
||||
new DataTable.Api( dt ).settings()[0] :
|
||||
dt.fnSettings();
|
||||
this.s.init = config || {};
|
||||
this.dom.table = this.s.dt.nTable;
|
||||
|
||||
$.extend( true, this.c, AutoFill.defaults, config );
|
||||
|
||||
/* Add and configure the columns */
|
||||
this._initColumns();
|
||||
|
||||
/* Auto Fill click and drag icon */
|
||||
var filler = $('<div/>', {
|
||||
'class': 'AutoFill_filler'
|
||||
} )
|
||||
.appendTo( 'body' );
|
||||
this.dom.filler = filler[0];
|
||||
|
||||
// Get the height / width of the click element
|
||||
this.s.filler.height = filler.height();
|
||||
this.s.filler.width = filler.width();
|
||||
filler[0].style.display = "none";
|
||||
|
||||
/* Border display - one div for each side. We can't just use a single
|
||||
* one with a border, as we want the events to effectively pass through
|
||||
* the transparent bit of the box
|
||||
*/
|
||||
var border;
|
||||
var appender = document.body;
|
||||
if ( that.s.dt.oScroll.sY !== "" ) {
|
||||
that.s.dt.nTable.parentNode.style.position = "relative";
|
||||
appender = that.s.dt.nTable.parentNode;
|
||||
}
|
||||
|
||||
border = $('<div/>', {
|
||||
"class": "AutoFill_border"
|
||||
} );
|
||||
this.dom.borderTop = border.clone().appendTo( appender )[0];
|
||||
this.dom.borderRight = border.clone().appendTo( appender )[0];
|
||||
this.dom.borderBottom = border.clone().appendTo( appender )[0];
|
||||
this.dom.borderLeft = border.clone().appendTo( appender )[0];
|
||||
|
||||
/* Events */
|
||||
filler.on( 'mousedown.DTAF', function (e) {
|
||||
this.onselectstart = function() { return false; };
|
||||
that._fnFillerDragStart.call( that, e );
|
||||
return false;
|
||||
} );
|
||||
|
||||
$('tbody', this.dom.table).on(
|
||||
'mouseover.DTAF mouseout.DTAF',
|
||||
'>tr>td, >tr>th',
|
||||
function (e) {
|
||||
that._fnFillerDisplay.call( that, e );
|
||||
}
|
||||
);
|
||||
|
||||
$(this.dom.table).on( 'destroy.dt.DTAF', function () {
|
||||
filler.off( 'mousedown.DTAF' ).remove();
|
||||
$('tbody', this.dom.table).off( 'mouseover.DTAF mouseout.DTAF' );
|
||||
} );
|
||||
},
|
||||
|
||||
|
||||
_initColumns: function ( )
|
||||
{
|
||||
var that = this;
|
||||
var i, ien;
|
||||
var dt = this.s.dt;
|
||||
var config = this.s.init;
|
||||
|
||||
for ( i=0, ien=dt.aoColumns.length ; i<ien ; i++ ) {
|
||||
this.s.columns[i] = $.extend( true, {}, AutoFill.defaults.column );
|
||||
}
|
||||
|
||||
dt.oApi._fnApplyColumnDefs(
|
||||
dt,
|
||||
config.aoColumnDefs || config.columnDefs,
|
||||
config.aoColumns || config.columns,
|
||||
function (colIdx, def) {
|
||||
that._fnColumnOptions( colIdx, def );
|
||||
}
|
||||
);
|
||||
|
||||
// For columns which don't have read, write, step functions defined,
|
||||
// use the default ones
|
||||
for ( i=0, ien=dt.aoColumns.length ; i<ien ; i++ ) {
|
||||
var column = this.s.columns[i];
|
||||
|
||||
if ( ! column.read ) {
|
||||
column.read = this._fnReadCell;
|
||||
}
|
||||
if ( ! column.write ) {
|
||||
column.read = this._fnWriteCell;
|
||||
}
|
||||
if ( ! column.step ) {
|
||||
column.read = this._fnStep;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
"_fnColumnOptions": function ( i, opts )
|
||||
{
|
||||
var column = this.s.columns[ i ];
|
||||
var set = function ( outProp, inProp ) {
|
||||
if ( opts[ inProp[0] ] !== undefined ) {
|
||||
column[ outProp ] = opts[ inProp[0] ];
|
||||
}
|
||||
if ( opts[ inProp[1] ] !== undefined ) {
|
||||
column[ outProp ] = opts[ inProp[1] ];
|
||||
}
|
||||
};
|
||||
|
||||
// Compatibility with the old Hungarian style of notation
|
||||
set( 'enable', ['bEnable', 'enable'] );
|
||||
set( 'read', ['fnRead', 'read'] );
|
||||
set( 'write', ['fnWrite', 'write'] );
|
||||
set( 'step', ['fnStep', 'step'] );
|
||||
set( 'increment', ['bIncrement', 'increment'] );
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Find out the coordinates of a given TD cell in a table
|
||||
* @method _fnTargetCoords
|
||||
* @param {Node} nTd
|
||||
* @returns {Object} x and y properties, for the position of the cell in the tables DOM
|
||||
*/
|
||||
"_fnTargetCoords": function ( nTd )
|
||||
{
|
||||
var nTr = $(nTd).parents('tr')[0];
|
||||
var position = this.s.dt.oInstance.fnGetPosition( nTd );
|
||||
|
||||
return {
|
||||
"x": $('td', nTr).index(nTd),
|
||||
"y": $('tr', nTr.parentNode).index(nTr),
|
||||
"row": position[0],
|
||||
"column": position[2]
|
||||
};
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Display the border around one or more cells (from start to end)
|
||||
* @method _fnUpdateBorder
|
||||
* @param {Node} nStart Starting cell
|
||||
* @param {Node} nEnd Ending cell
|
||||
* @returns void
|
||||
*/
|
||||
"_fnUpdateBorder": function ( nStart, nEnd )
|
||||
{
|
||||
var
|
||||
border = this.s.border.width,
|
||||
offsetStart = $(nStart).offset(),
|
||||
offsetEnd = $(nEnd).offset(),
|
||||
x1 = offsetStart.left - border,
|
||||
x2 = offsetEnd.left + $(nEnd).outerWidth(),
|
||||
y1 = offsetStart.top - border,
|
||||
y2 = offsetEnd.top + $(nEnd).outerHeight(),
|
||||
width = offsetEnd.left + $(nEnd).outerWidth() - offsetStart.left + (2*border),
|
||||
height = offsetEnd.top + $(nEnd).outerHeight() - offsetStart.top + (2*border),
|
||||
oStyle;
|
||||
|
||||
// Recalculate start and end (when dragging "backwards")
|
||||
if( offsetStart.left > offsetEnd.left) {
|
||||
x1 = offsetEnd.left - border;
|
||||
x2 = offsetStart.left + $(nStart).outerWidth();
|
||||
width = offsetStart.left + $(nStart).outerWidth() - offsetEnd.left + (2*border);
|
||||
}
|
||||
|
||||
if ( this.s.dt.oScroll.sY !== "" )
|
||||
{
|
||||
/* The border elements are inside the DT scroller - so position relative to that */
|
||||
var
|
||||
offsetScroll = $(this.s.dt.nTable.parentNode).offset(),
|
||||
scrollTop = $(this.s.dt.nTable.parentNode).scrollTop(),
|
||||
scrollLeft = $(this.s.dt.nTable.parentNode).scrollLeft();
|
||||
|
||||
x1 -= offsetScroll.left - scrollLeft;
|
||||
x2 -= offsetScroll.left - scrollLeft;
|
||||
y1 -= offsetScroll.top - scrollTop;
|
||||
y2 -= offsetScroll.top - scrollTop;
|
||||
}
|
||||
|
||||
/* Top */
|
||||
oStyle = this.dom.borderTop.style;
|
||||
oStyle.top = y1+"px";
|
||||
oStyle.left = x1+"px";
|
||||
oStyle.height = this.s.border.width+"px";
|
||||
oStyle.width = width+"px";
|
||||
|
||||
/* Bottom */
|
||||
oStyle = this.dom.borderBottom.style;
|
||||
oStyle.top = y2+"px";
|
||||
oStyle.left = x1+"px";
|
||||
oStyle.height = this.s.border.width+"px";
|
||||
oStyle.width = width+"px";
|
||||
|
||||
/* Left */
|
||||
oStyle = this.dom.borderLeft.style;
|
||||
oStyle.top = y1+"px";
|
||||
oStyle.left = x1+"px";
|
||||
oStyle.height = height+"px";
|
||||
oStyle.width = this.s.border.width+"px";
|
||||
|
||||
/* Right */
|
||||
oStyle = this.dom.borderRight.style;
|
||||
oStyle.top = y1+"px";
|
||||
oStyle.left = x2+"px";
|
||||
oStyle.height = height+"px";
|
||||
oStyle.width = this.s.border.width+"px";
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Mouse down event handler for starting a drag
|
||||
* @method _fnFillerDragStart
|
||||
* @param {Object} e Event object
|
||||
* @returns void
|
||||
*/
|
||||
"_fnFillerDragStart": function (e)
|
||||
{
|
||||
var that = this;
|
||||
var startingTd = this.dom.currentTarget;
|
||||
|
||||
this.s.drag.dragging = true;
|
||||
|
||||
that.dom.borderTop.style.display = "block";
|
||||
that.dom.borderRight.style.display = "block";
|
||||
that.dom.borderBottom.style.display = "block";
|
||||
that.dom.borderLeft.style.display = "block";
|
||||
|
||||
var coords = this._fnTargetCoords( startingTd );
|
||||
this.s.drag.startX = coords.x;
|
||||
this.s.drag.startY = coords.y;
|
||||
|
||||
this.s.drag.startTd = startingTd;
|
||||
this.s.drag.endTd = startingTd;
|
||||
|
||||
this._fnUpdateBorder( startingTd, startingTd );
|
||||
|
||||
$(document).bind('mousemove.AutoFill', function (e) {
|
||||
that._fnFillerDragMove.call( that, e );
|
||||
} );
|
||||
|
||||
$(document).bind('mouseup.AutoFill', function (e) {
|
||||
that._fnFillerFinish.call( that, e );
|
||||
} );
|
||||
|
||||
/* Scrolling information cache */
|
||||
this.s.screen.y = e.pageY;
|
||||
this.s.screen.height = $(window).height();
|
||||
this.s.screen.scrollTop = $(document).scrollTop();
|
||||
|
||||
if ( this.s.dt.oScroll.sY !== "" )
|
||||
{
|
||||
this.s.scroller.top = $(this.s.dt.nTable.parentNode).offset().top;
|
||||
this.s.scroller.bottom = this.s.scroller.top + $(this.s.dt.nTable.parentNode).height();
|
||||
}
|
||||
|
||||
/* Scrolling handler - we set an interval (which is cancelled on mouse up) which will fire
|
||||
* regularly and see if we need to do any scrolling
|
||||
*/
|
||||
this.s.screen.interval = setInterval( function () {
|
||||
var iScrollTop = $(document).scrollTop();
|
||||
var iScrollDelta = iScrollTop - that.s.screen.scrollTop;
|
||||
that.s.screen.y += iScrollDelta;
|
||||
|
||||
if ( that.s.screen.height - that.s.screen.y + iScrollTop < 50 )
|
||||
{
|
||||
$('html, body').animate( {
|
||||
"scrollTop": iScrollTop + 50
|
||||
}, 240, 'linear' );
|
||||
}
|
||||
else if ( that.s.screen.y - iScrollTop < 50 )
|
||||
{
|
||||
$('html, body').animate( {
|
||||
"scrollTop": iScrollTop - 50
|
||||
}, 240, 'linear' );
|
||||
}
|
||||
|
||||
if ( that.s.dt.oScroll.sY !== "" )
|
||||
{
|
||||
if ( that.s.screen.y > that.s.scroller.bottom - 50 )
|
||||
{
|
||||
$(that.s.dt.nTable.parentNode).animate( {
|
||||
"scrollTop": $(that.s.dt.nTable.parentNode).scrollTop() + 50
|
||||
}, 240, 'linear' );
|
||||
}
|
||||
else if ( that.s.screen.y < that.s.scroller.top + 50 )
|
||||
{
|
||||
$(that.s.dt.nTable.parentNode).animate( {
|
||||
"scrollTop": $(that.s.dt.nTable.parentNode).scrollTop() - 50
|
||||
}, 240, 'linear' );
|
||||
}
|
||||
}
|
||||
}, 250 );
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Mouse move event handler for during a move. See if we want to update the display based on the
|
||||
* new cursor position
|
||||
* @method _fnFillerDragMove
|
||||
* @param {Object} e Event object
|
||||
* @returns void
|
||||
*/
|
||||
"_fnFillerDragMove": function (e)
|
||||
{
|
||||
if ( e.target && e.target.nodeName.toUpperCase() == "TD" &&
|
||||
e.target != this.s.drag.endTd )
|
||||
{
|
||||
var coords = this._fnTargetCoords( e.target );
|
||||
|
||||
if ( this.c.mode == "y" && coords.x != this.s.drag.startX )
|
||||
{
|
||||
e.target = $('tbody>tr:eq('+coords.y+')>td:eq('+this.s.drag.startX+')', this.dom.table)[0];
|
||||
}
|
||||
if ( this.c.mode == "x" && coords.y != this.s.drag.startY )
|
||||
{
|
||||
e.target = $('tbody>tr:eq('+this.s.drag.startY+')>td:eq('+coords.x+')', this.dom.table)[0];
|
||||
}
|
||||
|
||||
if ( this.c.mode == "either")
|
||||
{
|
||||
if(coords.x != this.s.drag.startX )
|
||||
{
|
||||
e.target = $('tbody>tr:eq('+this.s.drag.startY+')>td:eq('+coords.x+')', this.dom.table)[0];
|
||||
}
|
||||
else if ( coords.y != this.s.drag.startY ) {
|
||||
e.target = $('tbody>tr:eq('+coords.y+')>td:eq('+this.s.drag.startX+')', this.dom.table)[0];
|
||||
}
|
||||
}
|
||||
|
||||
// update coords
|
||||
if ( this.c.mode !== "both" ) {
|
||||
coords = this._fnTargetCoords( e.target );
|
||||
}
|
||||
|
||||
var drag = this.s.drag;
|
||||
drag.endTd = e.target;
|
||||
|
||||
if ( coords.y >= this.s.drag.startY ) {
|
||||
this._fnUpdateBorder( drag.startTd, drag.endTd );
|
||||
}
|
||||
else {
|
||||
this._fnUpdateBorder( drag.endTd, drag.startTd );
|
||||
}
|
||||
this._fnFillerPosition( e.target );
|
||||
}
|
||||
|
||||
/* Update the screen information so we can perform scrolling */
|
||||
this.s.screen.y = e.pageY;
|
||||
this.s.screen.scrollTop = $(document).scrollTop();
|
||||
|
||||
if ( this.s.dt.oScroll.sY !== "" )
|
||||
{
|
||||
this.s.scroller.scrollTop = $(this.s.dt.nTable.parentNode).scrollTop();
|
||||
this.s.scroller.top = $(this.s.dt.nTable.parentNode).offset().top;
|
||||
this.s.scroller.bottom = this.s.scroller.top + $(this.s.dt.nTable.parentNode).height();
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Mouse release handler - end the drag and take action to update the cells with the needed values
|
||||
* @method _fnFillerFinish
|
||||
* @param {Object} e Event object
|
||||
* @returns void
|
||||
*/
|
||||
"_fnFillerFinish": function (e)
|
||||
{
|
||||
var that = this, i, iLen, j;
|
||||
|
||||
$(document).unbind('mousemove.AutoFill mouseup.AutoFill');
|
||||
|
||||
this.dom.borderTop.style.display = "none";
|
||||
this.dom.borderRight.style.display = "none";
|
||||
this.dom.borderBottom.style.display = "none";
|
||||
this.dom.borderLeft.style.display = "none";
|
||||
|
||||
this.s.drag.dragging = false;
|
||||
|
||||
clearInterval( this.s.screen.interval );
|
||||
|
||||
var cells = [];
|
||||
var table = this.dom.table;
|
||||
var coordsStart = this._fnTargetCoords( this.s.drag.startTd );
|
||||
var coordsEnd = this._fnTargetCoords( this.s.drag.endTd );
|
||||
var columnIndex = function ( visIdx ) {
|
||||
return that.s.dt.oApi._fnVisibleToColumnIndex( that.s.dt, visIdx );
|
||||
};
|
||||
|
||||
// xxx - urgh - there must be a way of reducing this...
|
||||
if ( coordsStart.y <= coordsEnd.y ) {
|
||||
for ( i=coordsStart.y ; i<=coordsEnd.y ; i++ ) {
|
||||
if ( coordsStart.x <= coordsEnd.x ) {
|
||||
for ( j=coordsStart.x ; j<=coordsEnd.x ; j++ ) {
|
||||
cells.push( {
|
||||
node: $('tbody>tr:eq('+i+')>td:eq('+j+')', table)[0],
|
||||
x: j - coordsStart.x,
|
||||
y: i - coordsStart.y,
|
||||
colIdx: columnIndex( j )
|
||||
} );
|
||||
}
|
||||
}
|
||||
else {
|
||||
for ( j=coordsStart.x ; j>=coordsEnd.x ; j-- ) {
|
||||
cells.push( {
|
||||
node: $('tbody>tr:eq('+i+')>td:eq('+j+')', table)[0],
|
||||
x: j - coordsStart.x,
|
||||
y: i - coordsStart.y,
|
||||
colIdx: columnIndex( j )
|
||||
} );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
for ( i=coordsStart.y ; i>=coordsEnd.y ; i-- ) {
|
||||
if ( coordsStart.x <= coordsEnd.x ) {
|
||||
for ( j=coordsStart.x ; j<=coordsEnd.x ; j++ ) {
|
||||
cells.push( {
|
||||
node: $('tbody>tr:eq('+i+')>td:eq('+j+')', table)[0],
|
||||
x: j - coordsStart.x,
|
||||
y: i - coordsStart.y,
|
||||
colIdx: columnIndex( j )
|
||||
} );
|
||||
}
|
||||
}
|
||||
else {
|
||||
for ( j=coordsStart.x ; j>=coordsEnd.x ; j-- ) {
|
||||
cells.push( {
|
||||
node: $('tbody>tr:eq('+i+')>td:eq('+j+')', table)[0],
|
||||
x: coordsStart.x - j,
|
||||
y: coordsStart.y - i,
|
||||
colIdx: columnIndex( j )
|
||||
} );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// An auto-fill requires 2 or more cells
|
||||
if ( cells.length <= 1 ) {
|
||||
return;
|
||||
}
|
||||
|
||||
var edited = [];
|
||||
var previous;
|
||||
|
||||
for ( i=0, iLen=cells.length ; i<iLen ; i++ ) {
|
||||
var cell = cells[i];
|
||||
var column = this.s.columns[ cell.colIdx ];
|
||||
var read = column.read.call( column, cell.node );
|
||||
var stepValue = column.step.call( column, cell.node, read, previous, i, cell.x, cell.y );
|
||||
|
||||
column.write.call( column, cell.node, stepValue );
|
||||
|
||||
previous = stepValue;
|
||||
edited.push( {
|
||||
cell: cell,
|
||||
colIdx: cell.colIdx,
|
||||
newValue: stepValue,
|
||||
oldValue: read
|
||||
} );
|
||||
}
|
||||
|
||||
if ( this.c.complete !== null ) {
|
||||
this.c.complete.call( this, edited );
|
||||
}
|
||||
|
||||
// In 1.10 we can do a static draw
|
||||
if ( DataTable.Api ) {
|
||||
new DataTable.Api( this.s.dt ).draw( false );
|
||||
}
|
||||
else {
|
||||
this.s.dt.oInstance.fnDraw();
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Display the drag handle on mouse over cell
|
||||
* @method _fnFillerDisplay
|
||||
* @param {Object} e Event object
|
||||
* @returns void
|
||||
*/
|
||||
"_fnFillerDisplay": function (e)
|
||||
{
|
||||
var filler = this.dom.filler;
|
||||
|
||||
/* Don't display automatically when dragging */
|
||||
if ( this.s.drag.dragging)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
/* Check that we are allowed to AutoFill this column or not */
|
||||
var nTd = (e.target.nodeName.toLowerCase() == 'td') ? e.target : $(e.target).parents('td')[0];
|
||||
var iX = this._fnTargetCoords(nTd).column;
|
||||
if ( !this.s.columns[iX].enable )
|
||||
{
|
||||
filler.style.display = "none";
|
||||
return;
|
||||
}
|
||||
|
||||
if (e.type == 'mouseover')
|
||||
{
|
||||
this.dom.currentTarget = nTd;
|
||||
this._fnFillerPosition( nTd );
|
||||
|
||||
filler.style.display = "block";
|
||||
}
|
||||
else if ( !e.relatedTarget || !e.relatedTarget.className.match(/AutoFill/) )
|
||||
{
|
||||
filler.style.display = "none";
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Position the filler icon over a cell
|
||||
* @method _fnFillerPosition
|
||||
* @param {Node} nTd Cell to position filler icon over
|
||||
* @returns void
|
||||
*/
|
||||
"_fnFillerPosition": function ( nTd )
|
||||
{
|
||||
var offset = $(nTd).offset();
|
||||
var filler = this.dom.filler;
|
||||
filler.style.top = (offset.top - (this.s.filler.height / 2)-1 + $(nTd).outerHeight())+"px";
|
||||
filler.style.left = (offset.left - (this.s.filler.width / 2)-1 + $(nTd).outerWidth())+"px";
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
// Alias for access
|
||||
DataTable.AutoFill = AutoFill;
|
||||
DataTable.AutoFill = AutoFill;
|
||||
|
||||
|
||||
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Constants
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
/**
|
||||
* AutoFill version
|
||||
* @constant version
|
||||
* @type String
|
||||
* @default See code
|
||||
*/
|
||||
AutoFill.version = "1.2.1";
|
||||
|
||||
|
||||
/**
|
||||
* AutoFill defaults
|
||||
* @namespace
|
||||
*/
|
||||
AutoFill.defaults = {
|
||||
/**
|
||||
* Mode for dragging (restrict to y-axis only, x-axis only, either one or none):
|
||||
*
|
||||
* * `y` - y-axis only (default)
|
||||
* * `x` - x-axis only
|
||||
* * `either` - either one, but not both axis at the same time
|
||||
* * `both` - multiple cells allowed
|
||||
*
|
||||
* @type {string}
|
||||
* @default `y`
|
||||
*/
|
||||
mode: 'y',
|
||||
|
||||
complete: null,
|
||||
|
||||
/**
|
||||
* Column definition defaults
|
||||
* @namespace
|
||||
*/
|
||||
column: {
|
||||
/**
|
||||
* If AutoFill should be enabled on this column
|
||||
*
|
||||
* @type {boolean}
|
||||
* @default true
|
||||
*/
|
||||
enable: true,
|
||||
|
||||
/**
|
||||
* Allow automatic increment / decrement on this column if a number
|
||||
* is found.
|
||||
*
|
||||
* @type {boolean}
|
||||
* @default true
|
||||
*/
|
||||
increment: true,
|
||||
|
||||
/**
|
||||
* Cell read function
|
||||
*
|
||||
* Default function will simply read the value from the HTML of the
|
||||
* cell.
|
||||
*
|
||||
* @type {function}
|
||||
* @param {node} cell `th` / `td` element to read the value from
|
||||
* @return {string} Data that has been read
|
||||
*/
|
||||
read: function ( cell ) {
|
||||
return $(cell).html();
|
||||
},
|
||||
|
||||
/**
|
||||
* Cell write function
|
||||
*
|
||||
* Default function will simply write to the HTML and tell the DataTable
|
||||
* to update.
|
||||
*
|
||||
* @type {function}
|
||||
* @param {node} cell `th` / `td` element to write the value to
|
||||
* @return {string} Data two write
|
||||
*/
|
||||
write: function ( cell, val ) {
|
||||
var table = $(cell).parents('table');
|
||||
if ( DataTable.Api ) {
|
||||
// 1.10
|
||||
table.DataTable().cell( cell ).data( val );
|
||||
}
|
||||
else {
|
||||
// 1.9
|
||||
var dt = table.dataTable();
|
||||
var pos = dt.fnGetPosition( cell );
|
||||
dt.fnUpdate( val, pos[0], pos[2], false );
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Step function. This provides the ability to customise how the values
|
||||
* are incremented.
|
||||
*
|
||||
* @param {node} cell `th` / `td` element that is being operated upon
|
||||
* @param {string} read Cell value from `read` function
|
||||
* @param {string} last Value of the previous cell
|
||||
* @param {integer} i Loop counter
|
||||
* @param {integer} x Cell x-position in the current auto-fill. The
|
||||
* starting cell is coordinate 0 regardless of its physical position
|
||||
* in the DataTable.
|
||||
* @param {integer} y Cell y-position in the current auto-fill. The
|
||||
* starting cell is coordinate 0 regardless of its physical position
|
||||
* in the DataTable.
|
||||
* @return {string} Value to write
|
||||
*/
|
||||
step: function ( cell, read, last, i, x, y ) {
|
||||
// Increment a number if it is found
|
||||
var re = /(\-?\d+)/;
|
||||
var match = this.increment && last ? last.match(re) : null;
|
||||
if ( match ) {
|
||||
return last.replace( re, parseInt(match[1],10) + (x<0 || y<0 ? -1 : 1) );
|
||||
}
|
||||
return last === undefined ?
|
||||
read :
|
||||
last;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
return AutoFill;
|
||||
};
|
||||
|
||||
|
||||
// Define as an AMD module if possible
|
||||
if ( typeof define === 'function' && define.amd ) {
|
||||
define( ['jquery', 'datatables'], factory );
|
||||
}
|
||||
else if ( typeof exports === 'object' ) {
|
||||
// Node/CommonJS
|
||||
factory( require('jquery'), require('datatables') );
|
||||
}
|
||||
else if ( jQuery && !jQuery.fn.dataTable.AutoFill ) {
|
||||
// Otherwise simply initialise as normal, stopping multiple evaluation
|
||||
factory( jQuery, jQuery.fn.dataTable );
|
||||
}
|
||||
|
||||
|
||||
}(window, document));
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
/*!
|
||||
AutoFill 1.2.1
|
||||
©2008-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
(function(o,j,m){var l=function(c,k){var h=function(d,b){if(!(this instanceof h))throw"Warning: AutoFill must be initialised with the keyword 'new'";if(!c.fn.dataTableExt.fnVersionCheck("1.7.0"))throw"Warning: AutoFill requires DataTables 1.7 or greater";this.c={};this.s={filler:{height:0,width:0},border:{width:2},drag:{startX:-1,startY:-1,startTd:null,endTd:null,dragging:!1},screen:{interval:null,y:0,height:0,scrollTop:0},scroller:{top:0,bottom:0},columns:[]};this.dom={table:null,filler:null,borderTop:null,
|
||||
borderRight:null,borderBottom:null,borderLeft:null,currentTarget:null};this.fnSettings=function(){return this.s};this._fnInit(d,b);return this};h.prototype={_fnInit:function(d,b){var a=this;this.s.dt=k.Api?(new k.Api(d)).settings()[0]:d.fnSettings();this.s.init=b||{};this.dom.table=this.s.dt.nTable;c.extend(!0,this.c,h.defaults,b);this._initColumns();var e=c("<div/>",{"class":"AutoFill_filler"}).appendTo("body");this.dom.filler=e[0];this.s.filler.height=e.height();this.s.filler.width=e.width();e[0].style.display=
|
||||
"none";var g,f=j.body;""!==a.s.dt.oScroll.sY&&(a.s.dt.nTable.parentNode.style.position="relative",f=a.s.dt.nTable.parentNode);g=c("<div/>",{"class":"AutoFill_border"});this.dom.borderTop=g.clone().appendTo(f)[0];this.dom.borderRight=g.clone().appendTo(f)[0];this.dom.borderBottom=g.clone().appendTo(f)[0];this.dom.borderLeft=g.clone().appendTo(f)[0];e.on("mousedown.DTAF",function(b){this.onselectstart=function(){return false};a._fnFillerDragStart.call(a,b);return false});c("tbody",this.dom.table).on("mouseover.DTAF mouseout.DTAF",
|
||||
">tr>td, >tr>th",function(b){a._fnFillerDisplay.call(a,b)});c(this.dom.table).on("destroy.dt.DTAF",function(){e.off("mousedown.DTAF").remove();c("tbody",this.dom.table).off("mouseover.DTAF mouseout.DTAF")})},_initColumns:function(){var d=this,b,a,e=this.s.dt,g=this.s.init;b=0;for(a=e.aoColumns.length;b<a;b++)this.s.columns[b]=c.extend(!0,{},h.defaults.column);e.oApi._fnApplyColumnDefs(e,g.aoColumnDefs||g.columnDefs,g.aoColumns||g.columns,function(a,b){d._fnColumnOptions(a,b)});b=0;for(a=e.aoColumns.length;b<
|
||||
a;b++)if(e=this.s.columns[b],e.read||(e.read=this._fnReadCell),e.write||(e.read=this._fnWriteCell),!e.step)e.read=this._fnStep},_fnColumnOptions:function(d,b){var a=this.s.columns[d],c=function(c,d){b[d[0]]!==m&&(a[c]=b[d[0]]);b[d[1]]!==m&&(a[c]=b[d[1]])};c("enable",["bEnable","enable"]);c("read",["fnRead","read"]);c("write",["fnWrite","write"]);c("step",["fnStep","step"]);c("increment",["bIncrement","increment"])},_fnTargetCoords:function(d){var b=c(d).parents("tr")[0],a=this.s.dt.oInstance.fnGetPosition(d);
|
||||
return{x:c("td",b).index(d),y:c("tr",b.parentNode).index(b),row:a[0],column:a[2]}},_fnUpdateBorder:function(d,b){var a=this.s.border.width,e=c(d).offset(),g=c(b).offset(),f=e.left-a,i=g.left+c(b).outerWidth(),n=e.top-a,h=g.top+c(b).outerHeight(),j=g.left+c(b).outerWidth()-e.left+2*a,k=g.top+c(b).outerHeight()-e.top+2*a;e.left>g.left&&(f=g.left-a,i=e.left+c(d).outerWidth(),j=e.left+c(d).outerWidth()-g.left+2*a);""!==this.s.dt.oScroll.sY&&(a=c(this.s.dt.nTable.parentNode).offset(),e=c(this.s.dt.nTable.parentNode).scrollTop(),
|
||||
g=c(this.s.dt.nTable.parentNode).scrollLeft(),f-=a.left-g,i-=a.left-g,n-=a.top-e,h-=a.top-e);a=this.dom.borderTop.style;a.top=n+"px";a.left=f+"px";a.height=this.s.border.width+"px";a.width=j+"px";a=this.dom.borderBottom.style;a.top=h+"px";a.left=f+"px";a.height=this.s.border.width+"px";a.width=j+"px";a=this.dom.borderLeft.style;a.top=n+"px";a.left=f+"px";a.height=k+"px";a.width=this.s.border.width+"px";a=this.dom.borderRight.style;a.top=n+"px";a.left=i+"px";a.height=k+"px";a.width=this.s.border.width+
|
||||
"px"},_fnFillerDragStart:function(d){var b=this,a=this.dom.currentTarget;this.s.drag.dragging=!0;b.dom.borderTop.style.display="block";b.dom.borderRight.style.display="block";b.dom.borderBottom.style.display="block";b.dom.borderLeft.style.display="block";var e=this._fnTargetCoords(a);this.s.drag.startX=e.x;this.s.drag.startY=e.y;this.s.drag.startTd=a;this.s.drag.endTd=a;this._fnUpdateBorder(a,a);c(j).bind("mousemove.AutoFill",function(a){b._fnFillerDragMove.call(b,a)});c(j).bind("mouseup.AutoFill",
|
||||
function(a){b._fnFillerFinish.call(b,a)});this.s.screen.y=d.pageY;this.s.screen.height=c(o).height();this.s.screen.scrollTop=c(j).scrollTop();""!==this.s.dt.oScroll.sY&&(this.s.scroller.top=c(this.s.dt.nTable.parentNode).offset().top,this.s.scroller.bottom=this.s.scroller.top+c(this.s.dt.nTable.parentNode).height());this.s.screen.interval=setInterval(function(){var a=c(j).scrollTop();b.s.screen.y=b.s.screen.y+(a-b.s.screen.scrollTop);b.s.screen.height-b.s.screen.y+a<50?c("html, body").animate({scrollTop:a+
|
||||
50},240,"linear"):b.s.screen.y-a<50&&c("html, body").animate({scrollTop:a-50},240,"linear");b.s.dt.oScroll.sY!==""&&(b.s.screen.y>b.s.scroller.bottom-50?c(b.s.dt.nTable.parentNode).animate({scrollTop:c(b.s.dt.nTable.parentNode).scrollTop()+50},240,"linear"):b.s.screen.y<b.s.scroller.top+50&&c(b.s.dt.nTable.parentNode).animate({scrollTop:c(b.s.dt.nTable.parentNode).scrollTop()-50},240,"linear"))},250)},_fnFillerDragMove:function(d){if(d.target&&"TD"==d.target.nodeName.toUpperCase()&&d.target!=this.s.drag.endTd){var b=
|
||||
this._fnTargetCoords(d.target);"y"==this.c.mode&&b.x!=this.s.drag.startX&&(d.target=c("tbody>tr:eq("+b.y+")>td:eq("+this.s.drag.startX+")",this.dom.table)[0]);"x"==this.c.mode&&b.y!=this.s.drag.startY&&(d.target=c("tbody>tr:eq("+this.s.drag.startY+")>td:eq("+b.x+")",this.dom.table)[0]);"either"==this.c.mode&&(b.x!=this.s.drag.startX?d.target=c("tbody>tr:eq("+this.s.drag.startY+")>td:eq("+b.x+")",this.dom.table)[0]:b.y!=this.s.drag.startY&&(d.target=c("tbody>tr:eq("+b.y+")>td:eq("+this.s.drag.startX+
|
||||
")",this.dom.table)[0]));"both"!==this.c.mode&&(b=this._fnTargetCoords(d.target));var a=this.s.drag;a.endTd=d.target;b.y>=this.s.drag.startY?this._fnUpdateBorder(a.startTd,a.endTd):this._fnUpdateBorder(a.endTd,a.startTd);this._fnFillerPosition(d.target)}this.s.screen.y=d.pageY;this.s.screen.scrollTop=c(j).scrollTop();""!==this.s.dt.oScroll.sY&&(this.s.scroller.scrollTop=c(this.s.dt.nTable.parentNode).scrollTop(),this.s.scroller.top=c(this.s.dt.nTable.parentNode).offset().top,this.s.scroller.bottom=
|
||||
this.s.scroller.top+c(this.s.dt.nTable.parentNode).height())},_fnFillerFinish:function(){var d=this,b,a;c(j).unbind("mousemove.AutoFill mouseup.AutoFill");this.dom.borderTop.style.display="none";this.dom.borderRight.style.display="none";this.dom.borderBottom.style.display="none";this.dom.borderLeft.style.display="none";this.s.drag.dragging=!1;clearInterval(this.s.screen.interval);var e=[],g=this.dom.table,f=this._fnTargetCoords(this.s.drag.startTd),i=this._fnTargetCoords(this.s.drag.endTd),h=function(a){return d.s.dt.oApi._fnVisibleToColumnIndex(d.s.dt,
|
||||
a)};if(f.y<=i.y)for(b=f.y;b<=i.y;b++)if(f.x<=i.x)for(a=f.x;a<=i.x;a++)e.push({node:c("tbody>tr:eq("+b+")>td:eq("+a+")",g)[0],x:a-f.x,y:b-f.y,colIdx:h(a)});else for(a=f.x;a>=i.x;a--)e.push({node:c("tbody>tr:eq("+b+")>td:eq("+a+")",g)[0],x:a-f.x,y:b-f.y,colIdx:h(a)});else for(b=f.y;b>=i.y;b--)if(f.x<=i.x)for(a=f.x;a<=i.x;a++)e.push({node:c("tbody>tr:eq("+b+")>td:eq("+a+")",g)[0],x:a-f.x,y:b-f.y,colIdx:h(a)});else for(a=f.x;a>=i.x;a--)e.push({node:c("tbody>tr:eq("+b+")>td:eq("+a+")",g)[0],x:f.x-a,y:f.y-
|
||||
b,colIdx:h(a)});if(!(1>=e.length)){var g=[],m;b=0;for(a=e.length;b<a;b++){var f=e[b],i=this.s.columns[f.colIdx],h=i.read.call(i,f.node),l=i.step.call(i,f.node,h,m,b,f.x,f.y);i.write.call(i,f.node,l);m=l;g.push({cell:f,colIdx:f.colIdx,newValue:l,oldValue:h})}null!==this.c.complete&&this.c.complete.call(this,g);k.Api?(new k.Api(this.s.dt)).draw(!1):this.s.dt.oInstance.fnDraw()}},_fnFillerDisplay:function(d){var b=this.dom.filler;if(!this.s.drag.dragging){var a="td"==d.target.nodeName.toLowerCase()?
|
||||
d.target:c(d.target).parents("td")[0],e=this._fnTargetCoords(a).column;if(this.s.columns[e].enable)if("mouseover"==d.type)this.dom.currentTarget=a,this._fnFillerPosition(a),b.style.display="block";else{if(!d.relatedTarget||!d.relatedTarget.className.match(/AutoFill/))b.style.display="none"}else b.style.display="none"}},_fnFillerPosition:function(d){var b=c(d).offset(),a=this.dom.filler;a.style.top=b.top-this.s.filler.height/2-1+c(d).outerHeight()+"px";a.style.left=b.left-this.s.filler.width/2-1+c(d).outerWidth()+
|
||||
"px"}};k.AutoFill=h;k.AutoFill=h;h.version="1.2.1";h.defaults={mode:"y",complete:null,column:{enable:!0,increment:!0,read:function(d){return c(d).html()},write:function(d,b){var a=c(d).parents("table");if(k.Api)a.DataTable().cell(d).data(b);else{var a=a.dataTable(),e=a.fnGetPosition(d);a.fnUpdate(b,e[0],e[2],!1)}},step:function(c,b,a,e,g,f){c=/(\-?\d+)/;return(e=this.increment&&a?a.match(c):null)?a.replace(c,parseInt(e[1],10)+(0>g||0>f?-1:1)):a===m?b:a}}};return h};"function"===typeof define&&define.amd?
|
||||
define(["jquery","datatables"],l):"object"===typeof exports?l(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.AutoFill&&l(jQuery,jQuery.fn.dataTable)})(window,document);
|
|
@ -0,0 +1,152 @@
|
|||
/* Set the defaults for DataTables initialisation */
|
||||
$.extend( true, $.fn.dataTable.defaults, {
|
||||
"sDom": "<'row'<'col-xs-6'l><'col-xs-6'f>r>t<'row'<'col-xs-6'i><'col-xs-6'p>>",
|
||||
"sPaginationType": "bootstrap",
|
||||
"oLanguage": {
|
||||
"sLengthMenu": "_MENU_ records per page"
|
||||
}
|
||||
} );
|
||||
|
||||
|
||||
|
||||
|
||||
/* Default class modification */
|
||||
$.extend( $.fn.dataTableExt.oStdClasses, {
|
||||
"sWrapper": "dataTables_wrapper form-inline",
|
||||
"sFilterInput": "form-control input-sm",
|
||||
"sLengthSelect": "form-control input-sm"
|
||||
} );
|
||||
|
||||
|
||||
/* API method to get paging information */
|
||||
$.fn.dataTableExt.oApi.fnPagingInfo = function ( oSettings )
|
||||
{
|
||||
return {
|
||||
"iStart": oSettings._iDisplayStart,
|
||||
"iEnd": oSettings.fnDisplayEnd(),
|
||||
"iLength": oSettings._iDisplayLength,
|
||||
"iTotal": oSettings.fnRecordsTotal(),
|
||||
"iFilteredTotal": oSettings.fnRecordsDisplay(),
|
||||
"iPage": oSettings._iDisplayLength === -1 ?
|
||||
0 : Math.ceil( oSettings._iDisplayStart / oSettings._iDisplayLength ),
|
||||
"iTotalPages": oSettings._iDisplayLength === -1 ?
|
||||
0 : Math.ceil( oSettings.fnRecordsDisplay() / oSettings._iDisplayLength )
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
/* Bootstrap style pagination control */
|
||||
$.extend( $.fn.dataTableExt.oPagination, {
|
||||
"bootstrap": {
|
||||
"fnInit": function( oSettings, nPaging, fnDraw ) {
|
||||
var oLang = oSettings.oLanguage.oPaginate;
|
||||
var fnClickHandler = function ( e ) {
|
||||
e.preventDefault();
|
||||
if ( oSettings.oApi._fnPageChange(oSettings, e.data.action) ) {
|
||||
fnDraw( oSettings );
|
||||
}
|
||||
};
|
||||
|
||||
$(nPaging).append(
|
||||
'<ul class="pagination">'+
|
||||
'<li class="prev disabled"><a href="#">← '+oLang.sPrevious+'</a></li>'+
|
||||
'<li class="next disabled"><a href="#">'+oLang.sNext+' → </a></li>'+
|
||||
'</ul>'
|
||||
);
|
||||
var els = $('a', nPaging);
|
||||
$(els[0]).bind( 'click.DT', { action: "previous" }, fnClickHandler );
|
||||
$(els[1]).bind( 'click.DT', { action: "next" }, fnClickHandler );
|
||||
},
|
||||
|
||||
"fnUpdate": function ( oSettings, fnDraw ) {
|
||||
var iListLength = 5;
|
||||
var oPaging = oSettings.oInstance.fnPagingInfo();
|
||||
var an = oSettings.aanFeatures.p;
|
||||
var i, ien, j, sClass, iStart, iEnd, iHalf=Math.floor(iListLength/2);
|
||||
|
||||
if ( oPaging.iTotalPages < iListLength) {
|
||||
iStart = 1;
|
||||
iEnd = oPaging.iTotalPages;
|
||||
}
|
||||
else if ( oPaging.iPage <= iHalf ) {
|
||||
iStart = 1;
|
||||
iEnd = iListLength;
|
||||
} else if ( oPaging.iPage >= (oPaging.iTotalPages-iHalf) ) {
|
||||
iStart = oPaging.iTotalPages - iListLength + 1;
|
||||
iEnd = oPaging.iTotalPages;
|
||||
} else {
|
||||
iStart = oPaging.iPage - iHalf + 1;
|
||||
iEnd = iStart + iListLength - 1;
|
||||
}
|
||||
|
||||
for ( i=0, ien=an.length ; i<ien ; i++ ) {
|
||||
// Remove the middle elements
|
||||
$('li:gt(0)', an[i]).filter(':not(:last)').remove();
|
||||
|
||||
// Add the new list items and their event handlers
|
||||
for ( j=iStart ; j<=iEnd ; j++ ) {
|
||||
sClass = (j==oPaging.iPage+1) ? 'class="active"' : '';
|
||||
$('<li '+sClass+'><a href="#">'+j+'</a></li>')
|
||||
.insertBefore( $('li:last', an[i])[0] )
|
||||
.bind('click', function (e) {
|
||||
e.preventDefault();
|
||||
oSettings._iDisplayStart = (parseInt($('a', this).text(),10)-1) * oPaging.iLength;
|
||||
fnDraw( oSettings );
|
||||
} );
|
||||
}
|
||||
|
||||
// Add / remove disabled classes from the static elements
|
||||
if ( oPaging.iPage === 0 ) {
|
||||
$('li:first', an[i]).addClass('disabled');
|
||||
} else {
|
||||
$('li:first', an[i]).removeClass('disabled');
|
||||
}
|
||||
|
||||
if ( oPaging.iPage === oPaging.iTotalPages-1 || oPaging.iTotalPages === 0 ) {
|
||||
$('li:last', an[i]).addClass('disabled');
|
||||
} else {
|
||||
$('li:last', an[i]).removeClass('disabled');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} );
|
||||
|
||||
|
||||
/*
|
||||
* TableTools Bootstrap compatibility
|
||||
* Required TableTools 2.1+
|
||||
*/
|
||||
if ( $.fn.DataTable.TableTools ) {
|
||||
// Set the classes that TableTools uses to something suitable for Bootstrap
|
||||
$.extend( true, $.fn.DataTable.TableTools.classes, {
|
||||
"container": "DTTT btn-group",
|
||||
"buttons": {
|
||||
"normal": "btn btn-default",
|
||||
"disabled": "disabled"
|
||||
},
|
||||
"collection": {
|
||||
"container": "DTTT_dropdown dropdown-menu",
|
||||
"buttons": {
|
||||
"normal": "",
|
||||
"disabled": "disabled"
|
||||
}
|
||||
},
|
||||
"print": {
|
||||
"info": "DTTT_print_info modal"
|
||||
},
|
||||
"select": {
|
||||
"row": "active"
|
||||
}
|
||||
} );
|
||||
|
||||
// Have the collection use a bootstrap compatible dropdown
|
||||
$.extend( true, $.fn.DataTable.TableTools.DEFAULTS.oTags, {
|
||||
"collection": {
|
||||
"container": "ul",
|
||||
"button": "li",
|
||||
"liner": "a"
|
||||
}
|
||||
} );
|
||||
}
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
/*!
|
||||
ColReorder 1.1.2
|
||||
©2010-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
(function(n,q,r){function o(b){for(var f=[],a=0,e=b.length;a<e;a++)f[b[a]]=a;return f}function l(b,f,a){f=b.splice(f,1)[0];b.splice(a,0,f)}function p(b,f,a){for(var e=[],c=0,d=b.childNodes.length;c<d;c++)1==b.childNodes[c].nodeType&&e.push(b.childNodes[c]);f=e[f];null!==a?b.insertBefore(f,e[a]):b.appendChild(f)}$.fn.dataTableExt.oApi.fnColReorder=function(b,f,a){var e=$.fn.dataTable.Api?!0:!1,c,d,j,i,m=b.aoColumns.length,g,h;g=function(a,c,b){if(a[c]){var e=a[c].split("."),d=e.shift();isNaN(1*d)||
|
||||
(a[c]=b[1*d]+"."+e.join("."))}};if(f!=a)if(0>f||f>=m)this.oApi._fnLog(b,1,"ColReorder 'from' index is out of bounds: "+f);else if(0>a||a>=m)this.oApi._fnLog(b,1,"ColReorder 'to' index is out of bounds: "+a);else{j=[];c=0;for(d=m;c<d;c++)j[c]=c;l(j,f,a);var k=o(j);c=0;for(d=b.aaSorting.length;c<d;c++)b.aaSorting[c][0]=k[b.aaSorting[c][0]];if(null!==b.aaSortingFixed){c=0;for(d=b.aaSortingFixed.length;c<d;c++)b.aaSortingFixed[c][0]=k[b.aaSortingFixed[c][0]]}c=0;for(d=m;c<d;c++){h=b.aoColumns[c];j=0;
|
||||
for(i=h.aDataSort.length;j<i;j++)h.aDataSort[j]=k[h.aDataSort[j]];e&&(h.idx=k[h.idx])}e&&$.each(b.aLastSort,function(a,c){b.aLastSort[a].src=k[c.src]});c=0;for(d=m;c<d;c++)h=b.aoColumns[c],"number"==typeof h.mData?(h.mData=k[h.mData],b.oApi._fnColumnOptions(b,c,{})):$.isPlainObject(h.mData)&&(g(h.mData,"_",k),g(h.mData,"filter",k),g(h.mData,"sort",k),g(h.mData,"type",k),b.oApi._fnColumnOptions(b,c,{}));if(b.aoColumns[f].bVisible){j=this.oApi._fnColumnIndexToVisible(b,f);i=null;for(c=a<f?a:a+1;null===
|
||||
i&&c<m;)i=this.oApi._fnColumnIndexToVisible(b,c),c++;g=b.nTHead.getElementsByTagName("tr");c=0;for(d=g.length;c<d;c++)p(g[c],j,i);if(null!==b.nTFoot){g=b.nTFoot.getElementsByTagName("tr");c=0;for(d=g.length;c<d;c++)p(g[c],j,i)}c=0;for(d=b.aoData.length;c<d;c++)null!==b.aoData[c].nTr&&p(b.aoData[c].nTr,j,i)}l(b.aoColumns,f,a);l(b.aoPreSearchCols,f,a);c=0;for(d=b.aoData.length;c<d;c++)g=b.aoData[c],e?(g.anCells&&l(g.anCells,f,a),"dom"!==g.src&&$.isArray(g._aData)&&l(g._aData,f,a)):($.isArray(g._aData)&&
|
||||
l(g._aData,f,a),l(g._anHidden,f,a));c=0;for(d=b.aoHeader.length;c<d;c++)l(b.aoHeader[c],f,a);if(null!==b.aoFooter){c=0;for(d=b.aoFooter.length;c<d;c++)l(b.aoFooter[c],f,a)}e&&(new $.fn.dataTable.Api(b)).rows().invalidate();c=0;for(d=m;c<d;c++)$(b.aoColumns[c].nTh).off("click.DT"),this.oApi._fnSortAttachListener(b,b.aoColumns[c].nTh,c);$(b.oInstance).trigger("column-reorder",[b,{iFrom:f,iTo:a,aiInvertMapping:k}])}};n=function(b){var f=function(a,e){var c;b.fn.dataTable.Api?c=(new b.fn.dataTable.Api(a)).settings()[0]:
|
||||
a.fnSettings?c=a.fnSettings():"string"===typeof a?b.fn.dataTable.fnIsDataTable(b(a)[0])&&(c=b(a).eq(0).dataTable().fnSettings()):a.nodeName&&"table"===a.nodeName.toLowerCase()?b.fn.dataTable.fnIsDataTable(a.nodeName)&&(c=b(a.nodeName).dataTable().fnSettings()):a instanceof jQuery?b.fn.dataTable.fnIsDataTable(a[0])&&(c=a.eq(0).dataTable().fnSettings()):c=a;var d=b.fn.dataTable.camelToHungarian;d&&(d(f.defaults,f.defaults,!0),d(f.defaults,e||{}));this.s={dt:null,init:b.extend(!0,{},f.defaults,e),fixed:0,
|
||||
fixedRight:0,dropCallback:null,mouse:{startX:-1,startY:-1,offsetX:-1,offsetY:-1,target:-1,targetIndex:-1,fromIndex:-1},aoTargets:[]};this.dom={drag:null,pointer:null};this.s.dt=c.oInstance.fnSettings();this.s.dt._colReorder=this;this._fnConstruct();c.oApi._fnCallbackReg(c,"aoDestroyCallback",b.proxy(this._fnDestroy,this),"ColReorder");return this};f.prototype={fnReset:function(){for(var a=[],b=0,c=this.s.dt.aoColumns.length;b<c;b++)a.push(this.s.dt.aoColumns[b]._ColReorder_iOrigCol);this._fnOrderColumns(a);
|
||||
return this},fnGetCurrentOrder:function(){return this.fnOrder()},fnOrder:function(a){if(a===r){for(var a=[],b=0,c=this.s.dt.aoColumns.length;b<c;b++)a.push(this.s.dt.aoColumns[b]._ColReorder_iOrigCol);return a}this._fnOrderColumns(o(a));return this},_fnConstruct:function(){var a=this,b=this.s.dt.aoColumns.length,c;this.s.init.iFixedColumns&&(this.s.fixed=this.s.init.iFixedColumns);this.s.fixedRight=this.s.init.iFixedColumnsRight?this.s.init.iFixedColumnsRight:0;this.s.init.fnReorderCallback&&(this.s.dropCallback=
|
||||
this.s.init.fnReorderCallback);for(c=0;c<b;c++)c>this.s.fixed-1&&c<b-this.s.fixedRight&&this._fnMouseListener(c,this.s.dt.aoColumns[c].nTh),this.s.dt.aoColumns[c]._ColReorder_iOrigCol=c;this.s.dt.oApi._fnCallbackReg(this.s.dt,"aoStateSaveParams",function(c,b){a._fnStateSave.call(a,b)},"ColReorder_State");var d=null;this.s.init.aiOrder&&(d=this.s.init.aiOrder.slice());this.s.dt.oLoadedState&&("undefined"!=typeof this.s.dt.oLoadedState.ColReorder&&this.s.dt.oLoadedState.ColReorder.length==this.s.dt.aoColumns.length)&&
|
||||
(d=this.s.dt.oLoadedState.ColReorder);if(d)if(a.s.dt._bInitComplete)b=o(d),a._fnOrderColumns.call(a,b);else{var f=!1;this.s.dt.aoDrawCallback.push({fn:function(){if(!a.s.dt._bInitComplete&&!f){f=true;var c=o(d);a._fnOrderColumns.call(a,c)}},sName:"ColReorder_Pre"})}else this._fnSetColumnIndexes()},_fnOrderColumns:function(a){if(a.length!=this.s.dt.aoColumns.length)this.s.dt.oInstance.oApi._fnLog(this.s.dt,1,"ColReorder - array reorder does not match known number of columns. Skipping.");else{for(var e=
|
||||
0,c=a.length;e<c;e++){var d=b.inArray(e,a);e!=d&&(l(a,d,e),this.s.dt.oInstance.fnColReorder(d,e))}(""!==this.s.dt.oScroll.sX||""!==this.s.dt.oScroll.sY)&&this.s.dt.oInstance.fnAdjustColumnSizing();this.s.dt.oInstance.oApi._fnSaveState(this.s.dt);this._fnSetColumnIndexes()}},_fnStateSave:function(a){var e,c,d,f=this.s.dt.aoColumns;a.ColReorder=[];if(a.aaSorting){for(e=0;e<a.aaSorting.length;e++)a.aaSorting[e][0]=f[a.aaSorting[e][0]]._ColReorder_iOrigCol;var i=b.extend(!0,[],a.aoSearchCols);e=0;for(c=
|
||||
f.length;e<c;e++)d=f[e]._ColReorder_iOrigCol,a.aoSearchCols[d]=i[e],a.abVisCols[d]=f[e].bVisible,a.ColReorder.push(d)}else if(a.order){for(e=0;e<a.order.length;e++)a.order[e][0]=f[a.order[e][0]]._ColReorder_iOrigCol;i=b.extend(!0,[],a.columns);e=0;for(c=f.length;e<c;e++)d=f[e]._ColReorder_iOrigCol,a.columns[d]=i[e],a.ColReorder.push(d)}},_fnMouseListener:function(a,e){var c=this;b(e).on("mousedown.ColReorder",function(a){a.preventDefault();c._fnMouseDown.call(c,a,e)})},_fnMouseDown:function(a,e){var c=
|
||||
this,d=b(a.target).closest("th, td").offset(),f=parseInt(b(e).attr("data-column-index"),10);f!==r&&(this.s.mouse.startX=a.pageX,this.s.mouse.startY=a.pageY,this.s.mouse.offsetX=a.pageX-d.left,this.s.mouse.offsetY=a.pageY-d.top,this.s.mouse.target=this.s.dt.aoColumns[f].nTh,this.s.mouse.targetIndex=f,this.s.mouse.fromIndex=f,this._fnRegions(),b(q).on("mousemove.ColReorder",function(a){c._fnMouseMove.call(c,a)}).on("mouseup.ColReorder",function(a){c._fnMouseUp.call(c,a)}))},_fnMouseMove:function(a){if(null===
|
||||
this.dom.drag){if(5>Math.pow(Math.pow(a.pageX-this.s.mouse.startX,2)+Math.pow(a.pageY-this.s.mouse.startY,2),0.5))return;this._fnCreateDragNode()}this.dom.drag.css({left:a.pageX-this.s.mouse.offsetX,top:a.pageY-this.s.mouse.offsetY});for(var b=!1,c=this.s.mouse.toIndex,d=1,f=this.s.aoTargets.length;d<f;d++)if(a.pageX<this.s.aoTargets[d-1].x+(this.s.aoTargets[d].x-this.s.aoTargets[d-1].x)/2){this.dom.pointer.css("left",this.s.aoTargets[d-1].x);this.s.mouse.toIndex=this.s.aoTargets[d-1].to;b=!0;break}b||
|
||||
(this.dom.pointer.css("left",this.s.aoTargets[this.s.aoTargets.length-1].x),this.s.mouse.toIndex=this.s.aoTargets[this.s.aoTargets.length-1].to);this.s.init.bRealtime&&c!==this.s.mouse.toIndex&&(this.s.dt.oInstance.fnColReorder(this.s.mouse.fromIndex,this.s.mouse.toIndex),this.s.mouse.fromIndex=this.s.mouse.toIndex,this._fnRegions())},_fnMouseUp:function(){b(q).off("mousemove.ColReorder mouseup.ColReorder");null!==this.dom.drag&&(this.dom.drag.remove(),this.dom.pointer.remove(),this.dom.drag=null,
|
||||
this.dom.pointer=null,this.s.dt.oInstance.fnColReorder(this.s.mouse.fromIndex,this.s.mouse.toIndex),this._fnSetColumnIndexes(),(""!==this.s.dt.oScroll.sX||""!==this.s.dt.oScroll.sY)&&this.s.dt.oInstance.fnAdjustColumnSizing(),null!==this.s.dropCallback&&this.s.dropCallback.call(this),this.s.dt.oInstance.oApi._fnSaveState(this.s.dt))},_fnRegions:function(){var a=this.s.dt.aoColumns;this.s.aoTargets.splice(0,this.s.aoTargets.length);this.s.aoTargets.push({x:b(this.s.dt.nTable).offset().left,to:0});
|
||||
for(var e=0,c=0,d=a.length;c<d;c++)c!=this.s.mouse.fromIndex&&e++,a[c].bVisible&&this.s.aoTargets.push({x:b(a[c].nTh).offset().left+b(a[c].nTh).outerWidth(),to:e});0!==this.s.fixedRight&&this.s.aoTargets.splice(this.s.aoTargets.length-this.s.fixedRight);0!==this.s.fixed&&this.s.aoTargets.splice(0,this.s.fixed)},_fnCreateDragNode:function(){var a=""!==this.s.dt.oScroll.sX||""!==this.s.dt.oScroll.sY,e=this.s.dt.aoColumns[this.s.mouse.targetIndex].nTh,c=e.parentNode,d=c.parentNode,f=d.parentNode,i=b(e).clone();
|
||||
this.dom.drag=b(f.cloneNode(!1)).addClass("DTCR_clonedTable").append(d.cloneNode(!1).appendChild(c.cloneNode(!1).appendChild(i[0]))).css({position:"absolute",top:0,left:0,width:b(e).outerWidth(),height:b(e).outerHeight()}).appendTo("body");this.dom.pointer=b("<div></div>").addClass("DTCR_pointer").css({position:"absolute",top:a?b("div.dataTables_scroll",this.s.dt.nTableWrapper).offset().top:b(this.s.dt.nTable).offset().top,height:a?b("div.dataTables_scroll",this.s.dt.nTableWrapper).height():b(this.s.dt.nTable).height()}).appendTo("body")},
|
||||
_fnDestroy:function(){var a,e;a=0;for(e=this.s.dt.aoDrawCallback.length;a<e;a++)if("ColReorder_Pre"===this.s.dt.aoDrawCallback[a].sName){this.s.dt.aoDrawCallback.splice(a,1);break}b(this.s.dt.nTHead).find("*").off(".ColReorder");b.each(this.s.dt.aoColumns,function(a,e){b(e.nTh).removeAttr("data-column-index")});this.s=this.s.dt._colReorder=null},_fnSetColumnIndexes:function(){b.each(this.s.dt.aoColumns,function(a,e){b(e.nTh).attr("data-column-index",a)})}};f.defaults={aiOrder:null,bRealtime:!1,iFixedColumns:0,
|
||||
iFixedColumnsRight:0,fnReorderCallback:null};f.version="1.1.2";b.fn.dataTable.ColReorder=f;b.fn.DataTable.ColReorder=f;"function"==typeof b.fn.dataTable&&"function"==typeof b.fn.dataTableExt.fnVersionCheck&&b.fn.dataTableExt.fnVersionCheck("1.9.3")?b.fn.dataTableExt.aoFeatures.push({fnInit:function(a){var b=a.oInstance;a._colReorder?b.oApi._fnLog(a,1,"ColReorder attempted to initialise twice. Ignoring second"):(b=a.oInit,new f(a,b.colReorder||b.oColReorder||{}));return null},cFeature:"R",sFeature:"ColReorder"}):
|
||||
alert("Warning: ColReorder requires DataTables 1.9.3 or greater - www.datatables.net/download");b.fn.dataTable.Api&&(b.fn.dataTable.Api.register("colReorder.reset()",function(){return this.iterator("table",function(a){a._colReorder.fnReset()})}),b.fn.dataTable.Api.register("colReorder.order()",function(a){return a?this.iterator("table",function(b){b._colReorder.fnOrder(a)}):this.context.length?this.context[0]._colReorder.fnOrder():null}));return f};"function"===typeof define&&define.amd?define(["jquery",
|
||||
"datatables"],n):"object"===typeof exports?n(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.ColReorder&&n(jQuery,jQuery.fn.dataTable)})(window,document);
|
|
@ -0,0 +1,23 @@
|
|||
/*!
|
||||
ColVis 1.1.1
|
||||
©2010-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
(function(j,i,k){j=function(d){var e=function(a,b){(!this.CLASS||"ColVis"!=this.CLASS)&&alert("Warning: ColVis must be initialised with the keyword 'new'");"undefined"==typeof b&&(b={});d.fn.dataTable.camelToHungarian&&d.fn.dataTable.camelToHungarian(e.defaults,b);this.s={dt:null,oInit:b,hidden:!0,abOriginal:[]};this.dom={wrapper:null,button:null,collection:null,background:null,catcher:null,buttons:[],groupButtons:[],restore:null};e.aInstances.push(this);this.s.dt=d.fn.dataTable.Api?(new d.fn.dataTable.Api(a)).settings()[0]:
|
||||
a;this._fnConstruct(b);return this};e.prototype={button:function(){return this.dom.wrapper},fnRebuild:function(){this.rebuild()},rebuild:function(){for(var a=this.dom.buttons.length-1;0<=a;a--)this.dom.collection.removeChild(this.dom.buttons[a]);this.dom.buttons.splice(0,this.dom.buttons.length);this.dom.restore&&this.dom.restore.parentNode(this.dom.restore);this._fnAddGroups();this._fnAddButtons();this._fnDrawCallback()},_fnConstruct:function(a){this._fnApplyCustomisation(a);var b=this,c,f;this.dom.wrapper=
|
||||
i.createElement("div");this.dom.wrapper.className="ColVis";this.dom.button=d("<button />",{"class":!this.s.dt.bJUI?"ColVis_Button ColVis_MasterButton":"ColVis_Button ColVis_MasterButton ui-button ui-state-default"}).append("<span>"+this.s.buttonText+"</span>").bind("mouseover"==this.s.activate?"mouseover":"click",function(a){a.preventDefault();b._fnCollectionShow()}).appendTo(this.dom.wrapper)[0];this.dom.catcher=this._fnDomCatcher();this.dom.collection=this._fnDomCollection();this.dom.background=
|
||||
this._fnDomBackground();this._fnAddGroups();this._fnAddButtons();c=0;for(f=this.s.dt.aoColumns.length;c<f;c++)this.s.abOriginal.push(this.s.dt.aoColumns[c].bVisible);this.s.dt.aoDrawCallback.push({fn:function(){b._fnDrawCallback.call(b)},sName:"ColVis"});d(this.s.dt.oInstance).bind("column-reorder",function(a,d,e){c=0;for(f=b.s.aiExclude.length;c<f;c++)b.s.aiExclude[c]=e.aiInvertMapping[b.s.aiExclude[c]];a=b.s.abOriginal.splice(e.iFrom,1)[0];b.s.abOriginal.splice(e.iTo,0,a);b.fnRebuild()});this._fnDrawCallback()},
|
||||
_fnApplyCustomisation:function(a){d.extend(!0,this.s,e.defaults,a);!this.s.showAll&&this.s.bShowAll&&(this.s.showAll=this.s.sShowAll);!this.s.restore&&this.s.bRestore&&(this.s.restore=this.s.sRestore);var a=this.s.groups,b=this.s.aoGroups;if(a)for(var c=0,f=a.length;c<f;c++)if(a[c].title&&(b[c].sTitle=a[c].title),a[c].columns)b[c].aiColumns=a[c].columns},_fnDrawCallback:function(){for(var a=this.s.dt.aoColumns,b=this.dom.buttons,c=this.s.aoGroups,f,g=0,h=b.length;g<h;g++)f=b[g],f.__columnIdx!==k&&
|
||||
d("input",f).prop("checked",a[f.__columnIdx].bVisible);b=0;for(f=c.length;b<f;b++){a:{for(var g=c[b].aiColumns,h=0,e=g.length;h<e;h++)if(!1===a[g[h]].bVisible){g=!1;break a}g=!0}if(g)d("input",this.dom.groupButtons[b]).prop("checked",!0),d("input",this.dom.groupButtons[b]).prop("indeterminate",!1);else{a:{g=c[b].aiColumns;h=0;for(e=g.length;h<e;h++)if(!0===a[g[h]].bVisible){g=!1;break a}g=!0}g?(d("input",this.dom.groupButtons[b]).prop("checked",!1),d("input",this.dom.groupButtons[b]).prop("indeterminate",
|
||||
!1)):d("input",this.dom.groupButtons[b]).prop("indeterminate",!0)}}},_fnAddGroups:function(){var a;if("undefined"!=typeof this.s.aoGroups)for(var b=0,c=this.s.aoGroups.length;b<c;b++)a=this._fnDomGroupButton(b),this.dom.groupButtons.push(a),this.dom.buttons.push(a),this.dom.collection.appendChild(a)},_fnAddButtons:function(){var a,b=this.s.dt.aoColumns;if(-1===d.inArray("all",this.s.aiExclude))for(var c=0,f=b.length;c<f;c++)-1===d.inArray(c,this.s.aiExclude)&&(a=this._fnDomColumnButton(c),a.__columnIdx=
|
||||
c,this.dom.buttons.push(a));"alpha"===this.s.order&&this.dom.buttons.sort(function(a,c){var d=b[a.__columnIdx].sTitle,f=b[c.__columnIdx].sTitle;return d===f?0:d<f?-1:1});this.s.restore&&(a=this._fnDomRestoreButton(),a.className+=" ColVis_Restore",this.dom.buttons.push(a));this.s.showAll&&(a=this._fnDomShowXButton(this.s.showAll,!0),a.className+=" ColVis_ShowAll",this.dom.buttons.push(a));this.s.showNone&&(a=this._fnDomShowXButton(this.s.showNone,!1),a.className+=" ColVis_ShowNone",this.dom.buttons.push(a));
|
||||
d(this.dom.collection).append(this.dom.buttons)},_fnDomRestoreButton:function(){var a=this;return d('<li class="ColVis_Special '+(this.s.dt.bJUI?"ui-button ui-state-default":"")+'">'+this.s.restore+"</li>").click(function(){for(var b=0,c=a.s.abOriginal.length;b<c;b++)a.s.dt.oInstance.fnSetColumnVis(b,a.s.abOriginal[b],!1);a._fnAdjustOpenRows();a.s.dt.oInstance.fnAdjustColumnSizing(!1);a.s.dt.oInstance.fnDraw(!1)})[0]},_fnDomShowXButton:function(a,b){var c=this;return d('<li class="ColVis_Special '+
|
||||
(this.s.dt.bJUI?"ui-button ui-state-default":"")+'">'+a+"</li>").click(function(){for(var a=0,d=c.s.abOriginal.length;a<d;a++)-1===c.s.aiExclude.indexOf(a)&&c.s.dt.oInstance.fnSetColumnVis(a,b,!1);c._fnAdjustOpenRows();c.s.dt.oInstance.fnAdjustColumnSizing(!1);c.s.dt.oInstance.fnDraw(!1)})[0]},_fnDomGroupButton:function(a){var b=this,c=this.s.aoGroups[a];return d('<li class="ColVis_Special '+(this.s.dt.bJUI?"ui-button ui-state-default":"")+'"><label><input type="checkbox" /><span>'+c.sTitle+"</span></label></li>").click(function(a){var g=
|
||||
!d("input",this).is(":checked");"li"!==a.target.nodeName.toLowerCase()&&(g=!g);for(a=0;a<c.aiColumns.length;a++)b.s.dt.oInstance.fnSetColumnVis(c.aiColumns[a],g)})[0]},_fnDomColumnButton:function(a){var b=this,c=this.s.dt.aoColumns[a],f=this.s.dt,c=null===this.s.fnLabel?c.sTitle:this.s.fnLabel(a,c.sTitle,c.nTh);return d("<li "+(f.bJUI?'class="ui-button ui-state-default"':"")+'><label><input type="checkbox" /><span>'+c+"</span></label></li>").click(function(c){var e=!d("input",this).is(":checked");
|
||||
"li"!==c.target.nodeName.toLowerCase()&&(e=!e);var i=d.fn.dataTableExt.iApiIndex;d.fn.dataTableExt.iApiIndex=b._fnDataTablesApiIndex.call(b);f.oFeatures.bServerSide?(b.s.dt.oInstance.fnSetColumnVis(a,e,!1),b.s.dt.oInstance.fnAdjustColumnSizing(!1),(""!==f.oScroll.sX||""!==f.oScroll.sY)&&b.s.dt.oInstance.oApi._fnScrollDraw(b.s.dt),b._fnDrawCallback()):b.s.dt.oInstance.fnSetColumnVis(a,e);d.fn.dataTableExt.iApiIndex=i;"input"===c.target.nodeName.toLowerCase()&&null!==b.s.fnStateChange&&b.s.fnStateChange.call(b,
|
||||
a,e)})[0]},_fnDataTablesApiIndex:function(){for(var a=0,b=this.s.dt.oInstance.length;a<b;a++)if(this.s.dt.oInstance[a]==this.s.dt.nTable)return a;return 0},_fnDomCollection:function(){return d("<ul />",{"class":!this.s.dt.bJUI?"ColVis_collection":"ColVis_collection ui-buttonset ui-buttonset-multi"}).css({display:"none",opacity:0,position:!this.s.bCssPosition?"absolute":""})[0]},_fnDomCatcher:function(){var a=this,b=i.createElement("div");b.className="ColVis_catcher";d(b).click(function(){a._fnCollectionHide.call(a,
|
||||
null,null)});return b},_fnDomBackground:function(){var a=this,b=d("<div></div>").addClass("ColVis_collectionBackground").css("opacity",0).click(function(){a._fnCollectionHide.call(a,null,null)});"mouseover"==this.s.activate&&b.mouseover(function(){a.s.overcollection=!1;a._fnCollectionHide.call(a,null,null)});return b[0]},_fnCollectionShow:function(){var a=this,b;b=d(this.dom.button).offset();var c=this.dom.collection,f=this.dom.background,e=parseInt(b.left,10),h=parseInt(b.top+d(this.dom.button).outerHeight(),
|
||||
10);this.s.bCssPosition||(c.style.top=h+"px",c.style.left=e+"px");d(c).css({display:"block",opacity:0});f.style.bottom="0px";f.style.right="0px";h=this.dom.catcher.style;h.height=d(this.dom.button).outerHeight()+"px";h.width=d(this.dom.button).outerWidth()+"px";h.top=b.top+"px";h.left=e+"px";i.body.appendChild(f);i.body.appendChild(c);i.body.appendChild(this.dom.catcher);d(c).animate({opacity:1},a.s.iOverlayFade);d(f).animate({opacity:0.1},a.s.iOverlayFade,"linear",function(){d.browser&&(d.browser.msie&&
|
||||
d.browser.version=="6.0")&&a._fnDrawCallback()});this.s.bCssPosition||(b="left"==this.s.sAlign?e:e-d(c).outerWidth()+d(this.dom.button).outerWidth(),c.style.left=b+"px",f=d(c).outerWidth(),d(c).outerHeight(),e=d(i).width(),b+f>e&&(c.style.left=e-f+"px"));this.s.hidden=!1},_fnCollectionHide:function(){var a=this;!this.s.hidden&&null!==this.dom.collection&&(this.s.hidden=!0,d(this.dom.collection).animate({opacity:0},a.s.iOverlayFade,function(){this.style.display="none"}),d(this.dom.background).animate({opacity:0},
|
||||
a.s.iOverlayFade,function(){i.body.removeChild(a.dom.background);i.body.removeChild(a.dom.catcher)}))},_fnAdjustOpenRows:function(){for(var a=this.s.dt.aoOpenRows,b=this.s.dt.oApi._fnVisbleColumns(this.s.dt),c=0,d=a.length;c<d;c++)a[c].nTr.getElementsByTagName("td")[0].colSpan=b}};e.fnRebuild=function(a){var b=null;"undefined"!=typeof a&&(b=a.fnSettings().nTable);for(var c=0,d=e.aInstances.length;c<d;c++)("undefined"==typeof a||b==e.aInstances[c].s.dt.nTable)&&e.aInstances[c].fnRebuild()};e.defaults=
|
||||
{active:"click",buttonText:"Show / hide columns",aiExclude:[],bRestore:!1,sRestore:"Restore original",bShowAll:!1,sShowAll:"Show All",sAlign:"left",fnStateChange:null,iOverlayFade:500,fnLabel:null,bCssPosition:!1,aoGroups:[],order:"column"};e.aInstances=[];e.prototype.CLASS="ColVis";e.VERSION="1.1.1";e.prototype.VERSION=e.VERSION;"function"==typeof d.fn.dataTable&&"function"==typeof d.fn.dataTableExt.fnVersionCheck&&d.fn.dataTableExt.fnVersionCheck("1.7.0")?d.fn.dataTableExt.aoFeatures.push({fnInit:function(a){var b=
|
||||
a.oInit;return(new e(a,b.colVis||b.oColVis||{})).button()},cFeature:"C",sFeature:"ColVis"}):alert("Warning: ColVis requires DataTables 1.7 or greater - www.datatables.net/download");d.fn.dataTable.ColVis=e;return d.fn.DataTable.ColVis=e};"function"===typeof define&&define.amd?define(["jquery","datatables"],j):"object"===typeof exports?j(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.ColVis&&j(jQuery,jQuery.fn.dataTable)})(window,document);
|
|
@ -0,0 +1,30 @@
|
|||
/*!
|
||||
FixedColumns 3.0.2
|
||||
©2010-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
(function(q,r){var o=function(d){var k=function(a,b){var c=this;if(!this instanceof k)alert("FixedColumns warning: FixedColumns must be initialised with the 'new' keyword.");else{"undefined"==typeof b&&(b={});d.fn.dataTable.camelToHungarian&&d.fn.dataTable.camelToHungarian(k.defaults,b);var g=d.fn.dataTable.Api?(new d.fn.dataTable.Api(a)).settings()[0]:a.fnSettings();this.s={dt:g,iTableColumns:g.aoColumns.length,aiOuterWidths:[],aiInnerWidths:[]};this.dom={scroller:null,header:null,body:null,footer:null,
|
||||
grid:{wrapper:null,dt:null,left:{wrapper:null,head:null,body:null,foot:null},right:{wrapper:null,head:null,body:null,foot:null}},clone:{left:{header:null,body:null,footer:null},right:{header:null,body:null,footer:null}}};g._oFixedColumns=this;g._bInitComplete?this._fnConstruct(b):g.oApi._fnCallbackReg(g,"aoInitComplete",function(){c._fnConstruct(b)},"FixedColumns")}};k.prototype={fnUpdate:function(){this._fnDraw(!0)},fnRedrawLayout:function(){this._fnColCalc();this._fnGridLayout();this.fnUpdate()},
|
||||
fnRecalculateHeight:function(a){delete a._DTTC_iHeight;a.style.height="auto"},fnSetRowHeight:function(a,b){a.style.height=b+"px"},fnGetPosition:function(a){var b=this.s.dt.oInstance;if(d(a).parents(".DTFC_Cloned").length){if("tr"===a.nodeName.toLowerCase())return a=d(a).index(),b.fnGetPosition(d("tr",this.s.dt.nTBody)[a]);var c=d(a).index(),a=d(a.parentNode).index();return[b.fnGetPosition(d("tr",this.s.dt.nTBody)[a]),c,b.oApi._fnVisibleToColumnIndex(this.s.dt,c)]}return b.fnGetPosition(a)},_fnConstruct:function(a){var b=
|
||||
this;if("function"!=typeof this.s.dt.oInstance.fnVersionCheck||!0!==this.s.dt.oInstance.fnVersionCheck("1.8.0"))alert("FixedColumns "+k.VERSION+" required DataTables 1.8.0 or later. Please upgrade your DataTables installation");else if(""===this.s.dt.oScroll.sX)this.s.dt.oInstance.oApi._fnLog(this.s.dt,1,"FixedColumns is not needed (no x-scrolling in DataTables enabled), so no action will be taken. Use 'FixedHeader' for column fixing when scrolling is not enabled");else{this.s=d.extend(!0,this.s,
|
||||
k.defaults,a);a=this.s.dt.oClasses;this.dom.grid.dt=d(this.s.dt.nTable).parents("div."+a.sScrollWrapper)[0];this.dom.scroller=d("div."+a.sScrollBody,this.dom.grid.dt)[0];this._fnColCalc();this._fnGridSetup();var c;d(this.dom.scroller).on("mouseover.DTFC touchstart.DTFC",function(){c="main"}).on("scroll.DTFC",function(){if("main"===c&&(0<b.s.iLeftColumns&&(b.dom.grid.left.liner.scrollTop=b.dom.scroller.scrollTop),0<b.s.iRightColumns))b.dom.grid.right.liner.scrollTop=b.dom.scroller.scrollTop});var g=
|
||||
"onwheel"in r.createElement("div")?"wheel.DTFC":"mousewheel.DTFC";if(0<b.s.iLeftColumns)d(b.dom.grid.left.liner).on("mouseover.DTFC touchstart.DTFC",function(){c="left"}).on("scroll.DTFC",function(){"left"===c&&(b.dom.scroller.scrollTop=b.dom.grid.left.liner.scrollTop,0<b.s.iRightColumns&&(b.dom.grid.right.liner.scrollTop=b.dom.grid.left.liner.scrollTop))}).on(g,function(a){b.dom.scroller.scrollLeft-="wheel"===a.type?-a.originalEvent.deltaX:a.originalEvent.wheelDeltaX});if(0<b.s.iRightColumns)d(b.dom.grid.right.liner).on("mouseover.DTFC touchstart.DTFC",
|
||||
function(){c="right"}).on("scroll.DTFC",function(){"right"===c&&(b.dom.scroller.scrollTop=b.dom.grid.right.liner.scrollTop,0<b.s.iLeftColumns&&(b.dom.grid.left.liner.scrollTop=b.dom.grid.right.liner.scrollTop))}).on(g,function(a){b.dom.scroller.scrollLeft-="wheel"===a.type?-a.originalEvent.deltaX:a.originalEvent.wheelDeltaX});d(q).on("resize.DTFC",function(){b._fnGridLayout.call(b)});var f=!0,e=d(this.s.dt.nTable);e.on("draw.dt.DTFC",function(){b._fnDraw.call(b,f);f=!1}).on("column-sizing.dt.DTFC",
|
||||
function(){b._fnColCalc();b._fnGridLayout(b)}).on("column-visibility.dt.DTFC",function(){b._fnColCalc();b._fnGridLayout(b);b._fnDraw(!0)}).on("destroy.dt.DTFC",function(){e.off("column-sizing.dt.DTFC destroy.dt.DTFC draw.dt.DTFC");d(b.dom.scroller).off("scroll.DTFC mouseover.DTFC");d(q).off("resize.DTFC");d(b.dom.grid.left.liner).off("scroll.DTFC mouseover.DTFC "+g);d(b.dom.grid.left.wrapper).remove();d(b.dom.grid.right.liner).off("scroll.DTFC mouseover.DTFC "+g);d(b.dom.grid.right.wrapper).remove()});
|
||||
this._fnGridLayout();this.s.dt.oInstance.fnDraw(!1)}},_fnColCalc:function(){var a=this,b=0,c=0;this.s.aiInnerWidths=[];this.s.aiOuterWidths=[];d.each(this.s.dt.aoColumns,function(g,f){var e=d(f.nTh),h;if(e.filter(":visible").length){var i=e.outerWidth();0===a.s.aiOuterWidths.length&&(h=d(a.s.dt.nTable).css("border-left-width"),i+="string"===typeof h?1:parseInt(h,10));a.s.aiOuterWidths.length===a.s.dt.aoColumns.length-1&&(h=d(a.s.dt.nTable).css("border-right-width"),i+="string"===typeof h?1:parseInt(h,
|
||||
10));a.s.aiOuterWidths.push(i);a.s.aiInnerWidths.push(e.width());g<a.s.iLeftColumns&&(b+=i);a.s.iTableColumns-a.s.iRightColumns<=g&&(c+=i)}else a.s.aiInnerWidths.push(0),a.s.aiOuterWidths.push(0)});this.s.iLeftWidth=b;this.s.iRightWidth=c},_fnGridSetup:function(){var a=this._fnDTOverflow(),b;this.dom.body=this.s.dt.nTable;this.dom.header=this.s.dt.nTHead.parentNode;this.dom.header.parentNode.parentNode.style.position="relative";var c=d('<div class="DTFC_ScrollWrapper" style="position:relative; clear:both;"><div class="DTFC_LeftWrapper" style="position:absolute; top:0; left:0;"><div class="DTFC_LeftHeadWrapper" style="position:relative; top:0; left:0; overflow:hidden;"></div><div class="DTFC_LeftBodyWrapper" style="position:relative; top:0; left:0; overflow:hidden;"><div class="DTFC_LeftBodyLiner" style="position:relative; top:0; left:0; overflow-y:scroll;"></div></div><div class="DTFC_LeftFootWrapper" style="position:relative; top:0; left:0; overflow:hidden;"></div></div><div class="DTFC_RightWrapper" style="position:absolute; top:0; left:0;"><div class="DTFC_RightHeadWrapper" style="position:relative; top:0; left:0;"><div class="DTFC_RightHeadBlocker DTFC_Blocker" style="position:absolute; top:0; bottom:0;"></div></div><div class="DTFC_RightBodyWrapper" style="position:relative; top:0; left:0; overflow:hidden;"><div class="DTFC_RightBodyLiner" style="position:relative; top:0; left:0; overflow-y:scroll;"></div></div><div class="DTFC_RightFootWrapper" style="position:relative; top:0; left:0;"><div class="DTFC_RightFootBlocker DTFC_Blocker" style="position:absolute; top:0; bottom:0;"></div></div></div></div>')[0],
|
||||
g=c.childNodes[0],f=c.childNodes[1];this.dom.grid.dt.parentNode.insertBefore(c,this.dom.grid.dt);c.appendChild(this.dom.grid.dt);this.dom.grid.wrapper=c;0<this.s.iLeftColumns&&(this.dom.grid.left.wrapper=g,this.dom.grid.left.head=g.childNodes[0],this.dom.grid.left.body=g.childNodes[1],this.dom.grid.left.liner=d("div.DTFC_LeftBodyLiner",c)[0],c.appendChild(g));0<this.s.iRightColumns&&(this.dom.grid.right.wrapper=f,this.dom.grid.right.head=f.childNodes[0],this.dom.grid.right.body=f.childNodes[1],this.dom.grid.right.liner=
|
||||
d("div.DTFC_RightBodyLiner",c)[0],b=d("div.DTFC_RightHeadBlocker",c)[0],b.style.width=a.bar+"px",b.style.right=-a.bar+"px",this.dom.grid.right.headBlock=b,b=d("div.DTFC_RightFootBlocker",c)[0],b.style.width=a.bar+"px",b.style.right=-a.bar+"px",this.dom.grid.right.footBlock=b,c.appendChild(f));if(this.s.dt.nTFoot&&(this.dom.footer=this.s.dt.nTFoot.parentNode,0<this.s.iLeftColumns&&(this.dom.grid.left.foot=g.childNodes[2]),0<this.s.iRightColumns))this.dom.grid.right.foot=f.childNodes[2]},_fnGridLayout:function(){var a=
|
||||
this.dom.grid,b=d(a.wrapper).width(),c=d(this.s.dt.nTable.parentNode).outerHeight(),g=d(this.s.dt.nTable.parentNode.parentNode).outerHeight(),f=this._fnDTOverflow(),e=this.s.iLeftWidth,h=this.s.iRightWidth;f.x&&(c-=f.bar);a.wrapper.style.height=g+"px";0<this.s.iLeftColumns&&(a.left.wrapper.style.width=e+"px",a.left.wrapper.style.height="1px",a.left.body.style.height=c+"px",a.left.foot&&(a.left.foot.style.top=(f.x?f.bar:0)+"px"),a.left.liner.style.width=e+f.bar+"px",a.left.liner.style.height=c+"px");
|
||||
0<this.s.iRightColumns&&(b-=h,f.y&&(b-=f.bar),a.right.wrapper.style.width=h+"px",a.right.wrapper.style.left=b+"px",a.right.wrapper.style.height="1px",a.right.body.style.height=c+"px",a.right.foot&&(a.right.foot.style.top=(f.x?f.bar:0)+"px"),a.right.liner.style.width=h+f.bar+"px",a.right.liner.style.height=c+"px",a.right.headBlock.style.display=f.y?"block":"none",a.right.footBlock.style.display=f.y?"block":"none")},_fnDTOverflow:function(){var a=this.s.dt.nTable,b=a.parentNode,c={x:!1,y:!1,bar:this.s.dt.oScroll.iBarWidth};
|
||||
a.offsetWidth>b.clientWidth&&(c.x=!0);a.offsetHeight>b.clientHeight&&(c.y=!0);return c},_fnDraw:function(a){this._fnGridLayout();this._fnCloneLeft(a);this._fnCloneRight(a);null!==this.s.fnDrawCallback&&this.s.fnDrawCallback.call(this,this.dom.clone.left,this.dom.clone.right);d(this).trigger("draw.dtfc",{leftClone:this.dom.clone.left,rightClone:this.dom.clone.right})},_fnCloneRight:function(a){if(!(0>=this.s.iRightColumns)){var b,c=[];for(b=this.s.iTableColumns-this.s.iRightColumns;b<this.s.iTableColumns;b++)this.s.dt.aoColumns[b].bVisible&&
|
||||
c.push(b);this._fnClone(this.dom.clone.right,this.dom.grid.right,c,a)}},_fnCloneLeft:function(a){if(!(0>=this.s.iLeftColumns)){var b,c=[];for(b=0;b<this.s.iLeftColumns;b++)this.s.dt.aoColumns[b].bVisible&&c.push(b);this._fnClone(this.dom.clone.left,this.dom.grid.left,c,a)}},_fnCopyLayout:function(a,b){for(var c=[],g=[],f=[],e=0,h=a.length;e<h;e++){var i=[];i.nTr=d(a[e].nTr).clone(!0,!0)[0];for(var j=0,n=this.s.iTableColumns;j<n;j++)if(-1!==d.inArray(j,b)){var l=d.inArray(a[e][j].cell,f);-1===l?(l=
|
||||
d(a[e][j].cell).clone(!0,!0)[0],g.push(l),f.push(a[e][j].cell),i.push({cell:l,unique:a[e][j].unique})):i.push({cell:g[l],unique:a[e][j].unique})}c.push(i)}return c},_fnClone:function(a,b,c,g){var f=this,e,h,i,j,n,l,k,m,p;if(g){null!==a.header&&a.header.parentNode.removeChild(a.header);a.header=d(this.dom.header).clone(!0,!0)[0];a.header.className+=" DTFC_Cloned";a.header.style.width="100%";b.head.appendChild(a.header);m=this._fnCopyLayout(this.s.dt.aoHeader,c);j=d(">thead",a.header);j.empty();e=0;
|
||||
for(h=m.length;e<h;e++)j[0].appendChild(m[e].nTr);this.s.dt.oApi._fnDrawHead(this.s.dt,m,!0)}else{m=this._fnCopyLayout(this.s.dt.aoHeader,c);p=[];this.s.dt.oApi._fnDetectHeader(p,d(">thead",a.header)[0]);e=0;for(h=m.length;e<h;e++){i=0;for(j=m[e].length;i<j;i++)p[e][i].cell.className=m[e][i].cell.className,d("span.DataTables_sort_icon",p[e][i].cell).each(function(){this.className=d("span.DataTables_sort_icon",m[e][i].cell)[0].className})}}this._fnEqualiseHeights("thead",this.dom.header,a.header);
|
||||
"auto"==this.s.sHeightMatch&&d(">tbody>tr",f.dom.body).css("height","auto");null!==a.body&&(a.body.parentNode.removeChild(a.body),a.body=null);a.body=d(this.dom.body).clone(!0)[0];a.body.className+=" DTFC_Cloned";a.body.style.paddingBottom=this.s.dt.oScroll.iBarWidth+"px";a.body.style.marginBottom=2*this.s.dt.oScroll.iBarWidth+"px";null!==a.body.getAttribute("id")&&a.body.removeAttribute("id");d(">thead>tr",a.body).empty();d(">tfoot",a.body).remove();var o=d("tbody",a.body)[0];d(o).empty();if(0<this.s.dt.aiDisplay.length){h=
|
||||
d(">thead>tr",a.body)[0];for(k=0;k<c.length;k++)n=c[k],l=d(this.s.dt.aoColumns[n].nTh).clone(!0)[0],l.innerHTML="",j=l.style,j.paddingTop="0",j.paddingBottom="0",j.borderTopWidth="0",j.borderBottomWidth="0",j.height=0,j.width=f.s.aiInnerWidths[n]+"px",h.appendChild(l);d(">tbody>tr",f.dom.body).each(function(a){var b=this.cloneNode(false);b.removeAttribute("id");a=f.s.dt.oFeatures.bServerSide===false?f.s.dt.aiDisplay[f.s.dt._iDisplayStart+a]:a;for(k=0;k<c.length;k++){var e=f.s.dt.aoData[a].anCells||
|
||||
f.s.dt.oApi._fnGetTdNodes(f.s.dt,a);n=c[k];if(e.length>0){l=d(e[n]).clone(true,true)[0];b.appendChild(l)}}o.appendChild(b)})}else d(">tbody>tr",f.dom.body).each(function(){l=this.cloneNode(true);l.className=l.className+" DTFC_NoData";d("td",l).html("");o.appendChild(l)});a.body.style.width="100%";a.body.style.margin="0";a.body.style.padding="0";g&&"undefined"!=typeof this.s.dt.oScroller&&b.liner.appendChild(this.s.dt.oScroller.dom.force.cloneNode(!0));b.liner.appendChild(a.body);this._fnEqualiseHeights("tbody",
|
||||
f.dom.body,a.body);if(null!==this.s.dt.nTFoot){if(g){null!==a.footer&&a.footer.parentNode.removeChild(a.footer);a.footer=d(this.dom.footer).clone(!0,!0)[0];a.footer.className+=" DTFC_Cloned";a.footer.style.width="100%";b.foot.appendChild(a.footer);m=this._fnCopyLayout(this.s.dt.aoFooter,c);b=d(">tfoot",a.footer);b.empty();e=0;for(h=m.length;e<h;e++)b[0].appendChild(m[e].nTr);this.s.dt.oApi._fnDrawHead(this.s.dt,m,!0)}else{m=this._fnCopyLayout(this.s.dt.aoFooter,c);b=[];this.s.dt.oApi._fnDetectHeader(b,
|
||||
d(">tfoot",a.footer)[0]);e=0;for(h=m.length;e<h;e++){i=0;for(j=m[e].length;i<j;i++)b[e][i].cell.className=m[e][i].cell.className}}this._fnEqualiseHeights("tfoot",this.dom.footer,a.footer)}b=this.s.dt.oApi._fnGetUniqueThs(this.s.dt,d(">thead",a.header)[0]);d(b).each(function(a){n=c[a];this.style.width=f.s.aiInnerWidths[n]+"px"});null!==f.s.dt.nTFoot&&(b=this.s.dt.oApi._fnGetUniqueThs(this.s.dt,d(">tfoot",a.footer)[0]),d(b).each(function(a){n=c[a];this.style.width=f.s.aiInnerWidths[n]+"px"}))},_fnGetTrNodes:function(a){for(var b=
|
||||
[],c=0,d=a.childNodes.length;c<d;c++)"TR"==a.childNodes[c].nodeName.toUpperCase()&&b.push(a.childNodes[c]);return b},_fnEqualiseHeights:function(a,b,c){if(!("none"==this.s.sHeightMatch&&"thead"!==a&&"tfoot"!==a)){var g,f,e=b.getElementsByTagName(a)[0],c=c.getElementsByTagName(a)[0],a=d(">"+a+">tr:eq(0)",b).children(":first");a.outerHeight();a.height();for(var e=this._fnGetTrNodes(e),b=this._fnGetTrNodes(c),h=[],c=0,a=b.length;c<a;c++)g=e[c].offsetHeight,f=b[c].offsetHeight,g=f>g?f:g,"semiauto"==this.s.sHeightMatch&&
|
||||
(e[c]._DTTC_iHeight=g),h.push(g);c=0;for(a=b.length;c<a;c++)b[c].style.height=h[c]+"px",e[c].style.height=h[c]+"px"}}};k.defaults={iLeftColumns:1,iRightColumns:0,fnDrawCallback:null,sHeightMatch:"semiauto"};k.version="3.0.2";d.fn.dataTable.FixedColumns=k;return d.fn.DataTable.FixedColumns=k};"function"===typeof define&&define.amd?define(["jquery","datatables"],o):"object"===typeof exports?o(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.FixedColumns&&o(jQuery,jQuery.fn.dataTable)})(window,
|
||||
document);
|
|
@ -0,0 +1,30 @@
|
|||
/*!
|
||||
FixedHeader 2.1.2
|
||||
©2010-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
var FixedHeader;
|
||||
(function(j,k,h){var l=function(e){FixedHeader=function(a,b){if(!this instanceof FixedHeader)alert("FixedHeader warning: FixedHeader must be initialised with the 'new' keyword.");else{var c={aoCache:[],oSides:{top:!0,bottom:!1,left:0,right:0},oZIndexes:{top:104,bottom:103,left:102,right:101},oCloneOnDraw:{top:!1,bottom:!1,left:!0,right:!0},oMes:{iTableWidth:0,iTableHeight:0,iTableLeft:0,iTableRight:0,iTableTop:0,iTableBottom:0},oOffset:{top:0},nTable:null,bFooter:!1,bInitComplete:!1};this.fnGetSettings=
|
||||
function(){return c};this.fnUpdate=function(){this._fnUpdateClones();this._fnUpdatePositions()};this.fnPosition=function(){this._fnUpdatePositions()};var d=e.fn.dataTable.Api?(new e.fn.dataTable.Api(a)).settings()[0]:a.fnSettings();d._oPluginFixedHeader=this;this.fnInit(d,b)}};FixedHeader.prototype={fnInit:function(a,b){var c=this.fnGetSettings(),d=this;this.fnInitSettings(c,b);""!==a.oScroll.sX||""!==a.oScroll.sY?alert("FixedHeader 2 is not supported with DataTables' scrolling mode at this time"):
|
||||
(c.nTable=a.nTable,a.aoDrawCallback.unshift({fn:function(){FixedHeader.fnMeasure();d._fnUpdateClones.call(d);d._fnUpdatePositions.call(d)},sName:"FixedHeader"}),c.bFooter=0<e(">tfoot",c.nTable).length?!0:!1,c.oSides.top&&c.aoCache.push(d._fnCloneTable("fixedHeader","FixedHeader_Header",d._fnCloneThead)),c.oSides.bottom&&c.aoCache.push(d._fnCloneTable("fixedFooter","FixedHeader_Footer",d._fnCloneTfoot)),c.oSides.left&&c.aoCache.push(d._fnCloneTable("fixedLeft","FixedHeader_Left",d._fnCloneTLeft,c.oSides.left)),
|
||||
c.oSides.right&&c.aoCache.push(d._fnCloneTable("fixedRight","FixedHeader_Right",d._fnCloneTRight,c.oSides.right)),FixedHeader.afnScroll.push(function(){d._fnUpdatePositions.call(d)}),e(j).resize(function(){FixedHeader.fnMeasure();d._fnUpdateClones.call(d);d._fnUpdatePositions.call(d)}),e(c.nTable).on("column-reorder.dt",function(){FixedHeader.fnMeasure();d._fnUpdateClones(!0);d._fnUpdatePositions()}).on("column-visibility.dt",function(){FixedHeader.fnMeasure();d._fnUpdateClones(!0);d._fnUpdatePositions()}),
|
||||
FixedHeader.fnMeasure(),d._fnUpdateClones(),d._fnUpdatePositions(),c.bInitComplete=!0)},fnInitSettings:function(a,b){if(b!==h&&(b.top!==h&&(a.oSides.top=b.top),b.bottom!==h&&(a.oSides.bottom=b.bottom),"boolean"==typeof b.left?a.oSides.left=b.left?1:0:b.left!==h&&(a.oSides.left=b.left),"boolean"==typeof b.right?a.oSides.right=b.right?1:0:b.right!==h&&(a.oSides.right=b.right),b.zTop!==h&&(a.oZIndexes.top=b.zTop),b.zBottom!==h&&(a.oZIndexes.bottom=b.zBottom),b.zLeft!==h&&(a.oZIndexes.left=b.zLeft),b.zRight!==
|
||||
h&&(a.oZIndexes.right=b.zRight),b.offsetTop!==h&&(a.oOffset.top=b.offsetTop),b.alwaysCloneTop!==h&&(a.oCloneOnDraw.top=b.alwaysCloneTop),b.alwaysCloneBottom!==h&&(a.oCloneOnDraw.bottom=b.alwaysCloneBottom),b.alwaysCloneLeft!==h&&(a.oCloneOnDraw.left=b.alwaysCloneLeft),b.alwaysCloneRight!==h))a.oCloneOnDraw.right=b.alwaysCloneRight},_fnCloneTable:function(a,b,c,d){var f=this.fnGetSettings(),g;"absolute"!=e(f.nTable.parentNode).css("position")&&(f.nTable.parentNode.style.position="relative");g=f.nTable.cloneNode(!1);
|
||||
g.removeAttribute("id");var i=k.createElement("div");i.style.position="absolute";i.style.top="0px";i.style.left="0px";i.className+=" FixedHeader_Cloned "+a+" "+b;"fixedHeader"==a&&(i.style.zIndex=f.oZIndexes.top);"fixedFooter"==a&&(i.style.zIndex=f.oZIndexes.bottom);"fixedLeft"==a?i.style.zIndex=f.oZIndexes.left:"fixedRight"==a&&(i.style.zIndex=f.oZIndexes.right);g.style.margin="0";i.appendChild(g);k.body.appendChild(i);return{nNode:g,nWrapper:i,sType:a,sPosition:"",sTop:"",sLeft:"",fnClone:c,iCells:d}},
|
||||
_fnMeasure:function(){var a=this.fnGetSettings(),b=a.oMes,c=e(a.nTable),d=c.offset(),f=this._fnSumScroll(a.nTable.parentNode,"scrollTop");this._fnSumScroll(a.nTable.parentNode,"scrollLeft");b.iTableWidth=c.outerWidth();b.iTableHeight=c.outerHeight();b.iTableLeft=d.left+a.nTable.parentNode.scrollLeft;b.iTableTop=d.top+f;b.iTableRight=b.iTableLeft+b.iTableWidth;b.iTableRight=FixedHeader.oDoc.iWidth-b.iTableLeft-b.iTableWidth;b.iTableBottom=FixedHeader.oDoc.iHeight-b.iTableTop-b.iTableHeight},_fnSumScroll:function(a,
|
||||
b){for(var c=a[b];(a=a.parentNode)&&!("HTML"==a.nodeName||"BODY"==a.nodeName);)c=a[b];return c},_fnUpdatePositions:function(){var a=this.fnGetSettings();this._fnMeasure();for(var b=0,c=a.aoCache.length;b<c;b++)"fixedHeader"==a.aoCache[b].sType?this._fnScrollFixedHeader(a.aoCache[b]):"fixedFooter"==a.aoCache[b].sType?this._fnScrollFixedFooter(a.aoCache[b]):"fixedLeft"==a.aoCache[b].sType?this._fnScrollHorizontalLeft(a.aoCache[b]):this._fnScrollHorizontalRight(a.aoCache[b])},_fnUpdateClones:function(a){var b=
|
||||
this.fnGetSettings();a&&(b.bInitComplete=!1);for(var c=0,d=b.aoCache.length;c<d;c++)b.aoCache[c].fnClone.call(this,b.aoCache[c]);a&&(b.bInitComplete=!0)},_fnScrollHorizontalRight:function(a){var b=this.fnGetSettings().oMes,c=FixedHeader.oWin,d=FixedHeader.oDoc,f=a.nWrapper,g=e(f).outerWidth();c.iScrollRight<b.iTableRight?(this._fnUpdateCache(a,"sPosition","absolute","position",f.style),this._fnUpdateCache(a,"sTop",b.iTableTop+"px","top",f.style),this._fnUpdateCache(a,"sLeft",b.iTableLeft+b.iTableWidth-
|
||||
g+"px","left",f.style)):b.iTableLeft<d.iWidth-c.iScrollRight-g?(this._fnUpdateCache(a,"sPosition","fixed","position",f.style),this._fnUpdateCache(a,"sTop",b.iTableTop-c.iScrollTop+"px","top",f.style),this._fnUpdateCache(a,"sLeft",c.iWidth-g+"px","left",f.style)):(this._fnUpdateCache(a,"sPosition","absolute","position",f.style),this._fnUpdateCache(a,"sTop",b.iTableTop+"px","top",f.style),this._fnUpdateCache(a,"sLeft",b.iTableLeft+"px","left",f.style))},_fnScrollHorizontalLeft:function(a){var b=this.fnGetSettings().oMes,
|
||||
c=FixedHeader.oWin,d=a.nWrapper,f=e(d).outerWidth();c.iScrollLeft<b.iTableLeft?(this._fnUpdateCache(a,"sPosition","absolute","position",d.style),this._fnUpdateCache(a,"sTop",b.iTableTop+"px","top",d.style),this._fnUpdateCache(a,"sLeft",b.iTableLeft+"px","left",d.style)):c.iScrollLeft<b.iTableLeft+b.iTableWidth-f?(this._fnUpdateCache(a,"sPosition","fixed","position",d.style),this._fnUpdateCache(a,"sTop",b.iTableTop-c.iScrollTop+"px","top",d.style),this._fnUpdateCache(a,"sLeft","0px","left",d.style)):
|
||||
(this._fnUpdateCache(a,"sPosition","absolute","position",d.style),this._fnUpdateCache(a,"sTop",b.iTableTop+"px","top",d.style),this._fnUpdateCache(a,"sLeft",b.iTableLeft+b.iTableWidth-f+"px","left",d.style))},_fnScrollFixedFooter:function(a){var b=this.fnGetSettings(),c=b.oMes,d=FixedHeader.oWin,f=a.nWrapper,b=e("thead",b.nTable).outerHeight(),g=e(f).outerHeight();d.iScrollBottom<c.iTableBottom?(this._fnUpdateCache(a,"sPosition","absolute","position",f.style),this._fnUpdateCache(a,"sTop",c.iTableTop+
|
||||
c.iTableHeight-g+"px","top",f.style),this._fnUpdateCache(a,"sLeft",c.iTableLeft+"px","left",f.style)):d.iScrollBottom<c.iTableBottom+c.iTableHeight-g-b?(this._fnUpdateCache(a,"sPosition","fixed","position",f.style),this._fnUpdateCache(a,"sTop",d.iHeight-g+"px","top",f.style),this._fnUpdateCache(a,"sLeft",c.iTableLeft-d.iScrollLeft+"px","left",f.style)):(this._fnUpdateCache(a,"sPosition","absolute","position",f.style),this._fnUpdateCache(a,"sTop",c.iTableTop+g+"px","top",f.style),this._fnUpdateCache(a,
|
||||
"sLeft",c.iTableLeft+"px","left",f.style))},_fnScrollFixedHeader:function(a){for(var b=this.fnGetSettings(),c=b.oMes,d=FixedHeader.oWin,e=a.nWrapper,g=0,i=b.nTable.getElementsByTagName("tbody"),h=0;h<i.length;++h)g+=i[h].offsetHeight;c.iTableTop>d.iScrollTop+b.oOffset.top?(this._fnUpdateCache(a,"sPosition","absolute","position",e.style),this._fnUpdateCache(a,"sTop",c.iTableTop+"px","top",e.style),this._fnUpdateCache(a,"sLeft",c.iTableLeft+"px","left",e.style)):d.iScrollTop+b.oOffset.top>c.iTableTop+
|
||||
g?(this._fnUpdateCache(a,"sPosition","absolute","position",e.style),this._fnUpdateCache(a,"sTop",c.iTableTop+g+"px","top",e.style),this._fnUpdateCache(a,"sLeft",c.iTableLeft+"px","left",e.style)):(this._fnUpdateCache(a,"sPosition","fixed","position",e.style),this._fnUpdateCache(a,"sTop",b.oOffset.top+"px","top",e.style),this._fnUpdateCache(a,"sLeft",c.iTableLeft-d.iScrollLeft+"px","left",e.style))},_fnUpdateCache:function(a,b,c,d,e){a[b]!=c&&(e[d]=c,a[b]=c)},_fnClassUpdate:function(a,b){var c=this;
|
||||
if("TR"===a.nodeName.toUpperCase()||"TH"===a.nodeName.toUpperCase()||"TD"===a.nodeName.toUpperCase()||"SPAN"===a.nodeName.toUpperCase())b.className=a.className;e(a).children().each(function(d){c._fnClassUpdate(e(a).children()[d],e(b).children()[d])})},_fnCloneThead:function(a){var b=this.fnGetSettings(),c=a.nNode;if(b.bInitComplete&&!b.oCloneOnDraw.top)this._fnClassUpdate(e("thead",b.nTable)[0],e("thead",c)[0]);else{var d=e(b.nTable).outerWidth();a.nWrapper.style.width=d+"px";for(c.style.width=d+
|
||||
"px";0<c.childNodes.length;)e("thead th",c).unbind("click"),c.removeChild(c.childNodes[0]);a=e("thead",b.nTable).clone(!0)[0];c.appendChild(a);var f=[],g=[];e("thead>tr th",b.nTable).each(function(){f.push(e(this).width())});e("thead>tr td",b.nTable).each(function(){g.push(e(this).width())});e("thead>tr th",b.nTable).each(function(a){e("thead>tr th:eq("+a+")",c).width(f[a]);e(this).width(f[a])});e("thead>tr td",b.nTable).each(function(a){e("thead>tr td:eq("+a+")",c).width(g[a]);e(this).width(g[a])});
|
||||
e("th.sorting, th.sorting_desc, th.sorting_asc",c).bind("click",function(){this.blur()})}},_fnCloneTfoot:function(a){var b=this.fnGetSettings(),c=a.nNode;for(a.nWrapper.style.width=e(b.nTable).outerWidth()+"px";0<c.childNodes.length;)c.removeChild(c.childNodes[0]);a=e("tfoot",b.nTable).clone(!0)[0];c.appendChild(a);e("tfoot:eq(0)>tr th",b.nTable).each(function(a){e("tfoot:eq(0)>tr th:eq("+a+")",c).width(e(this).width())});e("tfoot:eq(0)>tr td",b.nTable).each(function(a){e("tfoot:eq(0)>tr td:eq("+
|
||||
a+")",c).width(e(this).width())})},_fnCloneTLeft:function(a){for(var b=this.fnGetSettings(),c=a.nNode,d=e("tbody",b.nTable)[0];0<c.childNodes.length;)c.removeChild(c.childNodes[0]);c.appendChild(e("thead",b.nTable).clone(!0)[0]);c.appendChild(e("tbody",b.nTable).clone(!0)[0]);b.bFooter&&c.appendChild(e("tfoot",b.nTable).clone(!0)[0]);var f="gt("+(a.iCells-1)+")";e("thead tr",c).each(function(){e("th:"+f,this).remove()});e("tfoot tr",c).each(function(){e("th:"+f,this).remove()});e("tbody tr",c).each(function(){e("td:"+
|
||||
f,this).remove()});this.fnEqualiseHeights("thead",d.parentNode,c);this.fnEqualiseHeights("tbody",d.parentNode,c);this.fnEqualiseHeights("tfoot",d.parentNode,c);for(var g=d=0;g<a.iCells;g++)d+=e("thead tr th:eq("+g+")",b.nTable).outerWidth();c.style.width=d+"px";a.nWrapper.style.width=d+"px"},_fnCloneTRight:function(a){for(var b=this.fnGetSettings(),c=e("tbody",b.nTable)[0],d=a.nNode,f=e("tbody tr:eq(0) td",b.nTable).length;0<d.childNodes.length;)d.removeChild(d.childNodes[0]);d.appendChild(e("thead",
|
||||
b.nTable).clone(!0)[0]);d.appendChild(e("tbody",b.nTable).clone(!0)[0]);b.bFooter&&d.appendChild(e("tfoot",b.nTable).clone(!0)[0]);e("thead tr th:lt("+(f-a.iCells)+")",d).remove();e("tfoot tr th:lt("+(f-a.iCells)+")",d).remove();e("tbody tr",d).each(function(){e("td:lt("+(f-a.iCells)+")",this).remove()});this.fnEqualiseHeights("thead",c.parentNode,d);this.fnEqualiseHeights("tbody",c.parentNode,d);this.fnEqualiseHeights("tfoot",c.parentNode,d);for(var g=c=0;g<a.iCells;g++)c+=e("thead tr th:eq("+(f-
|
||||
1-g)+")",b.nTable).outerWidth();d.style.width=c+"px";a.nWrapper.style.width=c+"px"},fnEqualiseHeights:function(a,b,c){var d=e(a+" tr",b),f;e(a+" tr",c).each(function(a){f=d.eq(a).css("height");"Microsoft Internet Explorer"==navigator.appName&&(f=parseInt(f,10)+1);e(this).css("height",f);d.eq(a).css("height",f)})}};FixedHeader.oWin={iScrollTop:0,iScrollRight:0,iScrollBottom:0,iScrollLeft:0,iHeight:0,iWidth:0};FixedHeader.oDoc={iHeight:0,iWidth:0};FixedHeader.afnScroll=[];FixedHeader.fnMeasure=function(){var a=
|
||||
e(j),b=e(k),c=FixedHeader.oWin,d=FixedHeader.oDoc;d.iHeight=b.height();d.iWidth=b.width();c.iHeight=a.height();c.iWidth=a.width();c.iScrollTop=a.scrollTop();c.iScrollLeft=a.scrollLeft();c.iScrollRight=d.iWidth-c.iScrollLeft-c.iWidth;c.iScrollBottom=d.iHeight-c.iScrollTop-c.iHeight};FixedHeader.version="2.1.2";e(j).scroll(function(){FixedHeader.fnMeasure();for(var a=0,b=FixedHeader.afnScroll.length;a<b;a++)FixedHeader.afnScroll[a]()});e.fn.dataTable.FixedHeader=FixedHeader;return e.fn.DataTable.FixedHeader=
|
||||
FixedHeader};"function"===typeof define&&define.amd?define(["jquery","datatables"],l):"object"===typeof exports?l(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.FixedHeader&&l(jQuery,jQuery.fn.dataTable)})(window,document);
|
|
@ -0,0 +1,186 @@
|
|||
/* Set the defaults for DataTables initialisation */
|
||||
$.extend( true, $.fn.dataTable.defaults, {
|
||||
"sDom":
|
||||
"<'row'<'large-6 columns'l><'large-6 columns'f>r>"+
|
||||
"t"+
|
||||
"<'row'<'large-6 columns'i><'large-6 columns'p>>",
|
||||
"sPaginationType": "bootstrap",
|
||||
"oLanguage": {
|
||||
"sLengthMenu": "_MENU_ records per page"
|
||||
}
|
||||
} );
|
||||
|
||||
|
||||
/* API method to get paging information */
|
||||
$.fn.dataTableExt.oApi.fnPagingInfo = function ( oSettings )
|
||||
{
|
||||
return {
|
||||
"iStart": oSettings._iDisplayStart,
|
||||
"iEnd": oSettings.fnDisplayEnd(),
|
||||
"iLength": oSettings._iDisplayLength,
|
||||
"iTotal": oSettings.fnRecordsTotal(),
|
||||
"iFilteredTotal": oSettings.fnRecordsDisplay(),
|
||||
"iPage": oSettings._iDisplayLength === -1 ?
|
||||
0 : Math.ceil( oSettings._iDisplayStart / oSettings._iDisplayLength ),
|
||||
"iTotalPages": oSettings._iDisplayLength === -1 ?
|
||||
0 : Math.ceil( oSettings.fnRecordsDisplay() / oSettings._iDisplayLength )
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
/* Bootstrap style pagination control */
|
||||
$.extend( $.fn.dataTableExt.oPagination, {
|
||||
"bootstrap": {
|
||||
"fnInit": function( oSettings, nPaging, fnDraw ) {
|
||||
var oLang = oSettings.oLanguage.oPaginate;
|
||||
var fnClickHandler = function ( e ) {
|
||||
e.preventDefault();
|
||||
if ( oSettings.oApi._fnPageChange(oSettings, e.data.action) ) {
|
||||
fnDraw( oSettings );
|
||||
}
|
||||
};
|
||||
|
||||
$(nPaging).append(
|
||||
'<ul class="pagination">'+
|
||||
'<li class="prev arrow unavailable"><a href="">«</a></li>'+
|
||||
'<li class="next arrow unavailable"><a href="">»</a></li>'+
|
||||
'</ul>'
|
||||
);
|
||||
var els = $('a', nPaging);
|
||||
$(els[0]).bind( 'click.DT', { action: "previous" }, fnClickHandler );
|
||||
$(els[1]).bind( 'click.DT', { action: "next" }, fnClickHandler );
|
||||
},
|
||||
|
||||
"fnUpdate": function ( oSettings, fnDraw ) {
|
||||
var iListLength = 5;
|
||||
var oPaging = oSettings.oInstance.fnPagingInfo();
|
||||
var an = oSettings.aanFeatures.p;
|
||||
var pages = [];
|
||||
var i, ien, klass, host;
|
||||
|
||||
// This could use some improving - however, see
|
||||
// https://github.com/DataTables/DataTables/issues/163 - this will
|
||||
// be changing in the near future, so not much point in doing too
|
||||
// much just now
|
||||
if ( oPaging.iTotalPages <= 6 ) {
|
||||
for ( i=0 ; i<oPaging.iTotalPages ; i++ ) {
|
||||
pages.push( i );
|
||||
}
|
||||
}
|
||||
else {
|
||||
// Current page
|
||||
pages.push( oPaging.iPage );
|
||||
|
||||
// After current page
|
||||
var pagesAfter = oPaging.iPage + 2 >= oPaging.iTotalPages ?
|
||||
oPaging.iTotalPages :
|
||||
oPaging.iPage + 2;
|
||||
for ( i=oPaging.iPage+1 ; i<pagesAfter ; i++ ) {
|
||||
pages.push( i );
|
||||
}
|
||||
|
||||
// After gap
|
||||
if ( pagesAfter < oPaging.iTotalPages-2 ) {
|
||||
pages.push( null );
|
||||
}
|
||||
|
||||
// End
|
||||
if ( $.inArray( oPaging.iTotalPages-2, pages ) === -1 && oPaging.iPage < oPaging.iTotalPages-2 ) {
|
||||
pages.push( oPaging.iTotalPages-2 );
|
||||
}
|
||||
if ( $.inArray( oPaging.iTotalPages-1, pages ) === -1 ) {
|
||||
pages.push( oPaging.iTotalPages-1 );
|
||||
}
|
||||
|
||||
// Pages before
|
||||
var pagesBefore = oPaging.iPage - 2 > 0 ?
|
||||
oPaging.iPage - 2 :
|
||||
0;
|
||||
for ( i=oPaging.iPage-1 ; i>pagesBefore ; i-- ) {
|
||||
pages.unshift( i );
|
||||
}
|
||||
|
||||
// Before gap
|
||||
if ( pagesBefore > 1 ) {
|
||||
pages.unshift( null );
|
||||
}
|
||||
|
||||
// Start
|
||||
if ( $.inArray( 1, pages ) === -1 && oPaging.iTotalPages > 1 ) {
|
||||
pages.unshift( 1 );
|
||||
}
|
||||
if ( $.inArray( 0, pages ) === -1 ) {
|
||||
pages.unshift( 0 );
|
||||
}
|
||||
}
|
||||
|
||||
for ( i=0, ien=an.length ; i<ien ; i++ ) {
|
||||
// Remove the middle elements
|
||||
host = an[i];
|
||||
$('li:gt(0)', host).filter(':not(:last)').remove();
|
||||
|
||||
// Add the new list items and their event handlers
|
||||
$.each( pages, function( i, page ) {
|
||||
klass = page === null ? 'unavailable' :
|
||||
page === oPaging.iPage ? 'current' : '';
|
||||
$('<li class="'+klass+'"><a href="">'+(page===null? '…' : page+1)+'</a></li>')
|
||||
.insertBefore( $('li:last', host) )
|
||||
.bind('click', function (e) {
|
||||
e.preventDefault();
|
||||
oSettings._iDisplayStart = (parseInt($('a', this).text(),10)-1) * oPaging.iLength;
|
||||
fnDraw( oSettings );
|
||||
} );
|
||||
} );
|
||||
|
||||
// Add / remove disabled classes from the static elements
|
||||
if ( oPaging.iPage === 0 ) {
|
||||
$('li:first', host).addClass('unavailable');
|
||||
} else {
|
||||
$('li:first', host).removeClass('unavailable');
|
||||
}
|
||||
|
||||
if ( oPaging.iPage === oPaging.iTotalPages-1 || oPaging.iTotalPages === 0 ) {
|
||||
$('li:last', host).addClass('unavailable');
|
||||
} else {
|
||||
$('li:last', host).removeClass('unavailable');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} );
|
||||
|
||||
|
||||
/*
|
||||
* TableTools Foundation compatibility
|
||||
* Required TableTools 2.1+
|
||||
*/
|
||||
if ( $.fn.DataTable.TableTools ) {
|
||||
// Set the classes that TableTools uses to something suitable for Foundation
|
||||
$.extend( true, $.fn.DataTable.TableTools.classes, {
|
||||
"container": "DTTT button-group",
|
||||
"buttons": {
|
||||
"normal": "button",
|
||||
"disabled": "disabled"
|
||||
},
|
||||
"collection": {
|
||||
"container": "DTTT_dropdown dropdown-menu",
|
||||
"buttons": {
|
||||
"normal": "",
|
||||
"disabled": "disabled"
|
||||
}
|
||||
},
|
||||
"select": {
|
||||
"row": "active"
|
||||
}
|
||||
} );
|
||||
|
||||
// Have the collection use a bootstrap compatible dropdown
|
||||
$.extend( true, $.fn.DataTable.TableTools.DEFAULTS.oTags, {
|
||||
"collection": {
|
||||
"container": "ul",
|
||||
"button": "li",
|
||||
"liner": "a"
|
||||
}
|
||||
} );
|
||||
}
|
||||
|
|
@ -0,0 +1,102 @@
|
|||
|
||||
(function(){
|
||||
|
||||
var DataTable = $.fn.dataTable;
|
||||
var sort_prefix = 'css_right ui-icon ui-icon-';
|
||||
var toolbar_prefix = 'fg-toolbar ui-toolbar ui-widget-header ui-helper-clearfix ui-corner-';
|
||||
|
||||
/* Set the defaults for DataTables initialisation */
|
||||
$.extend( true, DataTable.defaults, {
|
||||
dom:
|
||||
'<"'+toolbar_prefix+'tl ui-corner-tr"lfr>'+
|
||||
't'+
|
||||
'<"'+toolbar_prefix+'bl ui-corner-br"ip>',
|
||||
renderer: 'jqueryui'
|
||||
} );
|
||||
|
||||
|
||||
$.extend( DataTable.ext.classes, {
|
||||
/* Full numbers paging buttons */
|
||||
"sPageButton": "fg-button ui-button ui-state-default",
|
||||
"sPageButtonActive": "ui-state-disabled",
|
||||
"sPageButtonDisabled": "ui-state-disabled",
|
||||
|
||||
/* Features */
|
||||
"sPaging": "dataTables_paginate fg-buttonset ui-buttonset fg-buttonset-multi "+
|
||||
"ui-buttonset-multi paging_", /* Note that the type is postfixed */
|
||||
|
||||
/* Sorting */
|
||||
"sSortAsc": "ui-state-default sorting_asc",
|
||||
"sSortDesc": "ui-state-default sorting_desc",
|
||||
"sSortable": "ui-state-default sorting",
|
||||
"sSortableAsc": "ui-state-default sorting_asc_disabled",
|
||||
"sSortableDesc": "ui-state-default sorting_desc_disabled",
|
||||
"sSortableNone": "ui-state-default sorting_disabled",
|
||||
"sSortIcon": "DataTables_sort_icon",
|
||||
|
||||
/* Scrolling */
|
||||
"sScrollHead": "dataTables_scrollHead "+"ui-state-default",
|
||||
"sScrollFoot": "dataTables_scrollFoot "+"ui-state-default",
|
||||
|
||||
/* Misc */
|
||||
"sHeaderTH": "ui-state-default",
|
||||
"sFooterTH": "ui-state-default",
|
||||
} );
|
||||
|
||||
|
||||
DataTable.ext.renderer.header.jqueryui = function ( settings, cell, column, idx, classes ) {
|
||||
$('<div/>')
|
||||
.addClass( 'DataTables_sort_wrapper' )
|
||||
.append( cell.contents() )
|
||||
.append( $('<span/>')
|
||||
.addClass( classes.sSortIcon+' '+column.sSortingClassJUI )
|
||||
)
|
||||
.appendTo( cell );
|
||||
|
||||
// Attach a sort listener to update on sort
|
||||
$(settings.nTable).on( 'order.dt', function ( e, settings, sorting, columns ) {
|
||||
cell
|
||||
.removeClass( classes.sSortAsc +" "+classes.sSortDesc )
|
||||
.addClass( columns[ idx ] == 'asc' ?
|
||||
classes.sSortAsc : columns[ idx ] == 'desc' ?
|
||||
classes.sSortDesc :
|
||||
column.sSortingClass
|
||||
);
|
||||
|
||||
cell
|
||||
.find( 'span' )
|
||||
.removeClass(
|
||||
sort_prefix+'triangle-1-n' +" "+
|
||||
sort_prefix+'triangle-1-s' +" "+
|
||||
sort_prefix+'carat-2-n-s' +" "+
|
||||
sort_prefix+'carat-1-n' +" "+
|
||||
sort_prefix+'carat-1-s'
|
||||
)
|
||||
.addClass( columns[ idx ] == 'asc' ?
|
||||
sort_prefix+'triangle-1-n' : columns[ idx ] == 'desc' ?
|
||||
sort_prefix+'triangle-1-s' :
|
||||
column.sSortingClassJUI
|
||||
);
|
||||
} );
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* TableTools jQuery UI compatibility
|
||||
* Required TableTools 2.1+
|
||||
*/
|
||||
if ( DataTable.TableTools ) {
|
||||
$.extend( true, DataTable.TableTools.classes, {
|
||||
"container": "DTTT_container ui-buttonset ui-buttonset-multi",
|
||||
"buttons": {
|
||||
"normal": "DTTT_button ui-button ui-state-default"
|
||||
},
|
||||
"collection": {
|
||||
"container": "DTTT_collection ui-buttonset ui-buttonset-multi"
|
||||
}
|
||||
} );
|
||||
}
|
||||
|
||||
|
||||
}());
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
/*!
|
||||
KeyTable 1.2.1
|
||||
©2010-2014 SpryMedia Ltd - datatables.net/license
|
||||
*/
|
||||
var KeyTable;
|
||||
(function(F,n,K){var A=function(d){KeyTable=function(j){function A(a){return function(e,c,p){(null===e||"number"==typeof e)&&(null===c||"number"==typeof c)&&"function"==typeof p?k[a].push({x:e,y:c,fn:p}):"object"==typeof e&&"function"==typeof c?(e=E(e),k[a].push({x:e[0],y:e[1],fn:c})):alert("Unhandable event type was added: x"+e+" y:"+c+" z:"+p)}}function L(a){return function(e,c,p){(null===e||"number"==typeof e)&&(null===c||"number"==typeof c)?"function"==typeof p?B(a,e,c,p):B(a,e,c):"object"==
|
||||
typeof e?(e=E(e),"function"==typeof c?B(a,e[0],e[1],c):B(a,e[0],e[1])):alert("Unhandable event type was removed: x"+e+" y:"+c+" z:"+p)}}function B(a,e,c,p){for(var h=0,b=0,d=k[a].length;b<d-h;b++)if("undefined"!=typeof p)k[a][b-h].x==e&&(k[a][b-h].y==c&&k[a][b-h].fn==p)&&(k[a].splice(b-h,1),h++);else if(k[a][b-h].x==e&&k[a][b-h].y==c)return k[a].splice(b,1),1;return h}function C(a,e,c){for(var p=0,a=k[a],b=0;b<a.length;b++)if(a[b].x==e&&a[b].y==c||null===a[b].x&&a[b].y==c||a[b].x==e&&null===a[b].y||
|
||||
null===a[b].x&&null===a[b].y)a[b].fn(w(e,c),e,c),p++;return p}function q(a,e){if(t!=a){"undefined"==typeof e&&(e=!0);null!==t&&G(t);d(a).addClass(x);d(a).parent().addClass(x);var c;if(i){c=i;for(var b=H(a)[1],h=o;b>=c.fnDisplayEnd();)0<=c._iDisplayLength?c._iDisplayStart+c._iDisplayLength<c.fnRecordsDisplay()&&(c._iDisplayStart+=c._iDisplayLength):c._iDisplayStart=0,i.oApi._fnCalculateEnd(c);for(;b<c._iDisplayStart;)c._iDisplayStart=0<=c._iDisplayLength?c._iDisplayStart-c._iDisplayLength:0,0>c._iDisplayStart&&
|
||||
(c._iDisplayStart=0),i.oApi._fnCalculateEnd(c);i.oApi._fnDraw(c);o=h}b=E(a);t=a;l=b[0];g=b[1];var r,j,k,m,f;if(e){r=d(F).height();b=d(F).width();j=d(n).scrollTop();h=d(n).scrollLeft();k=a.offsetHeight;m=a.offsetWidth;f=a;var q=0,s=0;if(f.offsetParent){q=f.offsetLeft;s=f.offsetTop;for(f=f.offsetParent;f;)q+=f.offsetLeft,s+=f.offsetTop,f=f.offsetParent}f=[q,s];if(i&&"undefined"!=typeof c.oScroll&&(""!==c.oScroll.sX||""!==c.oScroll.sY))f[1]-=d(c.nTable.parentNode).scrollTop(),f[0]-=d(c.nTable.parentNode).scrollLeft();
|
||||
f[1]+k>j+r?(r=f[1]+k-r,n.documentElement.scrollTop=r,n.body.scrollTop=r):f[1]<j&&(r=f[1],n.documentElement.scrollTop=r,n.body.scrollTop=r);f[0]+m>h+b?(b=f[0]+m-b,n.documentElement.scrollLeft=b,n.body.scrollLeft=b):f[0]<h&&(b=f[0],n.documentElement.scrollLeft=b,n.body.scrollLeft=b)}if(i&&"undefined"!=typeof c.oScroll&&(""!==c.oScroll.sX||""!==c.oScroll.sY))(c=c.nTable.parentNode,r=c.clientHeight,b=c.clientWidth,j=c.scrollTop,h=c.scrollLeft,k=a.offsetHeight,m=a.offsetWidth,a.offsetTop+k>r+j?c.scrollTop=
|
||||
a.offsetTop+k-r:a.offsetTop<j&&(c.scrollTop=a.offsetTop),a.offsetLeft+m>b+h)?c.scrollLeft=a.offsetLeft+m-b:a.offsetLeft<h&&(c.scrollLeft=a.offsetLeft);o||(o=!0);C("focus",l,g)}}function y(){G(t);t=g=l=null;o=!1}function G(a){d(a).removeClass(x);d(a).parent().removeClass(x);C("blur",l,g)}function I(){for(var a=this;"TD"!=a.nodeName;)a=a.parentNode;q(a);o||(o=!0)}function w(a,b){return i?"undefined"!=typeof i.aoData[i.aiDisplay[b]]?i.aoData[i.aiDisplay[b]].nTr.getElementsByTagName("td")[a]:null:d("tr:eq("+
|
||||
b+")>td:eq("+a+")",z)[0]}function E(a){return i?[d("td",a.parentNode).index(a),d("tr",a.parentNode.parentNode).index(a.parentNode)+i._iDisplayStart]:[d("td",a.parentNode).index(a),d("tr",a.parentNode.parentNode).index(a.parentNode)]}function H(a){for(var b=0,c=i.aiDisplay.length;b<c;b++)for(var d=i.aoData[i.aiDisplay[b]].nTr.getElementsByTagName("td"),h=0,g=d.length;h<g;h++)if(d[h]==a)return[h,b];return null}this.block=!1;this.event={remove:{}};this.fnGetCurrentPosition=function(){return[l,g]};this.fnGetCurrentData=
|
||||
function(){return t.innerHTML};this.fnGetCurrentTD=function(){return t};this.fnSetPosition=function(a,b){"object"==typeof a&&a.nodeName?q(a):q(w(a,b))};this.fnBlur=function(){y()};var z=null,t=null,l=null,g=null,J=null,x="focus",o=!1,k={action:[],esc:[],focus:[],blur:[]},i=null,D,s,u=!1,m;for(m in k)m&&(this.event[m]=A(m),this.event.remove[m]=L(m));var v;j===K?(m=d("table.KeyTable")[0],v=null):d.isPlainObject(j)?(m=j.table,v=j.datatable):(v=(new d.fn.dataTable.Api(j)).settings()[0],m=v.nTable);var b=
|
||||
j,J=this;"undefined"==typeof b&&(b={});"undefined"==typeof b.focus&&(b.focus=[0,0]);b.table=m;d(b.table).addClass("KeyTable");"undefined"!=typeof b.focusClass&&(x=b.focusClass);"undefined"!=typeof v&&(i=v);"undefined"==typeof b.initScroll&&(b.initScroll=!0);"undefined"==typeof b.form&&(b.form=!1);D=b.form;z=b.table.getElementsByTagName("tbody")[0];D?(j=n.createElement("div"),s=n.createElement("input"),j.style.height="1px",j.style.width="0px",j.style.overflow="hidden","undefined"!=typeof b.tabIndex&&
|
||||
(s.tabIndex=b.tabIndex),j.appendChild(s),b.table.parentNode.insertBefore(j,b.table.nextSibling),d(s).focus(function(){if(!u){o=true;u=false;typeof b.focus.nodeName!="undefined"?q(b.focus,b.initScroll):q(w(b.focus[0],b.focus[1]),b.initScroll);setTimeout(function(){s.blur()},0)}}),o=!1):("undefined"!=typeof b.focus.nodeName?q(b.focus,b.initScroll):q(w(b.focus[0],b.focus[1]),b.initScroll),o||(o=!0));d(n).bind("keydown",function(a){if(J.block||!o||a.metaKey||a.altKey||a.ctrlKey)return true;var b;b=z.getElementsByTagName("tr")[0].getElementsByTagName("td").length;
|
||||
var c;if(i){c=i.aiDisplay.length;var d=H(t);if(d===null)return;l=d[0];g=d[1]}else c=z.getElementsByTagName("tr").length;d=a.keyCode==9&&a.shiftKey?-1:a.keyCode;switch(d){case 13:a.preventDefault();a.stopPropagation();C("action",l,g);return true;case 27:if(!C("esc",l,g)){y();return}a=l;b=g;break;case -1:case 37:if(l>0){a=l-1;b=g}else if(g>0){a=b-1;b=g-1}else{if(d==-1&&D){u=true;s.focus();setTimeout(function(){u=false},0);o=false;y();return true}return false}break;case 38:if(g>0){a=l;b=g-1}else return false;
|
||||
break;case 36:a=l;b=0;break;case 33:a=l;b=g-10;b<0&&(b=0);break;case 9:case 39:if(l<b-1){a=l+1;b=g}else if(g<c-1){a=0;b=g+1}else{if(d==9&&D){u=true;s.focus();setTimeout(function(){u=false},0);o=false;y();return true}return false}break;case 40:if(g<c-1){a=l;b=g+1}else return false;break;case 35:a=l;b=c-1;break;case 34:a=l;b=g+10;b>c-1&&(b=c-1);break;default:return true}q(w(a,b));return false});if(i)d(i.nTable).on("click","td",I);else d(z).on("click","td",I);d(n).click(function(a){for(var a=a.target,
|
||||
d=false;a;){if(a==b.table){d=true;break}a=a.parentNode}d||y()})};KeyTable.version="1.2.1";d.fn.dataTable.KeyTable=KeyTable;return d.fn.DataTable.KeyTable=KeyTable};"function"===typeof define&&define.amd?define(["jquery","datatables"],A):"object"===typeof exports?A(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.KeyTable&&A(jQuery,jQuery.fn.dataTable)})(window,document);
|