Customer Relationship Management Systems

Zoho Deluge: Text (SMS) reminder using Twilio API (LocalSense)

What?
A very quick article to remind me how to send a text message using Twilio API in Zoho Deluge.

Why?
The use-case here is that we want local sense dialing where specific numbers are used both for outbound and inbound but local to the customer and we want to remind our customer that they have an appointment in 1 hour with us.

How?
The code is actually pretty straightforward but you will need to follow these steps to get the credentials:
Zoho Deluge: Calculate start and end of Daylight Savings Time

What?
An article to document how I calculated the start and end dates of when Daylight Savings Time is in effect.

Why?
Admittedly, most of Zoho apps have this built-in but here's some snippets of code in case you need them.

How?
I will use this to amend and refine but here's the snippets for the various DSTs around the world.
Zoho Deluge: Today, Tomorrow, Day After but Skip Sunday

What?
A very quick article with a snippet of code to get today's date, tomorrow's, and the day after's but it has to skip Sundays.

Why?
Wanting to create a schedule for availability over the next few days which needs to dynamically change. I am aware of the function .addBusinessDay() but that excludes Saturdays which my client still works on.

How?
We're going to get today's date, then use the .addDay(), check none of these are a Sunday, and move the next few days along:
Zoho Deluge: Generate List of TimeZones

What?
A quick article to take a list of options from a HTML select element and convert to a Zoho Deluge list that will eventually be used to populate a dropdown.

Why?
Because I find myself doing this quite a bit and wanted a quick way of extracting a SELECT list in someone else's form.

How?
So, let's copy the HTML select into a text editor, then escape the double-quotes, then prepend with a list declaration and append with a end of list suffix; loop through removing HTML tags and while we're at it, storing it in a list for Zoho Deluge:
Zoho Deluge: Date from a String (dd/MM/yyyy to yyyy-MM-dd)

What?
A quick article to remind me of the regex to change a date from the format dd/MM/yyyy to yyyy-MM-dd.

Why?
Irrespective of server, organization or user settings, the date handling can vary. If we are getting a date from a CSV or other external source as "dd/MM/yyyy", how do we guarantee that the system will understand the date correctly?

How?
It may be that when obtaining a date string and applying the method .toString("dd/MM/yyyy") is dependent on the settings. But making a date into a SQL format or from largest denominator to smallest in "yyyy-MM-dd" will usually handle the date better.
Zoho Deluge: Handle Commas between Quotes in a CSV (and New Lines)

What?
This is an article to demonstrate how to handle commas in a CSV file that were enclosed between two double-quotes. I've added to this the handling of new lines or carriage returns in between a pair of double-quotes.

Why?
Our use case is that we were trying to loop through rows of a CSV file which contained addresses which in turn contained commas. Saving this as a CSV and asking Deluge to parse the data in the appropriate columns was not working as expected.

How?
The quick answer is a regex that will replace any commas between two quotes with a custom string, to be exact:
v_FormattedData = r_Data.replaceAll("(\"[^\",]+)[,]([^\"]+\")","$1|mySpecialComma|$2",false);