From 4f36789a4bb1047227902cf2fe648c5555451820 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 6 Feb 2007 01:49:45 +0000 Subject: [PATCH] =?UTF-8?q?New:=20Possibilit=E9=20de=20saisir=20une=20adh?= =?UTF-8?q?=E9sion=20sur=20un=20adh=E9rent=20de=20type=20non=20soumis=20a?= =?UTF-8?q?=20cotisation.=20Dans=20ce=20cas,=20les=20champs=20montant=20so?= =?UTF-8?q?nt=20supprim=E9s.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/adherents/card_subscriptions.php | 81 ++++++++++++++----------- htdocs/langs/en_US/members.lang | 18 +++--- htdocs/langs/fr_FR/members.lang | 22 ++++--- 3 files changed, 67 insertions(+), 54 deletions(-) diff --git a/htdocs/adherents/card_subscriptions.php b/htdocs/adherents/card_subscriptions.php index ea3833432f6..dc869881b3f 100644 --- a/htdocs/adherents/card_subscriptions.php +++ b/htdocs/adherents/card_subscriptions.php @@ -65,6 +65,9 @@ if ($_POST["action"] == 'cotisation' && ! $_POST["cancel"]) $adh->id = $rowid; $adh->fetch($rowid); + $adht = new AdherentType($db); + $adht->fetch($adh->typeid); + $reday=$_POST["reday"]; $remonth=$_POST["remonth"]; $reyear=$_POST["reyear"]; @@ -86,17 +89,20 @@ if ($_POST["action"] == 'cotisation' && ! $_POST["cancel"]) $action='addsubscription'; } - if (! $_POST["cotisation"] > 0) - { - $errmsg=$langs->trans("ErrorFieldRequired",$langs->trans("Amount")); - $action='addsubscription'; - } - if ($conf->global->ADHERENT_BANK_USE) + if ($adht->cotisation) { - if (! $_POST["accountid"]) $errmsg=$langs->trans("ErrorFieldRequired",$langs->trans("FinancialAccount")); - if (! $_POST["operation"]) $errmsg=$langs->trans("ErrorFieldRequired",$langs->trans("PaymentMode")); - if (! $_POST["label"]) $errmsg=$langs->trans("ErrorFieldRequired",$langs->trans("Label")); - if ($errmsg) $action='addsubscription'; + if (! $_POST["cotisation"] > 0) + { + $errmsg=$langs->trans("ErrorFieldRequired",$langs->transnoentities("Amount")); + $action='addsubscription'; + } + if ($conf->global->ADHERENT_BANK_USE) + { + if (! $_POST["accountid"]) $errmsg=$langs->trans("ErrorFieldRequired",$langs->transnoentities("FinancialAccount")); + if (! $_POST["operation"]) $errmsg=$langs->trans("ErrorFieldRequired",$langs->transnoentities("PaymentMode")); + if (! $_POST["label"]) $errmsg=$langs->trans("ErrorFieldRequired",$langs->transnoentities("Label")); + if ($errmsg) $action='addsubscription'; + } } if ($action=='cotisation') @@ -211,6 +217,7 @@ print "\n"; */ print '
'; +// Lien nouvelle cotisation if ($action != 'addsubscription') { print "".$langs->trans("NewSubscription").""; @@ -355,39 +362,41 @@ if ($action == 'addsubscription' && $user->rights->adherent->cotisation->creer) } print ""; - - print ''.$langs->trans("Amount").' '.$langs->trans("Currency".$conf->monnaie).''; - - if ($conf->global->ADHERENT_BANK_USE) + if ($adht->cotisation) { - print ''.$langs->trans("FinancialAccount").''; - $html->select_comptes($_POST["accountid"],'accountid',0,'',1); - print "\n"; + print ''.$langs->trans("Amount").' '.$langs->trans("Currency".$conf->monnaie).''; - print ''.$langs->trans("PaymentMode").''; - $html->select_types_paiements($_POST["operation"],'operation'); - print "\n"; + if ($conf->global->ADHERENT_BANK_USE) + { + print ''.$langs->trans("FinancialAccount").''; + $html->select_comptes($_POST["accountid"],'accountid',0,'',1); + print "\n"; - print ''.$langs->trans('Numero'); - print ' (Numéro chèque ou virement)'; // \todo a traduire - print ''; - print ''; + print ''.$langs->trans("PaymentMode").''; + $html->select_types_paiements($_POST["operation"],'operation'); + print "\n"; - print ''.$langs->trans('CheckTransmitter'); - print ' (Emetteur du chèque)'; // \todo a traduire - print ''; - print ''; + print ''.$langs->trans('Numero'); + print ' (Numéro chèque ou virement)'; // \todo a traduire + print ''; + print ''; - print ''.$langs->trans('Bank'); - print ' (Banque du chèque)'; // \todo a traduire - print ''; - print ''; + print ''.$langs->trans('CheckTransmitter'); + print ' (Emetteur du chèque)'; // \todo a traduire + print ''; + print ''; - print ''.$langs->trans("Label").''; - print 'datefin?$adh->datefin:time())).'" >'; + print ''.$langs->trans('Bank'); + print ' (Banque du chèque)'; // \todo a traduire + print ''; + print ''; + + print ''.$langs->trans("Label").''; + print 'datefin?$adh->datefin:time())).'" >'; + } } - + print ''.$langs->trans("SendAcknowledgementByMail").''; print 'global->ADHERENT_MAIL_COTIS?' checked="true"':'').'>'; diff --git a/htdocs/langs/en_US/members.lang b/htdocs/langs/en_US/members.lang index 724b90c8694..71e7f4b1c71 100644 --- a/htdocs/langs/en_US/members.lang +++ b/htdocs/langs/en_US/members.lang @@ -46,16 +46,16 @@ MemberStatusResiliated=Resiliated member MemberStatusResiliatedShort=Resiliated MembersStatusToValid=Draft members MembersStatusToValidShort=Draft members -MembersStatusValidated=Members validated +MembersStatusValidated=Validated members MembersStatusPayed=Subscription up to date MembersStatusPayedShort=Up to date MembersStatusNotPayed=Subscription out of date MembersStatusNotPayedShort=Out of date -MembersStatusResiliated=Members resiliated -MembersStatusResiliatedShort=Members resiliated +MembersStatusResiliated=Resiliated members +MembersStatusResiliatedShort=Resiliated members NewCotisation=New contribution EditMember=Edit member -SubscriptionEndDate=Subscription end date +SubscriptionEndDate=Subscription's end date NewAttribute=New attribut AttributeCode=Attribute code OptionalFieldsSetup=Optional fields setup @@ -73,7 +73,7 @@ AddMember=Add member MemberType=Member type NoTypeDefinedGoToSetup=No member types defined. Go to setup - Members types NewMemberType=New member type -WelcomeEMail=Welcome Email +WelcomeEMail=Welcome e-mail SubscriptionRequired=Subscription required EditType=Edit member type VoteAllowed=Vote allowed @@ -83,11 +83,11 @@ Reenable=Reenable ResiliateMember=Resiliate a member ConfirmResiliateMember=Are you sure you want to resiliate this member ? DeleteMember=Delete a member -ConfirmDeleteMember=Are you sure you want to delete this member (Deleting a memeber will delete all his subscription) ? +ConfirmDeleteMember=Are you sure you want to delete this member (Deleting a member will delete all his subscriptions) ? Filehtpasswd=htpasswd file ValidateMember=Validate a member ConfirmValidateMember=Are you sure you want to validate this member ? -FollowingLinksArePublic=Following links ares opened pages not protected by any Dolibarr permission. +FollowingLinksArePublic=The following links are open pages not protected by any Dolibarr permission. PublicMemberList=Public member list BlankSubscriptionForm=Subscription form MemberPublicLinks=Public links/pages @@ -100,4 +100,6 @@ String=String Text=Text Int=Int Date=Date -DateAndTime=Date and time \ No newline at end of file +DateAndTime=Date and time +MemberNotOrNoMoreExpectedToSubscribe=Member not or no more expected to subscribe +AddSubscription=Add subscription \ No newline at end of file diff --git a/htdocs/langs/fr_FR/members.lang b/htdocs/langs/fr_FR/members.lang index c7317c201c4..5d85e50a092 100644 --- a/htdocs/langs/fr_FR/members.lang +++ b/htdocs/langs/fr_FR/members.lang @@ -12,8 +12,8 @@ MembersCards=Cartes des adh MembersList=Liste des adhérents MembersListToValid=Liste des adhérents brouillons (à valider) MembersListValid=Liste des adhérents valides -MembersListUpToDate=Liste des adhérents valides à jour de cotisation -MembersListNotUpToDate=Liste des adhérents valides non à jour de cotisation +MembersListUpToDate=Liste des adhérents valides à jour d'adhésion +MembersListNotUpToDate=Liste des adhérents valides non à jour d'adhésion MembersListResiliated=Liste des adhérents résiliés MembersListQualified=Liste des adhérents qualifiés MenuMembersToValidate=Adhérents brouillons @@ -21,9 +21,9 @@ MenuMembersValidated=Adh MenuMembersUpToDate=Adhérents à jour MenuMembersNotUpToDate=Adhérents non à jour MenuMembersResiliated=Adhérents résiliés -DateAbonment=Date cotisation -DateSubscription=Date cotisation -DateNextSubscription=Date prochaine cotisation +DateAbonment=Date adhésion +DateSubscription=Date adhésion +DateNextSubscription=Date prochaine adhésion DateEndSubscription=Date fin adhésion EndSubscription=Fin adhésion NewMember=Nouvel adhérent @@ -60,14 +60,14 @@ NewAttribute=Nouvel attribut AttributeCode=Code de l'attribut OptionalFieldsSetup=Configuration des champs optionnels MembersTypeSetup=Configuration des types d'adhérents -NewSubscription=Nouvelle cotisation -Subscription=Cotisation -Subscriptions=Cotisations +NewSubscription=Nouvelle adhésion +Subscription=Adhésion +Subscriptions=Adhésions SubscriptionLate=En retard -SubscriptionNotReceived=Cotisation non reçue +SubscriptionNotReceived=Adhésion non reçue SubscriptionLateShort=En retard SubscriptionNotReceivedShort=Non reçue -ListOfSubscriptions=Liste des cotisations +ListOfSubscriptions=Liste des adhésions SendCardByMail=Envoyer fiche AddMember=Ajouter adhérent MemberType=Type d'adhérent @@ -101,3 +101,5 @@ Text=Texte long Int=Numérique Date=Date DateAndTime=Date et heure +MemberNotOrNoMoreExpectedToSubscribe=Non soumis ou plus soumis à cotisation +AddSubscription=Ajout adhésion