| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- <template>
- <oa-scroll
- customClass="doorSettingSystem-container scroll-height"
- :customStyle="{
- //#ifdef APP-PLUS || MP-WEIXIN
- height: `calc(100vh - (0px))`,
- //#endif
- //#ifdef H5
- height: `calc(100vh - (0px))`,
- //#endif
- }"
- :refresherLoad="false"
- :refresherEnabled="false"
- :refresherDefaultStyle="'none'"
- :refresherBackground="'#f5f6f7'"
- :data-theme="'theme-' + proxy.$settingStore.themeColor.name"
- >
- <template #default>
- <text class="iconfont oaIcon-left" @click="handleExit()"></text>
- <u-cell-group>
- <!-- #ifdef APP-PLUS -->
- <u-cell title="网络设置" :value="1">
- <template #value>
- <view class="u-cell__value" @click="proxy.$settingStore.openSystemNetwork()">点击设置</view>
- <u-icon class="iconfont" name="arrow-right"></u-icon>
- </template>
- </u-cell>
- <u-cell title="IP地址" :value="ipAddress || '-'"></u-cell>
- <!-- #endif -->
- </u-cell-group>
- </template>
- </oa-scroll>
- <oa-upgrade ref="oaUpgradeRef" :themesColor="proxy.$settingStore.themeColor.color" />
- </template>
- <script setup>
- /*----------------------------------依赖引入-----------------------------------*/
- import { onLoad, onShow } from "@dcloudio/uni-app";
- import { reactive, getCurrentInstance, toRefs } from "vue";
- /*----------------------------------接口引入-----------------------------------*/
- /*----------------------------------组件引入-----------------------------------*/
- /*----------------------------------store引入-----------------------------------*/
- /*----------------------------------公共方法引入-----------------------------------*/
- const { proxy } = getCurrentInstance();
- /*----------------------------------公共变量-----------------------------------*/
- const state = reactive({
- ipAddress: "",
- });
- const { ipAddress } = toRefs(state);
- function refreshIpAddress() {
- proxy.$sys.getIpAddress({
- success: (res) => {
- state.ipAddress = res;
- },
- error: () => {
- state.ipAddress = "";
- },
- });
- }
- function handleExit() {
- proxy.$tab.navigateBack(1);
- }
- onLoad(() => {
- refreshIpAddress();
- });
- onShow(() => {
- refreshIpAddress();
- });
- </script>
- <style lang="scss" scoped>
- @import "../index.scss";
- </style>
|