We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

In Edit Task pop-up, duration field should not allow decimal values

In Edit Task pop-up, duration field should not allow decimal values


1 Reply

GM Gopinath Munusamy Syncfusion Team December 15, 2022 07:48 AM UTC

Hi Donika,


You can be able to restrict the decimal values in duration field by using the editType property as numericedit and columns.edit.params as zero decimal value. For your reference, a sample and code snippets are attached. Check the sample and documentation link below for more details.


Code Snippets:

[app.component.ts]

this.columns = [

      //...

      { field: 'Duration', headerText: 'Duration',

            editType:'numericedit', edit: {params: { decimals: 0 } }},

    ];


Sample: https://stackblitz.com/edit/angular-skxrs7-ep8g7t?file=app.component.ts,app.component.html,data.ts

UG Documentation: https://ej2.syncfusion.com/angular/documentation/gantt/managing-tasks/task-bar-editing/#cell-edit-type-and-its-params


Regards,

Gopinath M


Loader.
Up arrow icon