Search code examples
wso2jaggery-jswso2-identity-server

how to get current date and time in jaggery js?


I am working in wso2 data analytical server. I'm using query to get data based on timestamp but I have given time stamp manually. Please tell me how to get current date and time together in milliseconds in jaggery js ?


Solution

  • var currentDate = new Date();
    Math.round(Date.parse(currentDate) / 1000);
    var end = Date.parse(currentDate) // Converting in Timestamp