BEXIS Tech Talk Series #8: Implementation Notes Javad Chamanara January 2017 Jena, Germany
BEXIS Tech Talk Series
#8: Implementation Notes
Javad ChamanaraJanuary 2017
Jena, Germany
2BEXIS Tech Talk #8: Implementation Notes
Reminder
• Tech Talk 5: BExIS Extensibility
3BEXIS Tech Talk #8: Implementation Notes
Modules
• What is a module?A module is a set of related user facing
functions, operating from inside the BExIS shell
4BEXIS Tech Talk #8: Implementation Notes
Module Development Consideration
• ASP.NET MVC 5• Plug-ability– Independent development, testing, publishing– Online deployment
• Shell Integration – Menu integration– State Management
5BEXIS Tech Talk #8: Implementation Notes
Module Anatomy
• UI project:– Entry points– Controllers, Models, Views– Manifest file• Menus, dependencies, identification
• Services• Data Access
6BEXIS Tech Talk #8: Implementation Notes
Module Anatomy
• Bootstrapping – Install– Uninstall
• State Management– Start– Shutdown– Activate– InActivate
7BEXIS Tech Talk #8: Implementation Notes
Module Development Recipe
• 1: Defines the required names– <moduleID>: usually a three letter abbreviation of your
module name– <Affiliation>: the institute that owns the module– <projectName>: <Affiliation>.Modules.<moduleID>– <projectCode>: <projectName>.UI
8BEXIS Tech Talk #8: Implementation Notes
Create the UI project
• From scratch:– Read the “Module Development Recipes” doc
• From a template– Follow up
9BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Copy “Module.Template” folder to the Areas folder– The template is in the “Repo/Code/Templates”
folder– Replace the name with actual <moduleID>– Remove the tailing “Template” token
10BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Inside the folder, rename:– *.csproj to <projectCode>.csproj– *.csproj.user to <projectCode>.csproj.user
11BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• In the VS Solution explorer, at solution’s root• Create the “Modules” folder in does not exists• Create a <moduleID> folder under the “Modules” folder.
12BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Add Existing Project• <projectCode> from the Areas/<moduleId>• To solution/Modules/<moduleID> • Via “Add Existing Project”.
13BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• From inside VS, rename the followings:– ModuleIDModule.cs to <moduleID>Module.cs– ModuleID.Manifest.xml to
<moduleID>.Manifest.xml
14BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Edit the <moduleID>Module.cs – Update the namespace to <projectCode>– Update the class name to <moduleID>Module– Pass <moduleID> to the base constructor
15BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Edit /Views/web.config–Edit <add namespace="Template.UI" /> to <add
namespace="<projectCode>" />
16BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Edit the module manifest• Change the moduleId from “Template” to <moduleID>• Update other attributes and elements
17BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Develop designated features– Controllers/ Actions– Views
18BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Shell publishing does not include the module
19BEXIS Tech Talk #8: Implementation Notes
Create a Module from a Template
• Publish the module
20BEXIS Tech Talk #8: Implementation Notes
The Manifest File
21BEXIS Tech Talk #8: Implementation Notes
The Manifest File: Dependencies
• Must be installed and active• Required version is checked against available
one
22BEXIS Tech Talk #8: Implementation Notes
The Manifest File: Exports
• Publicly accessible module features• Plugged into the menu structure• Document order is preserved– Also catalog order
23BEXIS Tech Talk #8: Implementation Notes
The Manifest File: Exports
• Id: export port id for path/hierarchy building• Title: as menu label• Description: as tooltip• Controller: the controller name• Action: the action name• Argument: If the action has a parameter• Extends: The injection point in the menu
structure
24BEXIS Tech Talk #8: Implementation Notes
Module Publishing
• Shell is already published• Areas folder does not include the module• Publish the module into a folder• Create a zip bundle
25BEXIS Tech Talk #8: Implementation Notes
Module Registration
• Method 1:– Update Modules.Catalog.xml– Create the <moduleID>folder under Shell/Areas– Unzip the module zip file into the folder
• Method 2:– Use the SAM’s registration feature
26BEXIS Tech Talk #8: Implementation Notes
Module Management
27BEXIS Tech Talk #8: Implementation Notes
Documents
• Module Development Recipes• Naming Conventions• DLM API docs
28BEXIS Tech Talk #7: Configuration and Change Management
Outlook
What‘s next in the talk series?
Nothing
2929
Thanks!Questions?
Contact:[email protected]://bexis2.uni-jena.de
Acknowledgment
BEXIS Tech Talk #8: Implementation Notes