Closed wvkehoe closed 2 years ago
Hi @wvkehoe, the GetProperties
and GetFullPropertyTree
functions will only return properties that are defined by engine i.e. properties that are part of the engine JSON-RPC specification.
For custom properties that are set by e.g. the sense-client you will need to use the GetPropertiesRaw
or GetFullPropertyTreeRaw
functions instead. https://pkg.go.dev/github.com/qlik-oss/enigma-go#GenericObject.GetPropertiesRaw
There is an example for this as well here
@wennmo Thanks for the follow-up. I was able to use GetPropertiesRaw with this type unmarshal structure:
type customObjectProperties struct {
enigma.GenericObjectProperties
Title string `json:"title"`
Subtitle string `json:"subtitle"`
Footnote string `json:"footnote"`
}
to obtain the title, subtitle and footnote for each chart.
Unfortunately, when I try to do a similar approach with using GetPropertiesRaw on a sheet object to get its ownerId, publish status, creation and modified date using the following unmarshal structure, I don't get any results (just emty strings and :
type customSheetProperties struct {
enigma.GenericObjectProperties
OwnerId string `json:"ownerId"`
Published bool `json:"published"`
CreatedDate string `json:"createdDate"`
ModifiedDate string `json:"modifiedDate"`
}
Do you know where I can find the documentation on custom sheet properties?
Ok, great that it lead to some progress 👍
The properties defined by the client on a sheet (and other objects) should be documented on qlik.dev.
If you want to take a closer look at what properties that are returned from engine for a specific object/call you can also log the traffic in enigma-go
. There is an example for how to enable logging here
Hi @wvkehoe, can we consider this issue resolved?
Closing issue for now, since there are no remaining questions. Feel free to reopen or create a new issue if needed.
Description
It appears that the GetProperties and GetFullPropertyTree methods on a chart object do not return all of the properties of the chart.
Steps to Reproduce
Expected behavior
It is expected to find properties like title, subtitle, footnote, etc. but these properties are not included in the results of the chartObject.GetProperties method call.
Actual behavior
The results of the chartObj.GetProperties call includes content as shown below:
Environment
MacOS Big Sur 11.6.1, enigma-go v3.2.0
Operating system
Versions