Commit ca657b048275fbac4fd13e3c26808ad20e8ea128

Authored by fungleo
1 parent c1d1ace3

优化 index-tree.vue.vm 文件,undefined 修改为 null

ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
... ... @@ -253,7 +253,7 @@ export default {
253 253 queryParams: {
254 254 #foreach ($column in $columns)
255 255 #if($column.query)
256   - $column.javaField: undefined#if($velocityCount != $columns.size()),#end
  256 + $column.javaField: null#if($velocityCount != $columns.size()),#end
257 257  
258 258 #end
259 259 #end
... ... @@ -349,7 +349,7 @@ export default {
349 349 $column.javaField: []#if($velocityCount != $columns.size()),#end
350 350  
351 351 #else
352   - $column.javaField: undefined#if($velocityCount != $columns.size()),#end
  352 + $column.javaField: null#if($velocityCount != $columns.size()),#end
353 353  
354 354 #end
355 355 #end
... ... @@ -376,7 +376,7 @@ export default {
376 376 handleUpdate(row) {
377 377 this.reset();
378 378 this.getTreeselect();
379   - if (row != undefined) {
  379 + if (row != null) {
380 380 this.form.${treeParentCode} = row.${treeCode};
381 381 }
382 382 get${BusinessName}(row.${pkColumn.javaField}).then(response => {
... ... @@ -391,7 +391,7 @@ export default {
391 391 });
392 392 },
393 393 /** 提交按钮 */
394   - submitForm: function() {
  394 + submitForm() {
395 395 this.#[[$]]#refs["form"].validate(valid => {
396 396 if (valid) {
397 397 #foreach ($column in $columns)
... ... @@ -399,7 +399,7 @@ export default {
399 399 this.form.$column.javaField = this.form.${column.javaField}.join(",");
400 400 #end
401 401 #end
402   - if (this.form.${pkColumn.javaField} != undefined) {
  402 + if (this.form.${pkColumn.javaField} != null) {
403 403 update${BusinessName}(this.form).then(response => {
404 404 if (response.code === 200) {
405 405 this.msgSuccess("修改成功");
... ... @@ -434,4 +434,4 @@ export default {
434 434 }
435 435 }
436 436 };
437   -</script>
438 437 \ No newline at end of file
  438 +</script>
... ...