protected void submitPurchaseButtonClicked() throws ParseException {
		log.info("New payment started");
		try {
			log.debug("Contents of the current basket:\n"
					+ model.getCurrentPurchaseTableModel());
			domainController.submitCurrentPurchase(model
					.getCurrentPurchaseTableModel().getTableRows());
			
			double sum = 0;
			for (SoldItem item : model.getCurrentPurchaseTableModel().getTableRows()) {
				sum += item.getSum();
			}
			
			PayingWindow pw = new PayingWindow(model, this);
			
			pw.setCost(sum);
			try {
				pw.draw().setVisible(true);
				submitPurchase.setEnabled(false);
				cancelPurchase.setEnabled(false);
			} catch (java.text.ParseException e) {
				e.printStackTrace();
			}
			
		} catch (VerificationFailedException e1) {
			log.error(e1.getMessage());
		}
	}