当前位置:网站首页>map的使用(列表的数据赋值到表单,json逗号隔开显示赋值)
map的使用(列表的数据赋值到表单,json逗号隔开显示赋值)
2022-07-06 11:23:00 【小菜鸟码住】
<el-table :data="zdlxList" border style="width: 100%" max-height="250">
<el-table-column prop="zdlb" label="字段列表">
<template #default="scope">
<el-input v-model="scope.row.zdlb" type="textarea" placeholder="请输入字段列表" />
</template>
</el-table-column>
<el-table-column prop="zdsm" label="字段说明">
<template #default="scope">
<el-input v-model="scope.row.zdsm" type="textarea" placeholder="请输入字段说明" />
</template>
</el-table-column>
<el-table-column prop="zdlx" label="字段类型">
<template #default="scope">
<el-select v-model="scope.row.zdlx" :style="{ width: '100%' }" placeholder="请选择">
<el-option
v-for="item in zdlxTpye"
:key="item.value"
:label="item.label"
:value="item.label"
></el-option>
</el-select>
</template>
</el-table-column>
<el-table-column label="操作" width="100">
<template #default="scope">
<el-button link type="primary" size="small" @click.prevent="deleteRow(scope.$index)">
删除
</el-button>
</template>
</el-table-column>
</el-table>
js部分
const aa = zdlxList.value.map(a => {
return a.zdlx
})
const bb = zdlxList.value.map(a => {
return a.zdlb
})
const cc = zdlxList.value.map(a => {
return a.zdsm
})
data.form.fieldTypeList = aa.join(',')
data.form.fieldList = bb.join(',')
data.form.fieldDescList = cc.join(',')
边栏推荐
- Yutai micro rushes to the scientific innovation board: Huawei and Xiaomi fund are shareholders to raise 1.3 billion
- 使用map函数、split函数一行键入多个元素
- R语言ggplot2可视化时间序列柱形图:通过双色渐变配色颜色主题可视化时间序列柱形图
- 五金机电行业供应商智慧管理平台解决方案:优化供应链管理,带动企业业绩增长
- AIRIOT物联网平台赋能集装箱行业构建【焊接工位信息监控系统】
- PMP每日一练 | 考试不迷路-7.6
- 倒计时2天|腾讯云消息队列数据接入平台(Data Import Platform)直播预告
- R language uses rchisq function to generate random numbers that conform to Chi square distribution, and uses plot function to visualize random numbers that conform to Chi square distribution
- Detailed idea and code implementation of infix expression to suffix expression
- Binary search tree
猜你喜欢
Airiot IOT platform enables the container industry to build [welding station information monitoring system]
AutoCAD - what is the default lineweight for centerline drawing and CAD? Can I modify it?
Solution of commercial supply chain management platform for packaging industry: layout smart supply system and digitally integrate the supply chain of packaging industry
openmv4 学习笔记1----一键下载、图像处理背景知识、LAB亮度-对比度
If you have any problems, you can contact me. A rookie ~
Take a look at how cabloyjs workflow engine implements activiti boundary events
ROS custom message publishing subscription example
Pychrm Community Edition calls matplotlib pyplot. Solution of imshow() function image not popping up
应用使用Druid连接池经常性断链问题分析
Interview assault 63: how to remove duplication in MySQL?
随机推荐
Meilu biological IPO was terminated: the annual revenue was 385million, and Chen Lin was the actual controller
About NPM install error 1
Solve DoS attack production cases
朗坤智慧冲刺科创板:年营收4亿 拟募资7亿
Graffiti intelligence is listed on the dual main board in Hong Kong: market value of 11.2 billion Hong Kong, with an annual revenue of 300 million US dollars
Video based full link Intelligent Cloud? This article explains in detail what Alibaba cloud video cloud "intelligent media production" is
Computer network: sorting out common network interview questions (I)
Tensorflow and torch code verify whether CUDA is successfully installed
黑马--Redis篇
The second day of rhcsa study
Implementation of AVL tree
Abstract classes and abstract methods
AutoCAD - what is the default lineweight for centerline drawing and CAD? Can I modify it?
[depth first search] Ji suanke: Square
Don't miss this underestimated movie because of controversy!
Qlabel marquee text display
驼峰式与下划线命名规则(Camel case With hungarian notation)
渲大师携手向日葵,远控赋能云渲染及GPU算力服务
RT-Thread 组件 FinSH 使用时遇到的问题
pytorch常见损失函数