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

极路由 做网站短视频推广代理

极路由 做网站,短视频推广代理,有趣的网站有哪些,做网站用哪个版本的eclipse由于es6支持哈希#xff0c;所以数据量只要不太大#xff0c;就不需要对el-cascader进行点击后在调接口出现下一级#xff0c;很简单的就是直接获取所有数据。 templatedivel-cascader :modelValuemodelValue :propsinnerProps所以数据量只要不太大就不需要对el-cascader进行点击后在调接口出现下一级很简单的就是直接获取所有数据。 templatedivel-cascader :modelValuemodelValue :propsinnerProps :optionsoptions changehandleChange filterable:show-all-levelsshowAllLevels :disableddisabled :placeholderplaceholder :clearableclearablestylewidth:100% bluronBlur focusonFocus closehandleClose visible-changeonVisibleChange /!-- --- {{ modelValue }} --/div /templatescript langts setup import { ref, reactive, toRaw, onMounted, watch, onBeforeUnmount } from vue import type { CascaderProps } from element-plus import * as api from ./api.js;const props defineProps({modelValue: {type: Array,default: []},// 是否支持清空选项clearable: {type: Boolean,default: true,},// 是否多选// multiple: {// type: Boolean,// default: false,// },// 指定某省传入该自治区的areacodedesignation: {type: String,default: ,},// 仅显示最后一级showAllLevels: {type: Boolean,default: true,},// 是否禁用disabled: {type: Boolean,default: false,},// 输入框占位文本placeholder: {type: String,default: ,},// 是否选择任意一级选项还是最后叶子结点checkStrictly: {type: Boolean,default: true,},// 次级菜单的展开方式,click和hoverexpandTrigger: {type: String,default: click,},// 多选个数限制selectNummultipleSelectNum: {type: Number,default: 1,},// 省市县乡镇显示层级默认为2到区县。0为省1为市2为区县3为乡镇level: {type: Number,default: 2,}, })let options: any ref([]) //树 const watchArr ref([])onMounted(() {// 获取全量数据getAllData() })//重新定义一个值来接受prop const isMultiple ref(false)//因为prop中的值非动态响应所以需要通过watch监听immediate 初始化时接收父组件中的传值 watch(() props.multipleSelectNum, () {// isMultiple.value props.multipleSelectNum;if(props.multipleSelectNum 1) {isMultiple.value true}console.log(isMultiple.value,props.multipleSelectNum,---props.multipleSelectNum;);}, {immediate: true })onBeforeUnmount(() {})const emit defineEmits([update:modelValue, change]) const handleChange (e: any, e2: any) {watchArr.value eemit(change, e)emit(update:modelValue, e) }async function getAllData() {let res await api.SearchAdministrativeDivisions({queryArea: props.designation,level: props.level})options.value res.data }function onFocus(e: any) { } async function onBeforeFilter(e: any) {let res await api.SearchAdministrativeDivisions({queryArea: e})const fn (arr: any[]) {arr.forEach((item, index) {if (item.children item.children.length) {item.children fn(item.children)} else {if (item.children) delete item.children}})return arr}// console.log(options, ---options);options.value fn(res.data) } // const isMultiple ref(false) const innerProps: CascaderProps {checkStrictly: props.checkStrictly,// lazy: true,value: areaCode,label: name,multiple: isMultiple.value, //modifyexpandTrigger: props.expandTrigger, } const handleClose () { } const onBlur () {// console.log(---onBlur); } const onVisibleChange (e: any) {// if (props.modelValue.length props.multipleSelectNum props.multiple true) {if (props.modelValue.length props.multipleSelectNum isMultiple.value true) { //modifyfunction onRabbit(list: any) {list.forEach((el: any) {if (el.children el.children.length 0) {el.children onRabbit(el.children);}el.disabled false;el.isFlag false});return list;}const newList onRabbit(options.value);options.value newList;} } // 监听 watch(() watchArr.value,(newVal, oldVal) {// if (props.multiple true) {if (isMultiple.value true) { //modify// console.log(oldVal,watch监听变化前的数)// console.log(newVal, watch监听变化后的数据)if (newVal.length props.multipleSelectNum) {function onRabbit(list: any) {list.forEach((el: any) {if (el.children el.children.length 0) {el.children onRabbit(el.children);}newVal.forEach((v: any) {if (v[v.length - 1] ! el.areaCode) {if (el.isFlag) {} else {el.disabled trueel.isFlag true}} else {el.disabled falseel.isFlag true}})});return list;}const newList onRabbit(options.value);options.value newList;} else {function onRabbit(list: any) {list.forEach((el: any) {if (el.children el.children.length 0) {el.children onRabbit(el.children);}el.disabled false;el.isFlag false});return list;}const newList onRabbit(options.value);options.value newList;}}},{immediate: true, // 立即执行deep: true // 深度监听} ) /scriptstyle/style
http://www.hkea.cn/news/14285165/

相关文章:

  • 飞沐网站建设公司北京网站建设电影
  • wordpress主题外贸网站平面设计专业学什么
  • 网站友情链接与排名网站从建设到上线流程
  • 网站怎么做才能赚钱吗wordpress地址应该填什么意思
  • 个人网站免备案推广软文
  • 石家庄网站建设外包公司排名手机优化大师下载2022
  • 同时优化几个网站做网站得每年续费吗
  • 南沙建设局网站培训网站html
  • 企业网站报价正规营销型网站建设
  • 织梦建站模板开门红营销活动方案
  • 网站开发 超速云wordpress googlevis 嵌入
  • 做农宿的网站新的营销模式有哪些
  • 网站域名跳转代码有云服务器怎么做网站
  • 龙岗网站建设icxun玉田网站制作
  • 免费建设小说网站四川省建筑人才网
  • 英文外贸网站源码网络营销大师排行榜
  • 如何用ps做网站首页南召seo快速排名价格
  • 网站设计英文报告企业营销策划心得体会
  • 嘉兴网站建设策划方案wordpress menu背景
  • 手机网站 微信怎么做网站搜索
  • 运维网站建设wordpress 文档预览
  • php网站建设入门教程前端网站论文
  • 科技企业网站源码婚庆公司名字大全
  • 酒店网站设计的目的和意义用dw做购票网站模板
  • 怎么进入公司网站seo营销的概念
  • 网站建设与维护 实验报告心得网站开发调研方案
  • 分类信息网站系统cmswordpress在 分栏
  • 个人做外贸的网站武进网站建设好么
  • 新手建立企业网站流程摩洛哥网站后缀
  • 网站能不能用自己的电脑做服务器推广策略用英语怎么说