Schedule Nintex Workflow on every 15th of the month querying SP List - nintex-workflow

I have a SP Custom List with events matrix. I have a Start Date, End Date. I would like to gather all the events from the list that has a start date between 15th of the current month to 15th of the next month and send email notification with details of all those events.
I would like to schedule this workflow to run on every 15th of the month.
Please advise.
Thank you!

For this you would need to build a site workflow because this can be scheduled.
To get the workflow completed:
Step 1. From the workflow use the calculate date action to store the date variable to check for (I.E. between 15th and 15th). Step 2. Use the query list action to find all items (events) that meet that criteria. Step 3. Send email to owners/participant or whomever on those events.

Related

Alexa AMAZON.DATE slot default to past dates

I am using the AMAZON.DATE slot and I would like it to default to past dates.
For example, if a user says Monday I would like it to automatically select last Monday rather than next Monday.
In the documentation it confirms that it defaults to 'on or after the current date':
"Utterances that map to a specific date (such as "today", "now", or
"november twenty-fifth") convert to a complete date: 2015-11-25. Note
that this defaults to dates on or after the current date (see below
for more examples)."
For my application there is no way a future date would make sense so it wouldn't be too difficult to manually program this in but I just wondered if there was any other way of doing it?
No, you cannot change the behavior of built in slots, so if Alexa resolves user's answer as a date - before passing it to your further processing just subtract 7 from resolved value. It will give you the date in the past.

ExtJS 4.2 DatePicker get the first day and last day in the calendar

I have an ExtJS datepicker where I disable some dates so the user can't select them.
After the calendar is renderer I send to the server the current date and the server sends back an array of days to disable, so the visual result is the following:
The problem I have is that I don't know the first and last day showed in the datepicker.
In this image the first day is 08/31/2014 and the last day is 09/11/2014. How can I get those dates, so I can tell my server to check if within that range I have to disable any date.
In the calendar example the "yellow marked dates" have to been disabled.
Any clue? Appreciate in advance.
Check this fiddle: https://fiddle.sencha.com/#fiddle/8ms
this uses minDate, maxDate with disabledDates, disabledDays combination..to enable particular days and disable all other days.
You could arbitrarily set the minValue to this month's first day and maxValueto this month's last day and then assume this on the backend side.
http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.form.field.Date-cfg-minValue
Here's how to get current month's first and last day
Get first and last date of current month with javascript or jquery

scripting: create an allDayEvent spanning more than one day

When working with my calendar, I do the following to create an allDayEvent which spans more than one day (e.g.Vacation or scool halidays):
- I create an allDayEvent for the 1st day
- I click on the event
- now I may enter the last date and save the event.
How may I do this in a script? I may get the flag with "isAllDayEvent"; I may set a date with "setAllDayDate"; but how to set a start-date and an end-date to an AllDayEvent?
You have to use recurrence, see full documentation here
In your example it would use addDailyRule to repeat every day and until to define endDate.

How to handle recurring holidays in Salesforce

In salesforce I can create recurring holidays and based on that in my apex class I want to check whether the current day is holiday or not.
This works fine with normal non recurring holiday. But when I create recurring holiday there is no way to find whether current date will fall on any of the recurring dates.
the holiday object's ActivityDate returns the start date of holiday.
Does anyone have checked the recurring holidays in past for salesforce?
Here is how i would approach this.
Create a function that will take parameters like RECURRENCESTARTDATE , RECURRENCEENDDATEONLY, RECURRENCETYPE, RECURRENCEINTERVAL, RECURRENCEDAYOFWEEKMASK, RECURRENCEDAYOFMONTH, RECURRENCEINSTANCE, RECURRENCEMONTHOFYEAR.
Then this function will loop from start date and for ever iteration it will increment value till date is > today or date is > RECURRENCEENDDATEONLY
in this loop you can check if today's == date calculated above.
once this function is ready pull out list of all recurring holidays.
and call above function on each list item.
let me know if you have any questions.

Data Warehouse: Modelling a future schedule

I'm creating a DW that will contain data on financial securities such as bonds and loans. These securities are associated with payment schedules. For example, a bond could pay quarterly, while a mortgage would usually pay monthly (sometimes biweekly). The payment schedule is created when the security is traded and, in the majority of cases, will remain unchanged. However, the design would need to accommodate those cases where it does change.
I'm currently attempting to model this data and I'm having difficulty coming up with a workable design. One of the most commonly queried fields is "next payment date". Users often want to know when a security will pay next. Therefore, I want to make it as easy as possible for them to get the next payment date and amount for each security.
Also, users often run historical queries in which case they'd want the next payment date and amount as of a specific point in time. For example, they may want to look back at 1/31/09 and query the next payment dates (which would usually be in February 2009 for mortgages). It's also common that they want to query a security's entire payment schedule, which might consist of 360 records (30 year mortgage x 12 payments/year).
Since the next payment date and amount would be changing each month or even biweekly, these fields wouldn't seem to fit into a slow-changing dimension very well. It would probably make more sense to use a fact table, but I'm unsure of how to model it. Any ideas would be greatly appreciated.
Next payment date is an example of a "fact-free fact table". There's no measure, just FK's between at least two dimensions: the security and time.
You can denormalize the security to have a type-1 SCD (overwritten with each load) that has a few important "next payment dates".
I think it's probably better, however, to carry a few important payment dates along with the facts. If you have a "current balance" fact table for loans, then you have an applicable date for this balance, and you can carry previous and next payment dates along with the balance, also.
For the whole payment schedule, you have a special fact-free fact table that just has applicable date and the sequence of payment dates on into the future. That way, when the schedule changes, you can pick the payment sequence as of some particular date.
I would use a table (securityid,startdate, paymentevery, period) it could also include enddate, paymentpershare
period would be 1 for days, 2 for weeks, 3 for months, 4 for years.
So for security 1 that started paying weekly on 3/1/2009, then the date changed to every 20 days on 4/2, then weekly after 5/1/2009, then to monthly on 7/1/2009, it would contain:
1,'3/1/2009',1,2
1,'4/2/2009',20,1
1,'5/1/2009',1,2
1,'7/1/2009',1,3
To get the actual dates, I'd use an algorithm like this:
To know the payment dates on security 1 from 3/5/2009 to 5/17/2008:
Find first entry before 3/5 = 3/1
Loop:
Get next date that's after 3/5 and before the next entry (4/2 - weekly) = 3/8
Get next date that's before next the entry (4/2) = 3/15
Get next date that's before next the entry (4/2) = 3/22
Get next date that's before next the entry (4/2) = 3/29
Next date >4/2 switch to next entry:
Loop:
Get next date that's after 4/2 and before the next entry (5/1 - every 20 days) = 4/22
Next date 5/12 is AFTER next entry 5/1, switch to next entry
Loop:
Get next date that's after 5/1 and before the lastdate (5/17 - weekly) = 5/8
Get next date that's before the lastdate = 5/15
Next date > 5/17
The dates between 3/5/2009 and 5/17/2008 would be 3/8,3/15,3/22,3/29,4/22,5/8,5/15
Why not store the next payment date as the amount of days from the date of the current payment?
Further clarification:
There would be a fact for every past payment linked to some date dimension. Each one of these facts will have a field next payment in which will be an integer. The idea is that the date of the current payment + next payment in will be the date of the next payment fact. This should be able to cater for everything.

Resources