Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
2 Antwoorden
2513 Weergaven

Hello!

Is it somehow possible in the quotes customer-view (in the customer-portal) to disable the option "auto" in the signature module?

In my opinion, the process should start directly with the option "draft". I don't think that a signature with auto mode is legally binding.

I don't think it's user friendly if the customer has to click on "draft" first to place his real signature.

I really would love to use the signature module if it is possible to disable this auto-option.

Thanks for your support
Daniel


PS: I would have posted a screenshot but am not yet allowed to post images.


Avatar
Annuleer

Any update?

We think the same, this is not legal in spain.

Did you find a solution?

Auteur

@Sergio: Sorry, I didn't find any solution until now.

Beste antwoord

I've found a better solution which works generally and not just for the portal:


odoo.define('your_module.name_and_signature_extension', function (require) {
"use strict";

var NameAndSignature = require('web.name_and_signature').NameAndSignature;

NameAndSignature.include({
init: function (parent, options) {
// Ensure options is an object to avoid errors
options = options || {};
// Set default mode to 'draw' if not provided
options.mode = options.mode || 'draw';
// Call the original init function with the modified options
this._super(parent, options);
},
});

});

put this snippet in a seperate modul at static/src/js 

and load file in web.assets_frontend section in manifest

"assets": {
​"web.assets_frontend": [
​"/your_module/static/src/js/name_and_signature.js",
​],
}


with this code the default_mode is set to 'draw'


Avatar
Annuleer
Beste antwoord

I found a solution:

Edit this file

portal/static/src/js/portal_signature.js

change in line 161:

'mode': this.$el.data('mode'),

by

'mode': 'draw',

and add this later to the same file:

var style = jQuery('');
jQuery('html > head').append(style);
Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
2
aug. 25
1421
0
jul. 25
413
1
okt. 24
1636
1
aug. 23
3581
0
jun. 23
1914