Question dbtech-ecommerce/categories/{id}/ parameters

Status
Not open for further replies.

cpatrianakos

Customer

dbtech-ecommerce/categories/{id}/
Updates the specified category​

Parameters​

InputTypeDescription
category[title]string
category[description]string
category[parent_node_id]integer
category[display_order]integer

On the above, I am struggling to figure out the Parameters.

as you can see, I tried a few different things here. I can make a post to update a Category, but it just isnt reading any of my Edits.

C#:
        var category = new Dictionary<string, object>
        {
            { "category[title]", $"{title}" },
            { "description", description },
            { "parent_category_id", NP.Parent_Category_ID.text },
            { "display_order", NP.Display_Order.text }
        };

        string json = JsonConvert.SerializeObject(new { category });

as you see, I try a few different ideas between the different paameters, nothing I tried has seemed to work. the fact that you have brackets in the text tells me I am missing something. I figured out how to use the "Context[]" ones, but this one seems to go above my head.
 
I apologize, I figured it out. For anyone in the future that wants to know:


C#:
        Dictionary<string, string> content = new() {
            { "title", NP.Title.text },
            { "description", NP.Description.text },
            { "parent_category_id", NP.Parent_Category_ID.text },
            { "display_order", NP.Display_Order.text }
        };

        using (UnityWebRequest www = UnityWebRequest.Post(url, content)) {
 
Status
Not open for further replies.

DragonByte eCommerce

XenForo 2.0.6+ XenForo 2.1.x XenForo 2.2.x
Seller
DragonByte Technologies
Release date
Last update
Total downloads
2,480
Customer rating
4.83 star(s) 6 ratings
Back
Top