go to post Eduard Lebedyuk · Apr 17 You need to iterate on value: // extract json content from the request: set dynRequestJsonPayload = {}.%FromJSON(%request.Content) #dim JsonIterator As %Iterator.AbstractIterator set JsonIterator = dynRequestJsonPayload.%GetIterator() // iterate on json structure: if dynRequestJsonPayload '= "" { while JsonIterator.%GetNext(.key, .value, .NodeType) { if NodeType = "string" { do GlobalTrace("NodeType: " _ NodeType _ "; key: " _ key _ "; value: " _ value) } elseif NodeType = "array" { // i want to iterate on this array... // the following line throws the exeception "ERREUR #5002: Erreur ObjectScript: <INVALID OREF>traitementUFI+34^common.REST.1" set JsonIteratorSecondary = value.%GetIterator() } else { // Do something } } }
go to post Eduard Lebedyuk · Apr 16 Do you have Stay Connected setting equal to -1? Try setting it to a lower value, i.e. 30.
go to post Eduard Lebedyuk · Dec 29, 2023 The most secure approach is to use Privileged Routine Application.
go to post Eduard Lebedyuk · Dec 19, 2023 You can set it programmatically: set package = ##class(%PackageDefinition).%OpenId("User",,.sc) zw package package=2@%Library.PackageDefinition ; <OREF> +----------------- general information --------------- | oref value: 2 | class name: %Library.PackageDefinition | %%OID: $lb("User","%Library.PackageDefinition") | reference count: 2 +----------------- attribute values ------------------ | %Concurrency = 1 <Set> | ClientName = "" | Description = "" | GlobalPrefix = "" | Name = "User" | OwnerName = "" | RtnPrefix = "" | SQLName = "" +----------------- swizzled references --------------- | i%list = "" <Set> | r%list = "" <Set> +-----------------------------------------------------
go to post Eduard Lebedyuk · Dec 12, 2023 Are you getting Ens.StreamContainer? It would be OriginalFilename property in that case.
go to post Eduard Lebedyuk · Nov 30, 2023 Add %JSONIGNOREINVALIDFIELD param to your class and don't add Messages/SharedRelations properties. Parameter %JSONIGNOREINVALIDFIELD As BOOLEAN = 1;
go to post Eduard Lebedyuk · Nov 28, 2023 Why not just use %JSONFIELDNAME? Anyway, this works: Property "@name" As %String; Property "😋_are_you_sure_😋" As %String;
go to post Eduard Lebedyuk · Nov 5, 2023 What's "RO" stand for? ReadOnly. After the customer deployment, if there is any change made on the production settings (e.g. changing an AE Title on the DICOM service), those settings are stored in the APPCODE, and the settings will be lost after a container PODS restart (kubernetes recreating the PODS). Two ways to avoid that: Use System Default Settings Map only Production class to a third ReadWrite database, usually APPCONFIG
go to post Eduard Lebedyuk · Oct 25, 2023 Set ..%SessionId= "" before each SendSync/SendAsync should force a new session for each message sent.
go to post Eduard Lebedyuk · Oct 4, 2023 Sure, use indirection: >s ^ABC(1,2)=3 >s TEMP = "^ABC(1,2)" >w @TEMP 3
go to post Eduard Lebedyuk · Aug 29, 2023 Alternative approach: create a user which has access only to schemas you need.
go to post Eduard Lebedyuk · Aug 21, 2023 To check all parts of the request you can use this utility method which outputs all objects as a response. Just add this to any part of your code: set %response.ContentType = "html" do ##class(%CSP.Utils).DisplayAllObjects() return $$$OK