Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
sts网站
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liyang
sts网站
Commits
64f6a69d
Commit
64f6a69d
authored
Nov 25, 2021
by
Ricky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复代码生成复选框字典遗漏问题
parent
16734b1d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
1 deletion
+10
-1
VelocityUtils.java
...src/main/java/com/ruoyi/generator/util/VelocityUtils.java
+2
-1
index-tree.vue.vm
ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
+4
-0
index.vue.vm
ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
+4
-0
No files found.
ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityUtils.java
View file @
64f6a69d
...
...
@@ -274,7 +274,8 @@ public class VelocityUtils
for
(
GenTableColumn
column
:
columns
)
{
if
(!
column
.
isSuperColumn
()
&&
StringUtils
.
isNotEmpty
(
column
.
getDictType
())
&&
StringUtils
.
equalsAny
(
column
.
getHtmlType
(),
new
String
[]
{
GenConstants
.
HTML_SELECT
,
GenConstants
.
HTML_RADIO
}))
column
.
getHtmlType
(),
new
String
[]
{
GenConstants
.
HTML_SELECT
,
GenConstants
.
HTML_RADIO
,
GenConstants
.
HTML_CHECKBOX
}))
{
dicts
.
add
(
"'"
+
column
.
getDictType
()
+
"'"
);
}
...
...
ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
View file @
64f6a69d
...
...
@@ -108,7 +108,11 @@
#elseif($column.list && "" != $column.dictType)
<el-table-column label="${comment}" align="center" prop="${javaField}">
<template slot-scope="scope">
#if($column.htmlType == "checkbox")
<dict-tag :options="dict.type.${column.dictType}" :value="scope.row.${javaField} ? scope.row.${javaField}.split(',') : []"/>
#else
<dict-tag :options="dict.type.${column.dictType}" :value="scope.row.${javaField}"/>
#end
</template>
</el-table-column>
#elseif($column.list && "" != $javaField)
...
...
ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
View file @
64f6a69d
...
...
@@ -136,7 +136,11 @@
#elseif($column.list && "" != $column.dictType)
<el-table-column label="${comment}" align="center" prop="${javaField}">
<template slot-scope="scope">
#if($column.htmlType == "checkbox")
<dict-tag :options="dict.type.${column.dictType}" :value="scope.row.${javaField} ? scope.row.${javaField}.split(',') : []"/>
#else
<dict-tag :options="dict.type.${column.dictType}" :value="scope.row.${javaField}"/>
#end
</template>
</el-table-column>
#elseif($column.list && "" != $javaField)
...
...
Write
Preview
Markdown
is supported
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