Commit 6a449df815cd600ffa9a52cebe47d2962b336414
1 parent
cdf22cdd
Exists in
master
and in
109 other branches
message format
Showing
2 changed files
with
37 additions
and
37 deletions
Show diff stats
js/app/AmdaApp.js
@@ -590,15 +590,14 @@ Ext.define('amdaApp.AmdaApp', { | @@ -590,15 +590,14 @@ Ext.define('amdaApp.AmdaApp', { | ||
590 | 590 | ||
591 | if (isMigration) { // isSpecialInfo | 591 | if (isMigration) { // isSpecialInfo |
592 | myDesktopApp.getLoadedModule(myDesktopApp.dynamicModules.info.id, true, function(module) { | 592 | myDesktopApp.getLoadedModule(myDesktopApp.dynamicModules.info.id, true, function(module) { |
593 | - module.createWindow(isSpecialInfo, 'Welcome on AMDA', true); | ||
594 | - var win = myDesktopApp.getDesktop().getWindow(myDesktopApp.dynamicModules.info.id); | ||
595 | - | 593 | + module.createWindow(isSpecialInfo, 'Welcome on AMDA', true); |
596 | if ( isOldWS ) { | 594 | if ( isOldWS ) { |
595 | + var win = myDesktopApp.getDesktop().getWindow(myDesktopApp.dynamicModules.info.id); | ||
597 | win.on({ | 596 | win.on({ |
598 | show : function() { | 597 | show : function() { |
599 | Ext.Msg.show({ | 598 | Ext.Msg.show({ |
600 | title:'Welcome on new AMDA', | 599 | title:'Welcome on new AMDA', |
601 | - msg: 'It is your first visit of the new version of AMDA.<br/>'+ | 600 | + msg: 'It is your first visit on the new version of AMDA.<br/>'+ |
602 | 'Do you want to copy here your workspace from the old AMDA ?', | 601 | 'Do you want to copy here your workspace from the old AMDA ?', |
603 | buttons: Ext.Msg.YESNO, | 602 | buttons: Ext.Msg.YESNO, |
604 | icon: Ext.Msg.QUESTION, | 603 | icon: Ext.Msg.QUESTION, |
@@ -611,9 +610,7 @@ Ext.define('amdaApp.AmdaApp', { | @@ -611,9 +610,7 @@ Ext.define('amdaApp.AmdaApp', { | ||
611 | loadMask.hide(); | 610 | loadMask.hide(); |
612 | 611 | ||
613 | if (res.success == true) { | 612 | if (res.success == true) { |
614 | - myDesktopApp.infoMsg('<b>Your Wokspace has been copied</b><br/><br/> ' + | ||
615 | - '<b>Note : </b><br/><br> Plot Requests have not been copied - too many modifs!<br/>' + | ||
616 | - 'Derived params made from Remote params have not been copied<br/><br/>' + res.msg); | 613 | + myDesktopApp.infoMsg('<b>Your Wokspace has been copied to new AMDA</b><br/><br/> ' + res.msg); |
617 | } | 614 | } |
618 | else { | 615 | else { |
619 | myDesktopApp.errorMsg(res.error); | 616 | myDesktopApp.errorMsg(res.error); |
php/classes/UserWsTransfer.php
@@ -187,11 +187,11 @@ class UserWsTransfer { | @@ -187,11 +187,11 @@ class UserWsTransfer { | ||
187 | 187 | ||
188 | public function transferDerived() | 188 | public function transferDerived() |
189 | { | 189 | { |
190 | - $msg = '<b>WS (Derived) Params:</b><br/>'; | ||
191 | - | 190 | + $msg = '<br/><b><i>Derived Params:</i></b><br/><br/>'; |
191 | + $msg .= '<i>Note</i> : Parameters made from Remote Base parameters are not copied <br/><br/>'; | ||
192 | if (!$this->oldWs->load($this->oldWsDir.'WsParams.xml')) { | 192 | if (!$this->oldWs->load($this->oldWsDir.'WsParams.xml')) { |
193 | error_log('cannot load WsParams.xml for '.TRANSFERUSER,1,email); | 193 | error_log('cannot load WsParams.xml for '.TRANSFERUSER,1,email); |
194 | - return array('success' => false, 'error' => 'Sorry, we failed to get your WsParams from old AMDA'); | 194 | + return array('success' => false, 'error' => 'Sorry, we failed to get your Derived Params from old AMDA'); |
195 | } | 195 | } |
196 | 196 | ||
197 | if (!file_exists($this->newWsDir.'WsParams.xml')) | 197 | if (!file_exists($this->newWsDir.'WsParams.xml')) |
@@ -212,7 +212,7 @@ class UserWsTransfer { | @@ -212,7 +212,7 @@ class UserWsTransfer { | ||
212 | } | 212 | } |
213 | 213 | ||
214 | $paramXml = new DomDocument("1.0"); | 214 | $paramXml = new DomDocument("1.0"); |
215 | - $msg .= '<b>Not copied :</b><br/>'; | 215 | + $msg .= 'Not copied derived parameters :<br/>'; |
216 | 216 | ||
217 | foreach ($wsParamsOld as $param) { | 217 | foreach ($wsParamsOld as $param) { |
218 | $id = $param->getAttribute('xml:id'); | 218 | $id = $param->getAttribute('xml:id'); |
@@ -221,21 +221,21 @@ class UserWsTransfer { | @@ -221,21 +221,21 @@ class UserWsTransfer { | ||
221 | $expression = $param->getAttribute('buildchain'); | 221 | $expression = $param->getAttribute('buildchain'); |
222 | 222 | ||
223 | if ($this->deleteParam($expression,$deleted)) { | 223 | if ($this->deleteParam($expression,$deleted)) { |
224 | - $msg .= '<b>'.$name.'</b> : obsolete <br/> '.$expression.'<br/>'; | 224 | + $msg .= '<li><i>'.$name.'</i> : uses obsolete param<br/> '.$expression.'<br/>'; |
225 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 225 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
226 | $this->ws_deleted[] = $name; | 226 | $this->ws_deleted[] = $name; |
227 | continue; | 227 | continue; |
228 | } | 228 | } |
229 | 229 | ||
230 | if ($this->deleteParam($expression,$notready)) { | 230 | if ($this->deleteParam($expression,$notready)) { |
231 | - $msg .= '<b>'.$name.'</b> : not ready yet <br/> '.$expression.'<br/>'; | 231 | + $msg .= '<li><i>'.$name.'</i> : uses param not ready yet <br/> '.$expression.'<br/>'; |
232 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 232 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
233 | $this->ws_deleted[] = $name; | 233 | $this->ws_deleted[] = $name; |
234 | continue; | 234 | continue; |
235 | } | 235 | } |
236 | 236 | ||
237 | if ($this->deleteParam($expression,$notreadyFunctions)) { | 237 | if ($this->deleteParam($expression,$notreadyFunctions)) { |
238 | - $msg .= '<b>'.$name.'</b> : function not ready yet <br/> '.$expression.'<br/>'; | 238 | + $msg .= '<li><i>'.$name.'</i> : uses function not ready yet <br/> '.$expression.'<br/>'; |
239 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 239 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
240 | $this->ws_deleted[] = $name; | 240 | $this->ws_deleted[] = $name; |
241 | continue; | 241 | continue; |
@@ -243,14 +243,14 @@ class UserWsTransfer { | @@ -243,14 +243,14 @@ class UserWsTransfer { | ||
243 | 243 | ||
244 | if (!empty($this->wsd_deleted)) | 244 | if (!empty($this->wsd_deleted)) |
245 | if ($this->deleteParam($expression,$this->wsd_deleted)) { | 245 | if ($this->deleteParam($expression,$this->wsd_deleted)) { |
246 | - $msg .= '<b>'.$name.'</b> : uses obsolete myData param<br/> '.$expression.'<br/>'; | 246 | + $msg .= '<li><i>'.$name.'</i> : uses obsolete myData param<br/> '.$expression.'<br/>'; |
247 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 247 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
248 | $this->ws_deleted[] = $name; | 248 | $this->ws_deleted[] = $name; |
249 | continue; | 249 | continue; |
250 | } | 250 | } |
251 | 251 | ||
252 | if ($this->deleteParam($expression,array("CDAWEB","MAPSKP","VEXGRAZ","IMPEX"))) { | 252 | if ($this->deleteParam($expression,array("CDAWEB","MAPSKP","VEXGRAZ","IMPEX"))) { |
253 | - $msg .= '<b>'.$name.'</b> : uses remote params <br/> '.$expression.'<br/>'; | 253 | + $msg .= '<li><i>'.$name.'</i> : uses remote params <br/> '.$expression.'<br/>'; |
254 | $this->ws_deleted[] = $name; | 254 | $this->ws_deleted[] = $name; |
255 | continue; | 255 | continue; |
256 | } | 256 | } |
@@ -281,7 +281,7 @@ class UserWsTransfer { | @@ -281,7 +281,7 @@ class UserWsTransfer { | ||
281 | unlink($this->newWsDir.$id.'.xml'); | 281 | unlink($this->newWsDir.$id.'.xml'); |
282 | $paramsToRemove[] = $param; | 282 | $paramsToRemove[] = $param; |
283 | $this->ws_deleted[] = $name; | 283 | $this->ws_deleted[] = $name; |
284 | - $msg .= '<b>'.$name.'</b> : uses obsolete / not ready ws param : <br/> '.$expression.'<br/>'; | 284 | + $msg .= '<li><i>'.$name.'</i> : uses obsolete / not ready ws param : <br/> '.$expression.'<br/>'; |
285 | } | 285 | } |
286 | } | 286 | } |
287 | } | 287 | } |
@@ -294,13 +294,13 @@ class UserWsTransfer { | @@ -294,13 +294,13 @@ class UserWsTransfer { | ||
294 | $this->newWs->save($this->newWsDir.'WsParams.xml'); | 294 | $this->newWs->save($this->newWsDir.'WsParams.xml'); |
295 | $copied = $newParams->length - count($paramsToRemove); | 295 | $copied = $newParams->length - count($paramsToRemove); |
296 | 296 | ||
297 | - $msg .= '<br/><b>Copied : </b>'.$copied.' derived parameters<br/><br/>'; | 297 | + $msg .= '<br/><i>Copied : </i>'.$copied.' derived parameters<br/><br/>'; |
298 | return array('success' => true, 'msg' => $msg); | 298 | return array('success' => true, 'msg' => $msg); |
299 | } | 299 | } |
300 | 300 | ||
301 | public function transferTimeTables() | 301 | public function transferTimeTables() |
302 | { | 302 | { |
303 | - $msg = '<b>Time Tables:</b><br/>'; | 303 | + $msg = '<b><i>Time Tables:</i></b><br/><br/>'; |
304 | 304 | ||
305 | // get old time tab list | 305 | // get old time tab list |
306 | $this->newWs->load($this->oldWsDir.'Tt.xml'); | 306 | $this->newWs->load($this->oldWsDir.'Tt.xml'); |
@@ -318,19 +318,19 @@ class UserWsTransfer { | @@ -318,19 +318,19 @@ class UserWsTransfer { | ||
318 | } | 318 | } |
319 | 319 | ||
320 | $this->newWs->save($this->newWsDir.'Tt.xml'); | 320 | $this->newWs->save($this->newWsDir.'Tt.xml'); |
321 | - $msg .= '<b>Copied : </b>'.$timeTabs->length.' time tables<br/><br/>'; | 321 | + $msg .= '<i>Copied : </i>'.$timeTabs->length.' time tables<br/><br/>'; |
322 | return array('success' => true, 'msg' => $msg); | 322 | return array('success' => true, 'msg' => $msg); |
323 | } | 323 | } |
324 | 324 | ||
325 | public function transferConditions() | 325 | public function transferConditions() |
326 | { | 326 | { |
327 | - $msg = '<b>DataMining Requests</b><br/>'; | ||
328 | - | 327 | + $msg = '<b><i>Requests</i></b><br/><br/>'; |
328 | + $msg .= '<i>Note :</i> Plot requests are not copied : too much difference new-old AMDA<br/<br/><br/>'; | ||
329 | $oldRequestXml = new DomDocument("1.0"); | 329 | $oldRequestXml = new DomDocument("1.0"); |
330 | $newRequestXml = new DomDocument("1.0"); | 330 | $newRequestXml = new DomDocument("1.0"); |
331 | 331 | ||
332 | if (!$oldRequestXml->load($this->oldWsDir.'Request.xml')){ | 332 | if (!$oldRequestXml->load($this->oldWsDir.'Request.xml')){ |
333 | - $msg .= ' cannot copy<br/>'; | 333 | + $msg .= ' No Requests File<br/>'; |
334 | return array('success' => true, 'msg' => $msg); | 334 | return array('success' => true, 'msg' => $msg); |
335 | } | 335 | } |
336 | 336 | ||
@@ -346,6 +346,7 @@ class UserWsTransfer { | @@ -346,6 +346,7 @@ class UserWsTransfer { | ||
346 | 346 | ||
347 | $deleted = $this->getObsolete(); | 347 | $deleted = $this->getObsolete(); |
348 | $notready = $this->getNotready(); | 348 | $notready = $this->getNotready(); |
349 | + $msg .= 'Not copied DataMining requests :<br/>'; | ||
349 | 350 | ||
350 | foreach ($condNodes as $condNode) { | 351 | foreach ($condNodes as $condNode) { |
351 | $id = $condNode->getAttribute('xml:id'); | 352 | $id = $condNode->getAttribute('xml:id'); |
@@ -355,13 +356,13 @@ class UserWsTransfer { | @@ -355,13 +356,13 @@ class UserWsTransfer { | ||
355 | $condObj = json_decode($cond[0]); | 356 | $condObj = json_decode($cond[0]); |
356 | $expression = $condObj->expression; | 357 | $expression = $condObj->expression; |
357 | if ($this->deleteParam($expression, $deleted)) { | 358 | if ($this->deleteParam($expression, $deleted)) { |
358 | - $msg .= '<b>'.$name.'</b> : obsolete <br/> '.$expression.'<br/>'; | 359 | + $msg .= '<li><i>'.$name.'</i> : uses obsolete param<br/> '.$expression.'<br/>'; |
359 | $cond_deleted[] = $name; | 360 | $cond_deleted[] = $name; |
360 | continue; | 361 | continue; |
361 | } | 362 | } |
362 | 363 | ||
363 | if ($this->deleteParam($expression,$notready)) { | 364 | if ($this->deleteParam($expression,$notready)) { |
364 | - $msg .= '<b>'.$name.'</b> : not ready yet <br/> '.$expression.'<br/>'; | 365 | + $msg .= '<li><i>'.$name.'</i> : uses param not ready yet<br/> '.$expression.'<br/>'; |
365 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 366 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
366 | $cond_deleted[] = $name; | 367 | $cond_deleted[] = $name; |
367 | continue; | 368 | continue; |
@@ -369,7 +370,7 @@ class UserWsTransfer { | @@ -369,7 +370,7 @@ class UserWsTransfer { | ||
369 | 370 | ||
370 | if (!empty($this->wsd_deleted)) | 371 | if (!empty($this->wsd_deleted)) |
371 | if ($this->deleteParam($expression,$this->wsd_deleted)) { | 372 | if ($this->deleteParam($expression,$this->wsd_deleted)) { |
372 | - $msg .= '<b>'.$name.'</b> : uses obsolete myData param<br/> '.$expression.'<br/>'; | 373 | + $msg .= '<li><i>'.$name.'</i> : uses obsolete myData param<br/> '.$expression.'<br/>'; |
373 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 374 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
374 | $cond_deleted[] = $name; | 375 | $cond_deleted[] = $name; |
375 | continue; | 376 | continue; |
@@ -377,14 +378,14 @@ class UserWsTransfer { | @@ -377,14 +378,14 @@ class UserWsTransfer { | ||
377 | 378 | ||
378 | if (!empty($this->ws_deleted)) | 379 | if (!empty($this->ws_deleted)) |
379 | if ($this->deleteParam($expression,$this->ws_deleted)) { | 380 | if ($this->deleteParam($expression,$this->ws_deleted)) { |
380 | - $msg .= '<b>'.$name.'</b> : uses obsolete Derived param<br/> '.$expression.'<br/>'; | 381 | + $msg .= '<li><i>'.$name.'</i> : uses obsolete drived param<br/> '.$expression.'<br/>'; |
381 | // error_log( 'For INFO : DELETED '.$expression,1,email); | 382 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
382 | $cond_deleted[] = $name; | 383 | $cond_deleted[] = $name; |
383 | continue; | 384 | continue; |
384 | } | 385 | } |
385 | 386 | ||
386 | if ($this->deleteParam($expression,array("CDAWEB","MAPSKP","VEXGRAZ","IMPEX"))) { | 387 | if ($this->deleteParam($expression,array("CDAWEB","MAPSKP","VEXGRAZ","IMPEX"))) { |
387 | - $msg .= '<b>'.$name.'</b> : uses remote params <br/> '.$expression.'<br/>'; | 388 | + $msg .= '<li><i>'.$name.'</i> : uses remote params <br/> '.$expression.'<br/>'; |
388 | $cond_deleted[] = $name; | 389 | $cond_deleted[] = $name; |
389 | continue; | 390 | continue; |
390 | } | 391 | } |
@@ -396,14 +397,14 @@ class UserWsTransfer { | @@ -396,14 +397,14 @@ class UserWsTransfer { | ||
396 | } | 397 | } |
397 | 398 | ||
398 | $newRequestXml->save($this->newWsDir.'Request.xml'); | 399 | $newRequestXml->save($this->newWsDir.'Request.xml'); |
399 | - $msg .= ' <br/>'; | ||
400 | 400 | ||
401 | return array('success' => true, 'msg' => $msg); | 401 | return array('success' => true, 'msg' => $msg); |
402 | } | 402 | } |
403 | 403 | ||
404 | public function transferMyData() | 404 | public function transferMyData() |
405 | { | 405 | { |
406 | - $msg = '<b>My Data:</b><br/>'; | 406 | + $msg = '<b><i>MyData Parameters / My Files:</i></b><br/><br/>'; |
407 | + $msg.= '<i>Note :</i> CEF format is not implemented<br/><br/>'; | ||
407 | 408 | ||
408 | if (!$this->oldWs->load($this->oldWsDir.'WsParams.xml')) { | 409 | if (!$this->oldWs->load($this->oldWsDir.'WsParams.xml')) { |
409 | error_log('cannot load WsParams.xml for '.TRANSFERUSER,1,email); | 410 | error_log('cannot load WsParams.xml for '.TRANSFERUSER,1,email); |
@@ -422,7 +423,7 @@ class UserWsTransfer { | @@ -422,7 +423,7 @@ class UserWsTransfer { | ||
422 | $wsdParamsOld = $this->oldWs->getElementsByTagName('mydata'); | 423 | $wsdParamsOld = $this->oldWs->getElementsByTagName('mydata'); |
423 | 424 | ||
424 | if ($wsdParamsOld->length == 0) { | 425 | if ($wsdParamsOld->length == 0) { |
425 | - return array('success' => true, 'msg' => 'No parameters'); | 426 | + return array('success' => true, 'msg' => 'You have no MyData parameters'); |
426 | } | 427 | } |
427 | 428 | ||
428 | if (!$BaseXml->load(OLDUSERPATH.TRANSFERUSER.'/DATA/base.xml')) { | 429 | if (!$BaseXml->load(OLDUSERPATH.TRANSFERUSER.'/DATA/base.xml')) { |
@@ -435,7 +436,8 @@ class UserWsTransfer { | @@ -435,7 +436,8 @@ class UserWsTransfer { | ||
435 | 436 | ||
436 | $this->newWs->load($this->newWsDir.'WsParams.xml'); | 437 | $this->newWs->load($this->newWsDir.'WsParams.xml'); |
437 | $paramDom = new DomDocument("1.0"); | 438 | $paramDom = new DomDocument("1.0"); |
438 | - | 439 | + |
440 | + $msg.= ' Not copied parameters : <br/>'; | ||
439 | foreach ($wsdParamsOld as $wsdParamOld) { | 441 | foreach ($wsdParamsOld as $wsdParamOld) { |
440 | $format = $wsdParamOld->getAttribute('format'); | 442 | $format = $wsdParamOld->getAttribute('format'); |
441 | $name = $wsdParamOld->getAttribute('name'); | 443 | $name = $wsdParamOld->getAttribute('name'); |
@@ -443,7 +445,7 @@ class UserWsTransfer { | @@ -443,7 +445,7 @@ class UserWsTransfer { | ||
443 | $mask = $wsdParamOld->getAttribute('mask'); | 445 | $mask = $wsdParamOld->getAttribute('mask'); |
444 | if ($format == 'cef') { | 446 | if ($format == 'cef') { |
445 | $deletedVi[] = $mask; | 447 | $deletedVi[] = $mask; |
446 | - $msg .= '<b>'.$name.'</b> : CEF format is not implemented <br/>'; | 448 | + $msg .= '<li><i>'.$name.'</i><br/>'; |
447 | $this->wsd_deleted[] = 'wsd_'.$name; | 449 | $this->wsd_deleted[] = 'wsd_'.$name; |
448 | } | 450 | } |
449 | else { | 451 | else { |
@@ -505,11 +507,11 @@ class UserWsTransfer { | @@ -505,11 +507,11 @@ class UserWsTransfer { | ||
505 | if ($node) | 507 | if ($node) |
506 | $node->parentNode->removeChild($node); | 508 | $node->parentNode->removeChild($node); |
507 | } | 509 | } |
508 | - | 510 | + $msg .= 'Not copied files :<br/>'; |
509 | foreach ($deletedFiles as $vi) { | 511 | foreach ($deletedFiles as $vi) { |
510 | $node = $FilesXml->getElementById($vi); | 512 | $node = $FilesXml->getElementById($vi); |
511 | if ($node) { | 513 | if ($node) { |
512 | - $msg .= '<b>'.$vi.'</b> : CEF format is not implemented <br/>'; | 514 | + $msg .= '<li><i>'.$vi.'</i> <br/>'; |
513 | $node->parentNode->removeChild($node); | 515 | $node->parentNode->removeChild($node); |
514 | } | 516 | } |
515 | } | 517 | } |
@@ -521,7 +523,7 @@ class UserWsTransfer { | @@ -521,7 +523,7 @@ class UserWsTransfer { | ||
521 | 523 | ||
522 | public function transferFilters() | 524 | public function transferFilters() |
523 | { | 525 | { |
524 | - $msg = '<b>Filters:</b><br/>'; | 526 | + $msg = '<br/><br/><b><i>Filters:</i></b><br/><br/>'; |
525 | 527 | ||
526 | if (!curl_init($this->oldWsDir.'Filters.xml')) { | 528 | if (!curl_init($this->oldWsDir.'Filters.xml')) { |
527 | return array('success' => true, 'msg' => 'No filters at old AMDA'); | 529 | return array('success' => true, 'msg' => 'No filters at old AMDA'); |
@@ -533,7 +535,8 @@ class UserWsTransfer { | @@ -533,7 +535,8 @@ class UserWsTransfer { | ||
533 | } | 535 | } |
534 | 536 | ||
535 | $filterXml->save($this->newWsDir.'Filters.xml'); | 537 | $filterXml->save($this->newWsDir.'Filters.xml'); |
536 | - return array('success' => true, 'msg' => '<b>Filters</b> have been copied'); | 538 | + $msg .= 'Filters have been copied</br>'; |
539 | + return array('success' => true, 'msg' => $msg); | ||
537 | } | 540 | } |
538 | } | 541 | } |
539 | ?> | 542 | ?> |
540 | \ No newline at end of file | 543 | \ No newline at end of file |