|
|
@@ -6,10 +6,14 @@
|
|
|
class="manage-root-contain-left"
|
|
|
:activeMenuIndex="activeMenuIndex"
|
|
|
></nav-menu>
|
|
|
- <div class="manage-root-contain-right personnel-manage-right">
|
|
|
+ <div
|
|
|
+ class="manage-root-contain-right personnel-manage-right"
|
|
|
+ :class="[isPhone ? 'manage-root-contain-right-phone' : '']"
|
|
|
+ >
|
|
|
<breadcrumb
|
|
|
:breadcrumbList="breadcrumbList"
|
|
|
class="breadcrumb-box"
|
|
|
+ :class="[isPhone ? 'breadcrumb-box-phone' : '']"
|
|
|
></breadcrumb>
|
|
|
<div class="personal-inner">
|
|
|
<!--<div class="common-title-box">
|
|
|
@@ -35,7 +39,7 @@
|
|
|
>
|
|
|
</div>
|
|
|
</div>-->
|
|
|
- <div class="tabs">
|
|
|
+ <div class="tabs" :style="{ paddingBottom: isPhone ? '0' : '' }">
|
|
|
<a
|
|
|
:class="[tabsIndex === 0 ? 'active' : '']"
|
|
|
@click="handleChangeTabs(0)"
|
|
|
@@ -56,8 +60,18 @@
|
|
|
@click="handleChangeTabs(3)"
|
|
|
>白名单</a
|
|
|
> -->
|
|
|
+ <span
|
|
|
+ v-if="isPhone"
|
|
|
+ @click="showSearch = !showSearch"
|
|
|
+ style="font-size: 14px"
|
|
|
+ >{{ showSearch ? "收起查询条件" : "展开查询条件" }}</span
|
|
|
+ >
|
|
|
</div>
|
|
|
- <div class="search">
|
|
|
+ <div
|
|
|
+ class="search"
|
|
|
+ v-if="showSearch"
|
|
|
+ :class="[isPhone ? 'search-phone' : '']"
|
|
|
+ >
|
|
|
<div class="search-box" v-if="tabsIndex !== 2">
|
|
|
<div class="search-item">
|
|
|
<label>搜索</label>
|
|
|
@@ -197,7 +211,7 @@
|
|
|
key="table"
|
|
|
@sort-change="handleSort"
|
|
|
:default-sort="dataSort"
|
|
|
- :max-height="tableHeight"
|
|
|
+ :max-height="isPhone ? 'auto' : tableHeight"
|
|
|
@selection-change="handleSelectionChange"
|
|
|
v-loading="tableLoading"
|
|
|
>
|
|
|
@@ -282,55 +296,95 @@
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column fixed="right" label="操作" width="140">
|
|
|
+ <el-table-column
|
|
|
+ fixed="right"
|
|
|
+ label="操作"
|
|
|
+ :width="isPhone ? '50' : '140'"
|
|
|
+ >
|
|
|
<template slot-scope="scope">
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleEdit(scope.row)"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="primary-btn"
|
|
|
- >
|
|
|
- 编辑
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleUp(scope.row, 'up')"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="primary-btn"
|
|
|
- v-if="scope.row.status === 0"
|
|
|
- >
|
|
|
- 开启
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleUp(scope.row, 'down')"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="red-btn"
|
|
|
- v-else-if="scope.row.status === 1"
|
|
|
- >
|
|
|
- 停用
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleDelete(scope.row)"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="red-btn"
|
|
|
- v-if="scope.row.status === 0"
|
|
|
- >
|
|
|
- 删除
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleMove(scope.row)"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="primary-btn"
|
|
|
- >
|
|
|
- 移动
|
|
|
- </el-button>
|
|
|
+ <el-dropdown trigger="click" v-if="isPhone">
|
|
|
+ <span class="el-dropdown-link">
|
|
|
+ <svg-icon
|
|
|
+ icon-class="operate"
|
|
|
+ class="el-dropdown-link"
|
|
|
+ ></svg-icon>
|
|
|
+ </span>
|
|
|
+ <el-dropdown-menu slot="dropdown">
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleEdit(scope.row)"
|
|
|
+ >编辑</el-dropdown-item
|
|
|
+ >
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleUp(scope.row, 'up')"
|
|
|
+ v-if="scope.row.status === 0"
|
|
|
+ >开启</el-dropdown-item
|
|
|
+ >
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleUp(scope.row, 'down')"
|
|
|
+ v-else-if="scope.row.status === 1"
|
|
|
+ >停用</el-dropdown-item
|
|
|
+ >
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleDelete(scope.row)"
|
|
|
+ v-if="scope.row.status === 0"
|
|
|
+ >删除</el-dropdown-item
|
|
|
+ >
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleMove(scope.row)"
|
|
|
+ >移动</el-dropdown-item
|
|
|
+ >
|
|
|
+ </el-dropdown-menu>
|
|
|
+ </el-dropdown>
|
|
|
+ <template v-else>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleEdit(scope.row)"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="primary-btn"
|
|
|
+ >
|
|
|
+ 编辑
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleUp(scope.row, 'up')"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="primary-btn"
|
|
|
+ v-if="scope.row.status === 0"
|
|
|
+ >
|
|
|
+ 开启
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleUp(scope.row, 'down')"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="red-btn"
|
|
|
+ v-else-if="scope.row.status === 1"
|
|
|
+ >
|
|
|
+ 停用
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleDelete(scope.row)"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="red-btn"
|
|
|
+ v-if="scope.row.status === 0"
|
|
|
+ >
|
|
|
+ 删除
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleMove(scope.row)"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="primary-btn"
|
|
|
+ >
|
|
|
+ 移动
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
<el-pagination
|
|
|
+ v-if="total_count"
|
|
|
key="pagination"
|
|
|
background
|
|
|
@size-change="
|
|
|
@@ -340,8 +394,14 @@
|
|
|
:current-page="pageNumber"
|
|
|
:page-sizes="[10, 20, 30, 40]"
|
|
|
:page-size="pageSize"
|
|
|
- layout="total, prev, pager, next, sizes, jumper"
|
|
|
+ :layout="
|
|
|
+ isPhone
|
|
|
+ ? 'total, prev, pager, next'
|
|
|
+ : 'total, prev, pager, next, sizes, jumper'
|
|
|
+ "
|
|
|
:total="total_count"
|
|
|
+ :small="isPhone"
|
|
|
+ :pager-count="isPhone ? 5 : 7"
|
|
|
>
|
|
|
</el-pagination>
|
|
|
</template>
|
|
|
@@ -350,7 +410,7 @@
|
|
|
class="search-table"
|
|
|
:data="tableData"
|
|
|
style="width: 100%"
|
|
|
- :max-height="tableHeight"
|
|
|
+ :max-height="isPhone ? 'auto' : tableHeight"
|
|
|
key="auditTable"
|
|
|
@sort-change="handleSort"
|
|
|
:default-sort="dataSorts"
|
|
|
@@ -455,45 +515,80 @@
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column fixed="right" label="操作" width="170">
|
|
|
+ <el-table-column
|
|
|
+ fixed="right"
|
|
|
+ label="操作"
|
|
|
+ :width="isPhone ? '50' : '170'"
|
|
|
+ >
|
|
|
<template slot-scope="scope">
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleLook(scope.row)"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="primary-btn"
|
|
|
- >
|
|
|
- 查看
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleAudit(scope.row, 'up')"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="primary-btn"
|
|
|
- >
|
|
|
- 同意
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleAudit(scope.row, 'down')"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="red-btn"
|
|
|
- v-if="scope.row.audit_status === 0"
|
|
|
- >
|
|
|
- 拒绝
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- @click.native.prevent="handleMove(scope.row)"
|
|
|
- type="text"
|
|
|
- size="small"
|
|
|
- class="primary-btn"
|
|
|
- >
|
|
|
- 移动
|
|
|
- </el-button>
|
|
|
+ <el-dropdown trigger="click" v-if="isPhone">
|
|
|
+ <span class="el-dropdown-link">
|
|
|
+ <svg-icon
|
|
|
+ icon-class="operate"
|
|
|
+ class="el-dropdown-link"
|
|
|
+ ></svg-icon>
|
|
|
+ </span>
|
|
|
+ <el-dropdown-menu slot="dropdown">
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleLook(scope.row)"
|
|
|
+ >查看</el-dropdown-item
|
|
|
+ >
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleAudit(scope.row, 'up')"
|
|
|
+ >同意</el-dropdown-item
|
|
|
+ >
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleAudit(scope.row, 'down')"
|
|
|
+ v-if="scope.row.audit_status === 0"
|
|
|
+ >拒绝</el-dropdown-item
|
|
|
+ >
|
|
|
+
|
|
|
+ <el-dropdown-item
|
|
|
+ @click.native.prevent="handleMove(scope.row)"
|
|
|
+ >移动</el-dropdown-item
|
|
|
+ >
|
|
|
+ </el-dropdown-menu>
|
|
|
+ </el-dropdown>
|
|
|
+ <template v-else>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleLook(scope.row)"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="primary-btn"
|
|
|
+ >
|
|
|
+ 查看
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleAudit(scope.row, 'up')"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="primary-btn"
|
|
|
+ >
|
|
|
+ 同意
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleAudit(scope.row, 'down')"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="red-btn"
|
|
|
+ v-if="scope.row.audit_status === 0"
|
|
|
+ >
|
|
|
+ 拒绝
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ @click.native.prevent="handleMove(scope.row)"
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ class="primary-btn"
|
|
|
+ >
|
|
|
+ 移动
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
<el-pagination
|
|
|
+ v-if="total_count"
|
|
|
background
|
|
|
key="auditpagination"
|
|
|
@size-change="
|
|
|
@@ -503,125 +598,14 @@
|
|
|
:current-page="pageNumbers"
|
|
|
:page-sizes="[10, 20, 30, 40]"
|
|
|
:page-size="pageSizes"
|
|
|
- layout="total, prev, pager, next, sizes, jumper"
|
|
|
- :total="total_count"
|
|
|
- >
|
|
|
- </el-pagination>
|
|
|
- </template>
|
|
|
- <template v-if="tabsIndex === 2">
|
|
|
- <el-table
|
|
|
- :data="tableData"
|
|
|
- v-loading="tableLoading"
|
|
|
- :max-height="tableHeight"
|
|
|
- style="width: 100%"
|
|
|
- key="2"
|
|
|
- >
|
|
|
- <el-table-column type="expand">
|
|
|
- <template slot-scope="props">
|
|
|
- <el-form
|
|
|
- label-position="left"
|
|
|
- inline
|
|
|
- class="demo-table-expand"
|
|
|
- >
|
|
|
- <el-form-item>
|
|
|
- <h3 class="content-title">兑换内容</h3>
|
|
|
- <div
|
|
|
- class="content-list"
|
|
|
- v-for="(itemC, indexC) in props.row.goods_list"
|
|
|
- :key="indexC"
|
|
|
- >
|
|
|
- <span>{{ indexC + 1 + "." }}</span>
|
|
|
- <b>{{ itemC.goods_name }}</b>
|
|
|
- </div>
|
|
|
- </el-form-item>
|
|
|
- </el-form>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- type="index"
|
|
|
- label="#"
|
|
|
- sortable
|
|
|
- width="54"
|
|
|
- :index="(pageNumber - 1) * pageSize + 1"
|
|
|
- >
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- label="名称"
|
|
|
- prop="discount_code_name"
|
|
|
- width="300"
|
|
|
- >
|
|
|
- </el-table-column>
|
|
|
- <el-table-column label="兑换码" prop="discount_code" width="300">
|
|
|
- </el-table-column>
|
|
|
- <el-table-column label="绑定时间" prop="bind_time">
|
|
|
- </el-table-column>
|
|
|
- <el-table-column prop="use_status" label="状态" width="116">
|
|
|
- <template slot-scope="scope">
|
|
|
- <div
|
|
|
- class="status-box"
|
|
|
- v-if="codeStatusList[scope.row.use_status]"
|
|
|
- >
|
|
|
- <span
|
|
|
- :style="{
|
|
|
- background: codeStatusList[scope.row.use_status].color,
|
|
|
- }"
|
|
|
- ></span>
|
|
|
- <b
|
|
|
- :style="{
|
|
|
- color: codeStatusList[scope.row.use_status].color,
|
|
|
- }"
|
|
|
- >{{ codeStatusList[scope.row.use_status].text }}</b
|
|
|
- >
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- </el-table>
|
|
|
- <el-pagination
|
|
|
- background
|
|
|
- key="2"
|
|
|
- @size-change="
|
|
|
- (val) => handleSizeChange(val, 'pageSizeD', 'pageNumberD')
|
|
|
- "
|
|
|
- @current-change="(val) => handleCurrentChange(val, 'pageNumberD')"
|
|
|
- :current-page="pageNumberD"
|
|
|
- :page-sizes="[10, 20, 30, 40]"
|
|
|
- :page-size="pageSizes"
|
|
|
- layout="total, prev, pager, next, sizes, jumper"
|
|
|
- :total="total_count"
|
|
|
- >
|
|
|
- </el-pagination>
|
|
|
- </template>
|
|
|
- <template v-if="tabsIndex === 3">
|
|
|
- <el-table
|
|
|
- class="search-table"
|
|
|
- :data="tableData"
|
|
|
- style="width: 100%"
|
|
|
- :max-height="tableHeight"
|
|
|
- key="3"
|
|
|
- @sort-change="handleSort"
|
|
|
- :default-sort="dataSorts"
|
|
|
- v-loading="tableLoading"
|
|
|
- >
|
|
|
- <el-table-column
|
|
|
- prop="real_name"
|
|
|
- label="真实姓名"
|
|
|
- sortable="custom"
|
|
|
- >
|
|
|
- </el-table-column>
|
|
|
- <el-table-column prop="phone" label="手机号"> </el-table-column>
|
|
|
- </el-table>
|
|
|
- <el-pagination
|
|
|
- background
|
|
|
- key="3"
|
|
|
- @size-change="
|
|
|
- (val) => handleSizeChange(val, 'pageSizeW', 'pageNumberW')
|
|
|
+ :layout="
|
|
|
+ isPhone
|
|
|
+ ? 'total, prev, pager, next'
|
|
|
+ : 'total, prev, pager, next, sizes, jumper'
|
|
|
"
|
|
|
- @current-change="(val) => handleCurrentChange(val, 'pageNumberW')"
|
|
|
- :current-page="pageNumberW"
|
|
|
- :page-sizes="[10, 20, 30, 40]"
|
|
|
- :page-size="pageSizes"
|
|
|
- layout="total, prev, pager, next, sizes, jumper"
|
|
|
:total="total_count"
|
|
|
+ :small="isPhone"
|
|
|
+ :pager-count="isPhone ? 5 : 7"
|
|
|
>
|
|
|
</el-pagination>
|
|
|
</template>
|
|
|
@@ -633,7 +617,7 @@
|
|
|
:show-close="false"
|
|
|
:close-on-click-modal="false"
|
|
|
:modal-append-to-body="false"
|
|
|
- width="398px"
|
|
|
+ :width="isPhone ? '100%' : '398px'"
|
|
|
class="login-dialog person-dialog"
|
|
|
v-if="importFlag"
|
|
|
>
|
|
|
@@ -646,7 +630,7 @@
|
|
|
<!-- 移动 -->
|
|
|
<el-dialog
|
|
|
:visible.sync="sourceMoveFlag"
|
|
|
- width="500px"
|
|
|
+ :width="isPhone ? '100%' : '500px'"
|
|
|
append-to-body
|
|
|
:show-close="true"
|
|
|
title="移动人员"
|
|
|
@@ -826,6 +810,8 @@ export default {
|
|
|
btnLoading: false,
|
|
|
select_sources_id: "",
|
|
|
orgList: [],
|
|
|
+ isPhone: false,
|
|
|
+ showSearch: true,
|
|
|
};
|
|
|
},
|
|
|
//计算属性 类似于data概念
|
|
|
@@ -1238,9 +1224,17 @@ export default {
|
|
|
})
|
|
|
.catch(() => {});
|
|
|
},
|
|
|
+ handleCommand(command) {
|
|
|
+ this.$message(command);
|
|
|
+ },
|
|
|
},
|
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
|
created() {
|
|
|
+ const regExp = /Android|webOS|iPhone|BlackBerry|IEMobile|Opera Mini/i;
|
|
|
+ this.isPhone = regExp.test(navigator.userAgent) && window.innerWidth < 860;
|
|
|
+ if (this.isPhone) {
|
|
|
+ this.showSearch = false;
|
|
|
+ }
|
|
|
this.getTableHeight();
|
|
|
this.getList();
|
|
|
this.getOrgList();
|
|
|
@@ -1276,6 +1270,7 @@ export default {
|
|
|
.tabs {
|
|
|
display: flex;
|
|
|
padding-bottom: 16px;
|
|
|
+ align-items: center;
|
|
|
a {
|
|
|
font-size: 14px;
|
|
|
line-height: 22px;
|
|
|
@@ -1297,6 +1292,19 @@ export default {
|
|
|
display: flex;
|
|
|
justify-content: space-between;
|
|
|
align-items: flex-end;
|
|
|
+ &-phone {
|
|
|
+ display: block;
|
|
|
+ .search-right {
|
|
|
+ display: flex;
|
|
|
+ gap: 10px;
|
|
|
+ flex-flow: wrap;
|
|
|
+ height: auto;
|
|
|
+ .el-button + .el-button,
|
|
|
+ .el-checkbox.is-bordered + .el-checkbox.is-bordered {
|
|
|
+ margin-left: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
.search-box {
|
|
|
padding-top: 0;
|
|
|
@@ -1386,6 +1394,17 @@ export default {
|
|
|
.search-table {
|
|
|
margin-top: 20px !important;
|
|
|
}
|
|
|
+.manage-root-contain-right-phone {
|
|
|
+ .personal-inner {
|
|
|
+ min-height: calc(100vh - 124px);
|
|
|
+ height: auto;
|
|
|
+ }
|
|
|
+}
|
|
|
+:deep .el-dialog {
|
|
|
+ .el-input {
|
|
|
+ width: auto;
|
|
|
+ }
|
|
|
+}
|
|
|
</style>
|
|
|
<style lang="scss">
|
|
|
.organize-manage {
|