1 | <?php |
||
3 | class EcommerceCustomDeliveryPostalCode extends DataObject |
||
|
|||
4 | { |
||
5 | private static $db = array( |
||
6 | 'Title' => 'Varchar(255)', |
||
7 | 'PostalCodeLowestNumber' => 'Int', |
||
8 | 'PostalCodeHighestNumber' => 'Int', |
||
9 | 'PriceWithoutApplicableProducts' => 'Currency', |
||
10 | 'PriceWithApplicableProducts' => 'Currency' |
||
11 | ); |
||
12 | |||
13 | private static $singular_name = "Postal Code Special Delivery Zone"; |
||
14 | |||
15 | private static $belongs_many_many = array( |
||
16 | "EcommerceDBConfigs" => "EcommerceDBConfig" |
||
17 | ); |
||
18 | |||
19 | private static $summary_fields = array( |
||
20 | 'Title' => 'Title', |
||
21 | 'PostalCodeLowestNumber' => 'Postal Code From ', |
||
22 | 'PostalCodeHighestNumber' => 'Postal Code To', |
||
23 | 'PriceWithoutApplicableProducts' => 'w/out Special Products', |
||
24 | 'PriceWithApplicableProducts' => 'w/ Special Products' |
||
25 | ); |
||
26 | private static $field_labels = array( |
||
27 | 'PostalCodeLowestNumber' => 'Lowest postal code (e.g. 2011)', |
||
28 | 'PostalCodeHighestNumber' => 'Highest postal code (e.g. 2015)', |
||
29 | 'PriceWithoutApplicableProducts' => 'Delivery charge for orders without special products', |
||
30 | 'PriceWithApplicableProducts' => 'Delivery charge for orders with special products' |
||
31 | ); |
||
32 | |||
33 | public function getCMSFields() |
||
39 | } |
||
40 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.