def phone2numeric_filter(value): """Take a phone number and converts it in to its numerical equivalent.""" return phone2numeric(value)
def phone2numeric(value): """Takes a phone number and converts it in to its numerical equivalent.""" from django.utils.text import phone2numeric return phone2numeric(value)
def phone2numeric_filter(value): """Takes a phone number and converts it in to its numerical equivalent.""" return phone2numeric(value)
def test_phone2numeric(self): numeric = text.phone2numeric('0800 flowers') self.assertEqual(numeric, '0800 3569377') lazy_numeric = lazystr(text.phone2numeric('0800 flowers')) self.assertEqual(lazy_numeric, '0800 3569377')
def phone2numeric(value): """Takes a phone number and converts it in to its numerical equivalent.""" from django.utils.text import phone2numeric return phone2numeric(value)
def test_phone2numeric(self): numeric = text.phone2numeric("0800 flowers") self.assertEqual(numeric, "0800 3569377") lazy_numeric = lazystr(text.phone2numeric("0800 flowers")) self.assertEqual(lazy_numeric, "0800 3569377")
def test_phone2numeric(self): numeric = text.phone2numeric('0800 flowers') self.assertEqual(numeric, '0800 3569377') lazy_numeric = lazystr(text.phone2numeric('0800 flowers')) self.assertEqual(lazy_numeric, '0800 3569377')
def test_phone2numeric(self): numeric = text.phone2numeric("0800 flowers") self.assertEqual(numeric, "0800 3569377") lazy_numeric = lazystr(text.phone2numeric("0800 flowers")) self.assertEqual(lazy_numeric, "0800 3569377")
"""Default variable filters."""
def test_phone(inp): text.phone2numeric(inp)