Var newenv_8 = env_8.substr(0,8) //Convert the ENV.8 to remove the timeĭ1.setDate(d.getDate()-1) //Find the date 1 days agoĭ2.setDate(d.getDate()-2) //Find the date 2 days agoĭ3.setDate(d.getDate()-3) //Find the date 3 days agoĭ4.setDate(d.getDate()-4) //Find the date 4 days agoĭ5.setDate(d.getDate()-5) //Find the date 5 days agoĭ6.setDate(d.getDate()-6) //Find the date 6 days agoĭ7.setDate(d.getDate()-7) //Find the date 7 days agoĭ1 = DateUtil.formatDate(‘YYYYMMdd’, d1) //Format the date 1 days agoĭ2 = DateUtil.formatDate(‘YYYYMMdd’, d2) //Format the date 2 days agoĭ3 = DateUtil.formatDate(‘YYYYMMdd’, d3) //Format the date 3 days agoĭ4 = DateUtil.formatDate(‘YYYYMMdd’, d4) //Format the date 4 days agoĭ5 = DateUtil.formatDate(‘YYYYMMdd’, d5) //Format the date 5 days agoĭ6 = DateUtil.formatDate(‘YYYYMMdd’, d6) //Format the date 6 days agoĭ7 = DateUtil. if A08 Block if the Appointment Date/Time in EVN_8 is more than 7 days prior to the current date/time This is messy I admit but it works just fine. JavaScript and dates are never really fun. Classes in this package are part of the supported User API for use in channels/scripts. I recently had to filter a message based on the ENV.8 date value. - package This package is included in the JavaScript scope on both the client and the server.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |