Server Business Rules |
This topic discusses ShipExec server side business rules.
[TODO]
Business Rule Metadata is a required attribute on the business rule class. It is used by ShipExec to provide information about the business rule as well as assign a specific company to the business rule. The metadata is used during the load business rule process in the configuration tool.
[BusinessRuleMetadata(Author = "Joe", AuthorEmail = "joe@somecompany.com", Description = "Joe's Business Rules", Name = "Joe's Business Rules", Version = "1.0", CompanyId = "00000000-0000-0000-0000-000000000000")]
Property | Description |
---|---|
Author | This metadata property is required and should contain the author of the business rule. It is displayed in Management Studio. |
AuthorEmail | This metadata property is required and should contain the email address of the author. It is displayed in Management Studio. |
CompanyId | This metadata property is required and should contain the company id (guid) for the business rule. This is used during the load business rule process in the configuration tool to add the business rule to the company's configuration. It is displayed in Management Studio. |
Description | This metadata property is optional and is used to describe the business rule class. It is displayed in Management Studio. |
Name | This metadata property is required and should contain the display name for the business rule. It is displayed in Management Studio. |
Version | This metadata property is required and should contain the version of the business rule. It is displayed in Management Studio. |
Business rule properties are set when the business rule class is instantiated and can be used within the business rule methods.
Property | Description |
---|---|
BusinessObjectApi | Business Rule property that contains an instance of a IBusinessObjectApi. |
Logger | Business rule property that contains an instance of a ILogger. |
Profile | Business rule property that contains an instance of a IProfile. |
BusinessRuleSettings | Business rule property that contains a list of BusinessRuleSetting. BusinessRuleSettings are created in ShipExec Management Studio and are passed into the business rule class. |
Method | Description |
---|---|
Load Rules | |
Business rules hook that returns a ShipmentRequest object that can be used by shipping clients. | |
Rate Rules | |
Business rule hook that executes before the rate event. | |
Business rules hook that can be used to override the Rate event. | |
Business rule hook that executes after the rate event. | |
Ship Rules | |
Business rule hook that executes before the ship event. | |
Ship | Business rules hook that can be used to override the Ship event. |
Business rule hook that executes after the ship event. | |
Print Rules | |
Business rule hook that executes after the print event. | |
Business rule hook that executes after the print event. | |
Business rule hook that executes after the print event. | |
Business rules hook that executes when an error occurs while processing a shipment and can be used to return an error label to the shipping client. | |
Reprocess Rules | |
Business rules hook that executes before the Reprocess event. | |
Business rules hook that executes after the Reprocess event. | |
Void Rules | |
Business rules hook that executes before the Void event. | |
Business rules hook that can be used to override the Void event. | |
Business rules hook that executes after the Void event. | |
Group Rules | |
Business rules hook that executes before the CloseGroup event. | |
Business rules hook that executes after the CloseGroup event. | |
Business rules hook that executes before the CreateGroup event. | |
Business rules hook that executes after the CreateGroup event. | |
Business rules hook that executes before the ModifyGroup event. | |
Package List Rules | |
Business rules hook that executes before the ModifyPackageList event. | |
Business rules hook that executes after the ModifyPackageList event. | |
Manifest Rules | |
Business rules hook that executes before the CloseManifest event. | |
CloseManifest | Business rules hook that can be used to override the CloseManifest event. |
Business rules hook that executes after CloseManifest event. | |
Transmit Rules | |
Business rules hook that executes before the Transmit event. | |
Business rules hook that can be used to override the Transmit event. | |
Business rules hook that executes after the Transmit event. | |
Batch Rules | |
Business rules hook that sets the list of batch references displayed on the Batch screen in the shipping client. | |
Business rules hook that loads a batch. | |
Business rules hook to parse a custom file of batch records. | |
Business rules hook that executes before the ProcessBatch event. | |
Business rules hook that executes after the ProcessBatch event. | |
Pack Rules | |
Business rules hook that executes before the Pack event. | |
Business rules hook that executes after a Pack event. | |
Business rules hook that executes before the PackRate event. | |
Business rules hook that executes after a PackRate event. | |
Address Validation Rules | |
Business rules hook that executes before the AddressValidation event. | |
Business rules hook that can be used to override the AddressValidation event. | |
Business rules hook that executes after the AddressValidation event. | |
Collection Rules | |
Business rules hook that sets the list of box types displayed on the shipping screen in the shipping client. | |
Business rules hook that sets the list of available commodity contents that are available on the commodities screen in the shipping client. | |
Business rules hook that sets the list of available commodity contents that are available on the commodities screen in the shipping client. | |
Miscellaneous Rules | |
Business rule hook that exposes a custom method available to the shipping client to send messages to server side business rules. |