| @@ -33,9 +33,9 @@ | ||
| 33 | 33 | * License instance |
| 34 | 34 | */ |
| 35 | 35 | private Freemius $licence; |
| 36 | 36 | |
| 37 | - const VERSION = '7.1.4'; | |
| 37 | + const VERSION = '8.1.0'; | |
| 38 | 38 | |
| 39 | 39 | /** |
| 40 | 40 | * TierPricingTablePlugin constructor. |
| 41 | 41 | */ |
| @@ -238,8 +238,19 @@ | ||
| 238 | 238 | * @return string |
| 239 | 239 | */ |
| 240 | 240 | public static function getRulesSeparator(): string { |
| 241 | 241 | return apply_filters( 'tiered_pricing_table/rules_separator', ',' ); |
| 242 | + } | |
| 243 | + | |
| 244 | + /** | |
| 245 | + * Separator between the quantity and the price inside one rule ("20:100") in CSV export. | |
| 246 | + * Spreadsheets read "20:100" as a time; a store that edits exports in Excel can switch to "=", | |
| 247 | + * which the importer accepts next to ":" out of the box. | |
| 248 | + */ | |
| 249 | + public static function getRuleSeparator(): string { | |
| 250 | + $separator = (string) apply_filters( 'tiered_pricing_table/rule_separator', ':' ); | |
| 251 | + | |
| 252 | + return '' !== $separator ? $separator : ':'; | |
| 242 | 253 | } |
| 243 | 254 | |
| 244 | 255 | /** |
| 245 | 256 | * Get current user the prices calculate for. Sometimes current user can be different from the logged-in user. |