Explorar o código

commit to pull

miskson %!s(int64=3) %!d(string=hai) anos
pai
achega
c7c23af97d
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      hw9/script.js

+ 3 - 0
hw9/script.js

@@ -293,6 +293,8 @@ function Form(el, data, okCallback, cancelCallback){
 
 
     let checkInfo = (value, key, data, input, err) => {
+        console.log(this.initalData)
+        console.log(this.data)
         for(let key in this.validators) {
             if(key === 'isValid') continue;
             this.validators.isValid[key] = false
@@ -452,6 +454,7 @@ function Form(el, data, okCallback, cancelCallback){
     this.cancelCallback = cancelCallback
 
     this.data           = data
+    this.initalData = this.data    
     this.validators     = {isValid:{}}
 }