SmiData StartsWithFullWeek EndsWithFullWeek

When the week starts at sunday, a period starts with a full week if it starts on sunday and the period is more than 7 days and a period ends with a full week if it starts ends on saturday and the period is more than 7 days.

Smartsite SXML CopyCode image Copy Code
First day of the week: {locale.weekdayname(smidata.getfirstdayofweek(smi20))}

=== Saturday October 9th 2010
{smidata.startswithfullweek(datetime.getdate(2010, 10, 9), datetime.getdate(2010, 10, 31))}

=== Sunday October 10th 2010
{smidata.startswithfullweek(datetime.getdate(2010, 10, 10), datetime.getdate(2010, 10, 31))}

=== Monday October 11th 2010
{smidata.startswithfullweek(datetime.getdate(2010, 10, 11), datetime.getdate(2010, 10, 31))}


=== Friday October 8th 2010
{smidata.endswithfullweek(datetime.getdate(2010, 10, 1), datetime.getdate(2010, 10, 8))}

=== Saturday October 9th 2010
{smidata.endswithfullweek(datetime.getdate(2010, 10, 1), datetime.getdate(2010, 10, 9))}

=== Sunday October 10th 2010
{smidata.endswithfullweek(datetime.getdate(2010, 10, 1), datetime.getdate(2010, 10, 10))}
Example Result CopyCode image Copy Code
First day of the week: Sunday

=== Saturday October 9th 2010
false

=== Sunday October 10th 2010
true

=== Monday October 11th 2010
false


=== Friday October 8th 2010
false

=== Saturday October 9th 2010
true

=== Sunday October 10th 2010
false