summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js
diff options
context:
space:
mode:
authorXavier Morel <xmo@odoo.com>2017-10-09 16:50:29 +0200
committerXavier Morel <xmo@odoo.com>2017-10-09 16:50:47 +0200
commit03a2a571636657c90b2d344f2ed83cbe6459c081 (patch)
tree7155138b952c8fd98255cee25c59b554fbaebcd8 /addons/web/static/src/js
parente792bdbcafaaab2b1a9442ea6c5fd64e79e913fc (diff)
[FIX] unfuck JS docstrings
Diffstat (limited to 'addons/web/static/src/js')
-rw-r--r--addons/web/static/src/js/chrome/control_panel.js46
-rw-r--r--addons/web/static/src/js/core/dom.js6
-rw-r--r--addons/web/static/src/js/views/basic/basic_model.js2
3 files changed, 26 insertions, 28 deletions
diff --git a/addons/web/static/src/js/chrome/control_panel.js b/addons/web/static/src/js/chrome/control_panel.js
index 8be394205d5..98ce7814b7a 100644
--- a/addons/web/static/src/js/chrome/control_panel.js
+++ b/addons/web/static/src/js/chrome/control_panel.js
@@ -10,32 +10,32 @@ odoo.define('web.ControlPanelMixin', function (require) {
* we get the time to refactor the control panel.
*
* For example, here is what a typical client action would need to do to add
- * support for a control panel with some buttons:
+ * support for a control panel with some buttons::
*
- * var ControlPanelMixin = require('web.ControlPanelMixin');
+ * var ControlPanelMixin = require('web.ControlPanelMixin');
*
- * var SomeClientAction = Widget.extend(ControlPanelMixin, {
- * ...
- * start: function () {
- * this._renderButtons();
- * this._updateControlPanel();
+ * var SomeClientAction = Widget.extend(ControlPanelMixin, {
* ...
- * },
- * do_show: function () {
- * ...
- * this._updateControlPanel();
- * },
- * _renderButtons: function () {
- * this.$buttons = $(QWeb.render('SomeTemplate.Buttons'));
- * this.$buttons.on('click', ...);
- * },
- * _updateControlPanel: function () {
- * this.update_control_panel({
- * breadcrumbs: this.action_manager.get_breadcrumbs(),
- * cp_content: {
- * $buttons: this.$buttons,
- * },
- * });
+ * start: function () {
+ * this._renderButtons();
+ * this._updateControlPanel();
+ * ...
+ * },
+ * do_show: function () {
+ * ...
+ * this._updateControlPanel();
+ * },
+ * _renderButtons: function () {
+ * this.$buttons = $(QWeb.render('SomeTemplate.Buttons'));
+ * this.$buttons.on('click', ...);
+ * },
+ * _updateControlPanel: function () {
+ * this.update_control_panel({
+ * breadcrumbs: this.action_manager.get_breadcrumbs(),
+ * cp_content: {
+ * $buttons: this.$buttons,
+ * },
+ * });
*/
var ControlPanelMixin = {
need_control_panel: true,
diff --git a/addons/web/static/src/js/core/dom.js b/addons/web/static/src/js/core/dom.js
index b39f39cab9c..274f82bcc53 100644
--- a/addons/web/static/src/js/core/dom.js
+++ b/addons/web/static/src/js/core/dom.js
@@ -159,10 +159,8 @@ return {
/**
* Returns the selection range of an input or textarea
*
- * @param {Object} DOM item input or texteara
+ * @param {Object} node DOM item input or texteara
* @returns {Object} range
- * @returns {integer} range.start
- * @returns {integer} range.end
*/
getSelectionRange: function (node) {
return {
@@ -174,7 +172,7 @@ return {
* Returns the distance between a DOM element and the top-left corner of the
* window
*
- * @param {Object} node DOM element (input or texteara)
+ * @param {Object} e DOM element (input or texteara)
* @return {Object} the left and top distances in pixels
*/
getPosition: function (e) {
diff --git a/addons/web/static/src/js/views/basic/basic_model.js b/addons/web/static/src/js/views/basic/basic_model.js
index 294d7ce077b..5c6f5d2d851 100644
--- a/addons/web/static/src/js/views/basic/basic_model.js
+++ b/addons/web/static/src/js/views/basic/basic_model.js
@@ -198,7 +198,7 @@ var BasicModel = AbstractModel.extend({
* behind must be applied. This function applies changes stored in
* '_rawChanges' for a given viewType.
*
- * @param {string} id local resource id of a record
+ * @param {string} recordID local resource id of a record
* @param {string} viewType the current viewType
* @returns {Deferred<string>} resolves to the id of the record
*/