Author: nathangray
Date: Tue Apr 26 19:07:42 2016
New Revision: 55861
URL: http://svn.stylite.de/viewvc/egroupware?rev=55861&view=rev
Log:
Fix merge print placeholders for only links to a certain app
Modified:
trunk/egroupware/api/src/Storage/Merge.php
Modified: trunk/egroupware/api/src/Storage/Merge.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/src/Storage/Merge.php?rev=55861&r1=55860&r2=55861&view=diff
==============================================================================
--- trunk/egroupware/api/src/Storage/Merge.php (original)
+++ trunk/egroupware/api/src/Storage/Merge.php Tue Apr 26 19:07:42 2016
@@ -376,7 +376,7 @@
protected function get_all_links($app, $id, $prefix, &$content)
{
$array = array();
- $pattern = '@\$(link|links|attachments|links_attachments)\/?(title|href|link)?\/?([a-z]*)\$@';
+ $pattern = '@\$(links_attachments|links|attachments|link)\/?(title|href|link)?\/?([a-z]*)\$@';
static $link_cache=null;
$matches = null;
if(preg_match_all($pattern, $content, $matches))
@@ -418,7 +418,8 @@
$array[($prefix?$prefix.'/':'').$placeholder] = Api\Html::a_href(Api\Html::htmlspecialchars($title), $link);
break;
case 'links':
- $array[($prefix?$prefix.'/':'').$placeholder] = $this->get_links($app, $id, '!'.Api\Link::VFS_APPNAME, array(),$matches[2][$i]);
+ $link_app = $matches[3][$i] ? $matches[3][$i] : '!'.Api\Link::VFS_APPNAME;
+ $array[($prefix?$prefix.'/':'').$placeholder] = $this->get_links($app, $id, $link_app, array(),$matches[2][$i]);
break;
case 'attachments':
$array[($prefix?$prefix.'/':'').$placeholder] = $this->get_links($app, $id, Api\Link::VFS_APPNAME,array(),$matches[2][$i]);
------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.