I am trying to create a validator in my custom properties panel. The validator needs to check all keys in db to see if the workflow name (id) can be used (since this is the unique key). I am having a hard time injecting my Angular service, though i have read How to register custom service for injection - #3 by Etchelon
It seems no matter what i use, value, factory, or type, it then complains about the service’s constructor items not having a provider, so i add workflowRepo, then it wants a provider for http…etc.
export default {
__init__: [
'router',
'handler',
'apiService',
'workFlowRepo',
'workflowService'
],
router: ['type', Router],
handler: ['type', HttpHandler],
http: ['type', HttpClient],
apiService: ['type', APIService],
workflowRepo: ['type', WorkflowRepo],
workflowService: ['type', WorkflowService]
};
how I am using in properties provider:
static $inject = [
'camundaPropertiesProvider',
'workflowService'
];
constructor (
private camundaPropertiesProvider,
private workflowService
) {