Repository: netbox-community/netbox

Issue:
BNC port and Coax cable types
<!--
    NOTE: This form is only for proposing specific new features or enhancements.
    If you have a general idea or question, please post to our mailing list
    instead of opening an issue:

        https://groups.google.com/forum/#!forum/netbox-discuss

    NOTE: Due to an excessive backlog of feature requests, we are not currently
    accepting any proposals which significantly extend NetBox's feature scope.

    Please describe the environment in which you are running NetBox. Be sure
    that you are running an unmodified instance of the latest stable release
    before submitting a bug report.
-->
### Environment
* Python version:  3.6.8
* NetBox version: 2.6.1

<!--
    Describe in detail the new functionality you are proposing. Include any
    specific changes to work flows, data models, or the user interface.
-->
### Proposed Functionality
Patch panels and cables should support at a minimum BNC/Coaxial cables to document cross connecting T3/E3 interfaces.  Currently you can create a Serial interface on a Device with an interface type of T3/E3 but there are no suitable front/rear port types to connect it to on a panel.

<!--
    Convey an example use case for your proposed feature. Write from the
    perspective of a NetBox user who would benefit from the proposed
    functionality and describe how.
--->
### Use Case
Documentation of T3/E3 interconnects within a datacenter, or to external T3/E3 circuits.

<!--
    Note any changes to the database schema necessary to support the new
    feature. For example, does the proposal require adding a new model or
    field? (Not all new features require database changes.)
--->
### Database Changes
No DB changes needed, just new enums in PORT_TYPE_CHOICES and CABLE_TYPE_CHOICES

<!--
    List any new dependencies on external libraries or services that this new
    feature would introduce. For example, does the proposal require the
    installation of a new Python package? (Not all new features introduce new
    dependencies.)
-->
### External Dependencies
None


Discussion:
Proposed changes ready for pull in commit https://github.com/ragzilla/netbox/commit/99fc8f469b40b8be53dce76422d9db64f0b0c1a1#diff-586a99dcc48544d0f3261dfe26d69972

This does simplify the typical environment a bit by reducing the cable type to just Coax.  It would more accurately represent the environments I've worked in if there were 2 cable types for 734A/735A coax, but I defaulted to keeping things simple.
Looks good to submit a PR. One note: I'd change "coax" to "coaxial" just to be technically correct.

Resolving patch:
diff --git a/netbox/dcim/constants.py b/netbox/dcim/constants.py
--- a/netbox/dcim/constants.py
+++ b/netbox/dcim/constants.py
@@ -280,6 +280,7 @@
 # Pass-through port types
 PORT_TYPE_8P8C = 1000
 PORT_TYPE_110_PUNCH = 1100
+PORT_TYPE_BNC = 1200
 PORT_TYPE_ST = 2000
 PORT_TYPE_SC = 2100
 PORT_TYPE_SC_APC = 2110
@@ -296,6 +297,7 @@
         [
             [PORT_TYPE_8P8C, '8P8C'],
             [PORT_TYPE_110_PUNCH, '110 Punch'],
+            [PORT_TYPE_BNC, 'BNC'],
         ],
     ],
     [
@@ -376,6 +378,7 @@
 CABLE_TYPE_CAT7 = 1700
 CABLE_TYPE_DAC_ACTIVE = 1800
 CABLE_TYPE_DAC_PASSIVE = 1810
+CABLE_TYPE_COAXIAL = 1900
 CABLE_TYPE_MMF = 3000
 CABLE_TYPE_MMF_OM1 = 3010
 CABLE_TYPE_MMF_OM2 = 3020
@@ -397,6 +400,7 @@
             (CABLE_TYPE_CAT7, 'CAT7'),
             (CABLE_TYPE_DAC_ACTIVE, 'Direct Attach Copper (Active)'),
             (CABLE_TYPE_DAC_PASSIVE, 'Direct Attach Copper (Passive)'),
+            (CABLE_TYPE_COAXIAL, 'Coaxial'),
         ),
     ),
     (


Test patch: