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 | 590 | |
591 | 591 | if (isMigration) { // isSpecialInfo |
592 | 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 | 594 | if ( isOldWS ) { |
595 | + var win = myDesktopApp.getDesktop().getWindow(myDesktopApp.dynamicModules.info.id); | |
597 | 596 | win.on({ |
598 | 597 | show : function() { |
599 | 598 | Ext.Msg.show({ |
600 | 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 | 601 | 'Do you want to copy here your workspace from the old AMDA ?', |
603 | 602 | buttons: Ext.Msg.YESNO, |
604 | 603 | icon: Ext.Msg.QUESTION, |
... | ... | @@ -611,9 +610,7 @@ Ext.define('amdaApp.AmdaApp', { |
611 | 610 | loadMask.hide(); |
612 | 611 | |
613 | 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 | 615 | else { |
619 | 616 | myDesktopApp.errorMsg(res.error); | ... | ... |
php/classes/UserWsTransfer.php
... | ... | @@ -187,11 +187,11 @@ class UserWsTransfer { |
187 | 187 | |
188 | 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 | 192 | if (!$this->oldWs->load($this->oldWsDir.'WsParams.xml')) { |
193 | 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 | 197 | if (!file_exists($this->newWsDir.'WsParams.xml')) |
... | ... | @@ -212,7 +212,7 @@ class UserWsTransfer { |
212 | 212 | } |
213 | 213 | |
214 | 214 | $paramXml = new DomDocument("1.0"); |
215 | - $msg .= '<b>Not copied :</b><br/>'; | |
215 | + $msg .= 'Not copied derived parameters :<br/>'; | |
216 | 216 | |
217 | 217 | foreach ($wsParamsOld as $param) { |
218 | 218 | $id = $param->getAttribute('xml:id'); |
... | ... | @@ -221,21 +221,21 @@ class UserWsTransfer { |
221 | 221 | $expression = $param->getAttribute('buildchain'); |
222 | 222 | |
223 | 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 | 225 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
226 | 226 | $this->ws_deleted[] = $name; |
227 | 227 | continue; |
228 | 228 | } |
229 | 229 | |
230 | 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 | 232 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
233 | 233 | $this->ws_deleted[] = $name; |
234 | 234 | continue; |
235 | 235 | } |
236 | 236 | |
237 | 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 | 239 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
240 | 240 | $this->ws_deleted[] = $name; |
241 | 241 | continue; |
... | ... | @@ -243,14 +243,14 @@ class UserWsTransfer { |
243 | 243 | |
244 | 244 | if (!empty($this->wsd_deleted)) |
245 | 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 | 247 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
248 | 248 | $this->ws_deleted[] = $name; |
249 | 249 | continue; |
250 | 250 | } |
251 | 251 | |
252 | 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 | 254 | $this->ws_deleted[] = $name; |
255 | 255 | continue; |
256 | 256 | } |
... | ... | @@ -281,7 +281,7 @@ class UserWsTransfer { |
281 | 281 | unlink($this->newWsDir.$id.'.xml'); |
282 | 282 | $paramsToRemove[] = $param; |
283 | 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 | 294 | $this->newWs->save($this->newWsDir.'WsParams.xml'); |
295 | 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 | 298 | return array('success' => true, 'msg' => $msg); |
299 | 299 | } |
300 | 300 | |
301 | 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 | 305 | // get old time tab list |
306 | 306 | $this->newWs->load($this->oldWsDir.'Tt.xml'); |
... | ... | @@ -318,19 +318,19 @@ class UserWsTransfer { |
318 | 318 | } |
319 | 319 | |
320 | 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 | 322 | return array('success' => true, 'msg' => $msg); |
323 | 323 | } |
324 | 324 | |
325 | 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 | 329 | $oldRequestXml = new DomDocument("1.0"); |
330 | 330 | $newRequestXml = new DomDocument("1.0"); |
331 | 331 | |
332 | 332 | if (!$oldRequestXml->load($this->oldWsDir.'Request.xml')){ |
333 | - $msg .= ' cannot copy<br/>'; | |
333 | + $msg .= ' No Requests File<br/>'; | |
334 | 334 | return array('success' => true, 'msg' => $msg); |
335 | 335 | } |
336 | 336 | |
... | ... | @@ -346,6 +346,7 @@ class UserWsTransfer { |
346 | 346 | |
347 | 347 | $deleted = $this->getObsolete(); |
348 | 348 | $notready = $this->getNotready(); |
349 | + $msg .= 'Not copied DataMining requests :<br/>'; | |
349 | 350 | |
350 | 351 | foreach ($condNodes as $condNode) { |
351 | 352 | $id = $condNode->getAttribute('xml:id'); |
... | ... | @@ -355,13 +356,13 @@ class UserWsTransfer { |
355 | 356 | $condObj = json_decode($cond[0]); |
356 | 357 | $expression = $condObj->expression; |
357 | 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 | 360 | $cond_deleted[] = $name; |
360 | 361 | continue; |
361 | 362 | } |
362 | 363 | |
363 | 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 | 366 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
366 | 367 | $cond_deleted[] = $name; |
367 | 368 | continue; |
... | ... | @@ -369,7 +370,7 @@ class UserWsTransfer { |
369 | 370 | |
370 | 371 | if (!empty($this->wsd_deleted)) |
371 | 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 | 374 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
374 | 375 | $cond_deleted[] = $name; |
375 | 376 | continue; |
... | ... | @@ -377,14 +378,14 @@ class UserWsTransfer { |
377 | 378 | |
378 | 379 | if (!empty($this->ws_deleted)) |
379 | 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 | 382 | // error_log( 'For INFO : DELETED '.$expression,1,email); |
382 | 383 | $cond_deleted[] = $name; |
383 | 384 | continue; |
384 | 385 | } |
385 | 386 | |
386 | 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 | 389 | $cond_deleted[] = $name; |
389 | 390 | continue; |
390 | 391 | } |
... | ... | @@ -396,14 +397,14 @@ class UserWsTransfer { |
396 | 397 | } |
397 | 398 | |
398 | 399 | $newRequestXml->save($this->newWsDir.'Request.xml'); |
399 | - $msg .= ' <br/>'; | |
400 | 400 | |
401 | 401 | return array('success' => true, 'msg' => $msg); |
402 | 402 | } |
403 | 403 | |
404 | 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 | 409 | if (!$this->oldWs->load($this->oldWsDir.'WsParams.xml')) { |
409 | 410 | error_log('cannot load WsParams.xml for '.TRANSFERUSER,1,email); |
... | ... | @@ -422,7 +423,7 @@ class UserWsTransfer { |
422 | 423 | $wsdParamsOld = $this->oldWs->getElementsByTagName('mydata'); |
423 | 424 | |
424 | 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 | 429 | if (!$BaseXml->load(OLDUSERPATH.TRANSFERUSER.'/DATA/base.xml')) { |
... | ... | @@ -435,7 +436,8 @@ class UserWsTransfer { |
435 | 436 | |
436 | 437 | $this->newWs->load($this->newWsDir.'WsParams.xml'); |
437 | 438 | $paramDom = new DomDocument("1.0"); |
438 | - | |
439 | + | |
440 | + $msg.= ' Not copied parameters : <br/>'; | |
439 | 441 | foreach ($wsdParamsOld as $wsdParamOld) { |
440 | 442 | $format = $wsdParamOld->getAttribute('format'); |
441 | 443 | $name = $wsdParamOld->getAttribute('name'); |
... | ... | @@ -443,7 +445,7 @@ class UserWsTransfer { |
443 | 445 | $mask = $wsdParamOld->getAttribute('mask'); |
444 | 446 | if ($format == 'cef') { |
445 | 447 | $deletedVi[] = $mask; |
446 | - $msg .= '<b>'.$name.'</b> : CEF format is not implemented <br/>'; | |
448 | + $msg .= '<li><i>'.$name.'</i><br/>'; | |
447 | 449 | $this->wsd_deleted[] = 'wsd_'.$name; |
448 | 450 | } |
449 | 451 | else { |
... | ... | @@ -505,11 +507,11 @@ class UserWsTransfer { |
505 | 507 | if ($node) |
506 | 508 | $node->parentNode->removeChild($node); |
507 | 509 | } |
508 | - | |
510 | + $msg .= 'Not copied files :<br/>'; | |
509 | 511 | foreach ($deletedFiles as $vi) { |
510 | 512 | $node = $FilesXml->getElementById($vi); |
511 | 513 | if ($node) { |
512 | - $msg .= '<b>'.$vi.'</b> : CEF format is not implemented <br/>'; | |
514 | + $msg .= '<li><i>'.$vi.'</i> <br/>'; | |
513 | 515 | $node->parentNode->removeChild($node); |
514 | 516 | } |
515 | 517 | } |
... | ... | @@ -521,7 +523,7 @@ class UserWsTransfer { |
521 | 523 | |
522 | 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 | 528 | if (!curl_init($this->oldWsDir.'Filters.xml')) { |
527 | 529 | return array('success' => true, 'msg' => 'No filters at old AMDA'); |
... | ... | @@ -533,7 +535,8 @@ class UserWsTransfer { |
533 | 535 | } |
534 | 536 | |
535 | 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 | 543 | \ No newline at end of file | ... | ... |