Skip to content

Commit 69dfa67

Browse files
committed
[FIX] pos: do not mix create and validation date
The validation_date was using the creation_date value in the follwing scenario: 1. create a new order with a few lines (creation_date=t1) 2. reload the page, `init_from_JSON` uses validation_date=t1 3. validate the order at t2, ignored due to already stored value creation_date must be kept for tracablity reasons (e.g. pos_blackbox_be) Fixes https://www.odoo.com/groups/59/20542134
1 parent 7bdb6f9 commit 69dfa67

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

addons/point_of_sale/static/src/js/models.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1782,7 +1782,7 @@ exports.Order = Backbone.Model.extend({
17821782
},
17831783

17841784
initialize_validation_date: function () {
1785-
this.validation_date = this.validation_date || new Date();
1785+
this.validation_date = new Date();
17861786
},
17871787

17881788
set_tip: function(tip) {

0 commit comments

Comments
 (0)