phpcompta-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpcompta-dev] r5468 - in phpcompta/trunk: html/admin/sql/patch include


From: phpcompta-dev
Subject: [Phpcompta-dev] r5468 - in phpcompta/trunk: html/admin/sql/patch include sql
Date: Sat, 5 Oct 2013 16:30:34 +0200 (CEST)

Author: danydb
Date: 2013-10-05 16:30:34 +0200 (Sat, 05 Oct 2013)
New Revision: 5468

Modified:
   phpcompta/trunk/html/admin/sql/patch/upgrade107.sql
   phpcompta/trunk/include/class_contact.php
   phpcompta/trunk/include/contact.inc.php
   phpcompta/trunk/sql/upgrade.sql
Log:
Add contact menu

Modified: phpcompta/trunk/html/admin/sql/patch/upgrade107.sql
===================================================================
--- phpcompta/trunk/html/admin/sql/patch/upgrade107.sql 2013-10-04 15:50:36 UTC 
(rev 5467)
+++ phpcompta/trunk/html/admin/sql/patch/upgrade107.sql 2013-10-05 14:30:34 UTC 
(rev 5468)
@@ -283,7 +283,24 @@
 
 update menu_ref set me_menu = 'Trésorerie' where me_code='MENUFIN';
 
+create or replace function do_insert() returns void
+as
+$$
+declare
+    nCount integer;
+begin
+    select count(*) into nCount from menu_ref where me_file='contact.inc.php';
+    if nCount = 0 then
+        insert into menu_ref(ME_CODE,me_menu,me_file,me_description,me_type) 
values ('CONTACT','Contact','contact.inc.php','Liste des contacts','ME');
+    end if;
+end;
+$$
+language plpgsql;
 
+select do_insert();
+
+drop function do_insert();
+
 update version set val=108;
 
 commit;

Modified: phpcompta/trunk/include/class_contact.php
===================================================================
--- phpcompta/trunk/include/class_contact.php   2013-10-04 15:50:36 UTC (rev 
5467)
+++ phpcompta/trunk/include/class_contact.php   2013-10-05 14:30:34 UTC (rev 
5468)
@@ -79,8 +79,8 @@
 
                if ( $all_contact == 0 ) return "";
         $r=$bar;
-        $r.='<table border="0"  width="95%">
-            <TR style="background-color:lightgrey;">
+        $r.='<table id="contact_tb" class="sortable">
+            <TR>
             <th>Quick Code</th>
             <th>Nom</th>
             <th>Prénom</th>
@@ -123,8 +123,7 @@
             }
             $r.="<TR>";
             $qcode=$contact->strAttribut(ATTR_DEF_QUICKCODE);
-            $r.='<TD><A HREF="javascript:void(0)" 
onclick="this.ipopup=\'ipopcard\';this.qcode=(\''.$qcode.'\');fill_ipopcard(this);">'.$qcode.
-                "</A></TD>";
+            $r.='<TD>'.HtmlInput::card_detail($qcode)."</TD>";
             $r.="<TD>".$contact->strAttribut(ATTR_DEF_NAME)."</TD>";
             $r.="<TD>".$contact->strAttribut(ATTR_DEF_FIRST_NAME)."</TD>";
             $r.="<TD>".$l_company_name."</TD>";

Modified: phpcompta/trunk/include/contact.inc.php
===================================================================
--- phpcompta/trunk/include/contact.inc.php     2013-10-04 15:50:36 UTC (rev 
5467)
+++ phpcompta/trunk/include/contact.inc.php     2013-10-05 14:30:34 UTC (rev 
5468)
@@ -71,7 +71,7 @@
                <?php
                echo dossier::hidden();
                $a = (isset($_GET['query'])) ? $_GET['query'] : "";
-               printf(_('Recherche') . ' <input class="input_text" type="text" 
name="query" value="%s">', $a);
+               printf(_('Recherche') . HtmlInput::filter_table("contact_tb", 
"0,1,2,3,4,5,6", 1));
                $sel_card = new ISelect('cat');
                $sel_card->value = $cn->make_array('select fd_id, fd_label from 
fiche_def ' .
                        ' where  frd_id=' . FICHE_TYPE_CONTACT .

Modified: phpcompta/trunk/sql/upgrade.sql
===================================================================
--- phpcompta/trunk/sql/upgrade.sql     2013-10-04 15:50:36 UTC (rev 5467)
+++ phpcompta/trunk/sql/upgrade.sql     2013-10-05 14:30:34 UTC (rev 5468)
@@ -0,0 +1,17 @@
+create or replace function do_insert() returns void
+as
+$$
+declare
+    nCount integer;
+begin
+    select count(*) into nCount from menu_ref where me_file='contact.inc.php';
+    if nCount = 0 then
+        insert into menu_ref(ME_CODE,me_menu,me_file,me_description,me_type) 
values ('CONTACT','Contact','contact.inc.php','Liste des contacts','ME');
+    end if;
+end;
+$$
+language plpgsql;
+
+select do_insert();
+
+drop function do_insert();
\ No newline at end of file



---
PhpCompta est un logiciel de comptabilité libre en ligne (full web)
Projet opensource http://www.phpcompta.eu



reply via email to

[Prev in Thread] Current Thread [Next in Thread]