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

海口顶尖网站建设巴中市文旅新区关坝片区安置房建设项目

海口顶尖网站建设,巴中市文旅新区关坝片区安置房建设项目,苏州哪个网站建设最好,建工网查询19vue3实战-----菜单子树的展示 1.实现目标2.实现思路3.实现步骤3.1新建config配置文件3.2封装组件3.3使用组件 1.实现目标 如上,以上效果的难点是“在表格里面实现树形结构”。可以用element-plus框架中的table作为辅助: 可以自己查看文档了解怎么使用。 2.实现思路 上面的… 19vue3实战-----菜单子树的展示 1.实现目标2.实现思路3.实现步骤3.1新建config配置文件3.2封装组件3.3使用组件 1.实现目标 如上,以上效果的难点是“在表格里面实现树形结构”。可以用element-plus框架中的table作为辅助: 可以自己查看文档了解怎么使用。 2.实现思路 上面的效果不难实现,无非就是搭建界面。这里我不用常规方法“一个一个页面搭建”而是用之前写的文章https://blog.csdn.net/fageaaa/article/details/145572470中的方法--------通过配置生成页面。 3.实现步骤 3.1新建config配置文件 在menu文件夹下新建config配置文件: menu/config/content.config.ts const contentConfig {pageName: menu,header: {title: 菜单列表,btnTitle: 新建菜单},propsList: [{ label: 菜单名称, prop: name, width: 180px },{ label: 级别, prop: type, width: 120px },{ label: 菜单url, prop: url, width: 150px },{ label: 菜单icon, prop: icon, width: 200px },{ label: 排序, prop: sort, width: 120px },{ label: 权限, prop: permission, width: 150px },{ type: timer, label: 创建时间, prop: createAt },{ type: timer, label: 更新时间, prop: updateAt },{ type: handler, label: 操作, width: 150px }],childrenTree: {rowKey: id,treeProps: {children: children}} } export default contentConfig3.2封装组件 将各种各样的表格所在的内容区域封装为一个组件: components/page-content/page-content.vue: templatediv classcontentdiv classheaderh3 classtitle{{ contentConfig?.header?.title ?? 数据列表 }}/h3el-button typeprimary clickhandleNewUserClick{{ contentConfig?.header?.btnTitle ?? 新建数据 }}/el-button/divdiv classtableel-table:datapageListborderstylewidth: 100%v-bindcontentConfig.childrenTreetemplate v-foritem in contentConfig.propsList :keyitem.proptemplate v-ifitem.type timerel-table-column aligncenter v-binditemtemplate #defaultscope{{ formatUTC(scope.row[item.prop]) }}/template/el-table-column/templatetemplate v-else-ifitem.type handlerel-table-column aligncenter v-binditemtemplate #defaultscopeel-buttonsizesmalliconEdittypeprimarytextclickhandleEditBtnClick(scope.row)编辑/el-buttonel-buttonsizesmalliconDeletetypedangertextclickhandleDeleteBtnClick(scope.row.id)删除/el-button/template/el-table-column/templatetemplate v-else-ifitem.type customel-table-column aligncenter v-binditemtemplate #defaultscopeslot:nameitem.slotNamev-bindscope:propitem.prophNamewhy/slot/template/el-table-column/templatetemplate v-elseel-table-column aligncenter v-binditem //template/template/el-table/divdiv classpaginationel-paginationv-model:current-pagecurrentPagev-model:page-sizepageSize:page-sizes[10, 20, 30]layouttotal, sizes, prev, pager, next, jumper:totalpageTotalCountsize-changehandleSizeChangecurrent-changehandleCurrentChange//div/div /templatescript setup langts ... interface IProps {contentConfig: {pageName: stringheader?: {title?: stringbtnTitle?: string}propsList: any[]childrenTree?: any} }const props definePropsIProps() ... /scriptstyle langless scoped ... /style 3.3使用组件 templatediv classmenupage-content :content-configcontentConfig //div /templatescript setup langts namemenu import PageContent from /components/page-content/page-content.vue import contentConfig from ./config/content.config /scriptstyle scoped ... /style
http://www.w-s-a.com/news/358637/

相关文章:

  • 地方门户类网站产品推广惠州市中国建设银行网站
  • 网站建设公司推荐5788移动版wordpress
  • 产品类型 速成网站淘宝怎么建立自己的网站
  • 南京优化网站建设公司的网站怎么建设
  • 做网站开发能挣钱月嫂云商城网站建设
  • 包装网站模板新手入门网站建设
  • 做网站的天津哪个公司做网站
  • 网站建设摊销时间是多久微信官网免费下载安装
  • 网站解析是做a记录吗群晖 wordpress 阿里云
  • 涉县移动网站建设公司常州做网站的公司有哪些
  • 网站批量创建程序中国十大人力资源公司
  • 菏泽网站建设 梧桐树二次开发创造作用
  • 维护网站费用长沙广告设计公司排名
  • 模仿别人网站侵权wordpress 修改链接失效
  • wordpress文章设置受密码保护南宁网站优化公司哪家好
  • 网站开发工程师介绍设计类的网站
  • 嘉兴seo网站推广中山建网站多少钱
  • 高端汽车网站建设帮别人做网站自己为什么会被抓
  • 网站开发实验室建设方案wordpress 主题丢失
  • 珠宝网站建设平台分析报告郑州最新发布
  • 世界杯最新排名泉州seo网站关键词优
  • 广州公司网站提供如何推广新品
  • 网站建设如何描述沈阳网站建设推广平台
  • 用dw制作个介绍家乡网站学生个人简历
  • 建设银行企业网站访问不了wordpress搬到谷歌服务器
  • 网站建设与网站优化销售别墅庭院园林景观设计公司
  • 沈阳红方城网站建设专业的微网站哪家好
  • 医院网站asp东营信息发布平台
  • 网站全站建设开题报告范文南京本地网站
  • 网站漏洞扫描工具wampserver集成环境搭建了一个织梦cms网站