Commit d3bb3650 authored by minahilnichols's avatar minahilnichols Committed by Ezekiel Kigbo

Add formattedDate method for cleanliness

parent 61e1cf69
...@@ -61,8 +61,8 @@ export default { ...@@ -61,8 +61,8 @@ export default {
groupPath: this.groupPath, groupPath: this.groupPath,
title: this.title, title: this.title,
description: this.description, description: this.description,
startDate: this.startDate ? formatDate(this.startDate, 'yyyy-mm-dd') : null, startDate: this.formattedDate(this.startDate),
dueDate: this.dueDate ? formatDate(this.dueDate, 'yyyy-mm-dd') : null, dueDate: this.formattedDate(this.dueDate),
}, },
}; };
}, },
...@@ -80,6 +80,9 @@ export default { ...@@ -80,6 +80,9 @@ export default {
}, },
}, },
methods: { methods: {
formattedDate(date) {
return date ? formatDate(date, 'yyyy-mm-dd') : null;
},
save() { save() {
this.showValidation = true; this.showValidation = true;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment