@@ -13,6 +13,7 @@ import { insertAuditTrail } from "../../redux/application/application.actions.js
|
||||
import AuditTrailMapping from "../../utils/AuditTrailMappings.js";
|
||||
import { createStructuredSelector } from "reselect";
|
||||
import { selectBodyshop, selectCurrentUser } from "../../redux/user/user.selectors.js";
|
||||
const dayjs = require('../../utils/day');
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
bodyshop: selectBodyshop,
|
||||
@@ -69,7 +70,8 @@ export function TaskListContainer({
|
||||
* @returns {Promise<void>}
|
||||
*/
|
||||
const toggleCompletedStatus = async (id, currentStatus) => {
|
||||
const completed_at = !currentStatus ? new Date().toISOString() : null;
|
||||
const completed_at = !currentStatus ? dayjs().toISOString() : null;
|
||||
|
||||
try {
|
||||
const toggledTask = await toggleTaskCompleted({
|
||||
variables: {
|
||||
@@ -115,7 +117,7 @@ export function TaskListContainer({
|
||||
*/
|
||||
|
||||
const toggleDeletedStatus = async (id, currentStatus) => {
|
||||
const deleted_at = !currentStatus ? new Date().toISOString() : null;
|
||||
const deleted_at = !currentStatus ? dayjs().toISOString() : null;
|
||||
try {
|
||||
const toggledTask = await toggleTaskDeleted({
|
||||
variables: {
|
||||
|
||||
Reference in New Issue
Block a user