I have two dropdownlists which gets their data from a database table. Can such a custom property editor be handled by Courier? I am creating this as a property editor as I need only certain user types in Umbraco to be able to see them on the page.
Some users have taken a different approach when it comes to database tables in particular - rather than using a data resolver they use a sort of custom migration that adds a startup event handler that checks for the table and data and creates/updates the data as needed on startup. Of course, there are some tradeoffs with this approach in that you, potentially, can slow the app start up.
Courier can handle custom editors, but the real question is, do you need to resolve / change its value during deployment?
The really depends on what kind of data you store in the editor. If you store a key that changes between environments then yes, you need a resolver to change that value. If the value is the same on all your environments, then you dont have to do anything, courier will transfer the value.
In your case, with the custom table, courier does not handle deploying the entire table, I would recommend you do that separately, using the standard ways of deploying sql data.
Custom Property Editors with Courier
Hi,
I have two dropdownlists which gets their data from a database table. Can such a custom property editor be handled by Courier? I am creating this as a property editor as I need only certain user types in Umbraco to be able to see them on the page.
You can create a custom resolver - where your custom logic to handle the sync of your custom database table(s) will happen. See these (rather old) docs: https://our.umbraco.org/documentation/Add-ons/UmbracoCourier/Developer/DataResolvers and also some examples of other custom resolvers https://github.com/display/Umbraco-courier-providers .
Some users have taken a different approach when it comes to database tables in particular - rather than using a data resolver they use a sort of custom migration that adds a startup event handler that checks for the table and data and creates/updates the data as needed on startup. Of course, there are some tradeoffs with this approach in that you, potentially, can slow the app start up.
Courier can handle custom editors, but the real question is, do you need to resolve / change its value during deployment?
The really depends on what kind of data you store in the editor. If you store a key that changes between environments then yes, you need a resolver to change that value. If the value is the same on all your environments, then you dont have to do anything, courier will transfer the value.
In your case, with the custom table, courier does not handle deploying the entire table, I would recommend you do that separately, using the standard ways of deploying sql data.
Exactly the answers I was looking for Per and Paul. Much appreciated. Also write an own resolver is the full version of Courier required.
Poornima
Nope, you can just use the express version for that
Thanks Per, I also see that a version of Courier was released last week. Do you have any release notes for the same?
Poornima
is working on a reply...