| Conditions | 1 |
| Paths | 1 |
| Total Lines | 20 |
| Code Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 1 | Features | 1 |
| 1 | <?php |
||
| 25 | public function updateCMSFields(FieldList $fields) |
||
| 26 | { |
||
| 27 | $postage_config = GridFieldConfig_RelationEditor::create(); |
||
| 28 | $postage_config |
||
| 29 | ->removeComponentsByType(GridFieldAddNewButton::class) |
||
| 30 | ->addComponent(new GridFieldAddNewMultiClass("buttons-before-left")); |
||
| 31 | |||
| 32 | $fields->addFieldsToTab( |
||
| 33 | "Root.Shop", |
||
| 34 | [ |
||
| 35 | ToggleCompositeField::create( |
||
| 36 | 'PostageSettings', |
||
| 37 | _t("SilverCommerce\Postage.PostageSettings", "Postage Settings"), |
||
| 38 | [ |
||
| 39 | LiteralField::create("DiscountPadding", "<br/>"), |
||
| 40 | GridField::create( |
||
| 41 | 'PostageTypes', |
||
| 42 | '', |
||
| 43 | $this->owner->PostageTypes() |
||
| 44 | )->setConfig($postage_config) |
||
| 45 | ] |
||
| 51 |