Adds action button to display it in plugin menu. Button will be automatically removed on iikoFront restarts or you will dispose method's return value.
Namespace: Resto.Front.Api.V3.Extensions
Assembly: Resto.Front.Api.V3 (in Resto.Front.Api.V3.dll) Version: 4.1.1236.1 (4.1.1236.1)
Syntax
C#
public static IDisposable AddButton( this IPluginIntegrationService service, string caption, Action<IViewManager, IReceiptPrinter> action )
Parameters
- service
- Type: Resto.Front.Api.V3IPluginIntegrationService
- caption
- Type: SystemString
Text to display on button in 'Additional screen' -> 'Plugins menu'." - action
- Type: SystemActionIViewManager, IReceiptPrinter
Action to execute on button pressed.
Return Value
Type: IDisposableYou may dispose result to remove button.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type IPluginIntegrationService. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).See Also