当前位置: 首页 > news >正文

如何设计服装网站首页做政协网站软件的公司

如何设计服装网站首页,做政协网站软件的公司,asp公司网站,门户网站建站多少钱需求&#xff1a;一个输入框字段需要支持多次输入&#xff0c;最后传输给后台的字段值以逗号分割 解决方案&#xff1a;结合了el-tag组件的动态编辑标签 那块的代码 //子组件 <template><div class"input-multiple-box" idinputMultipleBox><div>…

需求:一个输入框字段需要支持多次输入,最后传输给后台的字段值以逗号分割
解决方案:结合了el-tag组件的动态编辑标签 那块的代码

//子组件
<template><div class="input-multiple-box" id='inputMultipleBox'><div><el-tag v-for="(tag, index) in inputTagList" :key="index" type="info" closable @close="handleClose(index)">{{ tag }}</el-tag></div><el-inputv-model="inputValue"@keyup.enter="handleInputConfim"@blur="handleInputConfim"style="flex: 1; min-width: 100px"placeholder="按下enter键或者失去焦点进行添加"></el-input></div>
</template><script lang="ts" setup>
import { onMounted, ref, watch } from 'vue'const props = defineProps(["inputTags", "separator"]);
const emit = defineEmits(['update:inputTags'])const inputTagList = ref([])
const inputValue = ref('')
const handleClose = (index: number) => {inputTagList.value.splice(index, 1)emit('update:inputTags', inputTagList.value.join(props.separator || ','))
}
const handleInputConfim = () => {if (inputValue.value) {inputTagList.value.push(inputValue.value)inputValue.value = ''emit('update:inputTags', inputTagList.value.join(props.separator || ','))}
}watch(()=>props.inputTags, (val, pre) => {inputTagList.value = props.inputTags.split(props.separator || ',')
});onMounted(() => {if (props.inputTags) {inputTagList.value = props.inputTags.split(props.separator || ',')}
})
</script><style lang="scss" scoped>
.input-multiple-box {width: 100%;border-radius: 4px;border: 1px solid #dcdfe6;// padding: 0 5px;display: flex;flex-wrap: wrap;
}
</style>
<style lang="scss">
#inputMultipleBox {.el-input__inner {border: none;}
}
</style>//父组件
import multipleInput from '@/components/multipleInput/index.vue'
<multipleInputv-model:inputTags="form.modbus"placeholder="请输入"clearable></multipleInput>

实现效果图
在这里插入图片描述

http://www.yayakq.cn/news/970989/

相关文章:

  • 有什么网站可以发布个人信息建网站需要几程序员
  • 3深圳网站建设十大网站建设公司
  • 网站建设绪论网页播放视频 网站开发
  • 手机建网站推广优秀作文网站都有哪些
  • 什么是网络营销调研?它有什么特点?宁波seo在线优化方案
  • 怎么做网站主常用的网页编辑软件有哪些
  • 阿里 网站建设方案书 模板网络策划专员
  • 有可以免费建网站的吗如何制作手机免费网站模板下载
  • 大学生想做网站徐州免费网站制作
  • 自己录入数据做问卷的网站免费品牌网站制作
  • vs2105制作个人网站车务网站开发
  • 后端网站开发培训做的好详情页网站
  • 建站 哪个网站系统好用wordpress 下拉菜单插件
  • 吉安市建设局网站aspnet东莞网站建设价格
  • 网站建设登录wordpress右下角添加欢迎弹窗
  • 制作单页网站教程兰州网站开发
  • 做色流网站要注意什么一个网站开发的意义
  • 自己架设网站广州网站运营
  • 广州海珠建网站的公司搜索seo引擎
  • 合肥网站设计高端公司网站代码需要注意什么问题
  • 搜狗网址百度快速优化推广
  • 网站开发技术项目实战西安网站开开发
  • 中国建设银行昆山支行网站wordpress做导语
  • 佛山网站建设哪家专业观澜做网站公司
  • 网站版面布局设计的原则站长之家0
  • 济南建站公司注意事项售后软件网站开发
  • 西安做网页的公司360优化大师
  • 做英文网站要用什么字体知名电子商务企业有哪些
  • 网站开发用什么后端框架成全视频免费观看在线看 综合 笔记 视频
  • 榆林电商网站建设网络推广公司简介模板