<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[FrontAccounting forum — Create local module for FA 2.4RC]]></title>
	<link rel="self" href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=6688&amp;type=atom" />
	<updated>2017-02-08T07:22:08Z</updated>
	<generator>PunBB</generator>
	<id>https://frontaccounting.com/punbb/viewtopic.php?id=6688</id>
		<entry>
			<title type="html"><![CDATA[Re: Create local module for FA 2.4RC]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=27495#p27495" />
			<content type="html"><![CDATA[<p>Change <em>&#039;version&#039; =&gt; &#039;-&#039;</em> to <em> &#039;version&#039; =&gt; &#039;2.4.0-2&#039; </em> in both installed_extensions.php and company/x/installed_extensions.php<br />Or you can commented lines 215-220 in admin/inst_modules.php then uncomment them after active your ext</p>]]></content>
			<author>
				<name><![CDATA[notrinos]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=36772</uri>
			</author>
			<updated>2017-02-08T07:22:08Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=27495#p27495</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Create local module for FA 2.4RC]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=27494#p27494" />
			<content type="html"><![CDATA[<p>I am trying to learn how to create module for FA 2.4RC. I just create a really simple one, only add a menu without anything. In my hooks, I write this:</p><p>class hooks_mymodule extends hooks {<br />&nbsp; &nbsp; var $module_name = &#039;My module&#039;;<br />&nbsp; &nbsp; <br />&nbsp; &nbsp; function install_options($app) {<br />&nbsp; &nbsp; &nbsp; &nbsp; global $path_to_root;</p><p>&nbsp; &nbsp; &nbsp; &nbsp; switch($app-&gt;id) {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; case &#039;stock&#039;:<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $app-&gt;add_lapp_function(1, _(&#039;My module&#039;),$path_to_root.&#039;/modules/mymodule/mymodule.php&#039;, &#039;SA_ITEM&#039;, MENU_MAINTENANCE);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; break;<br />&nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; }<br />&nbsp; &nbsp; function activate_extension($company, $check_only=true){<br />&nbsp; &nbsp; &nbsp; &nbsp; return;<br />&nbsp; &nbsp; }<br />&nbsp; &nbsp; <br />&nbsp; &nbsp; function deactivate_extension($company, $check_only=true){<br />&nbsp; &nbsp; &nbsp; &nbsp; return;<br />&nbsp; &nbsp; }<br />}</p><p>After I tried to activate it, I got this error:<br />Package mymodule is incompatible with current application version and cannot be activated.</p><p>What should I do? I think I don&#039;t need to create _init folder to create local extension.</p>]]></content>
			<author>
				<name><![CDATA[barbarian]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=18954</uri>
			</author>
			<updated>2017-02-08T06:42:15Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=27494#p27494</id>
		</entry>
</feed>
