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

网站模板怎么制作营销技巧和营销方法培训

网站模板怎么制作,营销技巧和营销方法培训,北京菜谱设计制作公司,天河做网站开发前言 因为公司业务开发需要拖拽功能。 ps#xff1a;该功能只能针对高度一致的#xff0c;如果高度不一致需要另外二开 演示 开始 templateview styleheight: 100%;movable-area :style{width: 100%, height: allHeight px}该功能只能针对高度一致的如果高度不一致需要另外二开 演示 开始 templateview styleheight: 100%;movable-area :style{width: 100%, height: allHeight px}movable-viewv-for(item, index) in list:keyitem.id:x0:yitem.y:style{height: itemHeight px, width: 100%,}directionalltouchstarthandleDragStart(index)changehandleMoving(index, $event)touchendhandleDragEndclassmovable-view!-- 这里可以放置步骤的详细内容 --view stylebackground-color: aqua; padding: 20rpx 0;{{ item.desc }}/view/movable-view/movable-area/view /templatescript export default {data() {return {list: [],cloneList: [],activeIndex: -1, // 选中oldIndex: -1,moveToIndex: -1, // 移动allHeight: 300,itemHeight: 50};},created() {for(let i 0; i 12; i ) {let info {id: i,desc: 测试 i}this.list.push(info)}this.allHeight 12 * this.itemHeightthis.initList(this.list)},methods: {deepCopy(source) {return JSON.parse(JSON.stringify(source));},initList(list[]){const newList this.deepCopy(list);this.list newList.map((item, index) {return {...item,y: index * this.itemHeight,key: Math.random() index};});//拷贝一份初始list值this.cloneList this.deepCopy(this.list);},// 拖拽开始handleDragStart(index) {this.activeIndex index;this.oldIndex index;},handleMoving(index, e){if (e.detail.source ! touch) return;const { x, y } e.detail;const currentY Math.floor((y this.itemHeight / 2) / this.itemHeight);this.moveToIndex Math.min(currentY, this.list.length - 1);//更新移动后的位置if (this.oldIndex ! this.moveToIndex this.oldIndex ! -1 this.moveToIndex ! -1) {const newList this.deepCopy(this.cloneList);//交换位置newList.splice(this.moveToIndex, 0, ...newList.splice(this.activeIndex, 1));this.list.forEach((item, index) {if (index ! this.activeIndex) {const itemIndex newList.findIndex(val val.id item.id);item.y itemIndex*this.itemHeight}});this.oldIndex this.moveToIndex;}},handleDragEnd(e) {if (this.moveToIndex ! -1 this.activeIndex ! -1 this.moveToIndex ! this.activeIndex) {this.cloneList.splice(this.moveToIndex, 0, ...this.cloneList.splice(this.activeIndex, 1));}// 重新排序下更新后的位置。this.initList(this.cloneList);this.activeIndex -1;this.oldIndex -1;this.moveToIndex -1;},}, }; /scriptstyle .movable-area {}.movable-view {} /style
http://www.dnsts.com.cn/news/254157.html

相关文章:

  • 如何给网站做外链做网页制作的价格
  • 唐山网站开发国外做二手服装网站
  • 上海做网站报价创建网站 英文
  • 合肥做网站的的公司有哪些各类微网站建设
  • 网站建设外包 源代码asp开源企业网站教程
  • 帮助做职业规划的网站高手优化网站
  • 建设银行ETC的网站是哪个免费看行情的软件大全免费
  • 网站建设仟首先金手指14wordpress基于
  • 上海大型网站建设公司排名公众号绑定网站
  • 江阴规划建设局网站编程网站scratch网址
  • 网站空间服务多少钱wordpress jet插件
  • 烟台城乡建设局网站织梦软件网站模板下载地址
  • 网站开发软件有百度一下就知道官方网站
  • h5网站开发实例教程呼伦贝尔网站开发
  • 太原网站制作企业制作招聘网页
  • 佛山做网站建设中装建设
  • 织梦dedecms网站简略标题shorttitle的使用方法私人设计工作室前景
  • 河北网站建设就业考试上海网络营销上海网络推广
  • 做正品的网站wordpress 4.7.5下载
  • 南京 网站建设wordpress代理管理多站点
  • 网站所有权查询微信小程序开发平台游戏
  • 网站后台做1个多少钱一级域名和二级域名做两个网站
  • 目前做网站婚纱网站建设步骤和方法
  • 最好记得网站域名网站建设运营维护合同
  • 网站301如何做网络推广平台服务
  • 企业网站代运营昆山建设网站
  • 企业网站建设hnktwl微商客源神器
  • 建网站后如何维护重庆设计集团
  • 南京优质网站建设方案网站的轮播怎么做的
  • 专业做网文的网站网站开发费用属于什么科目