Skip to content

Instantly share code, notes, and snippets.

@cmcdevitt
Created May 12, 2014 14:22
Show Gist options
  • Save cmcdevitt/d77de635802bddb4d462 to your computer and use it in GitHub Desktop.
Save cmcdevitt/d77de635802bddb4d462 to your computer and use it in GitHub Desktop.
ServiceNow start of week
var sevenDays = new GlideTime();sevenDays.setValue("168:00:00");var today = new GlideDateTime(gs.nowDateTime());var dtUtil = new DateTimeUtils();var firstDay = gs.getProperty("com.snc.time_card.start_day", 7);var start = dtUtil.getWeekStart(today, firstDay);start.subtract(sevenDays);start.getDisplayValue();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment