mirror of
https://gitee.com/dromara/mayfly-go
synced 2025-12-08 00:40:26 +08:00
feat: redis支持zset、redis数据操作界面优化
This commit is contained in:
41
mayfly_go_web/src/views/ops/redis/ViewerText.vue
Normal file
41
mayfly_go_web/src/views/ops/redis/ViewerText.vue
Normal file
@@ -0,0 +1,41 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-input type="textarea" v-model="modelValue" />
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import { reactive, watch, toRefs, onMounted } from 'vue';
|
||||
|
||||
const props = defineProps({
|
||||
content: {
|
||||
type: String,
|
||||
},
|
||||
})
|
||||
|
||||
const state = reactive({
|
||||
modelValue: '',
|
||||
});
|
||||
|
||||
const {
|
||||
modelValue,
|
||||
} = toRefs(state)
|
||||
|
||||
watch(
|
||||
() => props.content,
|
||||
(val: any) => {
|
||||
state.modelValue = val;
|
||||
}
|
||||
);
|
||||
|
||||
onMounted(() => {
|
||||
state.modelValue = props.content as any;
|
||||
})
|
||||
|
||||
const getContent = () => {
|
||||
return state.modelValue
|
||||
}
|
||||
|
||||
defineExpose({ getContent })
|
||||
|
||||
</script>
|
||||
<style lang="scss"></style>
|
||||
Reference in New Issue
Block a user