Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow Umbraco Data Types as Order Property Editors #433

Open
philipdanielhayton opened this issue Sep 21, 2023 · 0 comments
Open

Allow Umbraco Data Types as Order Property Editors #433

philipdanielhayton opened this issue Sep 21, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@philipdanielhayton
Copy link

Is your feature request related to a problem? Please describe.
It would be great if we could use existing Data Types as property editors on Order Properties.

Whilst this is kind of possible at the moment, it's tricker than it needs to be because the implementer must:
(A) go digging through the Umbraco code base to find the appropriate view to use, and
(B) structure the config in the way expected by the corresponding editor

For example; one of our clients needs the ability to customize confirmation emails using 'canned messages' depending on the fulfilment requirements. We store the canned messages as content nodes in Umbraco and the most appropriate one is 'picked' from the order edit screen. I did manage to get this working the MNTP, but it was a bit fiddly and I had to basically copy the config from the umbracoDataType table.

        { 
            alias: "instructionsTemplate", 
            label: "Instructions", 
            isReadOnly: false, 
            view: 'contentpicker',
            config: {
                "startNode": {
                    "type": "content",
                    "query": "$root/settings/storeSettingsFolder/storeSettings[@nodeName=\"Transfers\"]/transferEmailTemplateRepository"
                },
                "filter": "transferEmailTemplate",
                "minNumber": 0,
                "maxNumber":0,
                "showOpenButton":false,
                "ignoreUserStartNodes":false
            }
        }

Describe the solution you'd like
It would be great if we could just re-use an existing Data Type by supplying it's name or nodeId, something like this:

        {
            alias: "instructionsTemplate",
            label: "Instructions",
            isReadOnly: false,
            datatype: '[MNTP] Canned Response Picker'  OR '6060'
        }

Describe alternatives you've considered
As mentioned it is possible at the moment, so it's not a massive issue, but it does require a bit of digging and trial & error.

@philipdanielhayton philipdanielhayton added the enhancement New feature or request label Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant