Vishnu VaNnErI
Vishnu VaNnErI

Reputation: 931

Remove Time From Date Time field on POS Receipt in Odoo 12

Need to remove time from pos ticket

Need to remove time from pos ticket

Thanks

Upvotes: 1

Views: 987

Answers (2)

Vishnu VaNnErI
Vishnu VaNnErI

Reputation: 931

For Referring

var models = require('point_of_sale.models');
var field_utils = require('web.field_utils');



var _super_order = models.Order.prototype;
models.Order = models.Order.extend({

    initialize_validation_date: function () {
        _super_order.initialize_validation_date.apply(this,arguments);
        this.validation_date = new Date();
        this.formatted_validation_date = field_utils.format.date(
            moment(this.validation_date), {}, {timezone: false});

           },


        });

Upvotes: 0

Dipen Shah
Dipen Shah

Reputation: 2444

One of the Way. Check the linkClick Here from there you can inherit js on your app and change the format DateTime to date.

Like this - field_utils.format.date(moment(this.validation_date), {}, {timezone: false});

Thanks

Upvotes: 2

Related Questions