Commit bbc0a031 authored by 高宇's avatar 高宇

删除菜单

parent 40d3ebac
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
<div class="placeholder" /> <div class="placeholder" />
<!-- 表单区 --> <!-- 表单区 -->
<div style="padding:5px 10px"> <div style="padding:5px 10px">
<div class="mb12 font-small-bold">基础样式列表</div> <div class="mb12 font-small-bold">基础信息列表</div>
<el-table v-loading="loading" border :data="basicinfoMationList"> <el-table v-loading="loading" border :data="basicinfoMationList">
<el-table-column type="index" label="序号" width="50" /> <el-table-column type="index" label="序号" width="50" />
<el-table-column label="pn" prop="pn" :show-overflow-tooltip="true"> <el-table-column label="pn" prop="pn" :show-overflow-tooltip="true">
...@@ -57,14 +57,14 @@ ...@@ -57,14 +57,14 @@
{{ scope.row.pn || '-' }} {{ scope.row.pn || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="qty" prop="qty" :show-overflow-tooltip="true"> <el-table-column label="name" prop="name" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.qty || '-' }} {{ scope.row.name || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="name" prop="name" :show-overflow-tooltip="true"> <el-table-column label="qty" prop="qty" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.name || '-' }} {{ scope.row.qty || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="max_qty" prop="max_qty" :show-overflow-tooltip="true"> <el-table-column label="max_qty" prop="max_qty" :show-overflow-tooltip="true">
...@@ -87,9 +87,9 @@ ...@@ -87,9 +87,9 @@
{{ scope.row.createName || '-' }} {{ scope.row.createName || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作时间" prop="create_date" :show-overflow-tooltip="true"> <el-table-column label="操作时间" prop="createDate" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.create_date || '-' }} {{ parseTime(scope.row.createDate,'{y}-{m}-{d}') || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
...@@ -157,6 +157,7 @@ ...@@ -157,6 +157,7 @@
<script> <script>
import { queryList, add, getDetailById, updataInfo, deleteLogical } from '@/api/sample/basicInformation' import { queryList, add, getDetailById, updataInfo, deleteLogical } from '@/api/sample/basicInformation'
import {parseTime} from "@/utils";
export default { export default {
name: 'Index', name: 'Index',
...@@ -247,14 +248,20 @@ export default { ...@@ -247,14 +248,20 @@ export default {
this.reFrom() this.reFrom()
}, },
handleDelete(row) { handleDelete(row) {
console.log('row',row) console.log('row', row)
const id = row.businessId const id = row.businessId
deleteLogical(id).then(res => { this.$confirm('是否确认操作?', '提示', {
console.log('res',res) confirmButtonText: '确定',
if (res.code === 200) { cancelButtonText: '取消',
this.$message.success('操作成功') type: 'warning'
this.getList() }).then(res => {
} deleteLogical(id).then(res => {
console.log('res', res)
if (res.code === 200) {
this.$message.success('操作成功')
this.getList()
}
})
}) })
}, },
// 编辑 // 编辑
...@@ -272,6 +279,7 @@ export default { ...@@ -272,6 +279,7 @@ export default {
this.loading = true this.loading = true
queryList(this.queryParams).then(res => { queryList(this.queryParams).then(res => {
console.log('res', res) console.log('res', res)
res.rows.createDate = parseTime(res.rows.createDate,'{y}-{m}-{d}')
this.total = res.total this.total = res.total
this.basicinfoMationList = res.rows this.basicinfoMationList = res.rows
this.loading = false this.loading = false
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment