Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-9358

Integrating google phone number library for validating telecom numbers

    Details

    • Type: Improvement
    • Status: Patch Available
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: Upcoming Release
    • Fix Version/s: None
    • Component/s: ALL COMPONENTS
    • Labels:
      None

      Description

      As per discussion at
      https://lists.apache.org/list.html?dev@ofbiz.apache.org:lte=1M:Validating%20telecom%20numbers

      Need to integrate Google telephone number to validate telephone numbers formats of various countries.

      1. OFBIZ-9358.patch
        7 kB
        Renuka Srishti
      2. OFBIZ-9358.patch
        7 kB
        Renuka Srishti
      3. OFBIZ-9358.patch
        5 kB
        Renuka Srishti

        Activity

        Hide
        Renuka_Srishti Renuka Srishti added a comment -

        This patch contains following methods:

        splitPhoneNumber(String phoneNumber, Delegator delegator):
        It accepts a phoneNumber as a string and split the phoneNumber into countryCode, areaCode, and contactNumber. It returns a map which contains countryCode, areaCode, and contactNumber.

        isValidPhoneNumber(String phoneNumber, Delegator delegator):
        It returns true if parsed number is valid, or the number is either a possible fully-qualified number (containing the area code and country code), or if the number could be a possible local number (with a country code, but missing an area code).

        Show
        Renuka_Srishti Renuka Srishti added a comment - This patch contains following methods: splitPhoneNumber(String phoneNumber, Delegator delegator): It accepts a phoneNumber as a string and split the phoneNumber into countryCode, areaCode, and contactNumber. It returns a map which contains countryCode, areaCode, and contactNumber. isValidPhoneNumber(String phoneNumber, Delegator delegator): It returns true if parsed number is valid, or the number is either a possible fully-qualified number (containing the area code and country code), or if the number could be a possible local number (with a country code, but missing an area code).
        Hide
        Renuka_Srishti Renuka Srishti added a comment -

        Add one more point to the available patch:
        Use @Deprecated annotation to deprecate isUSPhoneNumber, isUSPhoneAreaCode, isUSPhoneMainNumber and isInternationalPhoneNumber methods of class UtilValidate.

        Show
        Renuka_Srishti Renuka Srishti added a comment - Add one more point to the available patch: Use @Deprecated annotation to deprecate isUSPhoneNumber, isUSPhoneAreaCode, isUSPhoneMainNumber and isInternationalPhoneNumber methods of class UtilValidate.
        Hide
        arunpati Arun Patidar added a comment -

        Committed slightly modified patch at revision 1802661

        Need more improvement in methods to add country Geo specific support. So not closing this ticket for now.

        Thanks Suraj Khurana and Renuka Srishti for your contribution.

        Show
        arunpati Arun Patidar added a comment - Committed slightly modified patch at revision 1802661 Need more improvement in methods to add country Geo specific support. So not closing this ticket for now. Thanks Suraj Khurana and Renuka Srishti for your contribution.
        Hide
        Renuka_Srishti Renuka Srishti added a comment -

        Hii Arun Patidar
        I think you are saying, that we can add one more support to check any telecom number is belong to the particular country or not?

        Show
        Renuka_Srishti Renuka Srishti added a comment - Hii Arun Patidar I think you are saying, that we can add one more support to check any telecom number is belong to the particular country or not?
        Hide
        deepak.dixit Deepak Dixit added a comment -

        Yes Renuka,
        It would be good if we have another method to validate phoneNumber based for country .

        Show
        deepak.dixit Deepak Dixit added a comment - Yes Renuka, It would be good if we have another method to validate phoneNumber based for country .

          People

          • Assignee:
            Renuka_Srishti Renuka Srishti
            Reporter:
            suraj.khurana Suraj Khurana
          • Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

            • Created:
              Updated:

              Development