当前位置:网站首页>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(',')
边栏推荐
- LeetCode-1279. 红绿灯路口
- RedisSystemException:WRONGTYPE Operation against a key holding the wrong kind of value
- Solution of intelligent management platform for suppliers in hardware and electromechanical industry: optimize supply chain management and drive enterprise performance growth
- Handwritten online chat system (principle part 1)
- R语言ggplot2可视化时间序列柱形图:通过双色渐变配色颜色主题可视化时间序列柱形图
- Interview assault 63: how to remove duplication in MySQL?
- 史上超级详细,想找工作的你还不看这份资料就晚了
- [depth first search] Ji suanke: a joke of replacement
- [depth first search] Ji suanke: Square
- MATLAB中deg2rad和rad2deg函数的使用
猜你喜欢
Mathematical knowledge -- code implementation of Gaussian elimination (elementary line transformation to solve equations)
Intelligent supply chain management system solution for hardware and electromechanical industry: digital intelligent supply chain "creates new blood" for traditional industries
Airiot IOT platform enables the container industry to build [welding station information monitoring system]
中缀表达式转后缀表达式详细思路及代码实现
The second day of rhcsa study
LeetCode-1279. Traffic light intersection
受益匪浅,安卓面试问题
Binary search tree
PMP practice once a day | don't get lost in the exam -7.6
Digital "new" operation and maintenance of energy industry
随机推荐
中缀表达式转后缀表达式详细思路及代码实现
ROS custom message publishing subscription example
谷粒商城--分布式高级篇P129~P339(完结)
涂鸦智能在香港双重主板上市:市值112亿港元 年营收3亿美元
R语言dplyr包进行数据分组聚合统计变换(Aggregating transforms)、计算dataframe数据的分组均值(mean)
Simple understanding of MySQL database
GCC [7] - compilation checks the declaration of functions, and link checks the definition bugs of functions
test about BinaryTree
Druid 数据库连接池 详解
First day of rhcsa study
Openmv4 learning notes 1 --- one click download, background knowledge of image processing, lab brightness contrast
English topic assignment (25)
The list of people who passed the fifth phase of personal ability certification assessment was published
Test technology stack arrangement -- self cultivation of test development engineers
Intelligent supply chain management system solution for hardware and electromechanical industry: digital intelligent supply chain "creates new blood" for traditional industries
Yutai micro rushes to the scientific innovation board: Huawei and Xiaomi fund are shareholders to raise 1.3 billion
Deep circulation network long-term blood pressure prediction [translation]
test about BinaryTree
C language daily practice - day 22: Zero foundation learning dynamic planning
Understanding disentangling in β- VAE paper reading notes