update ui_en

This commit is contained in:
ivan deng
2018-05-07 01:23:58 +08:00
parent c65bc2a09d
commit 4a6e885b11
6 changed files with 15 additions and 27 deletions

View File

@@ -1,10 +0,0 @@
/* 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

@@ -25,7 +25,7 @@ sheet全宽
} }
/* /*
强制表格滚动,企业版/社区版中生效 强制表格滚动,企业版/社区版中生效table加上 class="force_scroll"生效
*/ */
.force_scroll .table-responsive { .force_scroll .table-responsive {

View File

@@ -70,15 +70,18 @@ PivotView.include({
$(QWeb.render("odooApp.TreeSearch.Placeholder", {})).appendTo($node); $(QWeb.render("odooApp.TreeSearch.Placeholder", {})).appendTo($node);
var date_fields = []; var date_fields = [];
// 增加参数控制app_ui_show_search_date var canShow = 1;
// 增加参数控制app_ui_show_search_date,特殊处理
new Model('ir.config_parameter').call('search_read', [[['key', '=', 'app_ui_show_search_date']], ['value']]).then(function (show) { new Model('ir.config_parameter').call('search_read', [[['key', '=', 'app_ui_show_search_date']], ['value']]).then(function (show) {
if (show.length >= 1 && (show[0]['value'] == "True")) { if (show.length >= 1 && (show[0]['value'] == "False")) {
canShow = 0;
}
if (canShow) {
_.each(self.fields, function (value, key, list) { _.each(self.fields, function (value, key, list) {
if (value.store && value.type === "datetime" || value.type === "date") { if (value.store && value.type === "datetime" || value.type === "date") {
date_fields.push([key, value.string]); date_fields.push([key, value.string]);
} }
}); });
if (date_fields.length > 0) { if (date_fields.length > 0) {
self.$search_date = $(QWeb.render('odooApp.SearchDate', {'date_fields': date_fields})) self.$search_date = $(QWeb.render('odooApp.SearchDate', {'date_fields': date_fields}))
self.$search_date.find('.app_start_date').datetimepicker(datepickers_options); self.$search_date.find('.app_start_date').datetimepicker(datepickers_options);
@@ -122,7 +125,6 @@ PivotView.include({
} }
} }
}); });
//显示搜索键因为pivot特殊故要单独处理 //显示搜索键因为pivot特殊故要单独处理
}, },

View File

@@ -23,6 +23,12 @@ ListView.include({
this.ts_fields = []; this.ts_fields = [];
}, },
willStart: function() {
//代码自定义默认每页记录数
// the view's number of records per page (|| section)
this._limit = 200;
return this._super();
},
on_button_click: function (event) { on_button_click: function (event) {
var self = this; var self = this;
var $target = $(event.target), var $target = $(event.target),

View File

@@ -15,11 +15,11 @@
</span> </span>
<span style="float: left; margin-left: 2px;"> <span style="float: left; margin-left: 2px;">
<input style="height: 30px;" class="app_start_date form-control" size="10" placeholder="Start date" type="text" title="Press Enter to search"/> <input style="height: 30px;" class="app_start_date form-control" size="15" placeholder="Start date" type="text" title="Press Enter to search"/>
</span> </span>
<span style="float: left; margin-left: 2px;"> <span style="float: left; margin-left: 2px;">
<input style="height: 30px;" class="app_end_date form-control" size="10" placeholder="End date" type="text" title="Press Enter to search" /> <input style="height: 30px;" class="app_end_date form-control" size="15" placeholder="End date" type="text" title="Press Enter to search" />
</span> </span>
</div> </div>
</div> </div>
@@ -95,8 +95,5 @@
</li> </li>
</ul> </ul>
</div> </div>
</t> </t>
</templates> </templates>

View File

@@ -11,12 +11,5 @@
<script type="text/javascript" src="/app_ui_enhance/static/src/js/web_draggable_dialog.js"></script> <script type="text/javascript" src="/app_ui_enhance/static/src/js/web_draggable_dialog.js"></script>
</xpath> </xpath>
</template> </template>
<template id="assets_common" name="app_ui_enhance asset" inherit_id="report.assets_common">
<xpath expr="." position="inside">
<link rel="stylesheet" type="text/css" href="/app_ui_enhance/static/src/css/app_report_enhance.css"/>
</xpath>
</template>
</data> </data>
</odoo> </odoo>