header("Location: " . $_SERVER['PHP_SELF'] . "?id=" . $id); exit; } else { $mesg = $don->error; } } if ($action == 'set_paid') { if ($don->set_paye($id, $modepaiement) >= 0) { header("Location: " . $_SERVER['PHP_SELF'] . "?id=" . $id); exit; } else { $mesg = $don->error; } } if ($action == 'set_encaisse') { if ($don->set_encaisse($id) >= 0) { header("Location: " . $_SERVER['PHP_SELF'] . "?id=" . $id); exit; } else { $mesg = $don->error; } } /* * Build doc */ if ($action == 'builddoc') { $object = new Don($db); $object->fetch($id); // Save last template used to generate document if (GETPOST('model')) { $object->setDocModel($user, GETPOST('model', 'alpha'));
exit; } else $mesg=$don->error; } if ($_GET["action"] == 'set_paid') { if ($don->set_paye($_GET["rowid"], $modepaiement) >= 0) { Header("Location: fiche.php?rowid=".$_GET["rowid"]); exit; } else $mesg=$don->error; } if ($_GET["action"] == 'set_encaisse') { if ($don->set_encaisse($_GET["rowid"]) >= 0) { Header("Location: fiche.php?rowid=".$_GET["rowid"]); exit; } else $mesg=$don->error; } /* * Build doc */ if ($_REQUEST['action'] == 'builddoc') { $donation = new Don($db); $donation->fetch($_GET['rowid']);