| | |
| | | plain
|
| | | icon="el-icon-refresh"
|
| | | size="mini"
|
| | | @click="handleClearCache"
|
| | | @click="handleRefreshCache"
|
| | | v-hasPermi="['system:dict:remove']"
|
| | | >清理缓存</el-button>
|
| | | >刷新缓存</el-button>
|
| | | </el-col>
|
| | | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
| | | </el-row>
|
| | |
| | | <el-table-column label="字典名称" align="center" prop="dictName" :show-overflow-tooltip="true" />
|
| | | <el-table-column label="字典类型" align="center" :show-overflow-tooltip="true">
|
| | | <template slot-scope="scope">
|
| | | <router-link :to="'/dict/type/data/' + scope.row.dictId" class="link-type">
|
| | | <router-link :to="'/system/dict-data/index/' + scope.row.dictId" class="link-type">
|
| | | <span>{{ scope.row.dictType }}</span>
|
| | | </router-link>
|
| | | </template>
|
| | | </el-table-column>
|
| | | <el-table-column label="状态" align="center" prop="status" :formatter="statusFormat" />
|
| | | <el-table-column label="状态" align="center" prop="status">
|
| | | <template slot-scope="scope">
|
| | | <dict-tag :options="statusOptions" :value="scope.row.status"/>
|
| | | </template>
|
| | | </el-table-column>
|
| | | <el-table-column label="备注" align="center" prop="remark" :show-overflow-tooltip="true" />
|
| | | <el-table-column label="创建时间" align="center" prop="createTime" width="180">
|
| | | <template slot-scope="scope">
|
| | |
| | | </template>
|
| | |
|
| | | <script>
|
| | | import { listType, getType, delType, addType, updateType, exportType, clearCache } from "@/api/system/dict/type";
|
| | | import { listType, getType, delType, addType, updateType, exportType, refreshCache } from "@/api/system/dict/type";
|
| | |
|
| | | export default {
|
| | | name: "Dict",
|
| | |
| | | this.loading = false;
|
| | | }
|
| | | );
|
| | | },
|
| | | // 字典状态字典翻译
|
| | | statusFormat(row, column) {
|
| | | return this.selectDictLabel(this.statusOptions, row.status);
|
| | | },
|
| | | // 取消按钮
|
| | | cancel() {
|
| | |
| | | }).then(() => {
|
| | | this.getList();
|
| | | this.msgSuccess("删除成功");
|
| | | })
|
| | | }).catch(() => {});
|
| | | },
|
| | | /** 导出按钮操作 */
|
| | | handleExport() {
|
| | |
| | | }).then(response => {
|
| | | this.download(response.msg);
|
| | | this.exportLoading = false;
|
| | | })
|
| | | }).catch(() => {});
|
| | | },
|
| | | /** 清理缓存按钮操作 */
|
| | | handleClearCache() {
|
| | | clearCache().then(response => {
|
| | | this.msgSuccess("清理成功");
|
| | | /** 刷新缓存按钮操作 */
|
| | | handleRefreshCache() {
|
| | | refreshCache().then(() => {
|
| | | this.msgSuccess("刷新成功");
|
| | | });
|
| | | }
|
| | | }
|