v2.3 版本发布,详情查看版本说明
This commit is contained in:
@@ -6,8 +6,8 @@ eladmin 前端源码
|
|||||||
|
|
||||||
| | 后端源码 | 前端源码 |
|
| | 后端源码 | 前端源码 |
|
||||||
|--- |--- | --- |
|
|--- |--- | --- |
|
||||||
| github | https://github.com/elunez/eladmin | https://github.com/elunez/eladmin-qd |
|
| github | https://github.com/elunez/eladmin | https://github.com/elunez/eladmin-web |
|
||||||
| 码云 | https://gitee.com/elunez/eladmin | https://gitee.com/elunez/eladmin-qt |
|
| 码云 | https://gitee.com/elunez/eladmin | https://gitee.com/elunez/eladmin-web |
|
||||||
|
|
||||||
#### 开发文档
|
#### 开发文档
|
||||||
[https://docs.auauz.net/#/](https://docs.auauz.net/#/)
|
[https://docs.auauz.net/#/](https://docs.auauz.net/#/)
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "eladmin-web",
|
"name": "eladmin-web",
|
||||||
"version": "2.2.0",
|
"version": "2.3.0",
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"description": "eladmin 前端代码",
|
"description": "eladmin 前端代码",
|
||||||
"author": "jie <elunez@qq.com>",
|
"author": "jie <elunez@qq.com>",
|
||||||
|
|||||||
@@ -1,36 +1,23 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<div ref="editor" style="text-align:left;margin: 5px">
|
<div ref="editor" class="text"/>
|
||||||
<div v-html="editorContent"/>
|
|
||||||
</div>
|
|
||||||
<div style="margin: 12px 5px;font-size: 16px;font-weight: bold;color: #696969">HTML渲染如下:</div>
|
<div style="margin: 12px 5px;font-size: 16px;font-weight: bold;color: #696969">HTML渲染如下:</div>
|
||||||
<div class="editor-content" v-html="editorContent"/>
|
<div class="editor-content" v-html="editorContent"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { debounce } from 'lodash'
|
|
||||||
import { mapGetters } from 'vuex'
|
import { mapGetters } from 'vuex'
|
||||||
import E from 'wangeditor'
|
import E from 'wangeditor'
|
||||||
import { getToken } from '@/utils/auth'
|
import { getToken } from '@/utils/auth'
|
||||||
export default {
|
export default {
|
||||||
name: 'Editor',
|
name: 'Editor',
|
||||||
model: {
|
|
||||||
prop: 'value',
|
|
||||||
event: 'editorChange'
|
|
||||||
},
|
|
||||||
props: {
|
|
||||||
value: {
|
|
||||||
type: String,
|
|
||||||
default: () => ''
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
headers: {
|
headers: {
|
||||||
'Authorization': 'Bearer ' + getToken()
|
'Authorization': 'Bearer ' + getToken()
|
||||||
},
|
},
|
||||||
editorContent: this.value ||
|
editorContent:
|
||||||
`<h3 style="text-align: center;">欢迎使用 wangEditor 富文本编辑器!</h3>
|
`<h3 style="text-align: center;">欢迎使用 wangEditor 富文本编辑器!</h3>
|
||||||
<ul>
|
<ul>
|
||||||
<li>富文本中图片上传使用的是sm.ms图床,支持上传到七牛云:<a style="color: #42b983" target="_blank" href="https://sm.ms/">sm.ms</a></li>
|
<li>富文本中图片上传使用的是sm.ms图床,支持上传到七牛云:<a style="color: #42b983" target="_blank" href="https://sm.ms/">sm.ms</a></li>
|
||||||
@@ -51,11 +38,12 @@ export default {
|
|||||||
// 自定义文件名,不可修改,修改后会上传失败
|
// 自定义文件名,不可修改,修改后会上传失败
|
||||||
editor.customConfig.uploadFileName = 'file'
|
editor.customConfig.uploadFileName = 'file'
|
||||||
editor.customConfig.uploadImgServer = this.imagesUploadApi // 上传图片到服务器
|
editor.customConfig.uploadImgServer = this.imagesUploadApi // 上传图片到服务器
|
||||||
editor.customConfig.onblur = debounce(html => {
|
editor.customConfig.onchange = (html) => {
|
||||||
this.$emit('editorChange', html)
|
|
||||||
this.editorContent = html
|
this.editorContent = html
|
||||||
}, 1000)
|
}
|
||||||
editor.create()
|
editor.create()
|
||||||
|
// 初始化数据
|
||||||
|
editor.txt.html(this.editorContent)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@@ -64,4 +52,8 @@ export default {
|
|||||||
.editor-content{
|
.editor-content{
|
||||||
padding-left: 5px;
|
padding-left: 5px;
|
||||||
}
|
}
|
||||||
|
.text {
|
||||||
|
text-align:left;
|
||||||
|
margin: 5px
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -26,7 +26,7 @@
|
|||||||
<span>{{ parseTime(scope.row.loginTime) }}</span>
|
<span>{{ parseTime(scope.row.loginTime) }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="createTime" label="操作" width="100px">
|
<el-table-column prop="createTime" label="操作" width="100px" fixed="right">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-popover
|
<el-popover
|
||||||
v-permission="['admin']"
|
v-permission="['admin']"
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
</el-input>
|
</el-input>
|
||||||
</el-popover>
|
</el-popover>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-show="form.type.toString() === '1'" label="外链菜单">
|
<el-form-item v-show="form.type.toString() !== '2'" label="外链菜单">
|
||||||
<el-radio-group v-model="form.iframe" size="mini">
|
<el-radio-group v-model="form.iframe" size="mini">
|
||||||
<el-radio-button label="true">是</el-radio-button>
|
<el-radio-button label="true">是</el-radio-button>
|
||||||
<el-radio-button label="false">否</el-radio-button>
|
<el-radio-button label="false">否</el-radio-button>
|
||||||
@@ -33,10 +33,10 @@
|
|||||||
<el-radio-button label="false">否</el-radio-button>
|
<el-radio-button label="false">否</el-radio-button>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-show="form.type.toString() === '1'" label="菜单可见">
|
<el-form-item v-show="form.type.toString() !== '2'" label="菜单可见">
|
||||||
<el-radio-group v-model="form.hidden" size="mini">
|
<el-radio-group v-model="form.hidden" size="mini">
|
||||||
<el-radio-button label="true">是</el-radio-button>
|
<el-radio-button label="false">是</el-radio-button>
|
||||||
<el-radio-button label="false">否</el-radio-button>
|
<el-radio-button label="true">否</el-radio-button>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-show="form.type.toString() !== '2'" label="菜单标题" prop="name">
|
<el-form-item v-show="form.type.toString() !== '2'" label="菜单标题" prop="name">
|
||||||
|
|||||||
Reference in New Issue
Block a user