Commit 28a26786 authored by Thomas Huster's avatar Thomas Huster
Browse files

[17454] fixed calling bill.create by not using Handler util class

parent 502e842f
Loading
Loading
Loading
Loading
+0 −19
Original line number Diff line number Diff line
@@ -520,7 +520,6 @@ public class KonsZumVerrechnenView extends ViewPart implements ISaveablePart2 {
					setToolTipText(Messages.KonsZumVerrechnenView_createInvoices); //$NON-NLS-1$
				}
				
				@SuppressWarnings("unchecked")
				@Override
				public void run(){
					if (((StructuredSelection) tvSel.getSelection()).size() > 0) {
@@ -530,25 +529,7 @@ public class KonsZumVerrechnenView extends ViewPart implements ISaveablePart2 {
							return;
						}
					}
					// Handler.execute(getViewSite(), "bill.create", tSelection);
					ErstelleRnnCommand.ExecuteWithParams(getViewSite(), tSelection);
					/*
					 * IHandlerService handlerService = (IHandlerService)
					 * getViewSite().getService(IHandlerService.class); ICommandService cmdService =
					 * (ICommandService) getViewSite().getService(ICommandService.class); try {
					 * Command command = cmdService.getCommand("bill.create"); Parameterization px =
					 * new Parameterization(command.getParameter
					 * ("ch.elexis.RechnungErstellen.parameter" ), new
					 * TreeToStringConverter().convertToString(tSelection)); ParameterizedCommand
					 * parmCommand = new ParameterizedCommand(command, new Parameterization[] { px
					 * });
					 * 
					 * handlerService.executeCommand(parmCommand, null);
					 * 
					 * } catch (Exception ex) { throw new RuntimeException("add.command not found");
					 * }
					 */
					
					tvSel.refresh();
				}
			};
+2 −2
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@ import org.slf4j.LoggerFactory;
import ch.elexis.core.constants.StringConstants;
import ch.elexis.core.data.events.ElexisEventDispatcher;
import ch.elexis.core.data.status.ElexisStatus;
import ch.elexis.core.ui.commands.Handler;
import ch.elexis.core.ui.commands.ErstelleRnnCommand;
import ch.elexis.data.Fall;
import ch.elexis.data.Konsultation;
import ch.elexis.data.Mandant;
@@ -107,7 +107,7 @@ public class Rechnungslauf implements IRunnableWithProgress {
		
		if (skip) {
			monitor.subTask(Messages.Rechnungslauf_creatingBills); //$NON-NLS-1$
			Handler.executeWithProgress(kzv.getViewSite(), "bill.create", kzv.tSelection, monitor); //$NON-NLS-1$
			ErstelleRnnCommand.ExecuteWithParams(kzv.getViewSite(), kzv.tSelection);
		}
		monitor.done();
	}