@@ -262,7 +262,7 @@ def get_metadata(self):
262262
263263 elif self .pgIntro .pnlIntroduction .rbSaveExisting .GetValue ():
264264 # selected an existing series
265- method , processing_level , variable = self .pgExisting .getSeries ()
265+ method , processing_level , variable = self .pgExisting .get_selected_series ()
266266
267267 # Create action
268268 action = Actions ()
@@ -451,42 +451,34 @@ def on_wizard_finished(self, event):
451451 else:
452452 result = self.record_service.saveAs(Variable, Method, QCL, True)
453453 '''
454-
455-
456- #TODO: move all of this stuff into the edit_service file
457- # Create action
458- new_result = self .series_service .getResult (var = variable , meth = method , proc = proc_level )
459-
460- # action = self.series_service.create.createAction(action)
461-
462454 affiliation = self .action_page .get_affiliation ()
463455
464- new_action_by = ActionBy ()
465- new_action_by .ActionID = action .ActionID
466- new_action_by .RoleDescription = self .action_page .action_view .role_description_text_box .GetValue ()
467- new_action_by .AffiliationID = affiliation .AffiliationID
468- new_action_by .AffiliationObj = affiliation
456+ action_by = ActionBy ()
457+ action_by .ActionID = action .ActionID
458+ action_by .RoleDescription = self .action_page .action_view .role_description_text_box .GetValue ()
459+ action_by .AffiliationID = affiliation .AffiliationID
460+ action_by .AffiliationObj = affiliation
469461
470- #TODO end
462+ # result = self.series_service.getResult(var=variable, meth=method, proc=proc_level, action=action, actionby=action_by)
463+ result = self .record_service ._edit_service .getResult (var = variable , meth = method , proc = proc_level , action = action , actionby = action_by )
471464
472465 try :
473466 if rbSave :
474467 result = self .record_service .save ()
475468 elif rbSaveAsNew :
476- #TODO send in Action, and Actionby
477- result = self . record_service . save_as ( variable , method , proc_level )
469+ result = self . record_service . saveAs ( variable = variable , method = method , proc_level = proc_level ,
470+ action = action , action_by = action_by )
478471 elif rbSaveAsExisting :
479472 if overwrite :
480- #TODO send in just the result
481- result = self .record_service .save_existing (variable , method , proc_level )
473+ result = self .record_service .saveExisting (result = result )
482474 elif append :
483475 #TODO send in just the result
484476 #def save_appending(self, var = None, method =None, qcl = None, overwrite = False):
485477 #TODO if i require that original or new is selected I can call once with overwrite = original
486478 if original :
487- result = self .record_service .save_appending ( variable , method , proc_level , overwrite = False )
479+ result = self .record_service .saveAppend ( result = result , overwrite = False )
488480 elif new :
489- result = self .record_service .save_appending ( variable , method , proc_level , overwrite = True )
481+ result = self .record_service .saveAppend ( result = result , overwrite = True )
490482
491483 Publisher .sendMessage ("refreshSeries" )
492484
0 commit comments