From wiki.ginstr.com
Jump to: navigation, search
(Gets ginstr user data)
(Gets ginstr user data)
Line 9: Line 9:
 
===Gets ginstr user data===
 
===Gets ginstr user data===
  
:;<code>[gn:act_getUserData]|[target,keyword]</code>
+
:;<code>[gn:act_getUserData]|[target,keyword,triggerTarget,triggerEvent]</code>
  
 
:{| class="wikitable sortable" style="font-size: 85%; text-align: left;"
 
:{| class="wikitable sortable" style="font-size: 85%; text-align: left;"
Line 31: Line 31:
 
* <code>is24HoursTime</code> - gets time format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]] and if ends with "a" or "A" sets the [[target]] variable to <code>true</code>
 
* <code>is24HoursTime</code> - gets time format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]] and if ends with "a" or "A" sets the [[target]] variable to <code>true</code>
 
* <code>is24HoursDateTime</code> - gets dateTime format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]] and if ends with "a" or "A" sets the [[target]] variable to <code>true</code>
 
* <code>is24HoursDateTime</code> - gets dateTime format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]] and if ends with "a" or "A" sets the [[target]] variable to <code>true</code>
 +
|-
 +
| <code>[[target|triggerTarget]] (M103.8)</code>
 +
| [[target]] on which the defined event will be triggered
 +
* Valid [[target|targets]]:
 +
** any [[target|widget]]
 +
|-
 +
| <code>[[:Category:Events|triggerEvent]] (M103.8)</code>
 +
| [[:Category:Events|event]] from [[target]] which will be triggered
 +
* Valid [[:Category:Events|event]]:
 +
** any [[:Category:Events|event]]
 
|-
 
|-
 
|}
 
|}

Revision as of 09:37, 22 January 2020

gn:act_getUserData

Description
Action is used to get ginstr user data and store it into target
Action returns
void

Action signatures

Gets ginstr user data

[gn:act_getUserData]|[target,keyword,triggerTarget,triggerEvent]
Parameter Description
target target into which user data will be stored
keyword defines which type of ginstr user information we will retrieve

Can be:

triggerTarget (M103.8) target on which the defined event will be triggered
triggerEvent (M103.8) event from target which will be triggered

Example

screen.xml
<FrameLayout
    android:id="@+id/exampleFrame"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:visibility="gone"
    gn:act_set="[gn:act_getUserData]|[@+id/testWidget,dateFormat]" />

<com.ginstr.widgets.GnTextView
    android:id="@+id/testWidget" 
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"/>

after action execution

value in testWidget: dd MMM yyyy (depends on setting in ginstr web)