[IMP] project: make project description full height by default on edit
X-original-commit: 1d6edf18883eb8c47e365a1ffc2b355bd20c02f5
This commit is contained in:
@@ -57,7 +57,10 @@
|
||||
}
|
||||
.o_form_project_tasks .o_wysiwyg_resizer {
|
||||
border: 0;
|
||||
margin: 0 0px -51px 0px;
|
||||
margin: 0 0px -40px 0px;
|
||||
}
|
||||
.o_form_project_tasks .o_form_sheet, .o_form_project_tasks .oe_form_field_html, .o_form_project_tasks .o_wysiwyg_wrapper {
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
|
||||
.o_kanban_project_tasks .badge {
|
||||
|
||||
@@ -5,11 +5,25 @@ odoo.define('project.ProjectFormView', function (require) {
|
||||
const FormView = require('web.FormView');
|
||||
const FormController = require('web.FormController');
|
||||
const core = require('web.core');
|
||||
const { device } = require('web.config');
|
||||
const view_registry = require('web.view_registry');
|
||||
|
||||
const _t = core._t;
|
||||
|
||||
const ProjectFormController = FormController.extend({
|
||||
init() {
|
||||
this._super(...arguments);
|
||||
if (!device.isMobile) {
|
||||
core.bus.on("DOM_updated", this, () => {
|
||||
const $editable = this.$el.find('.note-editable');
|
||||
if ($editable.length) {
|
||||
const resizerHeight = this.$el.find('.o_wysiwyg_resizer').outerHeight();
|
||||
const newHeight = window.innerHeight - $editable.offset().top - resizerHeight - 1;
|
||||
$editable.outerHeight(newHeight);
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
_getActionMenuItems(state) {
|
||||
if (!this.archiveEnabled || !state.data['recurrence_id']) {
|
||||
return this._super(...arguments);
|
||||
@@ -32,7 +46,7 @@ odoo.define('project.ProjectFormView', function (require) {
|
||||
|
||||
_onDeleteRecord() {
|
||||
const record = this.model.get(this.handle);
|
||||
|
||||
|
||||
if(!record.data.recurrence_id) {
|
||||
return this._super(...arguments);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user