Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
RuoYi Vue
Commits
074b3c73
Commit
074b3c73
authored
Jan 05, 2021
by
RuoYi
Browse files
设置单图上传控件
parent
a118738d
Changes
2
Hide whitespace changes
Inline
Side-by-side
ruoyi-common/src/main/java/com/ruoyi/common/constant/GenConstants.java
View file @
074b3c73
...
...
@@ -76,8 +76,8 @@ public class GenConstants
/** 日期控件 */
public
static
final
String
HTML_DATETIME
=
"datetime"
;
/** 上传
控件
*/
public
static
final
String
HTML_
UPLOAD_IMAGE
=
"uploadImage
"
;
/**
单图
上传 */
public
static
final
String
HTML_
IMAGE_UPLOAD
=
"imageUpload
"
;
/** 富文本控件 */
public
static
final
String
HTML_EDITOR
=
"editor"
;
...
...
ruoyi-generator/src/main/java/com/ruoyi/generator/util/GenUtils.java
View file @
074b3c73
...
...
@@ -112,10 +112,10 @@ public class GenUtils
{
column
.
setHtmlType
(
GenConstants
.
HTML_SELECT
);
}
//
文件
字段设置
上传
控件
//
图片
字段设置
单图
控件
else
if
(
StringUtils
.
endsWithIgnoreCase
(
columnName
,
"image"
))
{
column
.
setHtmlType
(
GenConstants
.
HTML_UPLOAD
_IMAGE
);
column
.
setHtmlType
(
GenConstants
.
HTML_
IMAGE_
UPLOAD
);
}
// 内容字段设置富文本控件
else
if
(
StringUtils
.
endsWithIgnoreCase
(
columnName
,
"content"
))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment