mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-21 15:33:23 +01:00
* Api/Filemanager: create in non EPL missing /templates and app-sub-directores
Was caused by (unnecessary) transaction around defaul_records processing, causing during transaction inserted rows where not (yet) commited and therefore could not be read.
This commit is contained in:
parent
7f53f21098
commit
00fd12d651
@ -195,7 +195,7 @@ foreach($dirs as $path => $id)
|
||||
'fs_comment' => null,
|
||||
'fs_content' => null,
|
||||
);
|
||||
$GLOBALS['egw_setup']->db->insert('egw_sqlfs',$nrow,false,__LINE__,__FILE__,'phpgwapi');
|
||||
$GLOBALS['egw_setup']->db->insert('egw_sqlfs', $nrow, false, __LINE__, __FILE__, 'api');
|
||||
}
|
||||
// PostgreSQL seems to require to update the sequenz, after manually inserting id's
|
||||
$oProc->UpdateSequence('egw_sqlfs','fs_id');
|
||||
|
@ -11,7 +11,7 @@
|
||||
/* Basic information about this app */
|
||||
$setup_info['api']['name'] = 'api';
|
||||
$setup_info['api']['title'] = 'EGroupware API';
|
||||
$setup_info['api']['version'] = '17.1.006';
|
||||
$setup_info['api']['version'] = '17.9.002';
|
||||
$setup_info['api']['versions']['current_header'] = '1.29';
|
||||
// maintenance release in sync with changelog in doc/rpm-build/debian.changes
|
||||
$setup_info['api']['versions']['maintenance_release'] = '17.1.20190222';
|
||||
|
@ -516,6 +516,48 @@ function api_upgrade17_1_004()
|
||||
return $GLOBALS['setup_info']['api']['currentver'] = '17.1.005';
|
||||
}
|
||||
|
||||
/**
|
||||
* Create /templates and subdirectories, if they dont exist
|
||||
*
|
||||
* They are create as part of the installation for new installations and allways exist in EPL.
|
||||
* If they dont exist, you can not save the preferences of the concerned applications, unless
|
||||
* you either manually create the directory or remove the path from the default preferences.
|
||||
*
|
||||
* Rerun the 16.1.002 update, as (unnecessary) transaction prevented creation on install
|
||||
* with PHP MySQLi driver and probably all other drivers supporting transactions.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function api_upgrade17_1_005()
|
||||
{
|
||||
api_upgrade16_1_002();
|
||||
|
||||
return $GLOBALS['setup_info']['api']['currentver'] = '17.1.007';
|
||||
}
|
||||
|
||||
/**
|
||||
* 17.1.006 used previously set after what is now the 17.9.001 update
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function api_upgrade17_1_006()
|
||||
{
|
||||
api_upgrade16_1_002();
|
||||
|
||||
return $GLOBALS['setup_info']['api']['currentver'] = '17.9.002';
|
||||
}
|
||||
|
||||
/**
|
||||
* Update 17.1 --> 19, can be moved, if more 17.1 updates necessary
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function api_upgrade17_1_007()
|
||||
{
|
||||
api_upgrade16_1_002();
|
||||
|
||||
return $GLOBALS['setup_info']['api']['currentver'] = '17.9.001';
|
||||
}
|
||||
|
||||
/**
|
||||
* Store multiline history content as diff
|
||||
@ -525,7 +567,7 @@ function api_upgrade17_1_004()
|
||||
*
|
||||
* @return string new version
|
||||
*/
|
||||
function api_upgrade17_1_005()
|
||||
function api_upgrade17_9_001()
|
||||
{
|
||||
$renderer = new Horde_Text_Diff_Renderer_Unified();
|
||||
$start = microtime(true);
|
||||
@ -565,8 +607,8 @@ function api_upgrade17_1_005()
|
||||
while($n == $junk_size);
|
||||
$saved = number_format($saved/(1024.0*1024.0), 1);
|
||||
$time = number_format((microtime(true)-$start)/60, 1);
|
||||
echo "$total history-records converted in $time minutes to diff with a total of $saved MB saved\n";
|
||||
if ($total) echo "$total history-records converted in $time minutes to diff with a total of $saved MB saved\n";
|
||||
|
||||
return $GLOBALS['setup_info']['api']['currentver'] = '17.1.006';
|
||||
return $GLOBALS['setup_info']['api']['currentver'] = '17.9.002';
|
||||
}
|
||||
|
||||
|
@ -498,10 +498,8 @@ class setup_process
|
||||
{
|
||||
echo '<br>process->default_records(): Including default records for ' . $appname . "\n";
|
||||
}
|
||||
$GLOBALS['egw_setup']->oProc->m_odb->transaction_begin();
|
||||
$oProc = &$GLOBALS['egw_setup']->oProc; // to be compatible with old apps
|
||||
include ($appdir.'default_records.inc.php');
|
||||
$GLOBALS['egw_setup']->oProc->m_odb->transaction_commit();
|
||||
}
|
||||
/* $appdata['status'] = 'C'; */
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user