Plug-in Modules

Plugins are customized special code segments written by Arts Management specifically tailored to perform business rule logic to automatically alter prices on tickets, memberships, gift certificates, fees, donations, and/or mail lists for patrons who purchase either online, or via the box office. Their purpose is to enforce site specific rules during the sales process.

The organization describes a business rule / reason why to alter a patrons shopping cart purchases, then Arts Management writes customized code to perform that action. Plugin code may be required to change/adapt over time, depending if the business rules or requirements change within the organization from year to year.

The "how does a plugin work" is not as important from your viewpoint, as having a clearly defined business rule/requirement to Arts Management for each situation. Whats important is that a business rule offers an A or B solution. If conditions X, Y, and Z are met, then perform action A. If conditions P & Q are met, perform action B. etc. It can also be as simple as if condition R is met, perform action C.

Plugins cycle through the defined business rules each time an item is added or removed from the shopping cart. If any of the business rule conditions "match" items within the cart, then the those items are processes through the special code segment to alter their default state (i.e. alter their price, price code, and/or sales promotion —> the most common alterations).

Plugins allow patrons to utilize web sales for their purchases by receiving their justified discounts without having to contact the box office directly. Plugins are also utilized in the box office to automatically provide patrons their justified discounts; without having the box office staff to remember each business rule to determine discounts patron may be applicable for.

For example, plug-ins could achieve the following kinds of special rules:

  • if more than 10 tickets are purchased, automatically change them to a group sale
  • provide preferred seating areas to donors of a certain level
  • limit ticket sales to certain events at certain times of the year to people who buy subscriptions
  • automatically convert ticket sales from single tickets to subscriptions if the customers buys a certain number of tickets.
  • automatically give subscribers (or frequent buyers) discounts on subsequent tickets.
  • prevent a sale for next season unless a donation is received.

Plug-ins may be associated with specific sales promotions and also when checking out an order.

If you want a plug-in, you must contact Arts Management and speak with someone in Software Development department. Sales Plug-Ins are customized code, our standard custom programming rate per hour will apply.

Diataxis: 

Purchasing a Plug-In

If you want a plug-in, you must contact Arts Management and speak with someone in Software Development department. As Sales Plug-Ins are customized code, our standard custom programming rate per hour will apply.

Plug-in List Window

For information about how to access the Plug-in List Window, click here.

Inserts a New Plug-in through the Plug-in Detail Window. For more information on inserting plug-ins click here.
Opens the selected Plug-in Detail Window for editing. For more information on editing Plug-ins click here.
Duplicates the selected Plug-in.
Deletes a Plug-in. For more information on deleting Plug-ins click here.
Generates a report displaying the list of Plug-ins to the screen or default print location.
Exports the selected invoice comments in text tab-delimited format.

Plug-in Detail Window

Access the Plug-in Detail window by going to Setup > System Tables>Plug-in Modules and selecting the plug-in from the list of plug-ins. For more information on how to access the Plug-in List Window, click here.

Insert a New Plug-in through the Plug-in Detail Window. For more information on inserting Plug-ins click here .
Saves Plug-ins when added or edited in the Plug-in Detail Window. For more information on editing Plug-ins click here.
Creates a copy of the current Plug-in.
Undoes changes to the last saved point.
Deletes a Plug-in. For more information on deleting Plug-ins click here.
Checks the Plug-in for spelling errors.
Exports the selected Plug-in.
Imports a new Plug-in.

Inserting a Plug-in Purchased from AMS

  1. Open the Plug-in List Window.

    For information on how to access the Plug-in List Window, click here.

  2. Click the New button.

    The Plug-in Detail window opens.

  3. Enter a Name for the Plug-in in the Name Field.
  4. Drag-and-drop the .TM2 file containing the Plug-in Code provided by AMS into the PlugIn Code field.

  5. If you have been informed that your plugin is designed to work with a specific sales rule, enter it into the window. Otherwise entering anything here will do nothing.
  6. Click the Save button.
  7. Your new plug-in is ready to use.

Editing a Plug-in

  1. Open the Plug-in List window.

    Click here to learn how to access this window.

  2. Select the Plug-in to edit.

    Single click on a Plug-in to select it.

  3. Click the Open button.

    The Plug-in Detail window opens.

  4. Click the Export button.
  5. Save the export file.

    Save the export .TM2 text file in a known location where you will have easy access to it.

    Do NOT use change or remove the 3 character (.TM2) filename extension. Theatre Manager requires this unique filename extension when importing plugins.

  6. Edit the plug-in's .TM2 text file in Notepad++, BBEdit, or any other true text based file editor.

    Do NOT use Windows WordPad, Windows NotePad, Microsoft Word, TextEdit, SimpleText, or other non-text based file editors. Using these types of editors will alter the plugin file data structure and rendering the file unreadable by Theatre Manager.

  7. Using the text editor, change the plugin export .TM2 file as required.

    If your unsure on how to make changes to your customized plugin, or do not feel confident in making minor changes, please contact Arts Management Systems. We are here to help you.

    Hint: Make a note of the update date and changes made within the plugin .TM2 text file. The top section of the source code is an area of comments that record changes made to the file. This will help assist debugging the plugin in situations where a change to the plugin has an undesired effect.

    Hint: To easily locate where you are in the text file, the display of line numbers offers an easy indicator.

    If your using BBEdit, goto Edit Menu >> Text Options >> enable Display Line Numbers.

    If your using Notepad++, goto Settings Menu >> Preferences >> Editing >> enable Display Line Number.

  8. Click 'Save' in the text editor to save your changes.

    Hint: Save the changes to a new plugin .TM2 file rather then overwriting the existing .TM2 file. This will allow quick ability to revert back to the prior version of the plugin in situations where a change to the plugin has an undesired effect.

  9. On Theatre Manager's Plugin Detail Window, either:

    Drag & Drop the external plugin .TM2 file into the "Plugin Code" area.
    - or -
    Click the Import button to select the external plugin .TM2 file.

    After the plugin code has been updated, at the bottom of the window it will indicate "Successfully read and updated the Plug-In code".

  10. Click the Save button to save the changes.

    The changes to the plugin code will take effect immediately.

    Theatre Manager will not save changes made to the plug-in code, where those changes resulted in a coding syntax error. As well, attempts to import an updated plugin .TM2 file edited with a non-text based editor may result in Theatre Manager unable to save the changes.

Deleting a Plug-in

  1. Open the Plug-in List window.

    Click here to learn how to access the Plug-in List.

  2. Select the Plug-in to be deleted.

    Single click on a Plug-in to select it.

  3. Click the Delete button.

    The Delete Record confirmation opens.

  4. Click the Delete button.

    The Plug-in is now deleted.