* * $Id$ * $Source$ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * */ require("./pre.inc.php3"); require("../lib/functions.inc.php3"); require("../societe.class.php3"); require("../contact.class.php3"); require("cactioncomm.class.php3"); require("actioncomm.class.php3"); llxHeader(); $db = new Db(); if ($sortfield == "") { $sortfield="a.datea"; } if ($sortorder == "") { $sortorder="DESC"; } if ($page == -1) { $page = 0 ; } $limit = 26; $offset = $limit * $page ; $pageprev = $page - 1; $pagenext = $page + 1; print "< Prev\n| "; print " Next >\n"; $bc1="bgcolor=\"#90c090\""; $bc2="bgcolor=\"#b0e0b0\""; /* * * * */ if ($action=='add') { $actioncomm = new ActionComm($db); $actioncomm->date = $date; $actioncomm->type = $actionid; $actioncomm->contact = $contactid; $actioncomm->user = $user->id; $actioncomm->societe = $socid; $actioncomm->note = $note; $actioncomm->add(); } /* * * * */ if ($action=='create' && $actionid && $contactid) { $caction = new CActioncomm(); $caction->fetch($db, $actionid); $contact = new Contact($db); $contact->fetch($contactid); $societe = new Societe($db); $societe->get_nom($socid); print '