示例#1
0
class RackTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:rack", args=[A('uuid')])
    class Meta:
        model = DeviceRacks
        fields = ['pk','name','data_center','manufacturer', 'location','network_tag']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#2
0
class DeviceSwitcheTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:switch", args=[A("uuid")])
    class Meta:
        model = DeviceRouters
        fields = ['pk','name','account', 'password', 'mgmt_ip','os_version', 'port_amount']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#3
0
class DataCenterTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:data_center", args=[A('id')])
    class Meta:
        model = DataCenters
        fields = ['pk', 'name', 'address','website','phone','support_email','username']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#4
0
class VerdorTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:vendor", args=[A('id')])

    class Meta:
        model = Vendors
        fields = ['pk', 'name', 'type', 'description', 'website', 'status']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#5
0
class DeviceDriveTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn('infras:driver', args=[A("uuid")])

    class Meta:
        model = DeviceDrives
        fields = ['pk','name','disk_size','file_system']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#6
0
class ConnectionTable(tables.Table):
    pk = ToggleColumn()
    type = tables.LinkColumn("infras:connection", args=[A("uuid")])

    class Meta:
        model = Connections
        fields = ['pk','interface_a', 'interface_b', 'type', 'status', 'description']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#7
0
class DeviceBareTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:bare", args=[A("uuid")])
    class Meta:
        model = DeviceFirewalls
        fields = ['pk','name','account', 'password', 'mgmt_ip','os_version', 'port_amount',
                  'processor_model','no_of_processors','memory_chips','memory_size','motherboard_model',]
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#8
0
class DeviceFirewallTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:firewall", args=[A("uuid")])
    class Meta:
        model = DeviceFirewalls
        fields = ['pk','name','account', 'password', 'mgmt_ip','os_version', 'port_amount',
                  'license_amount','safe_area','unsafe_area']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#9
0
class DevicePowerTable(tables.Table):
    pk = ToggleColumn()
    name= tables.LinkColumn('infras:power', args=[A("uuid")])

    class Meta:
        model = DevicePowers
        fields = ['pk','name','outlet_amount','voltage','mgmt_ip']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#10
0
class InterfaceNetworkTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:interface_network", args=[A("uuid")])

    class Meta:
        model = InterfaceNetworks
        fields = ['pk','name', 'device', 'tag', 'type', 'status', 'description',
                  'speed', 'mac', 'port_model']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#11
0
class DeviceMaintenanceTable(tables.Table):
    pk = ToggleColumn()
    id = tables.LinkColumn("infras:device_maintenance", args=[A("uuid")])

    class Meta:
        model = DeviceMaintenances
        fields = ['pk','id','device', 'user', 'start_time','end_time',
                  'task_subject','task_detail','total_minutes','status','notes']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#12
0
class IPAddressTable(tables.Table):
    pk = ToggleColumn()
    address = tables.LinkColumn("infras:ip_address", args=[A("id")])
    prefix = tables.LinkColumn("infras:prefix", args=[A("prefix.id")])
    status = tables.TemplateColumn(STATUS_LABEL)

    class Meta:
        model = IPAddresses
        fields = ['pk', 'address','status','prefix','nat_address']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#13
0
class VlanTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:vlan", args=[A("id")])
    data_center = tables.LinkColumn("infras:data_center", args=[A('data_center.id')])
    device = tables.LinkColumn(A('get_device_url'), args=[A('device.uuid')])
    status = tables.TemplateColumn(STATUS_LABEL)
    class Meta:
        model = VLANs
        fields = ['pk', 'name','data_center','device','vid','status']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#14
0
class InterfaceRackTable(tables.Table):
    pk = ToggleColumn()
    name = tables.LinkColumn("infras:interface_rack", args=[A("uuid")])


    class Meta:
        model = InterfaceRacks
        fields = ['pk','name', 'device', 'tag', 'type', 'status', 'description',
                  'has_rail', 'rail_model', 'unit_no']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#15
0
class QuestionTable(tables.Table):
    pk = ToggleColumn()
    id = tables.LinkColumn('deployments:question', args=[A('uuid')])
    action = tables.TemplateColumn(template_code=Question_ACTIONS,
                                   orderable=False)

    class Meta:
        model = Questions
        fields = ['pk', 'id', 'name', 'type', 'required', 'action']
        attrs = {
            "class": "table table-bordered table-hover dataTable",
        }
示例#16
0
class DeployInstanceTable(tables.Table):
    pk = ToggleColumn()
    id = tables.LinkColumn('deployments:deploy_instance', args=[A('uuid')])
    action = tables.TemplateColumn(template_code=Deploy_Instance_ACTIONS,
                                   orderable=False)

    class Meta:
        model = DeployInstances
        fields = ['pk', 'id', 'deploy_policy', 'action']
        attrs = {
            "class": "table table-bordered table-hover dataTable",
        }
示例#17
0
class CloudTable(tables.Table):
    pk = ToggleColumn()
    id = tables.LinkColumn('deployments:cloud', args=[A('uuid')])
    action = tables.TemplateColumn(template_code=Cloud_ACTIONS,
                                   orderable=False)

    class Meta:
        model = Clouds
        fields = ['pk', 'id', 'name', 'action']
        attrs = {
            "class": "table table-bordered table-hover dataTable",
        }
示例#18
0
class PlanTable(tables.Table):
    """plan table"""
    """product table"""
    pk = ToggleColumn()
    id = tables.LinkColumn('plan', args=[A('uuid')])

    class Meta:
        model = Plans
        fields = ('pk', 'id', 'name', 'cpu', 'memory', 'disk', 'instance',
                  'price', 'created', 'last_updated')
        attrs = {
            "class": "table table-bordered table-hover dataTable",
        }
示例#19
0
class InstanceConfigurationTable(tables.Table):
    pk = ToggleColumn()
    id = tables.LinkColumn('deployments:instance_configuration',
                           args=[A('uuid')])
    action = tables.TemplateColumn(
        template_code=Instance_Configuration_ACTIONS, orderable=False)

    class Meta:
        model = InstanceConfigurations
        fields = ['pk', 'id', 'deploy_instance', 'action']
        attrs = {
            "class": "table table-bordered table-hover dataTable",
        }
示例#20
0
class IPPrefixTable(tables.Table):
    pk = ToggleColumn()
    prefix = tables.LinkColumn("infras:prefix", args=[A("id")])
    data_center = tables.LinkColumn("infras:data_center", args=[A('data_center.id')])
    device = tables.LinkColumn(A('get_device_url'), args=[A('device.uuid')])
    vlan = tables.LinkColumn("infras:vlan", args=[A("vlan.id")])
    online_date = tables.DateColumn(format="Y-m-d")
    status = tables.TemplateColumn(STATUS_LABEL)

    class Meta:
        model = IPPrefixes
        fields = ['pk', 'prefix', 'type','status','data_center','device','vlan','online_date']
        attrs = {
            'class':'table table-hover table-striped dataTable',
        }
示例#21
0
class ProductTable(tables.Table):
    """product table"""
    DETAIL_URL_NAME = 'product'
    pk = ToggleColumn()
    product_name = tables.LinkColumn(DETAIL_URL_NAME, args=[A('uuid')])
    plans = tables.Column(accessor='all_plans', orderable=False)
    summary = tables.Column(accessor='get_model.summary', orderable=False)

    class Meta:
        model = Products
        fields = ('pk', 'product_name', 'plans', 'product_type', 'summary',
                  'created', 'last_updated')
        # sequence = ('selection', 'summary')+fields
        attrs = {
            "class": "table table-bordered table-condensed table-hover",
        }
示例#22
0
class PackageTable(tables.Table):
    """Package table"""
    pk = ToggleColumn()
    id = tables.LinkColumn('packages:detail', args=[A('uuid')])
    package_name = tables.Column()
    created = tables.Column()
    client = tables.Column(accessor='client.email')
    status = tables.Column()
    deploy_status = tables.Column()
    deploy = tables.TemplateColumn(template_code=DEPLOY_ACTIONS,
                                   attrs={'td': {
                                       'class': 'text-right'
                                   }},
                                   verbose_name='')

    class Meta:
        model = Packages
        fields = ('pk', 'id', 'package_name', 'created', 'client', 'status',
                  'deploy_status')
        attrs = {
            "class": "table table-bordered table-condensed table-hover",
        }