Rule nickname | Rule configuration | Rule description | Rule explanation |
EXCHANGE | SETPRECEDENCE(ALPINE SKI,DEMO;SNOWBOARD,N/A;ALPINE SKI,SPORT;ALPINE SKI,RECREATIONAL;ALPINE BOOT,DEMO;BOARD BOOT, N/A;ALPINE BOOT,SPORT;ALPINE BOOT,RECREATIONAL) | Exchanges | In an exchange situation, demo skis trump all other rentals. Snowboards trump all other rentals except for demo skis. Sport skis trump all other rentals except for demo skis and snowboards. And so on. |
Rule nickname | Rule configuration | Rule description | Rule explanation |
1100DATES | 9/15/2012,10/17/2012,12/28/2012 | 11:00 HALF DAY DATES | List of dates separated by commas that have half-days calculated based on a check-out time that is between 11:00 AM and 2:30 PM. |
1115DATES | 12/24/2012,12/28/2012 | 11:15 HALF DAY DATES | List of dates separated by commas that have half-days calculated based on a check-out time that is between 11:15 AM and 2:30 PM. |
1130DATES | 10/5/2012,3/16/2013 | 11:30 HALF DAY DATES | List of dates separated by commas that have half-days calculated based on a check-out time that is between 11:30 AM and 2:30 PM. |
1145DATES | 10/19/2012,01/06/2013 | 11:45 HALF DAY DATES | List of dates separated by commas that have half-days calculated based on a check-out time that is between 11:45 PM and 2:30 PM. |
1200DATES | 11/12/2012 | 12:00 HALF DAY DATES | List of dates separated by commas that have half-days calculated based on a check-out time that is between 12:00 PM and 2:30 AM. |
1215DATES | 11/26/2012,12/02/2012 | 12:15 HALF DAY DATES | List of dates separated by commas that have half-days calculated based on a check-out time that is between 12:15 PM and 2:30 PM. |
Rule nickname | Rule configuration | Rule description | Rule explanation |
DAYS | IF(DATE(SUB(1100DATES)),CONVERTDAY(0-659,>=660,>=30,FULL)) IF(DATE(SUB(1100DATES)),CONVERTDAY(660-870,>=0,>=30,HALF)) IF(DATE(SUB(1115DATES)),CONVERTDAY(0-674,>=660,>=30,FULL)) IF(DATE(SUB(1115DATES)),CONVERTDAY(675-870,>=0,>=30,HALF)) IF(DATE(SUB(1130DATES)),CONVERTDAY(0-689,>=660,>=30,FULL)) IF(DATE(SUB(1130DATES)),CONVERTDAY(690-870,>=0,>=30,HALF)) IF(DATE(SUB(1145DATES)),CONVERTDAY(0-704,>=660,>=30,FULL)) IF(DATE(SUB(1145DATES)),CONVERTDAY(705-870,>=0,>=30,HALF)) IF(DATE(SUB(1200DATES)),CONVERTDAY(0-719,>=660,>=30,FULL)) IF(DATE(SUB(1200DATES)),CONVERTDAY(720-870,>=0,>=30,HALF)) IF(DATE(SUB(1215DATES)),CONVERTDAY(0-734,>=660,>=30,FULL)) IF(DATE(SUB(1215DATES)),CONVERTDAY(735-870,>=0,>=30,HALF)) CONVERTDAY(0-749,>=660,>=30,FULL) CONVERTDAY(750-870,>=0,>=30,HALF) | Days | Work through all of the half day exception date rules to determine whether a date within the rental period was a half or full day based on “exceptions” to the normal half/full day definition. For any of the rental dates not included in one of the half day exception date rules, calculate half and full days based on the standard 12:30 PM cut off time for full vs. half days. The first parameter is check-out time since midnight in minutes, the second parameter is check-in time since midnight in minutes, the third parameter is rental duration and the fourth parameter is the type of day/rental interval based on the three previous parameters. Note: If a day within the rental duration associated with the contract qualifies for a CONVERTDAY rule, all other CONVERTDAY rules are bypassed. |
Rule nickname | Rule configuration | Rule description | Rule explanation |
PREPROCESS | PREPROCESS(SUB(EXHANGE)SUB(DAYS)) | PREPROCESS | Go through the entire rental period and identify exchanges and day types. |
Rule nickname | Rule configuration | Rule description | Rule explanation |
DEMOS | IF(R_TYPELEVEL(ALPINE SKI,DEMO) AND R_PKG(ALPINE SKI BOOT,DEMO),ADDMODIFIER(RENTALS,AUTOSALE,PKG-DEMO)) IF(R_TYPELEVEL(ALPINE SKI,DEMO) AND R_PKG(ALPINE SKI BOOT,SPORT),ADDMODIFIER(RENTALS,AUTOSALE,PKG-DSSB)) IF(R_TYPELEVEL(ALPINE SKI,DEMO) AND R_PKG(ALPINE SKI BOOT,RECREATIONAL),ADDMODIFIER(RENTALS,AUTOSALE,PKG-DSRB)) IF(R_TYPELEVEL(ALPINE SKI,DEMO) AND NOT R_PKG(ALPINE SKI BOOT,DEMO) AND NOT R_PKG(ALPINE SKI BOOT,SPORT) AND NOT R_PKG(ALPINE SKI BOOT, RECREATIONAL),ADDMODIFIER(RENTALS, AUTOSALE,SKI-DEMO)) IF(R_TYPELEVEL(ALPINE SKI BOOT,DEMO) AND NOT R_PKG(ALPINE SKI, DEMO) AND NOT R_PKG(ALPINE SKI,SPORT) AND NOT R_PKG(ALPINE SKI, RECREATIONAL),ADDMODIFIER(RENTALS,AUTOSALE,BOOT-DEMO)) | Demos | If renting a demo ski along with a demo boot, sell a demo package item. If renting a demo ski along with a sport boot, sell a demo ski/sport boot package item. If renting a demo ski along with a recreational boot, sell a demo ski/recreational boot package item. If renting a demo ski alone (without being packaged with any level of alpine ski boot), sell a demo ski item. If renting a demo boot alone (without being packaged with any level of alpine ski), sell a demo boot item. |
SPORT | IF(R_TYPELEVEL(ALPINE SKI,SPORT) AND R_PKG(ALPINE SKI BOOT,SPORT),ADDMODIFIER(RENTALS,AUTOSALE,PKG-SPORT)) IF(R_TYPELEVEL(ALPINE SKI,SPORT) AND R_PKG(ALPINE SKI BOOT,DEMO),ADDMODIFIER(RENTALS,AUTOSALE,PKG-SSDB)) IF(R_TYPELEVEL(ALPINE SKI,SPORT) AND R_PKG(ALPINE SKI BOOT,RECREATIONAL),ADDMODIFIER(RENTALS,AUTOSALE,PKG-SSRB)) IF(R_TYPELEVEL(ALPINE SKI,SPORT) AND NOT R_PKG(ALPINE SKI BOOT,SPORT) AND NOT R_PKG(ALPINE SKI BOOT,DEMO) AND NOT R_PKG(ALPINE SKI BOOT, RECREATIONAL),ADDMODIFIER(RENTALS, AUTOSALE,SKI-SPORT)) IF(R_TYPELEVEL(ALPINE SKI BOOT,SPORT) AND NOT R_PKG(ALPINE SKI, DEMO) AND NOT R_PKG(ALPINE SKI,SPORT) AND NOT R_PKG(ALPINE SKI, RECREATIONAL),ADDMODIFIER(RENTALS,AUTOSALE,BOOT-SPORT)) | Sport | If renting a sport ski along with a sport boot, sell a sport package item. If renting a sport ski along with a demo boot, sell a sport ski/demo boot package item. If renting a sport ski along with a recreational boot, sell a sport ski/recreational boot package item. If renting a sport ski alone (without being packaged with any level of alpine ski boot) sell a sport ski item. If renting a sport boot alone (without being packaged with any level of an alpine ski) sell a sport boot item. |
REC | IF(R_TYPELEVEL(ALPINE SKI,RECREATIONAL) AND R_PKG(ALPINE SKI BOOT,RECREATIONAL),ADDMODIFIER(RENTALS,AUTOSALE,PKG-REC)) IF(R_TYPELEVEL(ALPINE SKI,RECREATIONAL) AND R_PKG(ALPINE SKI BOOT,DEMO),ADDMODIFIER(RENTALS,AUTOSALE,PKG-RSDB)) IF(R_TYPELEVEL(ALPINE SKI,RECREATIONAL) AND R_PKG(ALPINE SKI BOOT,SPORT),ADDMODIFIER(RENTALS,AUTOSALE,PKG-RSSB)) IF(R_TYPELEVEL(ALPINE SKI,RECREATIONAL) AND NOT R_PKG(ALPINE SKI BOOT,SPORT) AND NOT R_PKG(ALPINE SKI BOOT,DEMO) AND NOT R_PKG(ALPINE SKI BOOT, RECREATIONAL),ADDMODIFIER(RENTALS, AUTOSALE,SKI-REC)) IF(R_TYPELEVEL(ALPINE SKI BOOT,RECREATIONAL) AND NOT R_PKG(ALPINE SKI, DEMO) AND NOT R_PKG(ALPINE SKI,SPORT) AND NOT R_PKG(ALPINE SKI, RECREATIONAL),ADDMODIFIER(RENTALS,AUTOSALE,BOOT-REC)) | Recreational | If renting a recreational ski along with a recreational boot, sell a recreational package item. If renting a recreational ski along with a demo boot, sell a recreational ski/demo boot package item. If renting a recreational ski along with a sport boot, sell a recreational ski/sport boot package item. If renting a recreational ski alone (without being packaged with any level of alpine ski boot), sell a recreational ski item. If renting a recreational boot alone (without being packaged with any level of alpine ski), sell a recreational boot item. |
BOARD | IF(R_TYPE(BOARD) AND R_PKG(BOARD BOOT,N/A),ADDMODIFIER(RENTALS,AUTOSALE,PKG-BOARD)) IF(R_TYPE(BOARD) AND NOT R_PKG(BOARD BOOT,N/A),ADDMODIFIER(RENTALS,AUTOSALE,BOARD)) IF(R_TYPE(BOARD BOOT) AND NOT R_PKG(BOARD,N/A),ADDMODIFIER(RENTALS,AUTOSALE,BOARD BOOT)) | Board | If renting a snowboard (any level) with a snowboard boot, sell a snowboard package item. If renting a snowboard (any level) without a snowboard boot, sell a snowboard item. If renting a snowboard boot without a snowboard, sell a snowboard boot item. |
XC | IF(R_TYPE(CROSS COUNTRY SKI) AND R_PKG(CROSS COUNTRY BOOT,N/A),ADDMODIFIER(RENTALS,AUTOSALE,PKG-XC)) IF(R_TYPE(CROSS COUNTRY SKI) AND NOT R_PKG(CROSS COUNTRY BOOT,N/A),ADDMODIFIER(RENTALS,AUTOSALE,XCSKI)) IF(R_TYPE(CROSS COUNTRY BOOT) AND NOT R_PKG(CROSS COUNTRY SKI,N/A),ADDMODIFIER(RENTALS,AUTOSALE,XCBOOT)) | Cross country | If renting a cross country ski (any level) with a cross country boot, sell a cross country package item. If renting a cross country ski (any level) without a cross country boot, sell a cross country ski item. If renting a cross country boot without a cross country ski, sell a cross country boot item. |
TELEMARK | IF(R_TYPE(TELEMARK SKIS) AND R_PKG(TELEMARK BOOTS,N/A),ADDMODIFIER(RENTALS,AUTOSALE,PKG-TELE)) IF(R_TYPE(TELEMARK SKIS) AND NOT R_PKG(TELEMARK BOOTS,N/A),ADDMODIFIER(RENTALS,AUTOSALE,TELESKI)) IF(R_TYPE(TELEMARK BOOTS) AND NOT R_PKG(TELEMARK SKIS,N/A),ADDMODIFIER(RENTALS,AUTOSALE,TELEBOOT)) | Telemark | If renting a telemark ski (any level) with a telemark boot, sell a telemark package item. If renting a telemark ski (any level) without a telemark boot, sell a telemark ski item. If renting a telemark boot without a telemark ski, sell a telemark boot item. |
SNOWSHOES | IF(R_TYPE(SNOWSHOES),ADDMODIFIER(RENTALS,AUTOSALE,SNOWSHOES)) | Snowshoes | If renting a snowshoe (any level) sell a snowshoe item |
BIKE | IF(R_TYPE(BIKE),ADDMODIFIER(RENTALS,AUTOSALE,BIKE)) | Bike | If renting a bike (any level), sell a bike item. |
HELMET | IF(R_TYPE(HELMET),ADDMODIFIER(RENTALS,AUTOSALE,HELMET)) | Helmet | If renting a helmet (any level), sell a helmet item. |
Rule nickname | Rule configuration | Rule description | Rule explanation |
GROUPDAYS | POSTPROCESS(GROUPDAYS()) | Group days | Subtotal each unique combination of day types and auto-sold items together as opposed to displaying one line per day. |
Rule nickname | Rule configuration | Rule description | Rule explanation |
CONTRACT | SUB(PREPROCESS) SUB(DEMOS) SUB(SPORT) SUB(REC) SUB(BOARD) SUB(TELEMARK) SUB(XC) SUB(BIKE) SUB(HELMET) SUB(SNOWSHOES) SUB(GROUPDAYS) | Contract Auto-Sale Rule | Preprocess the rental activity associated with the contract to determine what type and level of equipment is counted in exchanges and also determine the various rental day types and number of these day types, within the rental period. Next, auto-sell the appropriate items based on the activity associated with the rental contract after the preprocessing has occurred. Finally, group the same day-type/auto-sold item combinations together on one line item per unique combination and increment the # of rental days on each unique line item as opposed to listing each day’s type and auto-sold item on separate lines. This is necessary to enable Dynamic Pricing capability based on multi-day rentals. |