基于vue3.0和element-plus的组件库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

73 lines
1.5 KiB

2 years ago
<template>
<WkbTag>ssss</WkbTag>
2 years ago
<el-button type="success" @click="newTerminal()">新终端</el-button>
2 years ago
<ListTable :data="data" :height="500" :props="prop"></ListTable>
2 years ago
<el-dialog class="no-padding" title="实时脚本终端" v-model="flag.termial" size="tiny" :close-on-click-modal="false" top="10vh"
width="80%">
<Terminal :url="url"></Terminal>
</el-dialog>
2 years ago
</template>
<script lang="ts" setup>
import { reactive, onMounted } from "vue";
import { useStore } from "vuex";
2 years ago
import { WkbTag, ListTable, Terminal } from "../packages";
2 years ago
const store = useStore();
2 years ago
const prefix = "ws://localhost/websocket/";
let index = 111;
let url = "";
const flag = reactive({
termial: false
})
2 years ago
const data = [
{ caseName: 111, taskName: 111, userId: 'test', content: 'content', createTime: 'createTime' }
]
const prop = [
{
code: "caseName",
name: "案件名称",
width: 110,
},
{
code: "taskName",
name: "任务名称",
width: 110,
},
{
code: "userId",
name: "用户名",
width: 100,
},
{
code: "content",
name: "日志内容",
width: 500,
},
{
code: "createTime",
name: "产生时间",
width: 170,
},
];
2 years ago
const newTerminal = () => {
url = prefix + ++index;
flag.termial = true;
}
2 years ago
onMounted(() => {
});
</script>
2 years ago
<style lang="scss">
::v-deep .no-padding .el-dialog__body {
background-color: black;
}
2 years ago
</style>