添加通过参数自动登录和隐藏设备列表接口
This commit is contained in:
parent
83c60a2c61
commit
16ba73cd49
|
@ -271,8 +271,18 @@ export default defineComponent({
|
||||||
});
|
});
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
if (auto_login.value) {
|
console.log((<any>window).user_search);
|
||||||
|
if ((<any>window).user_search?.user && (<any>window).user_search?.pwd) {
|
||||||
|
if ((<any>window).user_search?.host) {
|
||||||
|
data.ip_address = (<any>window).user_search?.host;
|
||||||
|
}
|
||||||
|
data.user_name = (<any>window).user_search?.user;
|
||||||
|
data.password = (<any>window).user_search?.pwd;
|
||||||
login_form.value.submit();
|
login_form.value.submit();
|
||||||
|
} else {
|
||||||
|
if (auto_login.value) {
|
||||||
|
login_form.value.submit();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,7 @@
|
||||||
</q-btn-dropdown>
|
</q-btn-dropdown>
|
||||||
|
|
||||||
<q-btn-dropdown
|
<q-btn-dropdown
|
||||||
|
v-if="show_device_list"
|
||||||
stretch
|
stretch
|
||||||
no-caps
|
no-caps
|
||||||
flat
|
flat
|
||||||
|
@ -429,7 +430,7 @@
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { defineComponent, ref, Ref, computed, watch } from "vue";
|
import { defineComponent, ref, Ref, computed, watch, onMounted } from "vue";
|
||||||
import { useStore } from "src/store";
|
import { useStore } from "src/store";
|
||||||
|
|
||||||
import GridSettingDialog from "src/components/GridSettingDialog.vue";
|
import GridSettingDialog from "src/components/GridSettingDialog.vue";
|
||||||
|
@ -573,6 +574,12 @@ export default defineComponent({
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
const show_device_list = ref(true);
|
||||||
|
onMounted(() => {
|
||||||
|
show_device_list.value =
|
||||||
|
typeof (<any>window).user_search?.hide_device_list == "undefined";
|
||||||
|
});
|
||||||
|
|
||||||
return {
|
return {
|
||||||
show_advanced_menu,
|
show_advanced_menu,
|
||||||
plan_running,
|
plan_running,
|
||||||
|
@ -581,6 +588,7 @@ export default defineComponent({
|
||||||
function_center_control,
|
function_center_control,
|
||||||
is_custon_isv,
|
is_custon_isv,
|
||||||
window_rect_edit_dialog,
|
window_rect_edit_dialog,
|
||||||
|
show_device_list,
|
||||||
|
|
||||||
async backupDB() {
|
async backupDB() {
|
||||||
let client = GlobalData.getInstance().getCurrentClient();
|
let client = GlobalData.getInstance().getCurrentClient();
|
||||||
|
|
Loading…
Reference in New Issue