From wiki.ginstr.com
Jump to: navigation, search
m (formatting)
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]</code>
  
{| class="wikitable sortable" style="font-size: 85%; text-align: left;"
+
:{| class="wikitable sortable" style="font-size: 85%; text-align: left;"
 
|-
 
|-
 
! scope="col" | Parameter
 
! scope="col" | Parameter
 
! scope="col" | Description
 
! scope="col" | Description
 
|-
 
|-
| [[target]]
+
| <code>[[target]]</code>
| [[target]] target into which user data will be stored
+
| [[target]] into which user data will be stored
 
* Valid [[target|targets]]:
 
* Valid [[target|targets]]:
:*[[Datatypes#text|text]]
+
:*<code>[[Datatypes#text|text]]</code>
 
|-
 
|-
| keyword
+
| <code>keyword</code>
| keyword defines which type of ginstr user information we will retrieve
+
| defines which type of ginstr user information we will retrieve
 
Can be:
 
Can be:
* <code>dateFormat</code> - gets date format set for ginstr user in ginstr web settings, returned formats [https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html formats]
+
* <code>dateFormat</code> - gets date format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]], returned formats [https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html formats]
* <code>timeFormat</code> - gets time format set for ginstr user in ginstr web settings, returned formats [https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html formats]
+
* <code>timeFormat</code> - gets time format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]], returned formats [https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html formats]
* <code>dateTimeFormat</code> - gets dateTime format set for ginstr user in ginstr web settings, returned formats [https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html formats]
+
* <code>dateTimeFormat</code> - gets dateTime format set for ginstr user in [[setup_ginstr_web#General_Settings|ginstr web settings]], returned formats [https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html formats]
 
* <code>userName</code> - gets userName of ginstr user
 
* <code>userName</code> - gets userName of ginstr user
 
|-
 
|-
Line 51: Line 51:
  
 
=====after action execution=====
 
=====after action execution=====
value in testWidget: <code>dd MMM yyyy</code> (depends on setting in ginstr web)
+
value in <code>testWidget</code>: <code>dd MMM yyyy</code> (depends on setting in [[ginstr web]])

Revision as of 20:05, 12 July 2017

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]
Parameter Description
target target into which user data will be stored
keyword defines which type of ginstr user information we will retrieve

Can be:

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)