Bugzilla – Attachment 41664 Details for
Bug 14683
Unable to clear SMS number
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14683: Unable to clear SMS number
Bug-14683-Unable-to-clear-SMS-number.patch (text/plain), 2.26 KB, created by
Joonas Kylmälä
on 2015-08-19 13:40:15 UTC
(
hide
)
Description:
Bug 14683: Unable to clear SMS number
Filename:
MIME Type:
Creator:
Joonas Kylmälä
Created:
2015-08-19 13:40:15 UTC
Size:
2.26 KB
patch
obsolete
>From 4dcb34a1c74a9fa403867efe668cc83b14887bb9 Mon Sep 17 00:00:00 2001 >From: =?UTF-8?q?Joonas=20Kylm=C3=A4l=C3=A4?= <j.kylmala@gmail.com> >Date: Wed, 19 Aug 2015 11:42:50 +0000 >Subject: [PATCH] Bug 14683: Unable to clear SMS number > >Enables to clear SMS number. > >To test: >1. Go to opac-messaging.pl >2. Insert SMS number and submit >3. Clear SMS number and submit >4. Observe that the sms number did not change >5. Apply patch >6. Clear SMS number and submit >7. Observe that the sms number changes > >Sponsored-by: Vaara-kirjastot >--- > opac/opac-messaging.pl | 9 ++++----- > 1 file changed, 4 insertions(+), 5 deletions(-) > >diff --git a/opac/opac-messaging.pl b/opac/opac-messaging.pl >index 69ae517..81140e6 100755 >--- a/opac/opac-messaging.pl >+++ b/opac/opac-messaging.pl >@@ -48,10 +48,9 @@ my ( $template, $borrowernumber, $cookie ) = get_template_and_user( > my $borrower = GetMemberDetails( $borrowernumber ); > my $messaging_options = C4::Members::Messaging::GetMessagingOptions(); > >-if ( defined $query->param('modify') && $query->param('modify') eq 'yes' ) { >- >- # If they've modified the SMS number, record it. >- if ( ( defined $query->param('SMSnumber') ) && ( $query->param('SMSnumber') ne $borrower->{'mobile'} ) ) { >+if ( defined $query->param('modify') && $query->param('modify') eq 'yes' ) { >+ >+ if ( $query->param('SMSnumber') ne $borrower->{'mobile'} ) { > ModMember( borrowernumber => $borrowernumber, > smsalertnumber => $query->param('SMSnumber') ); > $borrower = GetMemberDetails( $borrowernumber ); >@@ -65,7 +64,7 @@ C4::Form::MessagingPreferences::set_form_values({ borrowernumber => $borrowe > # warn( Data::Dumper->Dump( [ $messaging_options ], [ 'messaging_options' ] ) ); > $template->param( BORROWER_INFO => [ $borrower ], > messagingview => 1, >- SMSnumber => defined $borrower->{'smsalertnumber'} ? $borrower->{'smsalertnumber'} : $borrower->{'mobile'}, >+ SMSnumber => $borrower->{'smsalertnumber'} ? $borrower->{'smsalertnumber'} : $borrower->{'mobile'}, > SMSSendDriver => C4::Context->preference("SMSSendDriver"), > TalkingTechItivaPhone => C4::Context->preference("TalkingTechItivaPhoneNotification") ); > >-- >1.9.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 14683
:
41664
|
42050
|
42051
|
42162
|
42187
|
42188
|
42189