diff --git a/packages/ezflow_extension/ezextension/ezflow/datatypes/ezpage/ezpagetype.php b/packages/ezflow_extension/ezextension/ezflow/datatypes/ezpage/ezpagetype.php index 90ad3a51..dd20dbdb 100644 --- a/packages/ezflow_extension/ezextension/ezflow/datatypes/ezpage/ezpagetype.php +++ b/packages/ezflow_extension/ezextension/ezflow/datatypes/ezpage/ezpagetype.php @@ -850,6 +850,20 @@ function customObjectAttributeHTTPAction( $http, $action, $contentObjectAttribut eZContentBrowse::browse( $browseParameters, $module ); break; + case 'remove_source': + $page = $contentObjectAttribute->content(); + + $zone = $page->getZone( $params[1] ); + $block = $zone->getBlock( $params[2] ); + + $fetchParams = unserialize( $block->attribute( 'fetch_params' ) ); + + unset( $fetchParams['Source'] ); + + $block->setAttribute( 'fetch_params', serialize( $fetchParams ) ); + $contentObjectAttribute->setContent( $page ); + $contentObjectAttribute->store(); + break; case 'custom_attribute': $page = $contentObjectAttribute->content(); $zone = $page->getZone( $params[1] ); @@ -897,6 +911,19 @@ function customObjectAttributeHTTPAction( $http, $action, $contentObjectAttribut eZContentBrowse::browse( $browseParameters, $module ); break; + case 'custom_attribute_remove_source': + $page = $contentObjectAttribute->content(); + $zone = $page->getZone( $params[1] ); + $block = $zone->getBlock( $params[2] ); + + $customAttributes = $block->attribute( 'custom_attributes' ); + + unset( $customAttributes[$params[3]] ); + + $block->setAttribute( 'custom_attributes', $customAttributes ); + $contentObjectAttribute->setContent( $page ); + $contentObjectAttribute->store(); + break; case 'remove_item': $page = $contentObjectAttribute->content(); $zone = $page->getZone( $params[1] ); diff --git a/packages/ezflow_extension/ezextension/ezflow/design/standard/templates/block/edit/edit.tpl b/packages/ezflow_extension/ezextension/ezflow/design/standard/templates/block/edit/edit.tpl index 7c53d402..5924f246 100644 --- a/packages/ezflow_extension/ezextension/ezflow/design/standard/templates/block/edit/edit.tpl +++ b/packages/ezflow_extension/ezextension/ezflow/design/standard/templates/block/edit/edit.tpl @@ -59,6 +59,9 @@ {foreach ezini( $block.type, 'FetchParameters', 'block.ini' ) as $fetch_parameter => $value} {if eq( $fetch_parameter, 'Source' )} + {if is_set( $fetch_params['Source'] )} + + {/if}
{'Current source:'|i18n( 'design/standard/block/edit' )} {if is_set( $fetch_params['Source'] )} @@ -104,6 +107,9 @@ {if eq( $use_browse_mode[$custom_attrib], 'true' )} {if is_set($custom_attribute_names[$custom_attrib])}{/if} + {if is_set( $block.custom_attributes[$custom_attrib] )} + + {/if}
{'Current source:'|i18n( 'design/standard/block/edit' )} {if is_set( $block.custom_attributes[$custom_attrib] )}