Pages

Google ads Horizontal

Wednesday, November 25, 2015

CREATE NEW COMPONENT IN OFBIZ

  • Go to your project folder/ Open your project folder
  • Right click on the bottom of the panel where free white space and choose terminal
  • Type sudo ant create-component
  • After that command terminal will prompt for some information like:

  1. Component name: nmm
  2. Component resource name: Nmm
  3. Webapp name: nmm
  4. Base permission: NMM
  5. Confirm: Y

  • sudo ant run-install to install new created component
  • sudo ant run or sudo ant start to run the project
  • To see the component you have to visit like http://localhost:8080/nmm

          TO STOP ALL COMPONENT LOAD FOLLOW INSTRUCTION UNDER THE BELOW

          • $OFBIZ_HOME/applications/component-load.xml
            <component-loader xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/component-loader.xsd"> <load-component component-location="commonext"/><!-- common component used by most other components --> <!-- <load-component component-location="party"/> <load-component component-location="securityext"/> <load-component component-location="content"/> <load-component component-location="workeffort"/> <load-component component-location="product"/> <load-component component-location="manufacturing"/> <load-component component-location="accounting"/> <load-component component-location="humanres"/> <load-component component-location="order"/> <load-component component-location="marketing"/> --> </component-loader> 
          • $OFBIZ_HOME/specialpurpose/component-load.xml
            <component-loader xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/component-loader.xsd"> <!-- <load-component component-location="ecommerce"/> <load-component component-location="pos"/> <load-component component-location="hhfacility"/> <load-component component-location="assetmaint"/> <load-component component-location="cmssite"/> <load-component component-location="projectmgr"/> <load-component component-location="oagis"/> <load-component component-location="googlebase"/> <load-component component-location="ebay"/> <load-component component-location="myportal"/> <load-component component-location="webpos"/> --> <!-- <load-component component-location="workflow"/> --> <!-- <load-component component-location="shark"/> --> </component-loader> 
          • $OFBIZ_HOME/framework/component-load.xml
            <component-loader xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/component-loader.xsd"> <load-component component-location="geronimo"/> <load-component component-location="entity"/> <load-component component-location="catalina"/> <!-- <load-component component-location="jetty"/> --> <load-component component-location="security"/> <load-component component-location="datafile"/> <load-component component-location="minilang"/> <load-component component-location="common"/> <load-component component-location="service"/> <load-component component-location="entityext"/> <load-component component-location="bi"/> <load-component component-location="webapp"/> <load-component component-location="guiapp"/> <load-component component-location="widget"/> <load-component component-location="appserver"/> <load-component component-location="testtools"/> <load-component component-location="webtools"/> <load-component component-location="webslinger"/> <load-component component-location="images"/> <!-- <load-component component-location="example"/>--> <!-- <load-component component-location="exampleext"/>--> </component-loader> 
          • Now run the sudo ant run-install and sudo ant create-admin-user-login to populate the database.
          • https://localhost:8443/webtools
          • login as admin and passwordofbiz

          CUSTOMIZE FILE UPLOAD SIZE IN OFBIZ

          • Goto general.properties
          • find http.upload.max.sizethreshold
          • to change 10k to 40k replace 10240 with 40960
          • Save this file.

          OFBIZ HIDE COMPONENT FROM APP BAR

          • Open your component
          • Find ofbiz-component.xml
          • Open ofbiz-component.xml
          • Find <webapp/>
          • Write app-bar-display="false" into <webapp/> tag
          • Example:
            <?xml version="1.0" encoding="UTF-8"?> <ofbiz-component name="practice" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/ofbiz-component.xsd"> <resource-loader name="main" type="component"/> <webapp name="practice" title="Practice" server="default-server" base-permission="OFBTOOLS" location="webapp/practice" mount-point="/practice" app-bar-display="false"/> </ofbiz-component>