Exemple #1
0
$last_name->setClass("inputForm");
$email = new InputEmail();
$email->setClass("inputForm");
$btn_save = new Button();
$btn_save->setCaption("Save");
$btn_save->setClass("buttonform");
$btn_save->onTap(save());
$table_form->addControl($name, 1, 1);
$table_form->addControl($last_name, 2, 1);
$table_form->addControl($email, 3, 1);
$table_button = new Table();
$table_button->addControl($btn_save, 1, 1);
$table->addControl($table_form, 1, 1);
$table->addControl($table_button, 2, 1);
$win->addControl($table);
$win->Render();
function refresh()
{
    $ur = "http://www.demo.kikapptools.com/magento/apiKikApp/api.php?metodo=userData&customerToken=" . $token;
    $http = new httpClient();
    $result = $http->Execute('GET', $ur);
    $sdtUser = array("firstname" => DataType::Character(35), "lastname" => DataType::Character(50), "email" => DataType::Email());
    Data::FromJson($sdtUser, $result);
    //Asignamos valores a los inputs.
    $name = $sdtUser['firstname'];
    $last_name = $sdtUser['lastname'];
    $email = $sdtUser['email'];
}
function save()
{
    ProgressIndicator::Show();