dev commit
[brisk.git] / web / prefs.js
index 51b7eba..54d328d 100644 (file)
@@ -65,7 +65,7 @@ function prefs_apply(prefs_new, is_update, is_volat)
     }
 
     if (relo || !is_update) {
-        for (i = g_tables_auth_n ; i < g_tables_n ; i++) {
+        for (i = g_tables_appr_n ; i < g_tables_n ; i++) {
             if (i % 4 == 0) {
                 $('tr_noauth'+i).style.display = (prefs_new.listen == l_list_isol ? 'none' : '');
             }
@@ -79,9 +79,13 @@ function prefs_apply(prefs_new, is_update, is_volat)
             tra.show_noauth();
         }
 
-        if (false) {
+        if (true) {
             // ricalculation of standup area
+            g_prefs.listen = prefs_new.listen;
+
+            console.log('here we are');
             if (standup_data_old != null) {
+                console.log('here we are2');
                 standup_data = standup_data_old;
                 standup_data_old = null;
                 j_stand_cont(standup_data);
@@ -114,8 +118,12 @@ function prefs_save()
 
     ret = server_request('mesg', 'prefs|save','__POST__', 'prefs', JSON.stringify(g_prefs));
 
-    if (ret == 1)
+    if (ret == 1) {
         $('preferences').style.visibility = 'hidden';
+    }
+    else {
+        alert(ret);
+    }
 }
 
 function prefs_reset()
@@ -213,7 +221,7 @@ function list_set(what, is_update, info)
 
 
     if (relo || !is_update) {
-        for (i = g_tables_auth_n ; i < g_tables_n ; i++) {
+        for (i = g_tables_appr_n ; i < g_tables_n ; i++) {
             
             if (i % 4 == 0) {
                 $('tr_noauth'+i).style.display = (what == 'isolation' ? 'none' : '');