|
@@ -122,16 +122,7 @@ export default {
|
|
|
</script>
|
|
|
|
|
|
<template>
|
|
|
- <el-card
|
|
|
- v-loading="loading"
|
|
|
- style="
|
|
|
- width: calc(100% - 20px);
|
|
|
- height: 100%;
|
|
|
- margin: 10px;
|
|
|
- padding: 0 20px 20px 0;
|
|
|
- "
|
|
|
- :body-style="{ padding: 0 }"
|
|
|
- >
|
|
|
+ <el-card v-loading="loading" :body-style="{ padding: 0 }">
|
|
|
<see-model ref="SeeModel"></see-model>
|
|
|
<export-model ref="ExportModel"></export-model>
|
|
|
<invalid-model
|
|
@@ -147,61 +138,56 @@ export default {
|
|
|
:model="params"
|
|
|
label-width="auto"
|
|
|
label-position="right"
|
|
|
- style="padding: 20px 0 0"
|
|
|
>
|
|
|
- <el-row style="display: flex; flex-wrap: wrap">
|
|
|
- <el-col :span="22">
|
|
|
- <el-row :gutter="20" style="display: flex; flex-wrap: wrap">
|
|
|
- <el-col
|
|
|
- v-for="column in searchColumns"
|
|
|
- :key="column.title"
|
|
|
- :span="column.span || 6"
|
|
|
+ <el-row :gutter="20" style="display: flex; flex-wrap: wrap">
|
|
|
+ <el-col
|
|
|
+ v-for="column in searchColumns"
|
|
|
+ :key="column.title"
|
|
|
+ :span="column.span || 6"
|
|
|
+ >
|
|
|
+ <el-form-item :prop="column.key" :label="column.title">
|
|
|
+ <el-input
|
|
|
+ v-if="column.inputType === 'Input'"
|
|
|
+ v-model="params[column.key]"
|
|
|
+ :placeholder="column.placeholder"
|
|
|
+ style="width: 100%"
|
|
|
+ @keyup.enter.native="useQuery(params, page)"
|
|
|
+ ></el-input>
|
|
|
+ <el-select
|
|
|
+ v-if="column.inputType === 'Select'"
|
|
|
+ v-model="params[column.key]"
|
|
|
+ :disabled="column.disabled"
|
|
|
+ :clearable="column.clearable"
|
|
|
+ :placeholder="column.placeholder"
|
|
|
+ style="width: 100%"
|
|
|
+ @change="useQuery(params, page)"
|
|
|
+ @keyup.enter.native="useQuery(params, page)"
|
|
|
>
|
|
|
- <el-form-item :prop="column.key" :label="column.title">
|
|
|
- <el-input
|
|
|
- v-if="column.inputType === 'Input'"
|
|
|
- v-model="params[column.key]"
|
|
|
- :placeholder="column.placeholder"
|
|
|
- style="width: 100%"
|
|
|
- @keyup.enter.native="useQuery(params, page)"
|
|
|
- ></el-input>
|
|
|
- <el-select
|
|
|
- v-if="column.inputType === 'Select'"
|
|
|
- v-model="params[column.key]"
|
|
|
- :disabled="column.disabled"
|
|
|
- :clearable="column.clearable"
|
|
|
- :placeholder="column.placeholder"
|
|
|
- style="width: 100%"
|
|
|
- @change="useQuery(params, page)"
|
|
|
- @keyup.enter.native="useQuery(params, page)"
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="item in dict.type[column.referName]"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value"
|
|
|
- >
|
|
|
- </el-option>
|
|
|
- </el-select>
|
|
|
- <dr-popover-select
|
|
|
- v-if="column.inputType === 'PopoverSelect'"
|
|
|
- v-model="params[column.key]"
|
|
|
- :size="size"
|
|
|
- :source.sync="params"
|
|
|
- :title="column.title"
|
|
|
- :type="column.referName"
|
|
|
- :multiple="column.multiple"
|
|
|
- :readonly="column.readonly"
|
|
|
- :value-key="column.valueKey"
|
|
|
- :placeholder="column.placeholder"
|
|
|
- :data-mapping="column.dataMapping"
|
|
|
- @change="useQuery(params, page)"
|
|
|
- @keyup.enter.native="useQuery(params, page)"
|
|
|
- >
|
|
|
- </dr-popover-select>
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
- </el-row>
|
|
|
+ <el-option
|
|
|
+ v-for="item in dict.type[column.referName]"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ >
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ <dr-popover-select
|
|
|
+ v-if="column.inputType === 'PopoverSelect'"
|
|
|
+ v-model="params[column.key]"
|
|
|
+ :size="size"
|
|
|
+ :source.sync="params"
|
|
|
+ :title="column.title"
|
|
|
+ :type="column.referName"
|
|
|
+ :multiple="column.multiple"
|
|
|
+ :readonly="column.readonly"
|
|
|
+ :value-key="column.valueKey"
|
|
|
+ :placeholder="column.placeholder"
|
|
|
+ :data-mapping="column.dataMapping"
|
|
|
+ @change="useQuery(params, page)"
|
|
|
+ @keyup.enter.native="useQuery(params, page)"
|
|
|
+ >
|
|
|
+ </dr-popover-select>
|
|
|
+ </el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</el-form>
|
|
@@ -236,6 +222,7 @@ export default {
|
|
|
</el-button>
|
|
|
</el-row>
|
|
|
<el-table
|
|
|
+ v-if="tableData.length"
|
|
|
:size="size"
|
|
|
:data="tableData"
|
|
|
highlight-current-row
|
|
@@ -284,6 +271,7 @@ export default {
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
+ <el-empty v-else :image-size="200"></el-empty>
|
|
|
<pagination
|
|
|
:total="page.total"
|
|
|
:page.sync="page.pageNum"
|
|
@@ -292,3 +280,30 @@ export default {
|
|
|
/>
|
|
|
</el-card>
|
|
|
</template>
|
|
|
+<style scoped lang="scss">
|
|
|
+.el-card {
|
|
|
+ width: calc(100% - 20px);
|
|
|
+ height: 100%;
|
|
|
+ margin: 10px;
|
|
|
+ padding: 0 0 20px 0;
|
|
|
+ .el-form {
|
|
|
+ padding: 20px 0 0;
|
|
|
+ }
|
|
|
+ .el-row {
|
|
|
+ display: flex;
|
|
|
+ flex-wrap: wrap;
|
|
|
+ padding: 0 20px;
|
|
|
+ }
|
|
|
+ ::v-deep .el-table--mini {
|
|
|
+ width: 100%;
|
|
|
+ margin: 20px 0 0 0;
|
|
|
+ .el-table__cell {
|
|
|
+ height: 50px;
|
|
|
+ }
|
|
|
+ td.el-table__cell {
|
|
|
+ border-right: 0;
|
|
|
+ // border-bottom: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|