sms sender name validation
This commit is contained in:
parent
bc60c1f29c
commit
26f74ed121
@ -63,7 +63,15 @@ class DocType:
|
|||||||
|
|
||||||
def get_sender_name(self):
|
def get_sender_name(self):
|
||||||
"returns name as SMS sender"
|
"returns name as SMS sender"
|
||||||
return webnotes.conn.get_value('Manage Account', None, 'sms_sender_name') or 'ERPNext'
|
sender_name = webnotes.conn.get_value('Manage Account', None, 'sms_sender_name') or 'ERPNXT'
|
||||||
|
if len(sender_name) > 6:
|
||||||
|
msgprint("""
|
||||||
|
As per TRAI rule, sender name must be exactly 6 characters. \n
|
||||||
|
Kindly change sender name in Setup --> Global Defaults \n\n
|
||||||
|
|
||||||
|
Note: Hyphen, space, numeric digit , special characters are not allowed.
|
||||||
|
""", raise_exception=1)
|
||||||
|
return sender_name
|
||||||
|
|
||||||
def get_contact_number(self, arg):
|
def get_contact_number(self, arg):
|
||||||
"returns mobile number of the contact"
|
"returns mobile number of the contact"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user