问题
I'm in an AX 2012 R2 environment.
I've a custom document service in our environment. I can see it by opening the AIFService form in the AOT. There may be a better way of browsing all the available document services. I haven't found it yet.
Anyway, how do I find out all the parts (query, document name, document class name) associated with this custom service, assuming the standard naming conventions haven't been followed?
Thank you.
回答1:
To know what document services are available, go to the AOT - Classes - AIFDocumentService. Right click the class, then Add-Ins - Type hierarchy browser. You'll get a list of all document service classes.
To find the document class based on the service, just open the source code of the service and look at the code. The create
method for example takes a parameter of the type of the document and the find
methods returns an object of that type.
In the document class declaration you will find a marco. The name of that macro (minus DCT) will be the name of your query. The AxBC classes will be Ax
+ the name of the table, for example AxInventTable
.
回答2:
You can use this code:
AxdWizardParameters axdWizardParameters;
;
axdWizardParameters = AifServiceClassGenerator::getServiceParameters(classStr(YOURSERVICECLASSNAME));
info(axdWizardParameters.parmAifServiceClassName());
info(axdWizardParameters.parmAifEntityClassName());
info(axdWizardParameters.parmName());
info(axdWizardParameters.parmQueryName());
来源:https://stackoverflow.com/questions/24519411/find-out-aif-document-service-components