Page 1 of 1

Catalog Costs

Posted: Tue Aug 11, 2020 7:05 am
by johann
Hi simPRO people. :-)

Is it possible to get the cost values of Catalog items in the job items, quote items and cost center endpoints? We can list the items and get the price and qty etc, but not the costs.

We can get the costs from the catalogs endpoint obviously but it requires a lot of merging, and I thought we'd just ask about including it in the other endpoints as well first.

Thanks,
Johann

Re: Catalog Costs

Posted: Wed Aug 12, 2020 12:57 am
by Muqeet
Hello Johann,

You could probably use BasePrice from the job cost center catalog endpoint for cost value of an item.

Re: Catalog Costs

Posted: Wed Aug 12, 2020 8:11 am
by johann
Thanks Muqeet,

Why doesn't it include the BasePrice when I include the "Items" column in the job cost center request and we use "?display=all". Isn't that supposed to include all the sub-resources. That's what the documentation says: https://developer.simprogroup.com/apido ... bresources

But it never seems to fully work - it only includes a small subset of the sub-resources. For example in this case the BasePrice (amongst a lot of other things) is missing.

Surely this is a bug if you say in the documentation:
"Some resources have subresources. For example, jobs contain sections which contain cost centres, etc. You can fetch all of this data in one call using the query string parameter display=all... The response contains the sections, cost centres, labour items, catalog items, and all of the other data which is contained within the subresources."

Re: Catalog Costs

Posted: Thu Aug 13, 2020 1:25 am
by rick.lan
Hi Johann,

sorry for the incorrect information in the API documentation, ?display=all feature is supposed to be for users to retrieve a job data with sections / costcenters hierarchy, however, it is meant to display limited data only.

With most of the end points we can retrieve data directly from database without the need of data objects. However, for end points like jobs/quotes (and their sub end points) that have complex structure, we need to access it via object so all the values can be calculated properly.

Hence why with ?display=all we don't return too much data because it needs to load multiple data objects at once and may cause performance issue (we know some of our customers have 10+ sections in a job and each section has 3+ cost centers).

We understand the need of accessing basePrice and markup in ?display=all feature, we will add the request to our to do list.

cheers,

Re: Catalog Costs

Posted: Thu Aug 13, 2020 4:52 am
by johann
Hi Rick,

Thanks for that explanation. That calculated fields can have a performance impact makes sense. We would still prefer it all in one go though, haha. :-)

But I appreciate that you'll consider adding the non-calculated fields like basePrice and markUp. We'll keep that in mind if we find any others, where it's clear the user enters the data, rather than it being calculated.

Cheers
Johann

Re: Catalog Costs

Posted: Wed Sep 09, 2020 12:11 am
by johann
Sorry to give this a bump, but I was hoping for some news on this? Is there a feature request ticket # for adding basePrice and markup in display=all?

Thanks,
Johann

Re: Catalog Costs

Posted: Thu Sep 17, 2020 12:05 am
by johann
Hi again,

We have a second client now after this information - is this slated for a release somewhere on the roadmap yet?

Thanks,
Johann

Re: Catalog Costs

Posted: Thu Sep 17, 2020 12:48 am
by Muqeet
Hello Johann,

We have a ticket to make the requested fields available on job endpoint. We do not have a release date for it at the moment. We will this topic when we have set release date/version set for it.