add dialog draggable

This commit is contained in:
ivan deng
2018-01-31 20:47:35 +08:00
parent 000712850a
commit cd5f47581d
6 changed files with 123 additions and 12 deletions

View File

@@ -0,0 +1,10 @@
/* report更紧凑,无边框 */
.table-tight td {
padding: 2px !important;
border-top: 0px !important;
}
.table-tight > thead > tr > th, .table-tight > tbody > tr > th, .table-tight > tfoot > tr > th,
.table-tight > thead > tr > td, .table-tight > tbody > tr > td, .table-tight > tfoot > tr > td{
padding: 2px !important;
border-top: 0px !important;
}

View File

@@ -9,18 +9,21 @@
top: 3px;
content: "";
}
/*
list标头不换行
*/
.table-responsive {
white-space: nowrap !important;
}
/*
sheet全宽
*/
.o_form_view .o_form_sheet_bg .o_form_sheet {
max-width: 98%!important;
max-width: 98% !important;
}
/*
强制表格滚动,企业版/社区版中生效
*/
@@ -30,26 +33,39 @@ sheet全宽
overflow: hidden !important;
overflow-x: auto !important;
}
.force_scroll ::-webkit-scrollbar {
height: 16px!important;
height: 16px !important;
}
/* 滚动条的滑轨背景颜色 */
.force_scroll ::-webkit-scrollbar-track {
background-color: lightgrey!important;;
-webkit-border-radius: 2em !important;;
-moz-border-radius: 2em !important;;
border-radius: 2em !important;;
background-color: lightgrey !important;
-webkit-border-radius: 2em !important;
-moz-border-radius: 2em !important;
border-radius: 2em !important;
}
/* 滑块颜色 */
.force_scroll ::-webkit-scrollbar-thumb {
background-color: #666666 !important;;
-webkit-border-radius: 2em !important;;
-moz-border-radius: 2em !important;;
border-radius: 2em !important;;
background-color: #666666 !important;
-webkit-border-radius: 2em !important;
-moz-border-radius: 2em !important;
border-radius: 2em !important;
}
/* 横向滚动条和纵向滚动条相交处尖角的颜色 */
.force_scroll ::-webkit-scrollbar-corner {
background-color: black;
}
/* report更紧凑,无边框 */
.table-tight td {
padding: 2px !important;
border-top: 0px !important;
}
.table-tight > thead > tr > th, .table-tight > tbody > tr > th, .table-tight > tfoot > tr > th,
.table-tight > thead > tr > td, .table-tight > tbody > tr > td, .table-tight > tfoot > tr > td{
padding: 2px !important;
border-top: 0px !important;
}

View File

@@ -0,0 +1,60 @@
.tree_search_item {
cursor: pointer;
}
.tree_search_item .selected a:before {
font-family: FontAwesome;
position: absolute;
left: 6px;
top: 3px;
content: "";
}
/*
list标头不换行
*/
.table-responsive {
white-space: nowrap !important;
}
/*
sheet全宽
*/
.o_form_view .o_form_sheet_bg .o_form_sheet {
max-width: 98% !important;
}
/*
强制表格滚动,企业版/社区版中生效
*/
.force_scroll .table-responsive {
white-space: nowrap !important;
overflow: hidden !important;
overflow-x: auto !important;
}
.force_scroll ::-webkit-scrollbar {
height: 16px !important;
}
/* 滚动条的滑轨背景颜色 */
.force_scroll ::-webkit-scrollbar-track {
background-color: lightgrey !important;
-webkit-border-radius: 2em !important;
-moz-border-radius: 2em !important;
border-radius: 2em !important;
}
/* 滑块颜色 */
.force_scroll ::-webkit-scrollbar-thumb {
background-color: #666666 !important;
-webkit-border-radius: 2em !important;
-moz-border-radius: 2em !important;
border-radius: 2em !important;
}
/* 横向滚动条和纵向滚动条相交处尖角的颜色 */
.force_scroll ::-webkit-scrollbar-corner {
background-color: black;
}

View File

@@ -0,0 +1,17 @@
odoo.define('app_ui_enhance.web_draggable_dialog', function (require) {
'use strict';
var Dialog = require('web.Dialog');
Dialog.include({
open: function () {
this._super.apply(this, arguments);
this._opened.done(function(){
$(".modal.in").draggable({
handle: ".modal-header"
});
});
return this;
},
});
});