Extensions Overview

 

What are xTuple Extensions?

xTuple Extensions are a collective reference to custom scripts, screens, reports and other objects that may be added to the xTuple PostBooks core to enhance functionality without changing the core code or database schemas in any way.

xTuple ERP Embedded Design Tools

Several extension components can be created and modified directly from the xTuple ERP application.  You'll find these tools navigating the menu to System > Design:

  • Reports - xTuple ERP includes an embedded report writer application.  With this tool you can change visual presentation and the source query of standard reports or write your own from scratch.  Learn more...
  • Screens - xTuple ERP also includes an embedded version of Qt Designer.  From here you can import, export and create new screens from scratch using a graphical design tool. While you can not currently change core application screens with this tool, it is a great place to design your own custom displays, lists and maintenance screens.
  • Scripts - This is a lightweight text based code editor where you can write or paste in custom JavaScript code to modify the application. This is the way you can programatically modify both the appearance and behavior of core application windows and custom screens.  Learn more...
  • Custom Commands - You can create custom menu commands that launch external applications or custom screens.  These commands can even include custom privileges to control who may access them.  By default they fall into a "Custom" sub menu in a specified module, but with a little extra JavaScript they can be made to move and reappear anywhere in the menu structure. Learn more...
  • Packages - Packages are a way to bundle a group of extensions together into a single file that can be loaded and maintained all at once.  While, you can not edit package contents in the application, you can see the complete contents of packages that have been loaded and what their relationships are to other packages in the system.  Learn more...

xTuple External Tools

  • OpenRPT - This report writer utility embeded in xTuple ERP may be downloaded and run separately as well.  It also includes several other useful utilities including a renderer to print free standing reports and a utility to import report definition files in mass directly into a database.  Learn more...
  • MetaSQL - xTuple ERP supports the use of paramaterized queries which may be stored directly in the database.  These queries may be shared by core C++ code, JavaScript extensions and reports.  MetaSQL queries may be edited with any text editor or the MetaSQL Editor utility included with OpenRPT, which also allows testing of them on a live database.  When saved as files, MetaSQL files have an .mql extension.  OpenRPT also includes a MetaSQL import utility for mass importing of .mql files into the database.  Learn more...
  • Updater - xTuple uses a separate Updater utility to update xTuple ERP from one version to another, and to load and update extension packages.  Packages are compressed files that contain all the scripts involved in an update or extension bundle.  A configuration file package.xml defines what the contents are and how they are to be loaded into the database.  This file can direct the Updater to take the following actions:
    • Define the package version and schema
    • Load a SQL file designated as a new table, function, trigger or view
    • Create custom privileges
    • Create custom commands
    • Load application logic files including screens, scripts, reports, images and MetaSQL
    • Learn more...

Postgres Database Design Tools

xTuple relies exclusively on PostgresSQL as its database platform.  All business logic created by extensions is maintained in the database either as records or database objects.  Database design work such as the creation of new tables, functions, triggers and views can be accomplished using a variety of tools.  Psql is the defacto PostgreSQL command line tool while pgAdmin is the officially endorsed graphical interface.  All the objects necessary to extend xTuple can be created and edited from either of these tools.  However, there literally dozens of alternitive administration tools available as well.

xTuple does NOT recommend or endorse altering the core public or api schemas for local customizations.   All custom extensions should be created in their own schemas.  This ensures that extensions will not interfere with or be overwritten by upgrades to the xTuple core.  If you are interested in modifying the core please see the core development overview page.

The good news is if you intend on creating extension packages the Updater utility will automatically create a separate schema with the same name as your package, and several control tables to store all of your database application objects for you.  You can learn more about how this works in the packages topic.

Learn more

Click on the following links to learn more about interfacing with xTuple and building extensions:

 
sdifiore's picture
Offline
Joined: 10/21/2009
E/R model

Is it possible to have access to the E/R model of xtuples database?

 
paladinlogic's picture
Offline
Joined: 06/09/2008
E/R Model

We use Eclipse with Clay plug-in to generate an E/R model from a live connection to the database. This generates the model directly from the system.

Note that not all relationships between tables are defined as foreign keys ... this can lead to some fun and amusing results if you aren't careful!

Paladin Logic

 
yogiyang's picture
Offline
Joined: 12/26/2007
@Paladin Logic, That is one

@Paladin Logic,
That is one of the reason why XTuple should publish a complete E/R Model.

What do you say about this.

 
wet
wet's picture
Offline
Joined: 11/23/2010
Documentation automation

A project the size of xTuple would defintely benefit from an official E/R document. In my development practice I have acquained the habit of applying semi-automated methods / docs generators to have a least a tiny bit of it.

 
jhayczee's picture
Offline
Joined: 01/02/2013
Link for Video Tutorial

Hi, do you have any link for "Demo video on application scripting and building a screen" because the link is this page have problems when opening. Please help.

 
dlech's picture
Offline
Joined: 01/05/2013
Videos are now here:
 
jhayczee's picture
Offline
Joined: 01/02/2013
Thanks.

Thanks.

 
MissySchmidt's picture
Offline
Joined: 02/07/2012
Demo Videos have moved

All videos fomerly hosted at Sourceforge in .SWF format have been reformatted and you may find them here: http://www.xtuple.com/demo/videos

 
demo2010's picture
Offline
Joined: 03/01/2010
the Qt Designer links is

the Qt Designer links is broken.

 
ptyler's picture
Offline
Joined: 12/10/2008
Broken link

Fixed. Thanks for letting us know.

Regards,

Pierce

 

mead