CatalogSortOrder.php
2 weeks ago
CatalogVisibility.php
2 months ago
CurrencyPosition.php
1 month ago
DefaultCustomerAddress.php
3 months ago
DimensionUnit.php
1 month ago
FeaturePluginCompatibility.php
2 months ago
OrderInternalStatus.php
2 months ago
OrderItemType.php
3 months ago
OrderStatus.php
2 months ago
PaymentGatewayFeature.php
9 months ago
ProductStatus.php
2 months ago
ProductStockStatus.php
2 months ago
ProductTaxStatus.php
1 year ago
ProductType.php
2 months ago
StockDisplayFormat.php
2 weeks ago
TaxBasedOn.php
3 months ago
TaxDisplayMode.php
1 month ago
WeightUnit.php
1 month ago
StockDisplayFormat.php
34 lines
| 1 | <?php |
| 2 | |
| 3 | declare( strict_types = 1 ); |
| 4 | |
| 5 | namespace Automattic\WooCommerce\Enums; |
| 6 | |
| 7 | /** |
| 8 | * Enum class for the possible values of the 'woocommerce_stock_format' option. |
| 9 | * |
| 10 | * @since 11.1.0 |
| 11 | */ |
| 12 | final class StockDisplayFormat { |
| 13 | /** |
| 14 | * Always show the quantity remaining in stock (e.g. "12 in stock"). |
| 15 | * |
| 16 | * @var string |
| 17 | */ |
| 18 | public const ALWAYS_SHOW = ''; |
| 19 | |
| 20 | /** |
| 21 | * Only show the quantity remaining in stock when it is low (e.g. "Only 2 left in stock"). |
| 22 | * |
| 23 | * @var string |
| 24 | */ |
| 25 | public const LOW_AMOUNT = 'low_amount'; |
| 26 | |
| 27 | /** |
| 28 | * Never show the quantity remaining in stock. |
| 29 | * |
| 30 | * @var string |
| 31 | */ |
| 32 | public const NEVER = 'no_amount'; |
| 33 | } |
| 34 |