Need to build custom Picker for cdt

Requirement : Team we have an admin application which performs some write to DB , currently cdt is hardcoded as scope is limited to some apps.

Now we want to make it dynamic like after selecting datastore it should populate all the CDT associated with it or a custom picker to just search from all the CDT of system.

Any idea?

  Discussion posts and replies are publicly visible

Parents
  • Hi there,

    As far as I know, there is no direct method to get a list of all the CDTs of the system. But the other way round can be creating a dictionary in a rule with the CDT and its type number or any other identifier that you use to store the selected CDT. And then using it as choiceLabels and choiceValues in a dropdown or picker. The only caveat here is that you will have to manually add all the required CDTs in that rule and update it whenever a new CDT is introduced. 

    I'm interested in knowing what other people have to say about this problem. 

  • I think that a Create-Read-Update-Delete DB UI is not a good use case for Appian. Did you consider alternatives?

  • We are not creating CRUD forms. Basically we have an API which is bringing some documents from another environment and those new doc id need to be updated into DB but documents are part of multiple applications and hence multiple tables will be needed to update on a dynamic basis. Let say i am moving application A documents from source to Appian system and it should update A table with new doc id. Tried to see if writetomultiple ds can work but have to hard cord CDT in multiple IF.

  • 0
    Certified Lead Developer
    in reply to gauravp0003

    OK. Then ...

    We did something similar. At least in terms of implementation. My suggestion is as follows:

    Each application which wants to accept documents has to implement its own process model with a defined set of input parameters.

    I assume that the data from the API contains some values by which you find out which application is targeted.

    Create a decision table mapping these values to process models. Put this decision table into a start process smart service which forwards the data in defined parameters.

    This would be a pretty simple and scalable design.

Reply
  • 0
    Certified Lead Developer
    in reply to gauravp0003

    OK. Then ...

    We did something similar. At least in terms of implementation. My suggestion is as follows:

    Each application which wants to accept documents has to implement its own process model with a defined set of input parameters.

    I assume that the data from the API contains some values by which you find out which application is targeted.

    Create a decision table mapping these values to process models. Put this decision table into a start process smart service which forwards the data in defined parameters.

    This would be a pretty simple and scalable design.

Children