From 131a235d2e2bec6144c3eca7e406baf9fa699392 Mon Sep 17 00:00:00 2001 From: paidaxing444 <12qwaszx> Date: Thu, 28 May 2020 18:10:33 +0800 Subject: [PATCH] =?UTF-8?q?20200528-zlp-1=201=E5=B7=B2=E5=AE=8C=E5=96=84?= =?UTF-8?q?=E5=9F=B9=E8=AE=AD=E7=AE=A1=E7=90=86=E5=8A=9F=E8=83=BD=202?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=A4=9A=E7=BA=A7=E5=AD=97=E5=85=B8=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/main.js | 3 +- ruoyi-ui/src/utils/ruoyi.js | 12 ++ .../src/views/benyi_train/video/index.vue | 197 ++++++++++++------ .../project/common/CommonController.java | 2 +- .../controller/SysDictMoedataController.java | 92 ++++++++ .../project/system/domain/SysDictMoedata.java | 151 ++++++++++++++ .../system/mapper/SysDictMoedataMapper.java | 61 ++++++ .../service/ISysDictMoedataService.java | 61 ++++++ .../impl/SysDictMoedataServiceImpl.java | 95 +++++++++ .../mybatis/benyi/ByTrainVideoMapper.xml | 4 +- .../mybatis/system/SysDictMoedataMapper.xml | 91 ++++++++ 11 files changed, 697 insertions(+), 72 deletions(-) create mode 100644 ruoyi/src/main/java/com/ruoyi/project/system/controller/SysDictMoedataController.java create mode 100644 ruoyi/src/main/java/com/ruoyi/project/system/domain/SysDictMoedata.java create mode 100644 ruoyi/src/main/java/com/ruoyi/project/system/mapper/SysDictMoedataMapper.java create mode 100644 ruoyi/src/main/java/com/ruoyi/project/system/service/ISysDictMoedataService.java create mode 100644 ruoyi/src/main/java/com/ruoyi/project/system/service/impl/SysDictMoedataServiceImpl.java create mode 100644 ruoyi/src/main/resources/mybatis/system/SysDictMoedataMapper.xml diff --git a/ruoyi-ui/src/main.js b/ruoyi-ui/src/main.js index 6b3c53cf8..c955a87b6 100644 --- a/ruoyi-ui/src/main.js +++ b/ruoyi-ui/src/main.js @@ -18,7 +18,7 @@ import './assets/icons' // icon import './permission' // permission control import { getDicts } from "@/api/system/dict/data"; import { getConfigKey } from "@/api/system/config"; -import { parseTime, resetForm, addDateRange, selectDictLabel, download, handleTree } from "@/utils/ruoyi"; +import { parseTime, resetForm, addDateRange, selectDictLabel,selectMoeDictLabel, download, handleTree } from "@/utils/ruoyi"; import Pagination from "@/components/Pagination"; import Video from 'video.js' @@ -32,6 +32,7 @@ Vue.prototype.parseTime = parseTime Vue.prototype.resetForm = resetForm Vue.prototype.addDateRange = addDateRange Vue.prototype.selectDictLabel = selectDictLabel +Vue.prototype.selectMoeDictLabel = selectMoeDictLabel Vue.prototype.download = download Vue.prototype.handleTree = handleTree diff --git a/ruoyi-ui/src/utils/ruoyi.js b/ruoyi-ui/src/utils/ruoyi.js index dc18b9122..bbf4fb2ed 100644 --- a/ruoyi-ui/src/utils/ruoyi.js +++ b/ruoyi-ui/src/utils/ruoyi.js @@ -77,6 +77,18 @@ export function selectDictLabel(datas, value) { return actions.join(''); } +// 回显数据字典 +export function selectMoeDictLabel(datas, value) { + var actions = []; + Object.keys(datas).map((key) => { + if (datas[key].id == ('' + value)) { + actions.push(datas[key].name); + return false; + } + }) + return actions.join(''); +} + // 通用下载方法 export function download(fileName) { window.location.href = baseURL + "/common/download?fileName=" + encodeURI(fileName) + "&delete=" + true; diff --git a/ruoyi-ui/src/views/benyi_train/video/index.vue b/ruoyi-ui/src/views/benyi_train/video/index.vue index f5410f2cf..edfc3ff38 100644 --- a/ruoyi-ui/src/views/benyi_train/video/index.vue +++ b/ruoyi-ui/src/views/benyi_train/video/index.vue @@ -1,6 +1,15 @@