Commit eec5c58b4a8d118270bfedb87cf38ebcab6fcc39
1 parent
a34edef6
修改代码生成字典字段int类型没有自动选中问题
Showing
2 changed files
with
8 additions
and
4 deletions
ruoyi/src/main/resources/vm/vue/index-tree.vue.vm
| ... | ... | @@ -146,7 +146,8 @@ |
| 146 | 146 | v-for="dict in ${field}Options" |
| 147 | 147 | :key="dict.dictValue" |
| 148 | 148 | :label="dict.dictLabel" |
| 149 | - :value="dict.dictValue" | |
| 149 | + #if($column.javaType == "Integer"):value="parseInt(dict.dictValue)"#else:value="dict.dictValue"#end | |
| 150 | + | |
| 150 | 151 | ></el-option> |
| 151 | 152 | </el-select> |
| 152 | 153 | </el-form-item> |
| ... | ... | @@ -162,7 +163,8 @@ |
| 162 | 163 | <el-radio |
| 163 | 164 | v-for="dict in ${field}Options" |
| 164 | 165 | :key="dict.dictValue" |
| 165 | - :label="dict.dictValue" | |
| 166 | + #if($column.javaType == "Integer"):label="parseInt(dict.dictValue)"#else:label="dict.dictValue"#end | |
| 167 | + | |
| 166 | 168 | >{{dict.dictLabel}}</el-radio> |
| 167 | 169 | </el-radio-group> |
| 168 | 170 | </el-form-item> | ... | ... |
ruoyi/src/main/resources/vm/vue/index.vue.vm
| ... | ... | @@ -174,7 +174,8 @@ |
| 174 | 174 | v-for="dict in ${field}Options" |
| 175 | 175 | :key="dict.dictValue" |
| 176 | 176 | :label="dict.dictLabel" |
| 177 | - :value="dict.dictValue" | |
| 177 | + #if($column.javaType == "Integer"):value="parseInt(dict.dictValue)"#else:value="dict.dictValue"#end | |
| 178 | + | |
| 178 | 179 | ></el-option> |
| 179 | 180 | </el-select> |
| 180 | 181 | </el-form-item> |
| ... | ... | @@ -190,7 +191,8 @@ |
| 190 | 191 | <el-radio |
| 191 | 192 | v-for="dict in ${field}Options" |
| 192 | 193 | :key="dict.dictValue" |
| 193 | - :label="dict.dictValue" | |
| 194 | + #if($column.javaType == "Integer"):label="parseInt(dict.dictValue)"#else:label="dict.dictValue"#end | |
| 195 | + | |
| 194 | 196 | >{{dict.dictLabel}}</el-radio> |
| 195 | 197 | </el-radio-group> |
| 196 | 198 | </el-form-item> | ... | ... |