|
|
@@ -0,0 +1,269 @@
|
|
|
+<template>
|
|
|
+ <div>
|
|
|
+ <el-container>
|
|
|
+ <el-header>
|
|
|
+ <el-row type="flex" class="row-bg" justify="space-between">
|
|
|
+ <!-- 认证状态 -->
|
|
|
+ <div class="select-group appeal-conditions">
|
|
|
+ <slot name="screen-type"></slot>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!-- 搜索 -->
|
|
|
+ <div class="select-group search-conditions">
|
|
|
+ <el-row type="flex" class="row-bg">
|
|
|
+ <el-select v-model="commonKey" placeholder="请选择">
|
|
|
+ <el-option
|
|
|
+ v-for="item in searchKeys"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ <div class="input-group" style="width: 242px;margin-left: 5px;">
|
|
|
+ <input type="text" class="form-control search-keyword" title="keyword" v-model="commonKeyword">
|
|
|
+ <span class="input-group-btn">
|
|
|
+ <button class="btn btn-default btn-search" type="button" @click="() => $emit('search', commonKey, commonKeyword)">搜索</button>
|
|
|
+ </span>
|
|
|
+ </div>
|
|
|
+ </el-row>
|
|
|
+ </div>
|
|
|
+ </el-row>
|
|
|
+ </el-header>
|
|
|
+ <el-main>
|
|
|
+ <slot></slot>
|
|
|
+ </el-main>
|
|
|
+ <el-footer>
|
|
|
+ <el-row type="flex" class="row-bg">
|
|
|
+ <button
|
|
|
+ type="button"
|
|
|
+ class="btn btn-default btn-refresh"
|
|
|
+ @click="() => $emit('refresh-data')">
|
|
|
+ 刷新
|
|
|
+ </button>
|
|
|
+
|
|
|
+ <div class="pagination-area">
|
|
|
+ <el-pagination
|
|
|
+ background
|
|
|
+ layout="prev, pager, next"
|
|
|
+ prev-text="< 上一页"
|
|
|
+ next-text="下一页 >"
|
|
|
+ :page-size="pageSize"
|
|
|
+ :total="total"
|
|
|
+ @current-change="currentPage => $emit('current-change', currentPage)">
|
|
|
+ </el-pagination>
|
|
|
+ </div>
|
|
|
+ </el-row>
|
|
|
+ </el-footer>
|
|
|
+ </el-container>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+ export default {
|
|
|
+ name: 'common-home',
|
|
|
+ props: {
|
|
|
+ pageSize: Number,
|
|
|
+ total: Number,
|
|
|
+ searchKeys: Array,
|
|
|
+ searchKey: String,
|
|
|
+ searchKeyword: String
|
|
|
+ },
|
|
|
+ data () {
|
|
|
+ return {
|
|
|
+ commonKey: this.searchKey,
|
|
|
+ commonKeyword: this.searchKeyword
|
|
|
+ }
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ searchKey: function (value) {
|
|
|
+ this.commonKey = value
|
|
|
+ },
|
|
|
+ commonKey: function (value) {
|
|
|
+ this.$emit('update:searchKey', value)
|
|
|
+ },
|
|
|
+ searchKeyword: function (value) {
|
|
|
+ this.commonKeyword = value
|
|
|
+ },
|
|
|
+ commonKeyword: function (value) {
|
|
|
+ this.$emit('update:searchKeyword', value)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+</script>
|
|
|
+
|
|
|
+<style scoped>
|
|
|
+ .el-header {
|
|
|
+ height: 60px;
|
|
|
+ padding-right: 10px;
|
|
|
+ padding-left: 22px;
|
|
|
+ background-color: #E6EDF1;
|
|
|
+ justify-content: space-between;
|
|
|
+ }
|
|
|
+ .el-main {
|
|
|
+ height: 463px;
|
|
|
+ padding: 0;
|
|
|
+ }
|
|
|
+ .el-footer {
|
|
|
+ height: 64px;
|
|
|
+ background-color: #E8EDF1;
|
|
|
+ }
|
|
|
+ .select-group {
|
|
|
+ padding: 15px 0;
|
|
|
+ }
|
|
|
+ .input-group-btn:before{
|
|
|
+ content: '';
|
|
|
+ position: absolute;
|
|
|
+ top: 10px;
|
|
|
+ left: 0;
|
|
|
+ width: 1px;
|
|
|
+ height: 13px;
|
|
|
+ background: #D2D2D2;
|
|
|
+ z-index: 5;
|
|
|
+ }
|
|
|
+ .search-keyword {
|
|
|
+ width: 186px;
|
|
|
+ height: 32px;
|
|
|
+ border-radius: 0;
|
|
|
+ border-right-style: none;
|
|
|
+ box-shadow: none;
|
|
|
+ -webkit-box-shadow: none;
|
|
|
+ }
|
|
|
+ .search-keyword:focus,
|
|
|
+ .search-keyword:active,
|
|
|
+ .search-keyword:visited {
|
|
|
+ border-color: #CCCCCC;
|
|
|
+ }
|
|
|
+ .btn-search {
|
|
|
+ width: 58px;
|
|
|
+ height: 32px;
|
|
|
+ border-radius: 0;
|
|
|
+ border-left-style: none;
|
|
|
+ outline: none;
|
|
|
+ box-shadow: none;
|
|
|
+ -webkit-box-shadow: none;
|
|
|
+
|
|
|
+ color: #2281E1;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .btn-search:active,
|
|
|
+ .btn-search:hover,
|
|
|
+ .btn-search:focus,
|
|
|
+ .btn-search:visited {
|
|
|
+ outline: none;
|
|
|
+ background-color: #FFFFFF;
|
|
|
+ border-color: #CCCCCC;
|
|
|
+ }
|
|
|
+ .btn-refresh {
|
|
|
+ margin: 17px 0;
|
|
|
+ width: 50px;
|
|
|
+ height: 28px;
|
|
|
+ border-radius: 0;
|
|
|
+
|
|
|
+ color: #000000;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .pagination-area {
|
|
|
+ padding: 17px 0 17px 150px;
|
|
|
+ }
|
|
|
+</style>
|
|
|
+
|
|
|
+<style>
|
|
|
+ /* screen select */
|
|
|
+ .appeal-conditions div label {
|
|
|
+ margin: 0 14px 0 28px;
|
|
|
+ color: #000000;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .appeal-conditions div label:first-child {
|
|
|
+ margin-left: 0;
|
|
|
+ }
|
|
|
+ /* element ui */
|
|
|
+ .el-select .el-input .el-input__inner {
|
|
|
+ color: #505050;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-select .el-input input.el-input__inner::-webkit-input-placeholder {
|
|
|
+ color: #505050;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-select .el-input input.el-input__inner:-moz-placeholder {
|
|
|
+ color: #505050;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-select .el-input input.el-input__inner::-moz-placeholder {
|
|
|
+ color: #505050;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-select .el-input input.el-input__inner:-ms-input-placeholder {
|
|
|
+ color: #505050;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .appeal-conditions .el-input .el-input__inner {
|
|
|
+ height: 32px;
|
|
|
+ width: 100px;
|
|
|
+ border-radius: 0;
|
|
|
+ }
|
|
|
+ .search-conditions .el-input .el-input__inner {
|
|
|
+ height: 32px;
|
|
|
+ width: 120px;
|
|
|
+ border-radius: 0;
|
|
|
+ }
|
|
|
+ .el-pagination button, .el-pagination span:not([class*=suffix]) {
|
|
|
+ color: #000000;
|
|
|
+ font-weight: normal;
|
|
|
+ }
|
|
|
+ .el-pagination.is-background .btn-next, .el-pagination.is-background .btn-prev, .el-pagination.is-background .el-pager li {
|
|
|
+ font-weight: normal;
|
|
|
+ }
|
|
|
+ .el-pagination.is-background .el-pager li.active {
|
|
|
+ background-color: #303743;
|
|
|
+ color: #fff;
|
|
|
+ }
|
|
|
+ .el-table th.is-leaf:first-child {
|
|
|
+ padding-left: 40px;
|
|
|
+ }
|
|
|
+ .el-table--enable-row-transition .el-table__body td:first-child {
|
|
|
+ padding-left: 40px;
|
|
|
+ }
|
|
|
+ .el-table th>.cell {
|
|
|
+ color: #000000;
|
|
|
+ font-size: 13px;
|
|
|
+ font-weight: normal;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-table th {
|
|
|
+ padding: 9px 8px 8px;
|
|
|
+ }
|
|
|
+ .el-table--enable-row-hover .el-table__body tr:hover>td {
|
|
|
+ background-color: #D0E5F5;
|
|
|
+
|
|
|
+ color: #000000;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ /* striped row */
|
|
|
+ .el-table--enable-row-hover .el-table__body tr.el-table__row--striped:hover>td {
|
|
|
+ background-color: #D0E5F5;
|
|
|
+
|
|
|
+ color: #000000;
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-table td {
|
|
|
+ padding: 4px 0;
|
|
|
+
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: "Microsoft YaHei", sans-serif;
|
|
|
+ }
|
|
|
+ .el-table--striped .el-table__body tr.el-table__row--striped td {
|
|
|
+ background: #F4F4F4;
|
|
|
+ }
|
|
|
+</style>
|