update
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button @click="getDataList()">查询</el-button>
|
||||
<el-button @click="test()">测试</el-button>
|
||||
<el-button v-if="$hasPermission('monitoring:product:save')" type="primary" @click="addOrUpdateHandle()">新增</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
@@ -52,6 +53,8 @@
|
||||
></el-pagination>
|
||||
<!-- 弹窗, 新增 / 修改 -->
|
||||
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update>
|
||||
|
||||
<base-dialog v-if="showbasedialog" ref="basedialog" :configs="addOrUpdateConfigs"></base-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -60,7 +63,7 @@ import AddOrUpdate from './product-add-or-update'
|
||||
import BaseTable from '@/components/base-table'
|
||||
import TableOperateComponent from '@/components/base-table/components/operationComponent'
|
||||
import TableTextComponent from '@/components/base-table/components/detailComponent'
|
||||
|
||||
import BaseDialog from '@/components/base-dialog/addOrUpdate'
|
||||
const tableConfigs = [
|
||||
{ type: 'index', name: '序号' },
|
||||
{ prop: 'updateTime', name: '添加时间' },
|
||||
@@ -135,10 +138,10 @@ const addOrUpdateConfigs = {
|
||||
}
|
||||
],
|
||||
operations: [
|
||||
{ name: 'reset', url: true },
|
||||
{ name: 'save', url: 'api/product/add' },
|
||||
{ name: 'update', url: 'api/product/update' },
|
||||
{ name: 'reset', url: true }
|
||||
],
|
||||
{ name: 'update', url: 'api/product/update' }
|
||||
]
|
||||
// extraComponents: [
|
||||
// {
|
||||
// name: 'CompName',
|
||||
@@ -162,17 +165,27 @@ export default {
|
||||
totalPage: 0,
|
||||
dataListLoading: false,
|
||||
dataListSelections: [],
|
||||
addOrUpdateVisible: false
|
||||
addOrUpdateVisible: false,
|
||||
addOrUpdateConfigs,
|
||||
showbasedialog: false
|
||||
}
|
||||
},
|
||||
components: {
|
||||
AddOrUpdate,
|
||||
BaseTable
|
||||
BaseTable,
|
||||
BaseDialog
|
||||
},
|
||||
activated() {
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
//
|
||||
test() {
|
||||
this.showbasedialog = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs.basedialog.init()
|
||||
})
|
||||
},
|
||||
// 获取数据列表
|
||||
getDataList() {
|
||||
this.dataListLoading = true
|
||||
|
||||
Reference in New Issue
Block a user