Changeset 72558 in spip-zone
- Timestamp:
- May 3, 2013, 1:52:11 PM (8 years ago)
- Location:
- _plugins_/commandes/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
_plugins_/commandes/trunk/commandes_pipelines.php
r72262 r72558 62 62 63 63 /** 64 * accueil : liste des commandes à envoyer 64 * accueil : liste des commandes en attente de validation 65 * 66 * @param array $flux 67 * @return array $flux 65 68 */ 66 69 function commandes_accueil_encours($flux) { … … 78 81 79 82 83 /* 84 * Mettre à jour les dates de paiement ou d'envoi 85 * lors de la modification du statut d'une commande 86 * 87 * @param array $flux 88 * @return array $flux 89 */ 90 function commandes_pre_edition($flux){ 91 92 if ( 93 $action = $flux['args']['action'] 94 and $table = $flux['args']['table'] 95 and $statut = $flux['data']['statut'] 96 and $action == 'instituer' 97 and $table == table_objet_sql('commande') 98 and $date = date('Y-m-d H:i:s') // il faudrait copier la date de maj pour bien faire... 99 ) { 100 switch ($statut) { 101 case 'paye'; 102 $flux['data']['date_paiement'] = $date; 103 break; 104 case 'envoye'; 105 $flux['data']['date_envoi'] = $date; 106 break; 107 } 108 } 109 110 return($flux); 111 } 112 80 113 ?> -
_plugins_/commandes/trunk/paquet.xml
r72262 r72558 1 1 <paquet 2 3 4 version="0.9.5"5 6 7 8 9 10 2 prefix="commandes" 3 categorie="divers" 4 version="0.9.6" 5 etat="dev" 6 compatibilite="[3.0.5;3.0.*]" 7 logo="prive/themes/spip/images/commande.png" 8 documentation="" 9 schema="0.3" 10 > 11 11 12 12 <nom>Commandes</nom> … … 14 14 <auteur lien="http://www.ldd.fr">Les Développements Durables</auteur> 15 15 <auteur lien="http://magraine.net">Matthieu Marcillaud</auteur> 16 16 17 17 <licence lien="http://www.gnu.org/licenses/gpl-3.0.html">GPL 3</licence> 18 18 19 19 <traduire module="commandes" reference="fr" gestionnaire="salvatore" /> 20 20 21 21 <necessite nom="saisies" compatibilite="[1.18.2;]" /> 22 22 <necessite nom="prix" compatibilite="[0.1.0;]" /> … … 28 28 <pipeline nom="accueil_encours" inclure="commandes_pipelines.php" /> 29 29 <pipeline nom="insert_head_css" inclure="commandes_pipelines.php" /> 30 30 <pipeline nom="pre_edition" inclure="commandes_pipelines.php" /> 31 31 32 <pipeline nom="declarer_tables_interfaces" inclure="base/commandes.php" /> 32 33 <pipeline nom="declarer_tables_principales" inclure="base/commandes.php" /> … … 34 35 <pipeline nom="rechercher_liste_des_champs" inclure="base/commandes.php" /> 35 36 <pipeline nom="rechercher_liste_des_jointures" inclure="base/commandes.php" /> 36 37 37 38 <pipeline nom="autoriser" inclure="commandes_autorisations.php" /> 38 39 39 40 <menu nom="commandes" titre="commandes:nom_bouton_plugin" parent="menu_edition" icone="images/commande-16.png" action="commandes" /> 40 41 </paquet>
Note: See TracChangeset
for help on using the changeset viewer.