Device identity, collector enrollment file, and network device fixes
This commit is contained in:
@@ -33,22 +33,26 @@
|
||||
{{ heroWarranty.label }}<template v-if="heroWarranty.enddate"> - {{ warrantyDate(heroWarranty.enddate) }}</template>
|
||||
</span>
|
||||
</div>
|
||||
<!-- hero-detail / -label / -value are the styled classes every other
|
||||
detail page uses. This page had its own detail-item / label / value
|
||||
names, which match nothing in the stylesheet, so the label and the
|
||||
value rendered as one run-together string. -->
|
||||
<div class="hero-details">
|
||||
<div class="detail-item" v-if="device.assetnumber">
|
||||
<span class="label">Asset #</span>
|
||||
<span class="value">{{ device.assetnumber }}</span>
|
||||
<div class="hero-detail" v-if="device.assetnumber">
|
||||
<span class="hero-detail-label">Asset #</span>
|
||||
<span class="hero-detail-value">{{ device.assetnumber }}</span>
|
||||
</div>
|
||||
<div class="detail-item" v-if="device.serialnumber">
|
||||
<span class="label">Serial</span>
|
||||
<span class="value mono">{{ device.serialnumber }}</span>
|
||||
<div class="hero-detail" v-if="device.serialnumber">
|
||||
<span class="hero-detail-label">Serial</span>
|
||||
<span class="hero-detail-value mono">{{ device.serialnumber }}</span>
|
||||
</div>
|
||||
<div class="detail-item" v-if="device.locationname">
|
||||
<span class="label">Location</span>
|
||||
<span class="value">{{ device.locationname }}</span>
|
||||
<div class="hero-detail" v-if="device.locationname">
|
||||
<span class="hero-detail-label">Location</span>
|
||||
<span class="hero-detail-value">{{ device.locationname }}</span>
|
||||
</div>
|
||||
<div class="detail-item" v-if="device.businessunitname">
|
||||
<span class="label">Business Unit</span>
|
||||
<span class="value">{{ device.businessunitname }}</span>
|
||||
<div class="hero-detail" v-if="device.businessunitname">
|
||||
<span class="hero-detail-label">Business Unit</span>
|
||||
<span class="hero-detail-value">{{ device.businessunitname }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="hero-features" v-if="device.networkdevice">
|
||||
|
||||
@@ -161,7 +161,7 @@
|
||||
<label for="modelnumberid">Model</label>
|
||||
<select id="modelnumberid" v-model="form.modelnumberid" class="form-control">
|
||||
<option value="">Select Model</option>
|
||||
<option v-for="m in models" :key="m.modelnumberid" :value="m.modelnumberid">
|
||||
<option v-for="m in filteredModels" :key="m.modelnumberid" :value="m.modelnumberid">
|
||||
{{ m.modelnumber }}
|
||||
</option>
|
||||
</select>
|
||||
@@ -395,6 +395,15 @@ const generatedAssetNumber = computed(() => {
|
||||
})
|
||||
const vendors = ref([])
|
||||
const models = ref([])
|
||||
|
||||
// Models belong to a vendor, so picking one narrows the list - the same
|
||||
// behaviour PCForm, MachineForm and PrinterForm have. With no vendor chosen the
|
||||
// whole catalogue shows, rather than an empty dropdown that reads as "no models
|
||||
// exist" when it means "pick a vendor first".
|
||||
const filteredModels = computed(() => {
|
||||
if (!form.value.vendorid) return models.value
|
||||
return models.value.filter(m => m.vendorid === form.value.vendorid)
|
||||
})
|
||||
const locations = ref([])
|
||||
const statuses = ref([])
|
||||
const businessUnits = ref([])
|
||||
|
||||
Reference in New Issue
Block a user