[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpcompta-dev] r5281 - in phpcompta/trunk: html html/admin html/admin/s
From: |
phpcompta-dev |
Subject: |
[Phpcompta-dev] r5281 - in phpcompta/trunk: html html/admin html/admin/sql/patch include sql |
Date: |
Sat, 18 May 2013 00:25:03 +0200 (CEST) |
Author: danydb
Date: 2013-05-18 00:25:03 +0200 (Sat, 18 May 2013)
New Revision: 5281
Added:
phpcompta/trunk/html/admin/sql/patch/upgrade106.sql
Modified:
phpcompta/trunk/html/admin/setup.php
phpcompta/trunk/html/user_login.php
phpcompta/trunk/include/config_file.php
phpcompta/trunk/include/constant.php
phpcompta/trunk/include/user_menu.php
phpcompta/trunk/sql/upgrade.sql
Log:
Last bugs
Modified: phpcompta/trunk/html/admin/setup.php
===================================================================
--- phpcompta/trunk/html/admin/setup.php 2013-05-17 21:13:39 UTC (rev
5280)
+++ phpcompta/trunk/html/admin/setup.php 2013-05-17 22:25:03 UTC (rev
5281)
@@ -51,22 +51,23 @@
$succeed="<span style=\"font-size:18px;color:green\">✓</span>";
$inc_path=get_include_path();
global $os;
-/**
- address@hidden create correctly the htaccess file
- */
-function create_htaccess()
-{
-
- $inc_path=get_include_path();
+$inc_path=get_include_path();
global $os;
if ( strpos($inc_path,";") != 0 ) {
- $new_path=$inc_path.';..\..\include;addon';
+ $new_path=$inc_path.';../../include;addon';
$os=0; /* $os is 0 for windoz */
} else {
$new_path=$inc_path.':../../include:addon';
$os=1; /* $os is 1 for unix */
}
+/**
+ address@hidden create correctly the htaccess file
+ */
+function create_htaccess()
+{
+ global $os;
+
/* If htaccess file doesn't exists we create them here
* if os == 1 then windows, 0 means Unix
*/
@@ -100,7 +101,7 @@
"php_flag session.use_only_cookies on");
if ( $os == 0 )
- fwrite($hFile,'php_value include_path
.;..\..\include;..\include;addon'."\n");
+ fwrite($hFile,'php_value include_path
.;../../include;../include;addon'."\n");
else
fwrite($hFile,'php_value include_path
.:../../include:../include:addon'."\n");
foreach ($array as $value ) fwrite($hFile,$value."\n");
@@ -340,7 +341,7 @@
if ( ! isset($_POST['go']) )
exit();
// Check if account_repository exists
- if ( defined("MULTI") && MULTI== 0)
+ if (!defined("MULTI") || (defined("MULTI") && MULTI == 1))
$account = $cn->count_sql("select * from pg_database where
datname=lower('" . domaine . "account_repository')");
else
$account=1;
@@ -392,7 +393,7 @@
echo "<h1>Mise a jour du systeme</h1>";
echo "<h2 > Mise à jour dossier</h2>";
-if (defined("MULTI") && MULTI == 0)
+if (defined("MULTI") && MULTI == 0)
{
$db = new Database();
if ($db->exist_table("version") == false)
Added: phpcompta/trunk/html/admin/sql/patch/upgrade106.sql
===================================================================
--- phpcompta/trunk/html/admin/sql/patch/upgrade106.sql
(rev 0)
+++ phpcompta/trunk/html/admin/sql/patch/upgrade106.sql 2013-05-17 22:25:03 UTC
(rev 5281)
@@ -0,0 +1,11 @@
+begin;
+update attr_def set ad_text='Compte bancaire' where ad_id=3;
+ALTER TABLE mod_payment DROP CONSTRAINT mod_payment_mp_fd_id_fkey ;
+ALTER TABLE mod_payment ADD CONSTRAINT mod_payment_mp_fd_id_fkey FOREIGN KEY
(mp_fd_id) REFERENCES fiche_def (fd_id) MATCH SIMPLE ON UPDATE
cascade ON DELETE cascade;
+ALTER TABLE mod_payment DROP CONSTRAINT mod_payment_mp_jrn_def_id_fkey ;
+ALTER TABLE mod_payment ADD CONSTRAINT mod_payment_mp_jrn_def_id_fkey FOREIGN
KEY (mp_jrn_def_id) REFERENCES jrn_def (jrn_def_id) MATCH SIMPLE ON UPDATE
CASCADE ON DELETE CASCADE;
+
+update version set val=107;
+
+commit;
+
Modified: phpcompta/trunk/html/user_login.php
===================================================================
--- phpcompta/trunk/html/user_login.php 2013-05-17 21:13:39 UTC (rev 5280)
+++ phpcompta/trunk/html/user_login.php 2013-05-17 22:25:03 UTC (rev 5281)
@@ -104,7 +104,7 @@
* folder if he's an "plugin user"
*/
-if ( $User->admin == 0 || (defined("MULTI")&&MULTI==0))
+if ( $User->admin == 0 )
{
// how many folder ?
$folder=$User->get_available_folder();
Modified: phpcompta/trunk/include/config_file.php
===================================================================
--- phpcompta/trunk/include/config_file.php 2013-05-17 21:13:39 UTC (rev
5280)
+++ phpcompta/trunk/include/config_file.php 2013-05-17 22:25:03 UTC (rev
5281)
@@ -105,7 +105,7 @@
}
/*!\brief create the config file
*/
-function config_file_create($p_array,$from_setup=1,$os=1)
+function config_file_create($p_array,$from_setup=1,$p_os=1)
{
extract ($p_array);
$add=($from_setup==1)?'..'.DIRECTORY_SEPARATOR:'';
@@ -118,7 +118,7 @@
fputs($hFile,"\r\n");
fputs($hFile, 'define("PG_PATH","'.$cpath.'");');
fputs($hFile,"\r\n");
- if ( $os == 1 )
+ if ( $p_os == 1 )
{
fputs($hFile,
'define("PG_RESTORE","'.$cpath.DIRECTORY_SEPARATOR.'pg_restore ");');
fputs($hFile,"\r\n");
Modified: phpcompta/trunk/include/constant.php
===================================================================
--- phpcompta/trunk/include/constant.php 2013-05-17 21:13:39 UTC (rev
5280)
+++ phpcompta/trunk/include/constant.php 2013-05-17 22:25:03 UTC (rev
5281)
@@ -41,17 +41,15 @@
$os=1; /* $os is 1 for unix */
}
set_include_path($new_path);
-if ( defined("MULTI") && MULTI==0 ) {
- ini_set ('session.use_cookies',1);
- ini_set ('session.use_only_cookies','on');
- ini_set ('session.use_trans_sid','on');
- ini_set ('magic_quotes_gpc','off');
- ini_set ('max_execution_time',240);
- ini_set ('memory_limit','20M');
- ini_set ('post_max_size','20M');
- ini_set ('upload_max_filesize','20M');
+ini_set ('session.use_cookies',1);
+ini_set ('session.use_only_cookies','on');
+ini_set ('magic_quotes_gpc','off');
+ini_set ('max_execution_time',240);
+ini_set ('memory_limit','20M');
+ini_set ('default_charset',"UTF-8");
address@hidden ('session.use_trans_sid','on');
@session_start();
-}
+
/*
* Ini session
*/
@@ -64,9 +62,9 @@
$g_succeed="<span style=\"font-size:18px;color:green\">✓</span>";
/*set to none for production */
/* uncomment for production */
-define ('SVNINFO',5900);
+//define ('SVNINFO',5900);
$version_phpcompta=SVNINFO;
-define ("DEBUG",true);
+define ("DEBUG",false);
/* define ('SVNINFO',5015);
* $version_phpcompta=SVNINFO;
* define ("DEBUG",true);
@@ -77,7 +75,7 @@
define
("SITE_UPDATE_PLUGIN",'http://www.phpcompta.eu/plugin_last_version.txt');
-define ("DBVERSION",106);
+define ("DBVERSION",107);
define ("DBVERSIONREPO",14);
define ('NOTFOUND','--not found--');
Modified: phpcompta/trunk/include/user_menu.php
===================================================================
--- phpcompta/trunk/include/user_menu.php 2013-05-17 21:13:39 UTC (rev
5280)
+++ phpcompta/trunk/include/user_menu.php 2013-05-17 22:25:03 UTC (rev
5281)
@@ -106,14 +106,24 @@
break;
}
}
- $item=array
(array("admin_repo.php?action=user_mgt",_("Utilisateurs"),_('Gestion des
utilisateurs'),0),
+ if (!defined("MULTI")||(defined("MULTI")&&MULTI==1))
+ {
+ $item=array
(array("admin_repo.php?action=user_mgt",_("Utilisateurs"),_('Gestion des
utilisateurs'),0),
array("admin_repo.php?action=dossier_mgt",_("Dossiers"),_('Gestion des
dossiers'),1),
array("admin_repo.php?action=modele_mgt",_("Modèles"),_('Gestion des
modèles'),2),
array("admin_repo.php?action=restore",_("Restaure"),_("Restaure une base de
données"),3),
array("admin_repo.php?action=audit_log",_("Audit"),_("Utilisateurs qui se sont
connectés"),4),
array("login.php",_("Accueil"))
);
+ }
+ else
+ {
+ $item=array
(array("admin_repo.php?action=user_mgt",_("Utilisateurs"),_('Gestion des
utilisateurs'),0),
+
array("admin_repo.php?action=audit_log",_("Audit"),_("Utilisateurs qui se sont
connectés"),4),
+ array("login.php",_("Accueil"))
+ );
+ }
$menu=ShowItem($item,'H',"mtitle","mtitle",$def,'
style="width:80%;margin-left:10%" ');
return $menu;
}
Modified: phpcompta/trunk/sql/upgrade.sql
===================================================================
--- phpcompta/trunk/sql/upgrade.sql 2013-05-17 21:13:39 UTC (rev 5280)
+++ phpcompta/trunk/sql/upgrade.sql 2013-05-17 22:25:03 UTC (rev 5281)
@@ -1,5 +0,0 @@
-update attr_def set ad_text='Compte bancaire' where ad_id=3;
-ALTER TABLE mod_payment DROP CONSTRAINT mod_payment_mp_fd_id_fkey ;
-ALTER TABLE mod_payment ADD CONSTRAINT mod_payment_mp_fd_id_fkey FOREIGN KEY
(mp_fd_id) REFERENCES fiche_def (fd_id) MATCH SIMPLE ON UPDATE
cascade ON DELETE cascade;
-ALTER TABLE mod_payment DROP CONSTRAINT mod_payment_mp_jrn_def_id_fkey ;
-ALTER TABLE mod_payment ADD CONSTRAINT mod_payment_mp_jrn_def_id_fkey FOREIGN
KEY (mp_jrn_def_id) REFERENCES jrn_def (jrn_def_id) MATCH SIMPLE ON UPDATE
CASCADE ON DELETE CASCADE;
---
PhpCompta est un logiciel de comptabilité libre en ligne (full web)
Projet opensource http://www.phpcompta.eu
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpcompta-dev] r5281 - in phpcompta/trunk: html html/admin html/admin/sql/patch include sql,
phpcompta-dev <=