File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ define([
3333 this . config . checkModules = [ 'metrics' ] ;
3434
3535 this . state = {
36- modelType : 'rgs' ,
36+ modelType : 'rgs' , // rgs / clf / cls
3737 predictData : 'pred' ,
3838 targetData : 'y_test' ,
3939 // regression
@@ -156,35 +156,6 @@ define([
156156 } ) ;
157157 $ ( page ) . find ( '#targetData2' ) . replaceWith ( targetData2Selector . toTagString ( ) ) ;
158158
159- // load state
160- let that = this ;
161- Object . keys ( this . state ) . forEach ( key => {
162- let tag = $ ( page ) . find ( '#' + key ) ;
163- let tagName = $ ( tag ) . prop ( 'tagName' ) ; // returns with UpperCase
164- let value = that . state [ key ] ;
165- if ( value == undefined ) {
166- return ;
167- }
168- switch ( tagName ) {
169- case 'INPUT' :
170- let inputType = $ ( tag ) . prop ( 'type' ) ;
171- if ( inputType == 'text' || inputType == 'number' || inputType == 'hidden' ) {
172- $ ( tag ) . val ( value ) ;
173- break ;
174- }
175- if ( inputType == 'checkbox' ) {
176- $ ( tag ) . prop ( 'checked' , value ) ;
177- break ;
178- }
179- break ;
180- case 'TEXTAREA' :
181- case 'SELECT' :
182- default :
183- $ ( tag ) . val ( value ) ;
184- break ;
185- }
186- } ) ;
187-
188159 $ ( page ) . find ( '.vp-upper-box' ) . hide ( ) ;
189160 $ ( page ) . find ( '.vp-upper-box.' + this . state . modelType ) . show ( ) ;
190161
You can’t perform that action at this time.
0 commit comments