<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[FrontAccounting forum — API for Direct Invoice]]></title>
	<link rel="self" href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=4091&amp;type=atom" />
	<updated>2013-05-16T10:53:40Z</updated>
	<generator>PunBB</generator>
	<id>https://frontaccounting.com/punbb/viewtopic.php?id=4091</id>
		<entry>
			<title type="html"><![CDATA[Re: API for Direct Invoice]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=16675#p16675" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>itronics wrote:</cite><blockquote><p>You have to &#039;000001&#039; item defined first.<br />Janusz</p></blockquote></div><p>Hi Janusz,</p><p>It is defined.</p>]]></content>
			<author>
				<name><![CDATA[Zilvermeeuw]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=17887</uri>
			</author>
			<updated>2013-05-16T10:53:40Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=16675#p16675</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: API for Direct Invoice]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=16674#p16674" />
			<content type="html"><![CDATA[<p>You have to &#039;000001&#039; item defined first.<br />Janusz</p>]]></content>
			<author>
				<name><![CDATA[itronics]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=89</uri>
			</author>
			<updated>2013-05-16T10:49:35Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=16674#p16674</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[API for Direct Invoice]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=16663#p16663" />
			<content type="html"><![CDATA[<p>I am writing an extension on the Simple API to add &quot;Add Direct Invoice&quot; possibility. I want to call this from the Virtuemart webshop.</p><p>According to <a href="https://frontaccounting.com/punbb/viewtopic.php?pid=5789#p5789">forum link</a> I have the following code:<br /></p><div class="codebox"><pre><code>include_once($path_to_root . &quot;/sales/includes/cart_class.inc&quot;);
// Create cart object
$_SESSION[&#039;Items&#039;] = new cart(ST_SALESINVOICE, 0 );

// add customer
$br = get_branch(4); // Use a general customer with id=4
$_POST[&#039;customer_id&#039;] = $br[&#039;debtor_no&#039;];
$Ajax-&gt;activate(&#039;customer_id&#039;);

// Add items to cart
add_to_order($_SESSION[&#039;Items&#039;], &#039;000001&#039;, 1, 12, 0, &#039;&#039; );</code></pre></div><p>But no items are added to the card.</p><p>Any tips to solve this?</p>]]></content>
			<author>
				<name><![CDATA[Zilvermeeuw]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=17887</uri>
			</author>
			<updated>2013-05-16T06:42:20Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=16663#p16663</id>
		</entry>
</feed>
