<!--
 * @Description : 流程管理 - 填写共享盘链接 - 弹窗
 * @Author      : jinxin
 * @Date        : 2023-02-15 17:40:03
-->
<template>
    <el-dialog :model-value="isShowLinksDialog" :close-on-click-modal="false" :close-on-press-escape="false" :show-close="true" :title="linksTitle" width="380px" center>
        <el-form :model="data.form">
            <el-form-item class="write-link-body" label="链接地址">
                <el-input
                    v-model="data.form.remarks_vale"
                    maxlength="100"
                    placeholder="请输入"
                    show-word-limit
                    type="textarea"
                    resize="none"
                    :autosize="{minRows:5,maxRows:5}"
                />
            </el-form-item>
        </el-form>
        <template #footer>
            <span class="dialog-footer write-link-footer">
                <el-button @click="comClick('cancel')">取消</el-button>
                <el-button type="primary" @click="comClick('sure')">确定</el-button>
            </span>
        </template>
    </el-dialog>
</template>
<script>
import { defineComponent, onMounted, reactive } from 'vue';

export default defineComponent({
    props:{
        isShowLinksDialog:Boolean,
        linksTitle:String
    },
    emits:["update:isShowLinksDialog",'getDragWriteData'],
    setup(props,context){
        // 生命周期
        onMounted(()=>{})
        // 变量
        let data = reactive({
            form:{
                remarks_vale:''
            },
        })
        const comClick = (type) => {
            if(type == 'sure'){
                context.emit('getDragWriteData',data.form.remarks_vale)
            }
            context.emit("update:isShowLinksDialog",false)
        }
        return{
            data,
            props,
            comClick,
        }
    }
})
</script>
<style scoped>
::v-deep(.el-date-editor){
    width: 100%!important;
} 

::v-deep(.dialog-footer){
    margin-top: 10px!important;
}
</style>