|
|
@ -15,6 +15,12 @@ |
|
|
|
@click="showMessageBoxList" placeholder="显示消息" /> |
|
|
|
</a-layout-content> |
|
|
|
|
|
|
|
<!-- <a-layout-content :style="{ overflow: 'auto' }"> |
|
|
|
<div :style="{ padding: '15px' }"> |
|
|
|
{{pageRefCnt}} |
|
|
|
</div> |
|
|
|
</a-layout-content> --> |
|
|
|
|
|
|
|
<a-layout-content :style="{ overflow: 'auto' }"> |
|
|
|
<div :style="{ padding: '15px' }"> |
|
|
|
<service-configuration :service-key="activeServiceKey"></service-configuration> |
|
|
@ -44,7 +50,9 @@ |
|
|
|
|
|
|
|
</template> |
|
|
|
<script setup> |
|
|
|
import { onMounted, ref, h } from 'vue'; |
|
|
|
import { onMounted, ref, h ,watch, nextTick} from 'vue'; |
|
|
|
import { inject } from 'vue'; |
|
|
|
|
|
|
|
import ApiClient from '@/utils/ApiClient'; |
|
|
|
import ServiceConfiguration from './components/ServiceConfiguration.vue'; |
|
|
|
import { Modal } from 'ant-design-vue'; |
|
|
@ -59,6 +67,9 @@ const isSiderCollapsed = ref(false); |
|
|
|
const message = ref(''); // 添加一个响应式变量来存储消息 |
|
|
|
const messageColor = ref('black'); // 添加一个响应式变量来存储消息颜色 |
|
|
|
const messageBoxList = ref([]); // 添加一个响应式变量来存储消息列表 |
|
|
|
const pageRefCnt = inject('pageRefCnt'); // 获取 pageRefCnt 的引用 |
|
|
|
|
|
|
|
watch(() => pageRefCnt.value, onPageRefCntChange); |
|
|
|
|
|
|
|
// on mounted |
|
|
|
onMounted(mounted); |
|
|
@ -82,6 +93,14 @@ function actionMenuItemClick(event) { |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
async function onPageRefCntChange() { |
|
|
|
console.log('onPageRefCntChange', pageRefCnt.value); |
|
|
|
var oldServiceKey = activeServiceKey.value; |
|
|
|
activeServiceKey.value = null; |
|
|
|
await nextTick(); |
|
|
|
activeServiceKey.value = oldServiceKey; |
|
|
|
} |
|
|
|
|
|
|
|
// handle open change |
|
|
|
function handleOpenChange(keys) { |
|
|
|
openKeys.value = keys.length ? [keys[keys.length - 1]] : []; |
|
|
|