Browse Source

重新载入

master
maochaoying 2 years ago
parent
commit
8184e64ee5
  1. 29
      src/components/Debug.vue
  2. 4
      src/components/DetailTable.vue

29
src/components/Debug.vue

@ -97,6 +97,12 @@
</t-option>
</t-select>
<t-button class="save_btn" @click="onSubmit">保存</t-button>
<t-button
class="save_btn"
style="margin-left: 16px"
@click="loadConfig"
>载入配置</t-button
>
</div>
</div>
</div>
@ -186,6 +192,29 @@ const handleSelectChange = async val => {
}
}
const loadConfig = async () => {
const val = station_core_id.value
const res = await getCameraConfig(val)
if (res?.code == 200) {
if (res?.data?.exposure) {
exposure.value = res?.data?.exposure
// exposure
handleExposureTime(res?.data?.exposure)
} else {
exposure.value = 0
handleExposureTime(0)
}
if (res?.data?.brightness) {
simulation_brightness.value = res?.data?.brightness
// simulation_brightness
handleSimulationBrightness(res?.data?.brightness)
} else {
simulation_brightness.value = 0
handleSimulationBrightness(0)
}
}
}
onMounted(async () => {
const res = await coreListApi()
if (res?.code == 200) {

4
src/components/DetailTable.vue

@ -70,7 +70,6 @@ const columns = ref([
justifyContent: 'center',
}}
>
<p>{row.resultSerial}</p>
<svg
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
@ -130,6 +129,7 @@ const columns = ref([
</g>
</g>
</svg>
<p style={{ marginLeft: '10px' }}>{row.resultSerial}</p>
</div>
)
} else if (row.result == 2) {
@ -141,7 +141,6 @@ const columns = ref([
justifyContent: 'center',
}}
>
<p>{row.resultSerial}</p>
<svg
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
@ -201,6 +200,7 @@ const columns = ref([
</g>
</g>
</svg>
<p style={{ marginLeft: '10px' }}>{row.resultSerial}</p>
</div>
)
} else {

Loading…
Cancel
Save