summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwangwenrui <[email protected]>2019-11-08 10:42:22 +0800
committerwangwenrui <[email protected]>2019-11-08 10:42:22 +0800
commit920e6f44d0840ea0a220ab4df7c386933c72c49d (patch)
tree6fde32754fd9fa83c1929b970d4a72f742ff71e6
parent507e579efc3d39ee590d36c1457990abe20be722 (diff)
update
-rw-r--r--nezha-admin/src/main/resources/templates/js/modules/detect/addType.js10
-rw-r--r--nezha-admin/src/main/resources/templates/js/modules/detect/deteWarn.js4
2 files changed, 10 insertions, 4 deletions
diff --git a/nezha-admin/src/main/resources/templates/js/modules/detect/addType.js b/nezha-admin/src/main/resources/templates/js/modules/detect/addType.js
index a25844fc..7d5ac3c4 100644
--- a/nezha-admin/src/main/resources/templates/js/modules/detect/addType.js
+++ b/nezha-admin/src/main/resources/templates/js/modules/detect/addType.js
@@ -764,7 +764,7 @@ var addType=Vue.extend({
},
initDeteType:function(){
var temp=this;
- temp.$v.deteType.$reset();
+ temp.resetType();
if(temp.typeId==null){
temp.isUpdate=false;
temp.deteType={
@@ -907,7 +907,7 @@ var addType=Vue.extend({
},
formatDeteTypeToSimple: function () {
var temp=this;
- temp.deteType.method=temp.deteType.method.code;
+ temp.deteType.method=temp.defaultMethod.code;
$.each(temp.deteType.deteTypeMetas, function (i, v) {
temp.deteType.deteTypeMetas[i].fieldType = v.fieldType.code;
temp.deteType.deteTypeMetas[i].dataType = v.dataType.code;
@@ -1156,6 +1156,12 @@ var addType=Vue.extend({
}
},
+ resetType:function(){
+ var temp=this;
+ temp.$v.deteType.$reset();
+ temp.metaDirty=false;
+ temp.paramDirty=false;
+ },
destoryUploadComponet:function(){
this.file=null;
this.acceptFile=".sh";
diff --git a/nezha-admin/src/main/resources/templates/js/modules/detect/deteWarn.js b/nezha-admin/src/main/resources/templates/js/modules/detect/deteWarn.js
index 228139e0..8aa83da2 100644
--- a/nezha-admin/src/main/resources/templates/js/modules/detect/deteWarn.js
+++ b/nezha-admin/src/main/resources/templates/js/modules/detect/deteWarn.js
@@ -578,8 +578,8 @@ var warnComponet = Vue.extend({
uploadComponet.touch();
warnScripError=uploadComponet.error;
}
- console.log(temp.$v.deteWarn.$error+"|"+uploadComponet)
- return temp.$v.deteWarn.$error||uploadComponet;
+ console.log(temp.$v.deteWarn.$error+"|"+warnScripError)
+ return temp.$v.deteWarn.$error||warnScripError;
},
formatDeteSetToSimple:function(){
var temp=this;