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

数据资源网站如何做培训机构排名全国十大教育机构排名

数据资源网站如何做,培训机构排名全国十大教育机构排名,合肥网站公司哪家好,加上政府网站建设需求说明 现有的设置单元列表,每个带有虚线加号的可以看做是一组设置单元,点击加号可以添加一组设置单元.点击设置单元右上角可以删除对应的设置单元. 实现思路说明 利用数组元素添加或是删除的方式实现页面数量动态变化.由于每个设置单元内容都相同所以单独封装了一个子组件.…

需求说明

    现有的设置单元列表,每个带有虚线加号的可以看做是一组设置单元,点击加号可以添加一组设置单元.点击设置单元右上角可以删除对应的设置单元.在这里插入图片描述

实现思路说明

    利用数组元素添加或是删除的方式实现页面数量动态变化.由于每个设置单元内容都相同所以单独封装了一个子组件.下面是实现过程:
父页面

<template><view class="out"><view class="content"><view class="setting"><setFriend class="addUnit" v-for="unitIndex in unitList" :unitList="unitList"></setFriend><view class="addUnitClass" @click="addUnit"><image class="add_unit_img" src="../../static/add_unit.png"></image></view></view></view></view>
</template><script>export default {data() {return {// 自定义数组,元素可以随便写unitList:[1,2,3]}},methods: {addUnit(){// 添加添加按钮,数组添加一个元素,元素内容可以任意this.unitList.push(1)}}}
</script><style lang="scss">uni-page-body,page {height:100%;background-color: rgb(242, 242,242);}.out{display: flex;justify-content: center;align-items: center;width: 90%;margin: auto;.content{width: 100%;// height: 400px;display: flex;justify-content: center;align-items: center;flex-direction: column;.setting{width: 100%;display: flex;justify-content: flex-start;align-items: center;flex-direction: row;flex-wrap:wrap;.addUnit{width: 50%;height: 150px;margin-bottom: 15px;}.addUnitClass{position: relative;top: 10px;margin-left: 7px;width: 45%;height: 150px;margin-bottom: 15px;background-color: white;display: flex;justify-content: center;align-items: center;border-radius: 5px;.add_unit_img{width: 80%;height: 80%;}}}}}		</style>

设置单元子组件

<template><view><view class="unit"><image class="close_img" src="../../static/close_button.png" @click="closeUnit"></image><view class="uni_item"><image class="upload_img" src="../../static/upload_img.png"></image></view></view></view>
</template><script>export default {name:"setFriend",data() {return {};},// 设置属性unitListprops:{unitList: {type: Array,default: [1,2],required: false}},methods:{closeUnit(){// 点击关闭按钮,数组减一处理if(this.unitList.length != 0){this.unitList.splice(0, 1);}}}}
</script><style lang="scss">uni-page-body,page {height:100%;background-color: rgb(242, 242,242);}.unit{width: 90%;height: 150px;background-color: white;margin-top: 9px;margin-left: 5px;border-radius: 5px;position: relative;left: 1px;.close_img{width: 20px;height: 20px;position: absolute;left:140px;top:-8px;}.uni_item{width: 100%;height: 100%;display: flex;justify-content: center;align-items: center;flex-direction: column;.upload_img{width:65px;height: 65px;margin-bottom: 10px;}}}}</style>
http://www.khdw.cn/news/55145.html

相关文章:

  • 深圳有哪些公司比较可靠成都seo整站
  • 网站qq线客服咋做站长统计网站
  • 外贸做独立网站怎么样百度搜索引擎的功能
  • 哪里有做网站网上永久视频会员是真的吗
  • 农产品网站开发技术方案与设施惠州seo计费
  • 标准网站建设公司网络营销方式哪些
  • 湖南网站建设有限公司谷歌广告平台
  • 房地产行业网站开发百度搜索引擎下载免费
  • 做网站运营有前途吗站长工具 seo查询
  • 纯css做的响应式网站福建搜索引擎优化
  • 响应式手机网站个人网站该怎么打广告
  • 阜新建设工程信息网站广州seo网站优化培训
  • 2022永久免费客服系统南京seo网络推广
  • 社区网站推广方案app推广30元一单平台
  • 常见的网站盈利方式网站的建设流程
  • 平台网站是什么百度推广助手手机版
  • 怎么做化妆品网站内容规划免费域名 网站
  • 网站开发项目的简介2024免费网站推广大全
  • 南宁手机网站建设网络营销产品
  • 网站的前台后台自己怎么免费做网站
  • 单页网站怎么优化营销推广活动策划
  • 网站排名优化机构微信朋友圈广告推广代理
  • 响应式企业网站cms网络推广赚钱
  • asp系统网站源码信息流广告有哪些投放平台
  • 赣州做网站哪家好长沙seo网络公司
  • 做破解网站合法sem推广托管公司
  • 贵阳网站建设搜王道下拉网络营销优化
  • 网站做产品的审核工作怎么样线上培训机构
  • 纯静态网站模板营销网站制作公司
  • 建网站用的免费软件短视频营销案例