forked from sergejey/majordomo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
db_terminal.sql
2411 lines (2147 loc) · 211 KB
/
db_terminal.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
-- phpMyAdmin SQL Dump
-- version 3.4.9
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: Dec 03, 2015 at 03:49 PM
-- Server version: 5.1.46
-- PHP Version: 5.4.30
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
--
-- Database: `db_terminal`
--
-- --------------------------------------------------------
--
-- Table structure for table `admin_users`
--
DROP TABLE IF EXISTS `admin_users`;
CREATE TABLE IF NOT EXISTS `admin_users` (
`ID` tinyint(3) unsigned NOT NULL AUTO_INCREMENT,
`NAME` varchar(100) NOT NULL DEFAULT '',
`LOGIN` varchar(100) NOT NULL DEFAULT '',
`PASSWORD` varchar(100) NOT NULL DEFAULT '',
`EMAIL` varchar(100) NOT NULL DEFAULT '',
`COMMENTS` text,
`ACCESS` text,
`PRIVATE` tinyint(3) unsigned NOT NULL DEFAULT '0',
`EMAIL_ORDERS` tinyint(3) unsigned NOT NULL DEFAULT '0',
`EMAIL_INVENTORY` tinyint(3) unsigned NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ;
--
-- Dumping data for table `admin_users`
--
INSERT INTO `admin_users` (`ID`, `NAME`, `LOGIN`, `PASSWORD`, `EMAIL`, `COMMENTS`, `ACCESS`, `PRIVATE`, `EMAIL_ORDERS`, `EMAIL_INVENTORY`) VALUES
(1, 'Administrator', 'admin', '21232f297a57a5a743894a0e4a801fc3', '[email protected]', '', 'control_modules,control_access,master,cms_docs,news,statistic,newsletter,backup,edit_templates,newslist,saverestore,skins,settings,dateselect,thumb,footercode,holdingpage,dashboard,events,users,terminals,mediabrowser,player,commands,classes,history,locations,methods,properties,objects,pvalues,shoutbox,shoutrooms,jobs,btdevices,weather,usbdevices,app_mediabrowser,app_products,app_tdwiki,app_weather,layouts,scripts,rss_channels,languages,pinghosts,watchfolders,app_player,app_gpstrack,webvars,patterns,onewire,app_calendar,xray', 0, 0, 0);
-- --------------------------------------------------------
--
-- Table structure for table `app_quotes`
--
DROP TABLE IF EXISTS `app_quotes`;
CREATE TABLE IF NOT EXISTS `app_quotes` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`BODY` text,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
-- --------------------------------------------------------
--
-- Table structure for table `blockly_code`
--
DROP TABLE IF EXISTS `blockly_code`;
CREATE TABLE IF NOT EXISTS `blockly_code` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`SYSTEM_NAME` varchar(255) NOT NULL DEFAULT '',
`CODE_TYPE` int(3) NOT NULL DEFAULT '0',
`CODE` text,
`XML` text,
`UPDATED` datetime DEFAULT NULL,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=85 ;
--
-- Dumping data for table `blockly_code`
--
INSERT INTO `blockly_code` (`ID`, `SYSTEM_NAME`, `CODE_TYPE`, `CODE`, `XML`, `UPDATED`) VALUES
(1, 'script14', 0, '', '', '2014-09-03 12:28:53'),
(2, 'method87', 0, '//$params[''t'']\r\n $this->setProperty("updated",time());\r\n $this->setProperty("updatedTime",date("H:i",time()));\r\n $this->setProperty("alive",1); \r\n \r\n$ot=$this->object_title;\r\n$alive_timeout=(int)$this->getProperty("aliveTimeOut");\r\nif (!$alive_timeout) {\r\n $alive_timeout=30*60;\r\n}\r\nclearTimeOut($ot."_alive");\r\nsetTimeOut($ot."_alive","sg(''".$ot.".alive'',0);",$alive_timeout); \r\n\r\nif (!isset($params[''h''])) {\r\n return;\r\n}\r\n\r\n\r\n$old_temp=$this->getProperty(''humidity'');\r\n$t=round($params[''h''],1);\r\n\r\nif ($t>100) return;\r\n\r\n$this->setProperty(''humidity'',$t);\r\nif ($params[''uptime'']) {\r\n $this->setProperty(''uptime'',$params[''uptime'']);\r\n}\r\n\r\nif ($t>$old_temp) {\r\n $d=1;\r\n} elseif ($t<$old_temp) {\r\n $d=-1;\r\n} else {\r\n $d=0;\r\n}\r\n$this->setProperty(''direction'',$d);\r\n\r\n$linked_room=$this->getProperty("LinkedRoom");\r\nif ($linked_room) {\r\n setGlobal($linked_room.''.Humidity'',$t);\r\n}', '', '2014-09-03 13:51:53'),
(7, 'script16', 0, '// got data\r\n$sensor=$params[''sensor''];\r\nif (!$sensor) return 0;\r\n\r\n$hum=(int)str_replace(''-'','''',$params[''other_params''][6]);\r\nif ($hum>0 && $hum<=100) {\r\n callMethod(''hum''.$sensor.''.humChanged'',array(''h''=>$hum));\r\n}\r\n\r\n//$temp=((int)str_replace(''-'','''',$params[''other_params''][4]))/10;\r\n$b1 =(int)str_replace(''-'','''',$params[''other_params''][4]);\r\n$b2 =(int)str_replace(''-'','''',$params[''other_params''][5]);\r\n$y_temp=256*($b2 & 15)+$b1;\r\nif (($b2 & 8) != 0 ) { // отрицательное значение температуры\r\n $y_temp=4096-$y_temp;\r\n $temp = -1*($y_temp)/10;\r\n} else { // положительное значение температуры\r\n $temp = $y_temp/10;\r\n}\r\n\r\nif ($temp>-30 && $temp<=100) {\r\n callMethod(''temp''.$sensor.''.tempChanged'',array(''t''=>$temp));\r\n}', '', '2014-09-03 16:07:57'),
(10, 'method88', 0, '$rooms=getObjectsByClass("Rooms");\r\n$total=count($rooms);\r\nfor($i=0;$i<$total;$i++) {\r\n $rooms[$i][''room'']=getGlobal($rooms[$i][''TITLE''].''.Title'');\r\n if (!$rooms[$i][''room'']) {\r\n $rooms[$i][''room'']=$rooms[$i][''TITLE''];\r\n } \r\n $rooms[$i][''active'']=getGlobal($rooms[$i][''TITLE''].''.SomebodyHere'');\r\n $rooms[$i][''time'']=getGlobal($rooms[$i][''TITLE''].''.LatestActivity''); \r\n $rooms[$i][''diff'']=time()-$rooms[$i][''time''];\r\n} \r\n\r\nfunction rooms_cmp($a, $b)\r\n{\r\n if ($a[''diff''] == $b[''diff'']) {\r\n return 0;\r\n }\r\n return ($a[''diff''] < $b[''diff'']) ? -1 : 1;\r\n}\r\nusort($rooms,"rooms_cmp");\r\n\r\nif (!$rooms[0][''active'']) {\r\n $somebodyHomeText="Никого нет дома. Были в ".date(''H:i'',$rooms[0][''time''])." (".$rooms[0][''room''].")";\r\n} else {\r\n $res_rooms=array();\r\n for($i=0;$i<$total;$i++) {\r\n if ($rooms[$i][''active'']) {\r\n $res_rooms[]=$rooms[$i][''room''];\r\n } \r\n }\r\n $somebodyHomeText="Кто-то дома: ".implode(", ",$res_rooms); \r\n}\r\nsetGlobal(''somebodyHomeText'',$somebodyHomeText);\r\n//echo "Updated";', '', '2014-09-04 16:05:37'),
(9, 'method66', 0, '$latestActivity=$this->getProperty(''LatestActivity'');\r\n$this->setProperty(''LatestActivity'',time());\r\n$this->setProperty(''LatestActivityTime'',date(''H:i''));\r\n\r\n$this->setProperty(''SomebodyHere'',1);\r\n$ot=$this->object_title;\r\nif ($this->getProperty("IdleDelay")) {\r\n $activity_timeout=(int)$this->getProperty("IdleDelay");\r\n} else {\r\n $activity_timeout=10*60;\r\n}\r\nclearTimeOut($ot."_activity_timeout");\r\nsetTimeOut($ot."_activity_timeout","callMethod(''".$ot.".onIdle'');",$activity_timeout);\r\n$this->callMethod("updateActivityStatus");\r\n', '', '2014-09-04 16:05:03'),
(11, 'method89', 0, '$cmdline=''"c:\\Program Files\\nooLite\\nooLite.exe" -api ''.$params[''command''];\r\n$last_called=gg(''NoolightCommandSend'');\r\n$min_delay=3;\r\n$now=time();\r\nif (($now-$last_called)>$min_delay) {\r\n //safe_exec($cmdline);\r\n $last_callled=$now; \r\n sg(''NoolightCommandSend'',$last_called);\r\n DebMes("Noolite instant exec: ".$cmdline);\r\n system($cmdline);\r\n //exec($cmdline);\r\n} else {\r\n if ($last_callled<$now) {\r\n $last_callled=$now;\r\n }\r\n $last_called+=$min_delay;\r\n sg(''NoolightCommandSend'',$last_called);\r\n DebMes("Noolite scheduled job for ".date(''H:i:s'',$last_called));\r\n AddScheduledJob("noolight".md5($cmdline),"safe_exec(''".$cmdline."'');",$last_called);\r\n}\r\n\r\n', '', '2014-09-04 16:11:33'),
(12, 'method90', 0, '$this->setProperty("status",0);\r\n//safe_exec(''"c:\\Program Files\\nooLite\\noolite.exe" -api -off_ch''.$this->getProperty("channel"));\r\n$this->callMethod("sendCommand",array(''command''=>''-off_ch''.$this->getProperty("channel")));', '', '2014-09-04 16:12:35'),
(13, 'method91', 0, '$this->setProperty("status",1);\r\n$this->callMethod("sendCommand",array(''command''=>''-on_ch''.$this->getProperty("channel")));', '', '2014-09-04 16:13:08'),
(14, 'method92', 0, '', '', '2014-09-04 16:26:02'),
(15, 'method93', 0, '', '', '2014-09-04 16:26:13'),
(16, 'method94', 0, '', '', '2014-09-04 16:26:24'),
(17, 'method95', 0, '', '', '2014-09-04 16:26:34'),
(18, 'method96', 0, '', '', '2014-09-04 16:27:00'),
(84, 'object17_method59', 0, '$details=array();\r\n$red_state=0;\r\n$yellow_state=0;\r\n\r\n$cycles=array(''states''=>''states'',''main''=>''main'',''execs''=>''exec'',''scheduler''=>''scheduler'');\r\nforeach($cycles as $k=>$v) {\r\n $tm=getGlobal(''ThisComputer.cycle_''.$k.''Run'');\r\n if (time()-$tm>5*60) {\r\n $red_state=1;\r\n $details[]=$v." ".LANG_GENERAL_CYCLE." ".LANG_GENERAL_STOPPED.".";\r\n }\r\n}\r\n\r\n$cycles=array(''ping''=>''ping'',''webvars''=>''webvars'');\r\nforeach($cycles as $k=>$v) {\r\n $tm=getGlobal(''ThisComputer.cycle_''.$k.''Run'');\r\n if (time()-$tm>10*60) {\r\n $yellow_state=1;\r\n $details[]=$v." ".LANG_GENERAL_CYCLE." ".LANG_GENERAL_STOPPED."."; \r\n }\r\n}\r\n\r\nif ($red_state) {\r\n $state=''red'';\r\n $state_title=LANG_GENERAL_RED; \r\n} elseif ($yellow_state) {\r\n $state=''yellow'';\r\n $state_title=LANG_GENERAL_YELLOW; \r\n} else {\r\n $state=''green'';\r\n $state_title=LANG_GENERAL_GREEN; \r\n}\r\n\r\n$new_details=implode(". ",$details);\r\nif ($this->getProperty("stateDetails")!=$new_details) {\r\n $this->setProperty(''stateDetails'',$new_details);\r\n}\r\n\r\nif ($this->getProperty(''stateColor'')!=$state) {\r\n $this->setProperty(''stateColor'',$state);\r\n $this->setProperty(''stateTitle'',$state_title);\r\n if ($state!=''green'') {\r\n say(LANG_GENERAL_SYSTEM_STATE." ".LANG_GENERAL_CHANGED_TO." ".$state_title.".");\r\n say(implode(". ",$details));\r\n } else {\r\n say(LANG_GENERAL_SYSTEM_STATE." ".LANG_GENERAL_RESTORED_TO." ".$state_title);\r\n }\r\n $this->callMethod(''stateChanged'');\r\n}', '', '2015-12-03 14:46:44'),
(74, 'pattern6', 0, '', '', '2014-10-31 15:22:41'),
(75, 'pattern5', 0, '', '', '2014-10-31 15:22:55'),
(73, 'object18_method59', 0, '$details=array();\r\n$red_state=0;\r\n$yellow_state=0;\r\n\r\nif (!isOnline(''Internet'')) {\r\n $yellow_state=1;\r\n $details[]=LANG_GENERAL_NO_INTERNET_ACCESS;\r\n}\r\n\r\nif ($red_state) {\r\n $state=''red'';\r\n $state_title=LANG_GENERAL_RED; \r\n} elseif ($yellow_state) {\r\n $state=''yellow'';\r\n $state_title=LANG_GENERAL_YELLOW; \r\n} else {\r\n $state=''green'';\r\n $state_title=LANG_GENERAL_GREEN; \r\n}\r\n\r\n$new_details=implode(". ",$details);\r\nif ($this->getProperty("stateDetails")!=$new_details) {\r\n $this->setProperty(''stateDetails'',$new_details);\r\n}\r\n\r\nif ($this->getProperty(''stateColor'')!=$state) {\r\n $this->setProperty(''stateColor'',$state);\r\n $this->setProperty(''stateTitle'',$state_title);\r\n if ($state!=''green'') {\r\n say(LANG_GENERAL_COMMUNICATION_STATE." ".LANG_GENERAL_CHANGED_TO." ".$state_title.".");\r\n say(implode(". ",$details));\r\n } else {\r\n say(LANG_GENERAL_COMMUNICATION_STATE." ".LANG_GENERAL_RESTORED_TO." ".$state_title);\r\n }\r\n $this->callMethod(''stateChanged'');\r\n}', '', '2014-10-31 15:10:21'),
(60, 'script15', 0, '$weather.="Сегодня ожидается ".str_replace(''°'','' '',getGlobal(''weatherToday''));\r\n$weather.=". Завтра ".str_replace(''°'','' '',getGlobal(''weatherTomorrow''));\r\n$weather.=". Сейчас на улице ".getGlobal(''TempOutside'').''.'';\r\n$weather=str_replace(''°'','''',$weather);\r\nsay($weather,2);', '', '2014-10-30 15:32:00'),
(24, 'method97', 0, '$this->setProperty(''updated'',time());\r\n$this->setProperty(''updatedTime'',date(''H:i''));', '', '2014-09-04 17:34:10'),
(26, 'object72_method97', 0, 'say("Нажата на пульте кнопка Цэ!",2);', '', '2014-09-04 17:38:10'),
(27, 'object70_method97', 0, 'say("Нажата на пульте кнопка А!",2);', '', '2014-09-04 17:38:30'),
(28, 'object71_method97', 0, 'say("Нажата на пульте кнопка Бэ!",2);', '', '2014-09-04 17:38:48'),
(61, 'script17', 0, '$lastRead=getGlobal(''lastNewsRead'');\r\n$limit=10;\r\n\r\n$items=SQLSelect("SELECT TITLE FROM rss_items WHERE ADDED>''".date(''Y-m-d H:i:s'',$lastRead)."'' ORDER BY ADDED DESC LIMIT $limit");\r\n$total=count($items);\r\nif ($total==0) {\r\n $items=SQLSelect("SELECT TITLE FROM rss_items WHERE 1 ORDER BY ADDED DESC LIMIT 2");\r\n $total=count($items); \r\n}\r\n\r\n$res=array_reverse($items);\r\nfor($i=0;$i<$total;$i++) {\r\n say($res[$i][''TITLE''],2);\r\n}\r\nsetGlobal(''lastNewsRead'',time());', '', '2014-10-30 15:32:13'),
(35, 'object72_method98', 0, 'say("Нажата на пульте кнопка Цэ!",2);\r\nrunScript(''readLatestNews'');', '', '2014-09-04 18:04:04'),
(63, 'script18', 0, '// вытягиваем историю из переменной\r\n$alreadyPlayed=gg("AlreadyPlayedMusic");\r\nif (!$alreadyPlayed) {\r\n $alreadyPlayed=''0'';\r\n}\r\n\r\n// выбираем случайную папку\r\n$rec=SQLSelectOne("SELECT * FROM media_favorites WHERE ID NOT IN (".$alreadyPlayed.") ORDER BY RAND()");\r\n\r\nif (!$rec[''ID'']) {\r\n // папок больше не осталось, поэтому выбираем случайную и сбрасываем историю\r\n $rec=SQLSelectOne("SELECT * FROM media_favorites ORDER BY RAND()");\r\n $alreadyPlayed=''0'';\r\n}\r\n\r\n\r\nif ($rec[''ID'']) {\r\n\r\n // добавляем выбранную папку в историю\r\n $alreadyPlayed.='',''.$rec[''ID''];\r\n sg("AlreadyPlayedMusic",$alreadyPlayed);\r\n\r\n // запускаем на проигрывание\r\n $collection=SQLSelectOne("SELECT * FROM collections WHERE ID=".(int)$rec[''COLLECTION_ID'']);\r\n $path=$collection[''PATH''].$rec[''PATH''];\r\n playMedia($path);\r\n //setTimeOut(''VLCPlayer_update'',"callMethod(''VLCPlayer.update'');",10);\r\n\r\n}', '', '2014-10-30 15:32:40'),
(62, 'script19', 0, 'getURL(''http://localhost/rc/?command=vlc_pause'',0);', '', '2014-10-30 15:32:28'),
(39, 'object19_method64', 0, 'callMethod(''noo1.turnOff''); // выключаем тёплый пол\r\ncallMethod(''noo2.turnOff''); // выключаем бойлер на кухне', '', '2014-09-05 11:10:07'),
(40, 'object19_method65', 0, 'callMethod(''noo1.turnOn''); // включаем тёплый пол\r\ncallMethod(''noo2.turnOn''); // включаем бойлер на кухне', '', '2014-09-05 11:10:32'),
(76, 'script20', 0, 'say(LANG_GENERAL_SETTING_UP_LIGHTS,2);\r\n// to-do', '', '2014-10-31 15:25:11'),
(69, 'object17_method73', 0, '$details=array();\r\n$red_state=0;\r\n$yellow_state=0;\r\n\r\n$cycles=array(''states''=>''states cycle'',''main''=>''main cycle'',''execs''=>''exec cycle'',''scheduler''=>''scheduler cycle'');\r\nforeach($cycles as $k=>$v) {\r\n $tm=getGlobal(''ThisComputer.cycle_''.$k.''Run'');\r\n if (time()-$tm>5*60) {\r\n $red_state=1;\r\n $details[]=$v." stopped.";\r\n }\r\n}\r\n\r\n$cycles=array(''ping''=>''ping cycle'',''webvars''=>''webvars cycle'',''watchfolders''=>''watch folders cycle'',''rss''=>''RSS cycle'');\r\nforeach($cycles as $k=>$v) {\r\n $tm=getGlobal(''ThisComputer.cycle_''.$k.''Run'');\r\n if (time()-$tm>10*60) {\r\n $yellow_state=1;\r\n $details[]=$v." stopped.";\r\n }\r\n}\r\n\r\nif ($red_state) {\r\n $state=''red'';\r\n $state_title=''Red''; \r\n} elseif ($yellow_state) {\r\n $state=''yellow'';\r\n $state_title=''Yellow''; \r\n} else {\r\n $state=''green'';\r\n $state_title=''Green''; \r\n}\r\n\r\n$new_details=implode(". ",$details);\r\nif ($this->getProperty("stateDetails")!=$new_details) {\r\n $this->setProperty(''stateDetails'',$new_details);\r\n}\r\n\r\nif ($this->getProperty(''stateColor'')!=$state) {\r\n $this->setProperty(''stateColor'',$state);\r\n $this->setProperty(''stateTitle'',$state_title);\r\n if ($state!=''green'') {\r\n say("System state changed to ".$state_title.".");\r\n say(implode(". ",$details));\r\n } else {\r\n say("System state restored to ".$state_title);\r\n }\r\n $this->callMethod(''stateChanged'');\r\n}', '', '2014-10-30 15:44:01'),
(70, 'object16_method75', 0, '$details=array();\r\n$red_state=0;\r\n$yellow_state=0;\r\n\r\nif ($red_state) {\r\n $state=''red'';\r\n $state_title=LANG_GENERAL_RED; \r\n} elseif ($yellow_state) {\r\n $state=''yellow'';\r\n $state_title=LANG_GENERAL_YELLOW; \r\n} else {\r\n $state=''green'';\r\n $state_title=LANG_GENERAL_GREEN; \r\n}\r\n\r\n$new_details=implode(". ",$details);\r\nif ($this->getProperty("stateDetails")!=$new_details) {\r\n $this->setProperty(''stateDetails'',$new_details);\r\n}\r\n\r\nif ($this->getProperty(''stateColor'')!=$state) {\r\n $this->setProperty(''stateColor'',$state);\r\n $this->setProperty(''stateTitle'',$state_title);\r\n if ($state!=''green'') {\r\n say(LANG_GENERAL_SYSTEM_STATE." ".LANG_GENERAL_CHANGED_TO." ".$state_title.".");\r\n say(implode(". ",$details));\r\n } else {\r\n say(LANG_GENERAL_SYSTEM_STATE." ".LANG_GENERAL_RESTORED_TO." ".$state_title);\r\n }\r\n $this->callMethod(''stateChanged'');\r\n}', '', '2014-10-31 14:57:24'),
(59, 'script21', 0, '$res='''';\r\n if (gg(''Security.stateColor'')==''green'' && gg(''System.stateColor'')==''green'' && gg(''Communication.stateColor'')==''green'') {\r\n $res=''Все системы работают в штатном режиме'';\r\n } else {\r\n if (gg(''Security.stateColor'')!=''green'') {\r\n $res.=" Проблема безопасности: ".getGlobal(''Security.stateDetails'');\r\n }\r\n if (gg(''System.stateColor'')!=''green'') {\r\n $res.=" Системная проблема: ".getGlobal(''System.stateDetails'');\r\n } \r\n if (gg(''Communication.stateColor'')!=''green'') {\r\n $res.=" Проблема связи: ".getGlobal(''Communication.stateDetails'');\r\n } \r\n }\r\n say($res,5);', '', '2014-10-30 15:31:46'),
(48, 'script1', 0, 'say(getRandomLine(''morning''),2);\r\n//runScript(''readWunderTasks'');\r\nrunScript(''readWeatherToday'');\r\nrunScript(''reportStatus'');', '<xml xmlns="http://www.w3.org/1999/xhtml">\r\n <block type="majordomo_say" inline="false" x="140" y="51">\r\n <value name="TEXT">\r\n <block type="text">\r\n <title name="TEXT">Good morning!</title>\r\n </block>\r\n </value>\r\n <next>\r\n <block type="controls_if" inline="false">\r\n <value name="IF0">\r\n <block type="logic_negate" inline="false">\r\n <value name="BOOL">\r\n <block type="majordomo_getglobal">\r\n <title name="TEXT">ThisComputer.WeHaveGuests</title>\r\n </block>\r\n </value>\r\n </block>\r\n </value>\r\n <statement name="DO0">\r\n <block type="majordomo_runscript" inline="false">\r\n <title name="TEXT">sayTodayAgenda</title>\r\n <next>\r\n <block type="majordomo_runscript" inline="false">\r\n <title name="TEXT">playFavoriteMusic</title>\r\n </block>\r\n </next>\r\n </block>\r\n </statement>\r\n </block>\r\n </next>\r\n </block>\r\n</xml>', '2014-09-05 12:30:58'),
(47, 'script13', 0, 'say(getRandomLine(''evening''),2);\r\nrunScript(''reportStatus'');', '<xml xmlns="http://www.w3.org/1999/xhtml">\r\n <block type="majordomo_say" inline="false" x="140" y="51">\r\n <value name="TEXT">\r\n <block type="text">\r\n <title name="TEXT">Good morning!</title>\r\n </block>\r\n </value>\r\n <next>\r\n <block type="controls_if" inline="false">\r\n <value name="IF0">\r\n <block type="logic_negate" inline="false">\r\n <value name="BOOL">\r\n <block type="majordomo_getglobal">\r\n <title name="TEXT">ThisComputer.WeHaveGuests</title>\r\n </block>\r\n </value>\r\n </block>\r\n </value>\r\n <statement name="DO0">\r\n <block type="majordomo_runscript" inline="false">\r\n <title name="TEXT">sayTodayAgenda</title>\r\n <next>\r\n <block type="majordomo_runscript" inline="false">\r\n <title name="TEXT">playFavoriteMusic</title>\r\n </block>\r\n </next>\r\n </block>\r\n </statement>\r\n </block>\r\n </next>\r\n </block>\r\n</xml>', '2014-09-05 12:30:34'),
(52, 'script12', 0, '$id=$params[''rcswitch''];\r\nif ($id==''12345'') {\r\n //sensor 1\r\n}', '', '2014-10-30 15:10:27'),
(54, 'object8_method', 0, '', '', '2014-10-30 15:29:14'),
(55, 'object7_method', 0, '', '', '2014-10-30 15:29:39'),
(56, 'object6_method', 0, '', '', '2014-10-30 15:30:05'),
(57, 'object5_method', 0, '', '', '2014-10-30 15:30:17'),
(58, 'object1_method', 0, '', '', '2014-10-30 15:30:59'),
(67, 'script22', 1, 'runScript("reportStatus", array());\r\n', '<xml xmlns="http://www.w3.org/1999/xhtml">\r\n <block type="majordomo_script_21" id="7" inline="true" x="148" y="87"></block>\r\n</xml>', '2014-10-30 15:35:12'),
(66, 'method62', 0, '$this->setProperty(''status'',$params[''status'']); // выставляем статус сенсора\r\n$this->setProperty(''updatedTimestamp'',time()); // выставляем время срабатывания сенсора\r\n\r\n$this->setProperty(''alive'',1);\r\n$ot=$this->object_title;\r\n$alive_timeout=(int)$this->getProperty("aliveTimeOut");\r\nif (!$alive_timeout) {\r\n $alive_timeout=24*60*60;\r\n}\r\nclearTimeOut($ot."_alive");\r\nsetTimeOut($ot."_alive","sg(''".$ot.".alive'',0);",$alive_timeout);\r\n\r\nif ($params[''status'']) {\r\n \r\n $this->setProperty(''motionDetected'',1);\r\n clearTimeOut($this->object_title.''_detected''); \r\n setTimeOut($this->object_title.''_detected'',"setGlobal(''".$this->object_title.".motionDetected'',0);",30);\r\n\r\n $linked_room=$this->getProperty(''LinkedRoom'');\r\n if ($linked_room!='''') {\r\n callMethod($linked_room.''.onActivity'');\r\n }\r\n\r\n if ($this->object_title==''sensorMovement3'' || $this->object_title==''sensorMovementRemote1'' || $this->object_title==''sensorMovementRemote2'') {\r\n //|| $this->object_title==''sensorMovement5''\r\n return; // не реагируем на движение в спальне, по ip-сенсорам и по сенсору на втором этаже\r\n }\r\n\r\n ClearTimeOut("nobodyHome"); \r\n SetTimeOut("nobodyHome","callMethod(''NobodyHomeMode.activate'');", 1*60*60); // выполняем, если целый час никого не было\r\n\r\n if (getGlobal(''NobodyHomeMode.active'')) {\r\n callMethod(''NobodyHomeMode.deactivate'');\r\n }\r\n\r\n $last_register=registeredEventTime(''inhouseMovement''); // проверяем, когда в последний раз срабатывало событие "движение внутри дома"\r\n registerEvent(''inhouseMovement'',$this->name,2); // регистрируем событие "движение внутри дома" \r\n if (timeBetween(''05:00'', ''12:00'') && ((time()-$last_register)>2*60*60)) {\r\n runScript(''Greeting''); // запускаем скрипт "доброе утро"\r\n }\r\n}', '', '2014-10-30 15:34:47'),
(68, 'object6_method18', 0, '$h=(int)date(''G'',time());\r\n$m=date(''i'',time());\r\n\r\n\r\nif (isWeekDay()) {\r\n\r\n}\r\n\r\n\r\nif (($h>=8) && getGlobal(''clockChimeEnabled'')) {\r\n if ($m=="00") {\r\n say(timeNow(),1);\r\n }\r\n}\r\n\r\n\r\nsetGlobal(''timeNow'',date(''H:i''));\r\n\r\n$homeStatus=date(''H:i'');\r\nif (getGlobal(''NobodyHomeMode.active'')) {\r\n $homeStatus.='' Дома никого'';\r\n} else {\r\n $homeStatus.='' Дома кто-то есть'';\r\n}\r\n\r\n$homeStatus.='' ''.getGlobal(''Security.stateDetails'');\r\n$homeStatus.='' ''.getGlobal(''System.stateDetails'');\r\n$homeStatus.='' ''.getGlobal(''Communication.stateDetails'');\r\nsetGlobal(''HomeStatus'',$homeStatus);\r\n\r\n if (timeBetween(getGlobal(''SunRiseTime''),getGlobal(''SunSetTime'')) && getGlobal(''isDark'')=="1") {\r\n setGlobal("isDark",0);\r\n callMethod(''DarknessMode.deactivate''); \r\n } elseif (!timeBetween(getGlobal(''SunRiseTime''),getGlobal(''SunSetTime'')) && getGlobal(''isDark'')!="1") {\r\n setGlobal("isDark",1);\r\n callMethod(''DarknessMode.activate''); \r\n }\r\n \r\n if (timeIs(getGlobal(''SunRiseTime''))) {\r\n say(''Всходит солнце'');\r\n }\r\n if (timeIs(getGlobal(''SunSetTime''))) {\r\n say(''Солнце заходит'',2);\r\n }\r\n \r\nif (timeIs("23:30") && (gg("EconomMode.active")!="1") && (gg("NobodyHomeMode.active")=="1")) {\r\n say("Похоже никого нет сегодня, можно сэкономить немного.");\r\n callMethod(''EconomMode.activate'');\r\n}\r\n\r\nif (timeIs(''20:00'')) {\r\n callMethod(''NightMode.activate'');\r\n} elseif (timeIs(''08:00'')) {\r\n callMethod(''NightMode.deactivate'');\r\n}\r\n\r\nif (timeIs("03:00")) {\r\n runScript("systemMaintenance");\r\n}\r\n\r\nif (gg(''ThisComputer.AlarmStatus'') && timeIs(gg(''ThisComputer.AlarmTime''))) {\r\n runScript(''MorningAlarm'');\r\n}', '', '2014-10-30 15:38:26'),
(71, 'object16_method59', 0, '$details=array();\r\n$red_state=0;\r\n$yellow_state=0;\r\n\r\nif ($red_state) {\r\n $state=''red'';\r\n $state_title=LANG_GENERAL_RED; \r\n} elseif ($yellow_state) {\r\n $state=''yellow'';\r\n $state_title=LANG_GENERAL_YELLOW; \r\n} else {\r\n $state=''green'';\r\n $state_title=LANG_GENERAL_GREEN; \r\n}\r\n\r\n$new_details=implode(". ",$details);\r\nif ($this->getProperty("stateDetails")!=$new_details) {\r\n $this->setProperty(''stateDetails'',$new_details);\r\n}\r\n\r\nif ($this->getProperty(''stateColor'')!=$state) {\r\n $this->setProperty(''stateColor'',$state);\r\n $this->setProperty(''stateTitle'',$state_title);\r\n if ($state!=''green'') {\r\n say(LANG_GENERAL_SECURITY_STATE." ".LANG_GENERAL_CHANGED_TO." ".$state_title.".");\r\n say(implode(". ",$details));\r\n } else {\r\n say(LANG_GENERAL_SECURITY_STATE." ".LANG_GENERAL_RESTORED_TO." ".$state_title);\r\n }\r\n $this->callMethod(''stateChanged'');\r\n}', '', '2014-10-31 15:02:09'),
(78, 'object18_method74', 0, '$details=array();\r\n$red_state=0;\r\n$yellow_state=0;\r\n\r\nif (!isOnline(''Internet'')) {\r\n $yellow_state=1;\r\n $details[]=LANG_GENERAL_NO_INTERNET_ACCESS;\r\n}\r\n\r\nif ($red_state) {\r\n $state=''red'';\r\n $state_title=LANG_GENERAL_RED; \r\n} elseif ($yellow_state) {\r\n $state=''yellow'';\r\n $state_title=LANG_GENERAL_YELLOW; \r\n} else {\r\n $state=''green'';\r\n $state_title=LANG_GENERAL_GREEN; \r\n}\r\n\r\n$new_details=implode(". ",$details);\r\nif ($this->getProperty("stateDetails")!=$new_details) {\r\n $this->setProperty(''stateDetails'',$new_details);\r\n}\r\n\r\nif ($this->getProperty(''stateColor'')!=$state) {\r\n $this->setProperty(''stateColor'',$state);\r\n $this->setProperty(''stateTitle'',$state_title);\r\n if ($state!=''green'') {\r\n say(LANG_GENERAL_COMMUNICATION_STATE." ".LANG_GENERAL_CHANGED_TO." ".$state_title.".");\r\n say(implode(". ",$details));\r\n } else {\r\n say(LANG_GENERAL_COMMUNICATION_STATE." ".LANG_GENERAL_RESTORED_TO." ".$state_title);\r\n }\r\n $this->callMethod(''stateChanged'');\r\n}', '', '2014-10-31 15:33:53'),
(80, 'pattern8', 0, '', '', '2014-10-31 15:38:58'),
(81, 'pattern9', 0, '', '', '2014-10-31 15:39:25'),
(82, 'method61', 0, 'if ($params[''status'']) {\r\n $this->setProperty(''status'',$params[''status'']);\r\n}\r\n$this->setProperty(''updatedTimestamp'',time());\r\n\r\n$this->setProperty("alive",1);\r\n$ot=$this->object_title;\r\n$alive_timeout=(int)$this->getProperty("aliveTimeOut");\r\nif (!$alive_timeout) {\r\n $alive_timeout=12*60*60;\r\n}\r\nclearTimeOut($ot."_alive");\r\nsetTimeOut($ot."_alive","sg(''".$ot.".alive'',0);",$alive_timeout);', '', '2015-01-29 11:29:50'),
(83, 'command108', 0, '', '', '2015-12-03 14:45:18');
-- --------------------------------------------------------
--
-- Table structure for table `cached_values`
--
DROP TABLE IF EXISTS `cached_values`;
CREATE TABLE IF NOT EXISTS `cached_values` (
`KEYWORD` char(100) NOT NULL,
`DATAVALUE` char(255) NOT NULL,
`EXPIRE` datetime NOT NULL,
PRIMARY KEY (`KEYWORD`)
) ENGINE=MEMORY DEFAULT CHARSET=utf8;
--
-- Dumping data for table `cached_values`
--
INSERT INTO `cached_values` (`KEYWORD`, `DATAVALUE`, `EXPIRE`) VALUES
('MJD:ThisComputer.weatherFull', '(too big)', '2015-12-03 14:49:23'),
('MJD:ThisComputer.started_time', '1449142973', '2015-12-03 14:43:53'),
('MJD:Livingroom.Temperature', '22.4', '2015-12-03 14:43:56'),
('MJD:Livingroom.Humidity', '42', '2015-12-03 14:43:56'),
('MJD:ThisComputer.cycle_execsRun', '1449143362', '2015-12-03 14:50:22'),
('MJD:ThisComputer.cycle_mainRun', '1449143367', '2015-12-03 14:50:27'),
('MJD:ThisComputer.cycle_schedulerRun', '1449143363', '2015-12-03 14:50:23'),
('MJD:ThisComputer.timeNow', '14:49', '2015-12-03 14:50:00'),
('MJD:Security.stateColor', 'green', '2015-12-03 14:43:59'),
('MJD:Security.stateDetails', '', '2015-12-03 14:43:59'),
('MJD:System.stateColor', 'green', '2015-12-03 14:47:48'),
('MJD:System.stateDetails', '', '2015-12-03 14:47:48'),
('MJD:Communication.stateColor', 'green', '2015-12-03 14:43:59'),
('MJD:Communication.stateDetails', '', '2015-12-03 14:43:59'),
('MJD:ThisComputer.somebodyHomeText', '', '2015-12-03 14:43:59'),
('MJD:admin.seenAt', 'Home', '2015-12-03 14:48:55'),
('MJD:admin.CoordinatesUpdated', '10:00', '2015-12-03 14:48:55'),
('MJD:ThisComputer.uptime', '394', '2015-12-03 14:50:27'),
('MJD:ThisComputer.cycle_statesRun', '1449143365', '2015-12-03 14:50:25'),
('MJD:ThisComputer.cycle_rssRun', '1449143365', '2015-12-03 14:50:25'),
('MJD:ThisComputer.cycle_pingRun', '1449143366', '2015-12-03 14:50:26'),
('MJD:ThisComputer.cycle_webvarsRun', '1449143365', '2015-12-03 14:50:25'),
('MJD:ThisComputer.cycle_watchfoldersRun', '1447849728', '2015-12-03 14:44:00'),
('MJD:ClockChime.time', '2015-12-03 14:49:00', '2015-12-03 14:50:00'),
('MJD:ThisComputer.clockChimeEnabled', '1', '2015-12-03 14:44:00'),
('MJD:NobodyHomeMode.active', '0', '2015-12-03 14:44:00'),
('MJD:ThisComputer.HomeStatus', '14:49 Дома кто-то есть', '2015-12-03 14:50:00'),
('MJD:ThisComputer.SunRiseTime', '09:12', '2015-12-03 14:44:00'),
('MJD:ThisComputer.SunSetTime', '16:45', '2015-12-03 14:44:00'),
('MJD:ThisComputer.isDark', '0', '2015-12-03 14:44:00'),
('MJD:ThisComputer.AlarmStatus', '', '2015-12-03 14:44:00'),
('MJD:ThisComputer.volumeLevel', '90', '2015-12-03 14:44:28'),
('MJD:ThisComputer.TempOutside', '-0.9', '2015-12-03 14:44:28'),
('MJD:ThisComputer.textBoxTest', '0', '2015-12-03 14:46:01'),
('MJD:ThisComputer.AlarmTime', '09:30', '2015-12-03 14:46:01'),
('MJD:Switch1.status', '0', '2015-12-03 14:47:13'),
('MJD:System.stateTitle', 'Зелёный', '2015-12-03 14:47:48'),
('MJD:ThisComputer.minMsgLevel', '1', '2015-12-03 14:47:48'),
('MJD:admin.atHome', '', '2015-12-03 14:48:55'),
('MJD:admin.Coordinates', '', '2015-12-03 14:48:55'),
('MJD:admin.CoordinatesUpdatedTimestamp', '', '2015-12-03 14:48:55'),
('MJD:admin.fullName', '', '2015-12-03 14:48:55'),
('MJD:admin.isMoving', '', '2015-12-03 14:48:55');
-- --------------------------------------------------------
--
-- Table structure for table `calendar_categories`
--
DROP TABLE IF EXISTS `calendar_categories`;
CREATE TABLE IF NOT EXISTS `calendar_categories` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`ACTIVE` int(255) NOT NULL DEFAULT '0',
`PRIORITY` int(10) NOT NULL DEFAULT '0',
`ICON` varchar(70) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
-- --------------------------------------------------------
--
-- Table structure for table `calendar_events`
--
DROP TABLE IF EXISTS `calendar_events`;
CREATE TABLE IF NOT EXISTS `calendar_events` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`SYSTEM` varchar(255) NOT NULL DEFAULT '',
`NOTES` text,
`DUE` date DEFAULT NULL,
`ADDED` datetime DEFAULT NULL,
`DONE_WHEN` datetime DEFAULT NULL,
`IS_TASK` int(3) NOT NULL DEFAULT '0',
`IS_DONE` int(3) NOT NULL DEFAULT '0',
`IS_NODATE` int(3) NOT NULL DEFAULT '0',
`IS_REPEATING` int(3) NOT NULL DEFAULT '0',
`REPEAT_TYPE` int(3) NOT NULL DEFAULT '0',
`WEEK_DAYS` varchar(255) NOT NULL DEFAULT '',
`IS_REPEATING_AFTER` int(3) NOT NULL DEFAULT '0',
`REPEAT_IN` int(10) NOT NULL DEFAULT '0',
`USER_ID` int(10) NOT NULL DEFAULT '0',
`LOCATION_ID` int(10) NOT NULL DEFAULT '0',
`CALENDAR_CATEGORY_ID` int(10) NOT NULL DEFAULT '0',
`DONE_SCRIPT_ID` int(10) NOT NULL DEFAULT '0',
`DONE_CODE` text,
`LOG` text,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
-- --------------------------------------------------------
--
-- Table structure for table `classes`
--
DROP TABLE IF EXISTS `classes`;
CREATE TABLE IF NOT EXISTS `classes` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`PARENT_ID` int(10) NOT NULL DEFAULT '0',
`SUB_LIST` text,
`PARENT_LIST` text,
`NOLOG` int(3) NOT NULL DEFAULT '0',
`DESCRIPTION` text,
PRIMARY KEY (`ID`),
KEY `PARENT_ID` (`PARENT_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=34 ;
--
-- Dumping data for table `classes`
--
INSERT INTO `classes` (`ID`, `TITLE`, `PARENT_ID`, `SUB_LIST`, `PARENT_LIST`, `NOLOG`, `DESCRIPTION`) VALUES
(12, 'Skype', 0, '12', '0', 0, ''),
(19, 'tempSensors', 0, '19', '0', 0, ''),
(7, 'Timer', 0, '7', '0', 1, ''),
(18, 'BlueToothDevice', 0, '18', '0', 0, ''),
(9, 'USBDevice', 0, '9', '0', 0, ''),
(10, 'Computer', 0, '10', '0', 0, ''),
(20, 'WeatherStations', 0, '20', '0', 0, ''),
(21, 'systemStates', 0, '21', '0', 0, ''),
(22, 'keySensors', 0, '23', '0', 0, ''),
(23, 'inhouseMovementSensors', 22, '23', '22', 0, ''),
(24, 'OperationalModes', 0, '24', '0', 0, ''),
(25, 'Rooms', 0, '25', '0', 0, ''),
(26, 'Relays', 0, '29,31', '0', 0, ''),
(29, 'RCSwitches', 26, '29', '26', 0, ''),
(30, 'humiditySensors', 0, '30', '0', 0, 'Humidity Sensors'),
(31, 'Noolight', 26, '31', '26', 0, ''),
(32, 'Users', 0, '32', '0', 0, '');
-- --------------------------------------------------------
--
-- Table structure for table `collections`
--
DROP TABLE IF EXISTS `collections`;
CREATE TABLE IF NOT EXISTS `collections` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`PATH` varchar(255) NOT NULL DEFAULT '',
`TITLE` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=10 ;
-- --------------------------------------------------------
--
-- Table structure for table `commands`
--
DROP TABLE IF EXISTS `commands`;
CREATE TABLE IF NOT EXISTS `commands` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`COMMAND` varchar(255) NOT NULL DEFAULT '',
`URL` varchar(255) NOT NULL DEFAULT '',
`WIDTH` int(10) NOT NULL DEFAULT '0',
`HEIGHT` int(10) NOT NULL DEFAULT '0',
`PARENT_ID` int(10) NOT NULL DEFAULT '0',
`SUB_LIST` text,
`PARENT_LIST` text,
`PRIORITY` int(10) NOT NULL DEFAULT '0',
`WINDOW` varchar(255) NOT NULL DEFAULT '',
`AUTOSTART` int(3) NOT NULL DEFAULT '0',
`TYPE` char(50) NOT NULL DEFAULT '',
`MIN_VALUE` float NOT NULL DEFAULT '0',
`MAX_VALUE` float NOT NULL DEFAULT '0',
`CUR_VALUE` varchar(255) NOT NULL DEFAULT '',
`STEP_VALUE` float NOT NULL DEFAULT '0',
`LINKED_OBJECT` varchar(255) NOT NULL DEFAULT '',
`LINKED_PROPERTY` varchar(255) NOT NULL DEFAULT '',
`ONCHANGE_OBJECT` varchar(255) NOT NULL DEFAULT '',
`ONCHANGE_METHOD` varchar(255) NOT NULL DEFAULT '',
`ICON` varchar(50) NOT NULL DEFAULT '',
`DATA` text,
`SCRIPT_ID` int(10) NOT NULL DEFAULT '0',
`AUTO_UPDATE` int(10) NOT NULL DEFAULT '0',
`CODE` text,
`SYSTEM` varchar(255) NOT NULL DEFAULT '',
`EXT_ID` int(10) NOT NULL DEFAULT '0',
`VISIBLE_DELAY` int(10) NOT NULL DEFAULT '0',
`INLINE` int(3) NOT NULL DEFAULT '0',
`SUB_PRELOAD` int(3) NOT NULL DEFAULT '0',
`RENDER_TITLE` varchar(255) NOT NULL DEFAULT '',
`RENDER_DATA` text,
`RENDER_UPDATED` datetime DEFAULT NULL,
`SMART_REPEAT` int(3) NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=118 ;
--
-- Dumping data for table `commands`
--
INSERT INTO `commands` (`ID`, `TITLE`, `COMMAND`, `URL`, `WIDTH`, `HEIGHT`, `PARENT_ID`, `SUB_LIST`, `PARENT_LIST`, `PRIORITY`, `WINDOW`, `AUTOSTART`, `TYPE`, `MIN_VALUE`, `MAX_VALUE`, `CUR_VALUE`, `STEP_VALUE`, `LINKED_OBJECT`, `LINKED_PROPERTY`, `ONCHANGE_OBJECT`, `ONCHANGE_METHOD`, `ICON`, `DATA`, `SCRIPT_ID`, `AUTO_UPDATE`, `CODE`, `SYSTEM`, `EXT_ID`, `VISIBLE_DELAY`, `INLINE`, `SUB_PRELOAD`, `RENDER_TITLE`, `RENDER_DATA`, `RENDER_UPDATED`, `SMART_REPEAT`) VALUES
(1, '<#LANG_APP_MEDIA_BROWSER#>', '', '', 0, 0, 0, '2,3', '0', 6000, '', 0, '', 0, 0, '0', 0, '', '', '', '', '1_iPhone_MUSIC_5_sm.png', '', 0, 0, '', '', 0, 0, 0, 0, 'Медиа', '', '2015-12-03 14:42:25', 0),
(2, 'Browse', '', '/popup/app_mediabrowser.html', 0, 0, 1, '2', '1', 100, '', 0, 'url', 0, 0, '0', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Browse', '', '2014-07-15 21:13:34', 0),
(3, 'Player control', '', '', 0, 0, 1, '3', '1', 90, '', 0, 'custom', 0, 0, '0', 0, '', '', '', '', '', '[#module name="app_player" mode="menu"#]', 0, 0, '', '', 0, 0, 0, 0, 'Player control', '<!-- begin of file inner_code --><!-- begin of file ./templates/app_player/app_player.html -->\n\n<!-- Frontend -->\n <!-- begin of file ./templates/app_player/action_usual.html -->\n<script language="javascript">\n function playerCommandProcessed(id, data) {\n var elem=document.getElementById(''playerStatus'');\n elem.innerHTML=data; \n return false;\n }\n function playerCommand(pcmd) {\n if ($("#selPlayTerminal").val()=='''') return false;\n if ($("#hidPlayPath").val()=='''' && pcmd==''refresh'') return false;\n var elem=document.getElementById(''playerStatus'');\n elem.innerHTML=pcmd+''...'';\n var url="/popup/app_player.html?ajax=1";\n url+=''&command=''+pcmd;\n url+=''&play_terminal=''+$("#selPlayTerminal").val();\n url+=''&play=''+URLencode($("#hidPlayPath").val());\n url+=''&rnd=''+URLencode($("#hidPlayerRnd").val());\n if (pcmd==''volume'') {\n url+=''&volume=''+URLencode($("#selVolume").val());\n }\n //prompt(url, url);\n AJAXRequest(url, ''playerCommandProcessed'', '''');\n return false;\n }\n</script>\n<table border="0" cellpadding="0" cellspacing="0">\n <tr>\n <form action="/nf.php?pd=pz_Y29tbWFuZHM6e3BhcmVudF9pdGVtPTF9pz_YXBwbGljYXRpb246e2FjdGlvbj1tZW51fQ%3D%3Dpz_&md=app_player&inst=&" method="get" name="frmPlayerControl" id="frmPlayerControl">\n <td align="right" style="vertical-align:middle">\n <div style="display:none">\n <select name="play_terminal" id="selPlayTerminal">\n <option value="">\n \n <option value="MAIN" selected>Server\n \n </select>\n </div>\n <div id=''playerStatus'' style="color:white"></div>\n\n </td>\n </tr><tr>\n <td nowrap><select name="volume" id=''selVolume'' onChange="playerCommand(''volume'')">\n \n <option value="0">0%\n \n <option value="5">5%\n \n <option value="10">10%\n \n <option value="15">15%\n \n <option value="20">20%\n \n <option value="25">25%\n \n <option value="30">30%\n \n <option value="35">35%\n \n <option value="40">40%\n \n <option value="45">45%\n \n <option value="50">50%\n \n <option value="55">55%\n \n <option value="60">60%\n \n <option value="65">65%\n \n <option value="70">70%\n \n <option value="75">75%\n \n <option value="80">80%\n \n <option value="85">85%\n \n <option value="90" selected>90%\n \n <option value="95">95%\n \n <option value="100">100%\n \n </select></td>\n <td valign="top">\n <div style="float:left;width:48px;height:48px;text-align:center"><a href="#" onClick=''return playerCommand("pause");'' style="padding:0;margin:0;display:inline;"><img src="/img/icons/playback_pause.png" border="0"></a></div>\n <div style="float:left;width:48px;height:48px;text-align:center"><a href="#" onClick=''return playerCommand("prev");'' style="padding:0;margin:0;display:inline;"><img src="/img/icons/playback_prev.png" border="0"></a></div>\n <div style="float:left;width:48px;height:48px;text-align:center"><a href="#" onClick=''return playerCommand("refresh");'' style="padding:0;margin:0;display:inline;"><img src="/img/icons/playback_play.png" border="0"></a></div> \n <div style="float:left;width:48px;height:48px;text-align:center"><a href="#" onClick=''return playerCommand("next");'' style="padding:0;margin:0;display:inline;"><img src="/img/icons/playback_next.png" border="0"></a></div>\n <div style="float:left;width:48px;height:48px;text-align:center"><a href="#" onClick=''return playerCommand("fullscreen");'' style="padding:0;margin:0;display:inline;"><img src="/img/icons/eye.png" border="0"></a></div>\n <div style="float:left;width:48px;height:48px;text-align:center"><a href="#" onClick=''return playerCommand("close");'' style="padding:0;margin:0;display:inline;"><img src="/img/icons/delete.png" border="0"></a></div>\n </td>\n </tr>\n <input type="hidden" name="play" value="" id="hidPlayPath">\n <input type="hidden" name="rnd" value="" id="hidPlayerRnd">\n <input type="hidden" name="pd" value="pz_Y29tbWFuZHM6e3BhcmVudF9pdGVtPTF9pz_YXBwbGljYXRpb246e2FjdGlvbj1tZW51fQ%3D%3Dpz_">\n<input type="hidden" name="md" value="app_player">\n<input type="hidden" name="inst" value="">\n</FORM><!-- modified -->\n</table>\n<!-- end of file ./templates/app_player/action_usual.html -->\n\n\n<!-- end of file ./templates/app_player/app_player.html --><!-- end of file inner_code -->', '2014-10-30 15:42:22', 0),
(75, '<#LANG_MODULE_LAYOUTS#>', '', '', 0, 0, 86, '75', '86', 1000, '', 0, 'custom', 0, 0, '0', 0, '', '', '', '', '', '[#module name="layouts"#]', 0, 60, '', '', 0, 0, 0, 0, 'Домашние страницы', '<!-- begin of file inner_code --><!-- begin of file ./templates/layouts/layouts.html -->\n\n\n<!-- Frontend -->\n <!-- begin of file ./templates/layouts/action_usual.html -->\n\n <!-- action usual -->\n <!-- table layouts search -->\n \n <!-- begin of file ./templates/layouts/layouts_search_site.html --><!-- results -->\n\n\n<ul data-role="listview">\n\n <li>\n \n <a href="/page/8.html" target=_blank>Добро пожаловать!</a>\n \n \n \n </li>\n\n <li>\n \n \n \n <a href="/popup/scenes.html" target=_blank>Сцены</a>\n \n </li>\n\n <li>\n \n \n \n <a href="/popup/app_mediabrowser.html" target=_blank>Медиа</a>\n \n </li>\n\n <li>\n \n \n \n <a href="/popup/app_calendar.html" target=_blank>Календарь</a>\n \n </li>\n\n <li>\n \n \n \n <a href="/popup/app_products.html" target=_blank>Продукты</a>\n \n </li>\n\n <li>\n \n \n \n <a href="/popup/app_gpstrack.html" target=_blank>GPS</a>\n \n </li>\n\n</ul>\n\n<!-- end of file ./templates/layouts/layouts_search_site.html -->\n \n <!-- / table layouts search -->\n <!-- table layouts edit -->\n \n <!-- / table layouts edit -->\n <!-- table layouts view --> \n \n <!-- / table layouts view -->\n<!-- end of file ./templates/layouts/action_usual.html -->\n\n\n<!-- end of file ./templates/layouts/layouts.html --><!-- end of file inner_code -->', '2014-10-30 14:58:15', 0),
(82, '<#LANG_GENERAL_EVENTS_LOG#>', '', '', 0, 0, 0, '82', '0', 10, '', 0, 'label', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'История событий', '', '2015-12-03 14:42:25', 0),
(63, '%ClockChime.time%', '', '', 0, 0, 66, '63', '86,66', 10000, '', 0, 'custom', 0, 0, '0', 0, '', '', '', '', '', '%ClockChime.time%<br>\r\nhello! <a href="/test">test</a>', 0, 60, '', '', 0, 0, 0, 0, '2014-10-30 14:58:00', '2014-10-30 14:58:00<br>\r\nhello! <a href="/test">test</a>', '2014-10-30 14:58:15', 0),
(66, 'Demo controls', '', '', 0, 0, 86, '63,67,68,69,70,71,72,73,77,78,80', '86', 0, '', 0, '', 0, 0, '0', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Demo controls', '', '2014-07-15 12:25:40', 0),
(67, '<#LANG_LABEL#>', '', '', 0, 0, 66, '67', '86,66', 9000, '', 0, 'label', 0, 0, '0', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Подпись', '', '2014-09-04 16:17:08', 0),
(68, 'New window', '', 'http://google.com/', 600, 600, 66, '68', '86,66', 8000, '', 0, 'window', 0, 0, '0', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'New window', '', '2014-09-04 16:17:08', 0),
(69, '<#LANG_URL#>', '', 'http://google.com/', 0, 0, 66, '69', '86,66', 7000, '', 0, 'url', 0, 0, '0', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Ссылка', '', '2014-09-04 16:17:08', 0),
(70, 'Buttons', '', '', 0, 0, 66, '70', '86,66', 6000, '', 0, 'button', 0, 0, 'clicked', 0, '', '', '', '', '', '', 0, 0, 'say("Привет");', '', 0, 0, 0, 0, 'Buttons', '', '2014-09-04 16:17:08', 0),
(71, '<#LANG_ON_OFF_SWITCH#>', '', '', 0, 0, 66, '71', '86,66', 5000, '', 0, 'switch', 0, 0, '0', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Выключатель', '', '2014-09-04 16:17:08', 0),
(72, 'Select box', '', '', 0, 0, 66, '72', '86,66', 4000, '', 0, 'selectbox', 0, 0, '2', 0, '', '', '', '', '', '1|Item 1\r\n2|Item 2\r\n3|Item 3', 0, 0, '', '', 0, 0, 0, 0, 'Select box', '1|Item 1\r\n2|Item 2\r\n3|Item 3', '2014-09-04 16:17:08', 0),
(73, 'Plus minus box', '', '', 0, 0, 66, '73', '86,66', 3000, '', 0, 'plusminus', 0, 5, '3', 1, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Plus minus box', '', '2014-09-04 16:17:08', 0),
(74, '<#LANG_GENERAL_EVENTS_LOG#> (code)', '', '', 0, 0, 0, '74', '0', 9, '', 0, 'custom', 0, 0, '0', 0, '', '', '', '', '', '<div style="text-shadow:none;font-weight:normal;">[#module name="shoutbox" limit="10" reverse="1" mobile="1"#]</div>', 0, 60, '', '', 0, 0, 0, 0, 'История событий (code)', '<!-- begin of file inner_code --><div style="text-shadow:none;font-weight:normal;"><!-- begin of file ./templates/shoutbox/shoutbox.html -->\n\r\n<!-- Frontend -->\r\n \n\r\n <!-- action usual -->\r\n <!-- table shouts search -->\r\n \r\n \r\n<!-- table shouts search -->\r\n<!-- results -->\r\n\r\n<div class="shout_box"> <!-- begin shout_box -->\r\n\r\n<!-- search results (list) -->\r\n<div id="shoutboxContent" class="shout_content">\r\nЗагрузка......\r\n</div>\r\n<!-- / search results (list) -->\r\n<!-- / results -->\r\n\r\n\r\n<div class="shout_form">\r\n<form action="/nf.php?pd=pz_pz_YXBwbGljYXRpb246e2FjdGlvbj1tZW51fQ%3D%3Dpz_&md=shoutbox&inst=&" name="frmShoutBoxMsg" method="get" style="margin:0px" onSubmit=''return false;''>\r\n<input type="text" name="message" class="shout_input" placeholder="Команда"><input type="submit" name="submit" value="Отправить" onClick="return sendShoutMessage();" class="shout_button">\r\n<input type="hidden" name="pd" value="pz_pz_YXBwbGljYXRpb246e2FjdGlvbj1tZW51fQ%3D%3Dpz_">\n<input type="hidden" name="md" value="shoutbox">\n<input type="hidden" name="inst" value="">\n</FORM><!-- modified -->\r\n</div>\r\n\r\n</div> <!-- end shout_box -->\r\n<script language="javascript">\r\n\r\nvar shoutTimer;\r\n\r\n function updateShoutContent() {\r\n clearTimeout(shoutTimer);\r\n\r\n var url="/popup/shoutbox.html?";\r\n\r\n url=url+''&limit=10&getdata=1&reverse=1'';\r\n $.ajax({\r\n url: url,\r\n }).done(function(data) { \r\n if (data!='''') {\r\n old_data=$(''#shoutboxContent'').html();\r\n if (old_data!=data) {\r\n $(''#shoutboxContent'').html(data);\r\n }\r\n }\r\n\r\n \r\n shoutTimer=setTimeout("updateShoutContent('''', '''');", 10000);\r\n \r\n\r\n\r\n });\r\n\r\n }\r\n\r\n function sendShoutMessage() {\r\n if (document.frmShoutBoxMsg.message.value == '''') return false; \r\n var msg=URLencode(document.frmShoutBoxMsg.message.value);\r\n document.frmShoutBoxMsg.message.value='''';\r\n var url="/popup/shoutbox.html?";\r\n url=url+''&limit=10&msg=''+msg;\r\n $.ajax({\r\n url: url,\r\n }).done(function(data) { \r\n if (data!=''OK'' && data!='''') {\r\n $(''#shoutboxContent'').html(data);\r\n }\r\n });\r\n return false;\r\n }\r\n</script>\r\n\r\n\r\n<script language="javascript">\r\n updateShoutContent();\r\n</script>\r\n\r\n \r\n <!-- / table shouts search -->\r\n <!-- table shouts edit -->\r\n \r\n <!-- / table shouts edit -->\r\n <!-- table shouts view --> \r\n \r\n <!-- / table shouts view -->\r\n\r\n\r\n\r\n<!-- end of file ./templates/shoutbox/shoutbox.html --></div><!-- end of file inner_code -->', '2015-12-03 14:48:23', 0),
(77, 'Alarm time', '', '', 0, 0, 66, '77', '86,66', 0, '', 0, 'timebox', 0, 0, '09:30', 0, 'ThisComputer', 'AlarmTime', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Alarm time', '', '2014-09-04 16:17:08', 0),
(78, '<#LANG_TEXT_BOX#>', '', '', 0, 0, 66, '78', '86,66', 0, '', 0, 'textbox', 0, 0, '0', 0, 'ThisComputer', 'textBoxTest', '', '', '', '', 0, 10, '', '', 0, 0, 0, 0, 'Текстовое поле', '', '2014-10-30 14:58:15', 0),
(80, '<#LANG_SLIDER_BOX#>', '', '', 0, 0, 66, '80', '86,66', 0, '', 0, 'sliderbox', 0, 10, '0', 1, 'ThisComputer', 'textBoxTest', '', '', '', '', 0, 5, '', '', 0, 0, 0, 0, 'Слайдер', '', '2014-10-30 14:58:15', 0),
(86, '<#LANG_GENERAL_SERVICE#>', '', '', 0, 0, 0, '75,66,63,67,68,69,70,71,72,73,77,78,80,98,99', '0', 2, '', 0, '', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Сервис', '', '2015-12-03 14:42:25', 0),
(106, '<#LANG_GENERAL_CONTROL#>', '', '', 0, 0, 0, '108', '0', 7000, '', 0, '', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 1, 'Управление', '', '2015-12-03 14:42:25', 0),
(114, 'Admin (status)', '', '', 0, 0, 110, '114', '110', 950, '', 0, 'custom', 0, 0, '', 0, '', '', '', '', '', '%Admin.seenAt% (%Admin.CoordinatesUpdated%)\r\n<br><br>\r\n<a href="http://maps.google.com/maps?q=loc:%Admin.Coordinates%" target=_blank><img src="http://maps.googleapis.com/maps/api/staticmap?center=%Admin.Coordinates%&size=300x300&maptype=hybrid&sensor=false&zoom=16&markers=%Admin.Coordinates%"></a>', 0, 0, '', '', 0, 0, 0, 0, 'Admin (status)', ' ()\r\n<br><br>\r\n<a href="http://maps.google.com/maps?q=loc:" target=_blank><img src="http://maps.googleapis.com/maps/api/staticmap?center=&size=300x300&maptype=hybrid&sensor=false&zoom=16&markers="></a>', '2014-10-30 15:40:58', 0),
(91, '<#LANG_GENERAL_CLIMATE#> (<#LANG_GENERAL_OUTSIDE#>: %ThisComputer.TempOutside%°C / <#LANG_GENERAL_INSIDE#>: %Livingroom.Temperature%°C)', '', '', 0, 0, 0, '92,93,104,105', '0', 8000, '', 0, '', 0, 0, '', 0, '', '', '', '', '', '', 0, 60, '', '', 0, 0, 0, 1, 'Климат (На улице: -0.9°C / Дома: 22.4°C)', '', '2015-12-03 14:43:28', 0),
(92, '<#LANG_GENERAL_WEATHER_FORECAST#> (code)', '', '', 0, 0, 91, '92', '91', 1000, '', 0, 'custom', 0, 0, '', 0, '', '', '', '', '', '%ThisComputer.weatherFull%', 0, 0, '', '', 0, 0, 0, 0, 'Прогноз погоды (code)', '\n<b>Сегодня:</b><br />\nднем: +0°...+2°, пасмурно, туман, ночью: +0°...-2°, переменная облачность, туман, ветер: ЮЗ — 3-5 м/с, давление: 770 мм.рт.ст, влажность: 100%<br />\n<br />\n<b>Завтра:</b><br />\nднем: +4°...+6°, пасмурно, ночью: +2°...+4°, пасмурно, без существенных осадков, ветер: Ю — 6-8 м/с, давление: 768 мм.рт.ст, влажность: 100%<br />\n<br />\n<br />\n', '2015-12-03 14:43:28', 0),
(93, '<#LANG_GENERAL_WEATHER_FORECAST#>', '', '', 0, 0, 91, '93', '91', 1001, '', 0, 'label', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Прогноз погоды', '', '2015-12-03 14:42:25', 0),
(104, '<#LANG_GENERAL_INSIDE#>', '', '', 0, 0, 91, '104', '91', 2000, '', 0, 'label', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Дома', '', '2015-12-03 14:42:25', 0),
(105, '<#LANG_GENERAL_INSIDE#> (data)', '', '', 0, 0, 91, '105', '91', 1900, '', 0, 'custom', 0, 0, '', 0, '', '', '', '', '', 'Livingroom: %Livingroom.Temperature%°C / %Livingroom.Humidity%%', 0, 30, '', '', 0, 0, 0, 0, 'Дома (data)', 'Livingroom: 22.4°C / 42%', '2015-12-03 14:43:28', 0),
(97, 'State', '', '', 0, 0, 0, '97', '0', 100010, '', 0, 'custom', 0, 0, '', 0, '', '', '', '', '', '<big style="font-size:24px">%ThisComputer.timeNow%</big>\r\n\r\n<img src="/img/icons/status/lock_32_%Security.stateColor%.png" align="absmiddle"> %Security.stateDetails%\r\n<img src="/img/icons/status/system_32_%System.stateColor%.png" align="absmiddle"> %System.stateDetails%\r\n<img src="/img/icons/status/network_32_%Communication.stateColor%.png" align="absmiddle"> %Communication.stateDetails%\r\n<br/>\r\n%ThisComputer.somebodyHomeText%\r\n<br/>\r\nAdmin -- %Admin.seenAt% (%Admin.CoordinatesUpdated%)', 0, 10, '', '', 0, 0, 0, 0, 'State', '<big style="font-size:24px">14:48</big>\r\n\r\n<img src="/img/icons/status/lock_32_green.png" align="absmiddle"> \r\n<img src="/img/icons/status/system_32_green.png" align="absmiddle"> \r\n<img src="/img/icons/status/network_32_green.png" align="absmiddle"> \r\n<br/>\r\n\r\n<br/>\r\nAdmin -- Home (10:00)', '2015-12-03 14:48:02', 0),
(98, '<#LANG_SECTION_SETTINGS#>', '', '', 0, 0, 86, '99', '86', 20000, '', 0, '', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Настройки', '', '2014-08-25 17:04:27', 0),
(99, 'Говорить время', '', '', 0, 0, 98, '99', '86,98', 1000, '', 0, 'switch', 0, 0, '1', 0, 'ThisComputer', 'clockChimeEnabled', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Говорить время', '', '2014-08-25 17:04:33', 0),
(108, 'Switch 1', '', '', 0, 0, 106, '108', '106', 0, '', 0, 'switch', 0, 0, '0', 0, 'Switch1', 'status', '', 'refresh', '', '', 0, 300, '', '', 0, 0, 0, 0, 'Switch 1', '', '2014-10-31 15:30:26', 0),
(110, '<#LANG_MODULE_USERS#>', '', '', 0, 0, 0, '114,111', '0', 5000, '', 0, '', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Пользователи', '', '2015-12-03 14:42:25', 0),
(111, 'Admin', '', '', 0, 0, 110, '111', '110', 1000, '', 0, 'label', 0, 0, '', 0, '', '', '', '', '', '', 0, 0, '', '', 0, 0, 0, 0, 'Admin', '', '2014-10-30 15:40:58', 0);
-- --------------------------------------------------------
--
-- Table structure for table `country`
--
DROP TABLE IF EXISTS `country`;
CREATE TABLE IF NOT EXISTS `country` (
`COUNTRY_ID` int(10) NOT NULL,
`COUNTRY_GUID` varchar(48) NOT NULL,
`COUNTRY_NAME` varchar(64) NOT NULL,
`LM_DATE` datetime NOT NULL,
`COUNTRY_CODE` varchar(8) DEFAULT NULL,
`COUNTRY_PHONE_CODE` varchar(8) DEFAULT NULL,
`LATITUDE` float(18,5) DEFAULT NULL,
`LONGITUDE` float(18,5) DEFAULT NULL,
PRIMARY KEY (`COUNTRY_ID`),
KEY `AK_COUNTRY__GUID` (`COUNTRY_GUID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
--
-- Dumping data for table `country`
--
INSERT INTO `country` (`COUNTRY_ID`, `COUNTRY_GUID`, `COUNTRY_NAME`, `LM_DATE`, `COUNTRY_CODE`, `COUNTRY_PHONE_CODE`, `LATITUDE`, `LONGITUDE`) VALUES
(1, '25459617-F4D3-EB0A-6777-2D7CB5F876B9', 'Andorra', '2015-04-14 12:09:36', 'AD', '376', NULL, NULL),
(2, '24E45AEB-7FD7-783A-2008-F5A35CA064F7', 'United Arab Emirates', '2015-04-14 12:09:36', 'AE', '971', NULL, NULL),
(3, '3F039DE6-2908-4731-96FE-041E04A7E962', 'Afghanistan', '2015-04-14 12:09:36', 'AF', '93', NULL, NULL),
(4, 'F1FEB2CF-618A-59D0-0DDC-B4F8B4ED976E', 'Antigua and Barbuda', '2015-04-14 12:09:36', 'AG', '1268', NULL, NULL),
(5, '909E8639-771A-D2CD-4405-7A8368A9D04A', 'Anguilla', '2015-04-14 12:09:36', 'AI', '1264', NULL, NULL),
(6, '35173F09-0E98-0C3E-77A6-2AD8F8F5DE89', 'Albania', '2015-04-14 12:09:36', 'AL', '355', NULL, NULL),
(7, '632C5757-664D-108D-802F-3F62E78F41B9', 'Armenia', '2015-04-14 12:09:36', 'AM', '374', NULL, NULL),
(8, '33C045E6-E7F0-6886-FE2D-46C5EAA79042', 'Angola', '2015-04-14 12:09:36', 'AO', '244', NULL, NULL),
(9, '8E7E291E-B21C-ABAC-7791-4733C412D3CA', 'Argentina', '2015-04-14 12:09:36', 'AR', '54', NULL, NULL),
(10, 'F4EC01D6-D793-EE6C-58EA-D66DABE0E15F', 'American Samoa', '2015-04-14 12:09:36', 'AS', '1684', NULL, NULL),
(11, 'DA24D62E-C926-A91D-E11A-96AAD3E5DDE1', 'Austria', '2015-04-14 12:09:36', 'AT', '43', NULL, NULL),
(12, 'F193E97D-B13C-9506-D976-CCB52BC864BF', 'Australia', '2015-04-14 12:09:36', 'AU', '61', NULL, NULL),
(13, '363B89ED-E346-3EEE-67E1-77A9ACA104BE', 'Aruba', '2015-04-14 12:09:36', 'AW', '297', NULL, NULL),
(14, '0129859C-6BC4-C7C6-F0E7-212E8BFFE04F', 'Åland Islands', '2015-04-14 12:09:36', 'AX', '358', NULL, NULL),
(15, '96C23A30-8A7D-D545-6E33-1EF6070EAA2A', 'Azerbaijan', '2015-04-14 12:09:36', 'AZ', '994', NULL, NULL),
(16, '1C37B968-7D44-2AED-7171-116232E0376F', 'Bosnia and Herzegovina', '2015-04-14 12:09:36', 'BA', '387', NULL, NULL),
(17, '784A4C7F-8B44-353A-8B27-996E1B38791C', 'Barbados', '2015-04-14 12:09:36', 'BB', '1246', NULL, NULL),
(18, '735D20D8-45D8-B861-6B2B-9F1B22F86447', 'Bangladesh', '2015-04-14 12:09:36', 'BD', '880', NULL, NULL),
(19, '3B71F5B5-2AC2-9154-404D-191ABFBC4729', 'Belgium', '0000-00-00 00:00:00', '2015-04-', '32', NULL, NULL),
(20, 'B5CB258B-4F64-D109-E9D5-60A78ED0A637', 'Burkina Faso', '2015-04-14 12:09:36', 'BF', '226', NULL, NULL),
(21, '1B6E6DAD-F17E-C6C0-61A4-41B20394BDBE', 'Bulgaria', '2015-04-14 12:09:36', 'BG', '359', NULL, NULL),
(22, '6AB06D58-6177-06A7-0937-AA363E22FE30', 'Bahrain', '2015-04-14 12:09:36', 'BH', '973', NULL, NULL),
(23, 'D1581E51-B2B3-8078-F5EC-8463B5484393', 'Burundi', '2015-04-14 12:09:36', 'BI', '257', NULL, NULL),
(24, '28966864-22F6-35BD-5145-1B79E5FE95C0', 'Benin', '2015-04-14 12:09:36', 'BJ', '229', NULL, NULL),
(25, 'A0910149-4E0D-D1EF-9280-90C7CA4F713A', 'Saint Barthelemy', '2015-04-14 12:09:36', 'BL', '590', NULL, NULL),
(26, 'D10E4FAB-B35B-36E2-1B11-BD87D19D493E', 'Bermuda', '2015-04-14 12:09:36', 'BM', '1441', NULL, NULL),
(27, '2EF66919-5A42-5E57-9540-254370BCFA7F', 'Brunei', '2015-04-14 12:09:36', 'BN', '673', NULL, NULL),
(28, 'B17DC404-815D-16D1-3EE6-01CFF6108DA6', 'Bolivia', '2015-04-14 12:09:36', 'BO', '597', NULL, NULL),
(29, '1677F424-62EB-CDCA-59AE-82E6BE4CD643', 'Bonaire, Sint Eustatius and Saba', '2015-04-14 12:09:36', 'BQ', '599', NULL, NULL),
(30, '364A13CD-9DD4-EB69-B481-CAF5C67AD0F3', 'Brazil', '2015-04-14 12:09:36', 'BR', '55', NULL, NULL),
(31, '3287034B-9EF0-21E6-290F-4C1435488B14', 'Bahamas', '2015-04-14 12:09:36', 'BS', '1242', NULL, NULL),
(32, '3ECFA6CC-B473-444F-60B2-F2C325726A59', 'Bhutan', '2015-04-14 12:09:36', 'BT', '975', NULL, NULL),
(33, '5CB7E864-AA89-D6A6-6483-5A0B4BF4ECE7', 'Botswana', '2015-04-14 12:09:36', 'BW', '267', NULL, NULL),
(34, '549B645E-602C-E8DC-E661-0BC58B872507', 'Belarus', '2015-04-14 12:09:36', 'BY', '375', NULL, NULL),
(35, '6EBC4137-4D87-7153-6380-1917E5AB5CC8', 'Belize', '2015-04-14 12:09:36', 'BZ', '501', NULL, NULL),
(36, '62B9E5BF-CD36-7BF9-8C86-7145E0BB87C3', 'Canada', '2015-04-14 12:09:36', 'CA', '1', NULL, NULL),
(37, 'CE623909-C6BB-FBDB-AAC4-E93B1905A157', 'Cocos (Keeling) Islands', '2015-04-14 12:09:36', 'CC', '61', NULL, NULL),
(38, 'EE5B1165-2914-906F-FC6F-CAAE4D346925', 'Democratic Republic of the Congo', '2015-04-14 12:09:36', 'CD', '243', NULL, NULL),
(39, '2DAEE215-8156-00B0-9BCF-2A11D900E923', 'Central African Republic', '2015-04-14 12:09:36', 'CF', '236', NULL, NULL),
(40, 'EDADCB74-E7C3-1081-29BA-4F59B60FF6B2', 'Republic of the Congo', '2015-04-14 12:09:36', 'CG', '242', NULL, NULL),
(41, '5024DE57-E5BB-5A9D-917D-26A1749B8D60', 'Switzerland', '2015-04-14 12:09:36', 'CH', '41', NULL, NULL),
(42, 'ABA5802C-8FE2-211F-8002-BB96E7A364DB', 'Ivory Coast', '2015-04-14 12:09:36', 'CI', '225', NULL, NULL),
(43, '00C8EB2B-8085-1D54-BE4D-35EF87A255E6', 'Cook Islands', '2015-04-14 12:09:36', 'CK', '682', NULL, NULL),
(44, '834BD2B5-93D2-17A7-91BE-CE4DEEC43366', 'Chile', '2015-04-14 12:09:36', 'CL', '56', NULL, NULL),
(45, '28A21890-3B5D-8B00-9EBE-DED06FA1ECFB', 'Cameroon', '2015-04-14 12:09:36', 'CM', '237', NULL, NULL),
(46, 'CE0E5440-B3C0-12A5-1BA3-2387A270C634', 'China', '2015-04-14 12:09:36', 'CN', '86', NULL, NULL),
(47, '622727AA-9C09-1CBB-9C8F-5F23E4F6E7AF', 'Colombia', '2015-04-14 12:09:36', 'CO', '57', NULL, NULL),
(48, 'D3860772-0731-CCE8-3F3C-8DFC229DA443', 'Costa Rica', '2015-04-14 12:09:36', 'CR', '506', NULL, NULL),
(49, 'A394D714-E73A-8327-EB0C-C1A03AD5B75C', 'Cuba', '2015-04-14 12:09:36', 'CU', '53', NULL, NULL),
(50, '38DE8E73-B254-F18B-098D-FA063DB064DE', 'Cape Verde', '2015-04-14 12:09:36', 'CV', '238', NULL, NULL),
(51, 'E05C1047-00F5-9447-4AA4-F4D231A60CDF', 'Christmas Island', '2015-04-14 12:09:36', 'CX', '61', NULL, NULL),
(52, 'E29DE5EF-A293-9921-DB69-1AE56C94789C', 'Curaçao', '2015-04-14 12:09:36', 'CW', '', NULL, NULL),
(53, '91F38946-68B4-F218-A93C-87F8018AD49A', 'Cyprus', '2015-04-14 12:09:36', 'CY', '357', NULL, NULL),
(54, '673F53C2-5C02-9B22-E956-29879756BF15', 'Czech Republic', '2015-04-14 12:09:36', 'CZ', '420', NULL, NULL),
(55, '60C952C3-0504-DC75-9E1D-499EC374B0F0', 'Germany', '2015-04-14 12:09:36', 'DE', '49', NULL, NULL),
(56, '1A3A54C9-F2E1-3E5F-079C-999D110E8EEC', 'Djibouti', '2015-04-14 12:09:36', 'DJ', '253', NULL, NULL),
(57, '7547B15D-E21A-4A2E-5F9B-1DC727C53F4A', 'Denmark', '2015-04-14 12:09:36', 'DK', '45', NULL, NULL),
(58, '7E2CF84D-1879-374A-6A41-F03318A3FB25', 'Dominica', '2015-04-14 12:09:36', 'DM', '1767', NULL, NULL),
(59, 'A07E10D2-DB62-436D-E203-A884ED728CBC', 'Dominican Republic', '2015-04-14 12:09:36', 'DO', '1809', NULL, NULL),
(60, '6CFEBD8D-4ADA-B4FF-9160-90D0C2B2118E', 'Algeria', '2015-04-14 12:09:36', 'DZ', '213', NULL, NULL),
(61, 'BC4A1696-47D1-2617-ECF6-824BADEF4C4E', 'Ecuador', '2015-04-14 12:09:36', 'EC', '593', NULL, NULL),
(62, 'AFF8DFA6-F5EE-6A43-DC59-8213D20E198A', 'Estonia', '2015-04-14 12:09:36', 'EE', '372', NULL, NULL),
(63, 'ED2AC84C-40C7-F14D-378E-16EB10094294', 'Egypt', '2015-04-14 12:09:36', 'EG', '20', NULL, NULL),
(64, '25C7A12B-226A-8989-F33B-98FEAB37B18F', 'Western Sahara', '2015-04-14 12:09:36', 'EH', '', NULL, NULL),
(65, '0C0F61A7-CED3-882E-440F-0B8B6ED939DB', 'Eritrea', '2015-04-14 12:09:36', 'ER', '291', NULL, NULL),
(66, '81387FC3-0AD1-42E7-241E-2AA939641B95', 'Spain', '2015-04-14 12:09:36', 'ES', '34', NULL, NULL),
(67, '7D8BD697-9E59-4861-4BE9-61A8AD8B4936', 'Ethiopia', '2015-04-14 12:09:36', 'ET', '251', NULL, NULL),
(68, '561A54FF-8F65-8B92-483E-2DBE528429A4', 'Finland', '2015-04-14 12:09:36', 'FI', '358', NULL, NULL),
(69, '4D930C83-DEFD-ADEA-0D64-501B4E4911CF', 'Fiji', '2015-04-14 12:09:36', 'FJ', '679', NULL, NULL),
(70, '3EF989F2-6700-B8DA-F2B5-B4A831B30BCD', 'Falkland Islands', '2015-04-14 12:09:36', 'FK', '500', NULL, NULL),
(71, '6E21E535-BF55-E53C-3CAC-7C2B621EF05B', 'Micronesia', '2015-04-14 12:09:36', 'FM', '691', NULL, NULL),
(72, '25F1AC03-B255-50A9-654C-E043D61E7DA1', 'Faroe Islands', '2015-04-14 12:09:36', 'FO', '298', NULL, NULL),
(73, '06A3DB9C-B358-74A7-BBA2-99F760FDE24E', 'France', '2015-04-14 12:09:36', 'FR', '33', NULL, NULL),
(74, '7D2D339B-5568-2B6C-28F6-1CAD95AE685E', 'Gabon', '2015-04-14 12:09:36', 'GA', '241', NULL, NULL),
(75, '73D1D5BB-571F-08E7-2A4F-4AB63AA9793C', 'United Kingdom', '2015-04-14 12:09:36', 'GB', '44', NULL, NULL),
(76, '52764C53-FF3F-BA7C-14BF-7E6262C26BB6', 'Grenada', '2015-04-14 12:09:36', 'GD', '1473', NULL, NULL),
(77, 'ABAFEB9B-9DB0-5261-4625-53C6A32A8392', 'Georgia', '2015-04-14 12:09:36', 'GE', '995', NULL, NULL),
(78, '93A6ABF8-C217-B219-0AEF-F63F51330113', 'French Guiana', '2015-04-14 12:09:36', 'GF', '', NULL, NULL),
(79, 'DD5B81B6-DF46-6B93-40DD-32B63B1C4482', 'Guernsey', '2015-04-14 12:09:36', 'GG', '', NULL, NULL),
(80, 'AE89DC78-DD22-0165-1F4A-37757DC2C6A6', 'Ghana', '2015-04-14 12:09:36', 'GH', '233', NULL, NULL),
(81, '691A673C-A72B-45C6-EBA5-AE4D48128B0C', 'Gibraltar', '2015-04-14 12:09:36', 'GI', '350', NULL, NULL),
(82, 'E1C9DDCE-DFC6-C80E-9E6D-2CFACD5A3EF3', 'Greenland', '2015-04-14 12:09:36', 'GL', '299', NULL, NULL),
(83, 'DC6434F3-07BD-D0AF-5EF1-021830DD761A', 'Gambia', '2015-04-14 12:09:36', 'GM', '220', NULL, NULL),
(84, '0EB68AA9-0863-564B-E8B9-7BE51B19C627', 'Guinea', '2015-04-14 12:09:36', 'GN', '224', NULL, NULL),
(85, '64BAD731-A2B6-D774-4382-6A3F69041EB2', 'Guadeloupe ', '2015-04-14 12:09:36', 'GP', '', NULL, NULL),
(86, '72FFFB07-88AA-6CA5-C9A1-664AAE69E39F', 'Equatorial Guinea', '2015-04-14 12:09:36', 'GQ', '240', NULL, NULL),
(87, 'EBC8E95D-EFA7-A62F-E9D0-1230876D82AD', 'Greece', '2015-04-14 12:09:36', 'GR', '30', NULL, NULL),
(88, '589A3D09-2DAA-54DD-B119-8A8D0CD9E9B1', 'South Georgia and the South Sandwich Islands', '2015-04-14 12:09:36', 'GS', '', NULL, NULL),
(89, '6119B99F-E4B7-0B13-45F3-293FD0A84862', 'Guatemala', '2015-04-14 12:09:36', 'GT', '502', NULL, NULL),
(90, '6BC5F673-1D11-85D4-FF9E-3C43604EC2D0', 'Guam', '2015-04-14 12:09:36', 'GU', '1671', NULL, NULL),
(91, 'D94C617D-E792-CAAF-2E00-5A8EEA208C8C', 'Guinea-Bissau', '2015-04-14 12:09:36', 'GW', '245', NULL, NULL),
(92, '9313337B-D700-D83C-CA29-5F48D8726308', 'Guyana', '2015-04-14 12:09:36', 'GY', '592', NULL, NULL),
(93, 'CEFBA783-88BA-FFDE-77F3-43B3FF801484', 'Hong Kong', '2015-04-14 12:09:36', 'HK', '852', NULL, NULL),
(94, 'CBA2E631-D4D1-B735-81D3-5DAC86AE8C76', 'Honduras', '2015-04-14 12:09:36', 'HN', '504', NULL, NULL),
(95, 'FEA02A43-5185-C6A7-A26C-935578D43E6D', 'Croatia', '2015-04-14 12:09:36', 'HR', '385', NULL, NULL),
(96, '02927AD4-8894-FE99-C9DD-E0E7F4DC63B1', 'Haiti', '2015-04-14 12:09:36', 'HT', '509', NULL, NULL),
(97, '42405C6A-097F-BAF2-93A6-86513986110A', 'Hungary', '2015-04-14 12:09:36', 'HU', '36', NULL, NULL),
(98, '79798E7A-4327-469A-5EC1-81319DDC1E90', 'Indonesia', '2015-04-14 12:09:36', 'ID', '62', NULL, NULL),
(99, '2A8985F3-8891-5685-A0FF-972A5DF8620B', 'Ireland', '2015-04-14 12:09:36', 'IE', '353', NULL, NULL),
(100, 'EEBDEB95-6B76-B2B0-F2C9-2BFB1499E9FD', 'Israel', '2015-04-14 12:09:36', 'IL', '972', NULL, NULL),
(101, '71739793-0365-6479-F9A2-9B6F57239816', 'Isle of Man', '2015-04-14 12:09:36', 'IM', '44', NULL, NULL),
(102, '18AC27F9-4025-C8CF-DA36-36004B0C5CF3', 'India', '2015-04-14 12:09:36', 'IN', '91', NULL, NULL),
(103, '01BB783C-2123-8D92-36E3-397F1E9D5F7D', 'Iraq', '2015-04-14 12:09:36', 'IQ', '964', NULL, NULL),
(104, '422B82CA-FC9F-6FFF-151E-E342CBD26A32', 'Iran', '2015-04-14 12:09:36', 'IR', '98', NULL, NULL),
(105, 'CD0DAF28-6A3C-0CE3-1A06-218A7AA11408', 'Iceland', '2015-04-14 12:09:36', 'IS', '354', NULL, NULL),
(106, '8BA4B4DC-9E82-331B-7EE2-6577413FCFDE', 'Italy', '2015-04-14 12:09:36', 'IT', '39', NULL, NULL),
(107, 'D8777867-1C0B-ACF1-337A-6DD4B68B902B', 'Jersey', '2015-04-14 12:09:36', 'JE', '', NULL, NULL),
(108, '0DEFE08A-DFF2-7222-F6BC-C10BB2C2B3E3', 'Jamaica', '2015-04-14 12:09:36', 'JM', '1876', NULL, NULL),
(109, '8864615C-5A8F-56C1-262C-97CB8739E154', 'Jordan', '2015-04-14 12:09:36', 'JO', '962', NULL, NULL),
(110, 'A8DFE7EB-BA50-DF73-C88A-EB7A83636C98', 'Japan', '2015-04-14 12:09:36', 'JP', '81', NULL, NULL),
(111, 'D6F5CF13-36E4-E7D7-A6AE-32D622E2E905', 'Kenya', '2015-04-14 12:09:36', 'KE', '254', NULL, NULL),
(112, '6C1BE74C-56D3-ADFE-B75E-4DD174378C3B', 'Kyrgyzstan', '2015-04-14 12:09:36', 'KG', '996', NULL, NULL),
(113, '88F59F28-C9DC-F8B5-0AA3-6EE2F5BA2680', 'Cambodia', '2015-04-14 12:09:36', 'KH', '855', NULL, NULL),
(114, '221ACA06-D996-AA61-8EF8-A883B5EF088D', 'Kiribati', '2015-04-14 12:09:36', 'KI', '686', NULL, NULL),
(115, '50711EC0-9C17-A53D-C8D5-7BFCB17B9F74', 'Comoros', '2015-04-14 12:09:36', 'KM', '269', NULL, NULL),
(116, '5A63C8A4-AED9-E465-C42D-6B35D815788E', 'Saint Kitts and Nevis', '2015-04-14 12:09:36', 'KN', '1869', NULL, NULL),
(117, 'E2231181-F5A7-9C0D-A07D-DF498953BDB7', 'North Korea', '2015-04-14 12:09:36', 'KP', '850', NULL, NULL),
(118, '51E443A4-BBB7-45B3-BCCB-5D900AAC9A10', 'South Korea', '2015-04-14 12:09:36', 'KR', '82', NULL, NULL),
(119, '163246AC-AF1E-7EF1-ABD7-CA7C76048C0D', 'Kuwait', '2015-04-14 12:09:36', 'KW', '965', NULL, NULL),
(120, '627EF7AE-33FA-CBB0-5165-B69DE5D88639', 'Cayman Islands', '2015-04-14 12:09:36', 'KY', '1345', NULL, NULL),
(121, '4AF2B679-80E6-AE7A-6F8C-E30BB82170CB', 'Kazakhstan', '2015-04-14 12:09:36', 'KZ', '7', NULL, NULL),
(122, '5B49382E-7792-4FB2-5841-BDF46D215FB1', 'Laos', '2015-04-14 12:09:36', 'LA', '856', NULL, NULL),
(123, '4F9A2D48-4692-A93C-6A6C-A450F6B15B52', 'Lebanon', '2015-04-14 12:09:36', 'LB', '961', NULL, NULL),
(124, 'A969C15C-FDB8-B9BF-7A70-CA0B20F6E746', 'Saint Lucia', '2015-04-14 12:09:36', 'LC', '1758', NULL, NULL),
(125, 'D3A607AA-9E18-3D77-0504-8FB3762B08E9', 'Liechtenstein', '2015-04-14 12:09:36', 'LI', '423', NULL, NULL),
(126, '08186EF5-A816-5F3F-6334-2ACAFFC1036F', 'Sri Lanka', '2015-04-14 12:09:36', 'LK', '94', NULL, NULL),
(127, 'FEB0132D-0FA3-0A05-3088-59E88DFB6FCC', 'Liberia', '2015-04-14 12:09:36', 'LR', '231', NULL, NULL),
(128, 'D82F3778-BA0B-F2D7-87F1-F455816C0B10', 'Lesotho', '2015-04-14 12:09:36', 'LS', '266', NULL, NULL),
(129, 'ACC7107B-FEE4-C49E-AB16-5BBADE9707BB', 'Lithuania', '2015-04-14 12:09:36', 'LT', '370', NULL, NULL),
(130, 'D46FBEE9-CA64-2513-460C-6DE7B82E70AD', 'Luxembourg', '2015-04-14 12:09:36', 'LU', '352', NULL, NULL),
(131, 'EF9EF912-DBDC-2A60-3ABA-8F6413AB376C', 'Latvia', '2015-04-14 12:09:36', 'LV', '371', NULL, NULL),
(132, '331657A7-D80A-E3D9-306B-7B04580BE97A', 'Libya', '2015-04-14 12:09:36', 'LY', '218', NULL, NULL),
(133, '6F6551A5-A0D2-9614-2570-DB098D41795B', 'Morocco', '2015-04-14 12:09:36', 'MA', '212', NULL, NULL),
(134, 'D2C3C719-CFEF-92F9-1C75-4674404E2129', 'Monaco', '2015-04-14 12:09:36', 'MC', '377', NULL, NULL),
(135, 'AF24CA6E-08CF-9103-A408-198419511606', 'Moldova', '2015-04-14 12:09:36', 'MD', '373', NULL, NULL),
(136, '0B9CDE3D-E309-F36C-6C92-7A5A3CDB5C78', 'Montenegro', '2015-04-14 12:09:36', 'ME', '382', NULL, NULL),
(137, '7E7C60D7-8187-45FF-5856-FD4FE0A9F7F2', 'Saint Martin', '2015-04-14 12:09:36', 'MF', '1599', NULL, NULL),
(138, 'D0D90087-2CB8-BBF9-A0A7-7B9F83F0842A', 'Madagascar', '2015-04-14 12:09:36', 'MG', '261', NULL, NULL),
(139, '2148A143-2703-2688-50AC-4D449CC478C6', 'Marshall Islands', '2015-04-14 12:09:36', 'MH', '692', NULL, NULL),
(140, '4EDCA486-8363-D905-2223-0DD536C64FB1', 'Macedonia', '2015-04-14 12:09:36', 'MK', '389', NULL, NULL),
(141, 'D10BC835-779F-63B5-CD7F-77715C93EF5B', 'Mali', '2015-04-14 12:09:36', 'ML', '223', NULL, NULL),
(142, 'C6DE57ED-3F9E-5ECE-BED8-750D635B32D6', 'Burma (Myanmar)', '2015-04-14 12:09:36', 'MM', '95', NULL, NULL),
(143, '79B936B1-2C70-1B2B-CF22-5DF0EDA7BFF6', 'Mongolia', '2015-04-14 12:09:36', 'MN', '976', NULL, NULL),
(144, '340E0027-3A88-B6EF-1389-9830FF0111A1', 'Macau', '2015-04-14 12:09:36', 'MO', '853', NULL, NULL),
(145, '79F9CD19-DD9D-215E-C834-6896D595D1DB', 'Northern Mariana Islands', '2015-04-14 12:09:36', 'MP', '1670', NULL, NULL),
(146, '82B9D34C-D138-D44F-C78F-66E27B0B9DB5', 'Martinique', '2015-04-14 12:09:36', 'MQ', '', NULL, NULL),
(147, 'DE5DF1CD-0634-464F-0417-6E78249A9EFF', 'Mauritania', '2015-04-14 12:09:36', 'MR', '222', NULL, NULL),
(148, '6185D85F-EFD1-F321-5C88-FD92070CC6F9', 'Montserrat', '2015-04-14 12:09:36', 'MS', '1664', NULL, NULL),
(149, 'E06F0201-CA6B-EF55-EE95-7422AE9455EA', 'Malta', '2015-04-14 12:09:36', 'MT', '356', NULL, NULL),
(150, 'FB9AE8C0-1A45-2E86-6787-73467681C533', 'Mauritius', '2015-04-14 12:09:36', 'MU', '230', NULL, NULL),
(151, 'CCCFD4DB-F847-EFB5-A954-95C3E84C8810', 'Maldives', '2015-04-14 12:09:36', 'MV', '960', NULL, NULL),
(152, 'BAD2B0BE-60A9-CBF1-8650-F709F3F71937', 'Malawi', '2015-04-14 12:09:36', 'MW', '265', NULL, NULL),
(153, '8FB4F911-221D-C172-CD4A-2E3DDFC91E31', 'Mexico', '2015-04-14 12:09:36', 'MX', '52', NULL, NULL),
(154, '21DE1250-CA05-4ABE-5402-5AF7CEDEF190', 'Malaysia', '2015-04-14 12:09:36', 'MY', '60', NULL, NULL),
(155, '05CBFC51-7A5E-C473-BD2D-64E99EEF31AE', 'Mozambique', '2015-04-14 12:09:36', 'MZ', '258', NULL, NULL),
(156, '0CAA4FA5-DC6D-601A-001C-6D44E0DC5317', 'Namibia', '2015-04-14 12:09:36', 'NA', '264', NULL, NULL),
(157, '66330F5B-F3BC-C59D-E138-81AD487DCF5E', 'New Caledonia', '2015-04-14 12:09:36', 'NC', '687', NULL, NULL),
(158, 'D691B3AE-3239-514F-3A7C-82167837EA79', 'Niger', '2015-04-14 12:09:36', 'NE', '227', NULL, NULL),
(159, '0F9225AD-F626-4D0B-6201-E299B8BD215A', 'Norfolk Island', '2015-04-14 12:09:36', 'NF', '', NULL, NULL),
(160, '146B312A-59D0-71F1-FE10-6DF2E9FF3B13', 'Nigeria', '2015-04-14 12:09:36', 'NG', '234', NULL, NULL),
(161, 'D1B612B1-9C6B-C0FA-D185-9EF37FDD5B6B', 'Nicaragua', '2015-04-14 12:09:36', 'NI', '505', NULL, NULL),
(162, 'DBAE55F1-92C1-618E-32DD-FCFBCA5287F2', 'Netherlands', '2015-04-14 12:09:36', 'NL', '31', NULL, NULL),
(163, 'AA1566AC-5FBB-4165-5297-E3D1F56D23A2', 'Norway', '2015-04-14 12:09:36', 'NO', '47', NULL, NULL),
(164, '4BF12324-809E-BB44-C6B9-B7FCA9DC0160', 'Nepal', '2015-04-14 12:09:36', 'NP', '977', NULL, NULL),
(165, 'BE8F1645-08F9-9FBD-5885-1C0C6BC93848', 'Niue', '2015-04-14 12:09:36', 'NU', '683', NULL, NULL),
(166, '8761839C-0257-21D2-C497-382E5888F299', 'New Zealand', '2015-04-14 12:09:36', 'NZ', '64', NULL, NULL),
(167, '8AAA2CE8-5DDF-EE89-F73E-4757ED7AC246', 'Oman', '2015-04-14 12:09:36', 'OM', '968', NULL, NULL),
(168, 'CFFD5046-148C-6ED1-B68E-7A0FD7C591B7', 'Panama', '2015-04-14 12:09:36', 'PA', '507', NULL, NULL),
(169, 'CBF62F2B-70CD-EA41-2256-E45675C78C03', 'Peru', '2015-04-14 12:09:36', 'PE', '51', NULL, NULL),
(170, '6503A050-3EA4-38FA-FCE8-992DCE1B590B', 'French Polynesia', '2015-04-14 12:09:36', 'PF', '689', NULL, NULL),
(171, 'BA0C9E60-2EFE-AD8E-C0E7-29FCA7267DF5', 'Papua New Guinea', '2015-04-14 12:09:36', 'PG', '675', NULL, NULL),
(172, '88E336DC-5D75-752D-C77F-93A42D5B7C03', 'Philippines', '2015-04-14 12:09:36', 'PH', '63', NULL, NULL),
(173, '55FE4DF8-9BB2-126B-1F00-4334F8F7C640', 'Pakistan', '2015-04-14 12:09:36', 'PK', '92', NULL, NULL),
(174, '91DD425D-10F6-0FAC-73D3-5E3F5EFC86A2', 'Poland', '2015-04-14 12:09:36', 'PL', '48', NULL, NULL),
(175, '24354927-BE69-9B63-7324-7AE896674FF6', 'Saint Pierre and Miquelon', '2015-04-14 12:09:36', 'PM', '508', NULL, NULL),
(176, 'A21AA655-6CF5-A7A2-0CF3-374E511B7516', 'Pitcairn Islands', '2015-04-14 12:09:36', 'PN', '870', NULL, NULL),
(177, '7A0DF8B2-C5EC-FC58-9FC4-63FEC95F2DB9', 'Puerto Rico', '2015-04-14 12:09:36', 'PR', '1', NULL, NULL),
(178, '2BEE3A29-B3C8-7FE8-95F5-5DA81ECE0E75', 'State of Palestine', '2015-04-14 12:09:36', 'PS', '', NULL, NULL),
(179, '3BB8EFB5-BB65-F239-28B9-9B38E8FE83AE', 'Portugal', '2015-04-14 12:09:36', 'PT', '351', NULL, NULL),
(180, '7DFEFB58-159B-34CE-7B6E-5F5F74C0ED0B', 'Palau', '2015-04-14 12:09:36', 'PW', '680', NULL, NULL),
(181, '4E63C338-52F7-D693-39C8-6D9B09ECD5A8', 'Paraguay', '2015-04-14 12:09:36', 'PY', '595', NULL, NULL),
(182, '20319E02-E2D1-2FB9-B2B9-7CF8B7506DDF', 'Qatar', '2015-04-14 12:09:36', 'QA', '974', NULL, NULL),
(183, '0DF59336-53F1-F7C7-AB18-8DBF084DA125', 'Réunion', '2015-04-14 12:09:36', 'RE', '', NULL, NULL),
(184, 'E40912F1-CC15-4F2A-D8D1-FDC335CBC8CA', 'Romania', '2015-04-14 12:09:36', 'RO', '40', NULL, NULL),
(185, '38AC3FA4-283A-B36C-DC3D-1B59E7052A25', 'Serbia', '2015-04-14 12:09:36', 'RS', '381', NULL, NULL),
(186, '18A6D74E-6BE8-4CC8-8473-28EF91B436B2', 'Russia', '2015-04-14 12:09:36', 'RU', '7', NULL, NULL),
(187, '5E1EAB16-2E2F-39D3-0B0E-BF709AC39056', 'Rwanda', '2015-04-14 12:09:36', 'RW', '250', NULL, NULL),
(188, 'FDAB4E51-45A0-E5DF-1152-5DEAEC73C3AB', 'Saudi Arabia', '2015-04-14 12:09:36', 'SA', '966', NULL, NULL),
(189, 'CF21FB5C-9723-94F7-9F2B-F45CCAFC260D', 'Solomon Islands', '2015-04-14 12:09:36', 'SB', '677', NULL, NULL),
(190, '93C95D15-F10E-B87A-81DE-E9AAD84FC53A', 'Seychelles', '2015-04-14 12:09:36', 'SC', '248', NULL, NULL),
(191, '16302452-E1A6-D22C-5C99-133C48B5C980', 'Sudan', '2015-04-14 12:09:36', 'SD', '249', NULL, NULL),
(192, '472AA972-37BF-1FCF-5B13-03EAE9434088', 'Sweden', '2015-04-14 12:09:36', 'SE', '46', NULL, NULL),
(193, 'B2251D82-D868-DEAE-C811-4064951956F7', 'Singapore', '2015-04-14 12:09:36', 'SG', '65', NULL, NULL),
(194, 'F453E634-1155-9BCD-D903-08BEEC64C0A8', 'Saint Helena', '2015-04-14 12:09:36', 'SH', '290', NULL, NULL),
(195, 'B3D4C1FF-8E1D-DEEE-9A1A-39C83008F889', 'Slovenia', '2015-04-14 12:09:36', 'SI', '386', NULL, NULL),
(196, '8BF3EE1A-9967-AEDD-BA78-17C4087B28D9', 'Svalbard', '2015-04-14 12:09:36', 'SJ', '', NULL, NULL),
(197, '6FFA1E78-2CB2-B1CF-9D58-E0C9DEDA18AC', 'Slovakia', '2015-04-14 12:09:36', 'SK', '421', NULL, NULL),
(198, 'D6A4C632-C93A-839F-B09E-5480C4FAF1AD', 'Sierra Leone', '2015-04-14 12:09:36', 'SL', '232', NULL, NULL),
(199, '3DF96067-1DB6-B7CC-84B9-BAB7101F7131', 'San Marino', '2015-04-14 12:09:36', 'SM', '378', NULL, NULL),
(200, '2F0BC615-1C65-C7AA-47E8-9B5CA054D867', 'Senegal', '2015-04-14 12:09:36', 'SN', '221', NULL, NULL),
(201, 'C561F1FE-B072-5973-1DEC-F67D965DE27E', 'Somalia', '2015-04-14 12:09:36', 'SO', '252', NULL, NULL),
(202, '0775258C-EDC1-135D-E35C-01BD85F45F29', 'Suriname', '2015-04-14 12:09:36', 'SR', '597', NULL, NULL),
(203, 'AD0BAC3A-1DA4-23DA-0010-431A279304BE', 'Sao Tome and Principe', '2015-04-14 12:09:36', 'SS', '239', NULL, NULL),
(204, 'A4BDF3BD-B7F1-1B9B-CD98-A0C78ED53511', 'El Salvador', '2015-04-14 12:09:36', 'ST', '503', NULL, NULL),
(205, 'F4CEADD9-25F5-45F2-2E19-5B1795CE9D69', 'El Salvador', '2015-04-14 12:09:36', 'SV', '503', NULL, NULL),
(206, '46AD5507-C8B7-9F6D-571A-9E6E1C044CD6', 'Sint Maarten', '2015-04-14 12:09:36', 'SX', '', NULL, NULL),
(207, '3B28BF51-D190-F7CE-1BBA-49F72481AE3B', 'Syria', '2015-04-14 12:09:36', 'SY', '963', NULL, NULL),
(208, '1C48EC65-1073-25CD-5F53-7E4D22282B1B', 'Swaziland', '2015-04-14 12:09:36', 'SZ', '268', NULL, NULL),
(209, 'D3C33017-0BAE-B451-1190-B5A9A6D81265', 'Turks and Caicos Islands', '2015-04-14 12:09:36', 'TC', '1649', NULL, NULL),
(210, '436517D3-FF50-05BE-04A4-6314683C29BF', 'Chad', '2015-04-14 12:09:36', 'TD', '235', NULL, NULL),
(211, '373E212C-A17A-3D03-ACB3-588E2ECE1120', 'French Southern Territories', '2015-04-14 12:09:36', 'TF', '', NULL, NULL),
(212, '1DD74013-D596-D740-60F5-E007CFE9EE59', 'Togo', '2015-04-14 12:09:36', 'TG', '228', NULL, NULL),
(213, 'BF1DDCD3-0F3A-A81E-0508-910B20ED3822', 'Thailand', '2015-04-14 12:09:36', 'TH', '66', NULL, NULL),
(214, 'FB3A6E3C-53A9-CD6C-0F7C-302AB483B4BD', 'Tajikistan', '2015-04-14 12:09:36', 'TJ', '992', NULL, NULL),
(215, 'C343A6AB-0FAD-E093-7AF3-9589F5E58F64', 'Timor-Leste', '2015-04-14 12:09:36', 'TL', '670', NULL, NULL),
(216, 'DD3F11FD-CE04-AE45-D4DF-CB1324DDE122', 'Turkmenistan', '2015-04-14 12:09:36', 'TM', '993', NULL, NULL),
(217, '0AEF23A3-F684-B964-4D93-B507C40B66B4', 'Tunisia', '2015-04-14 12:09:36', 'TN', '216', NULL, NULL),
(218, 'A0662AD7-4934-E321-563F-6476311DD70C', 'Tonga', '2015-04-14 12:09:36', 'TO', '676', NULL, NULL),
(219, '5D0ECEE1-03F5-6D19-F5F3-F07F186DDF04', 'Turkey', '2015-04-14 12:09:36', 'TR', '90', NULL, NULL),
(220, 'F468D4C0-D571-5462-D0F1-6F0E4064AF46', 'Trinidad and Tobago', '2015-04-14 12:09:36', 'TT', '1868', NULL, NULL),
(221, 'BD92ECEC-C1D0-2516-23BF-75D5C2B05988', 'Tuvalu', '2015-04-14 12:09:36', 'TV', '688', NULL, NULL),
(222, 'C378CD23-31C4-6D56-EBA9-C38D38F74068', 'Taiwan', '2015-04-14 12:09:36', 'TW', '886', NULL, NULL),
(223, '11BAD1B7-D5B5-6F57-AE04-F483B2DEDAAB', 'Tanzania', '2015-04-14 12:09:36', 'TZ', '255', NULL, NULL),
(224, '4E7C6962-8A60-18F5-6380-6178B1BD4D1A', 'Ukraine', '2015-04-14 12:09:36', 'UA', '380', NULL, NULL),
(225, '2795DDE4-B42F-E010-4444-6F9AD1F42E87', 'Uganda', '2015-04-14 12:09:36', 'UG', '256', NULL, NULL),
(226, 'EF77733B-A972-EC78-8799-0BACF0ABF529', 'United States', '2015-04-14 12:09:36', 'US', '1', NULL, NULL),
(227, 'B1395F88-00C0-939B-DDFA-9DCBFB467EA4', 'Uruguay', '2015-04-14 12:09:36', 'UY', '598', NULL, NULL),
(228, '81E0BAA8-C899-C67F-9A1C-7F93971F181D', 'Uzbekistan', '2015-04-14 12:09:36', 'UZ', '998', NULL, NULL),
(229, '2ED293A8-00CF-E7F0-CA85-771A46E9F0B1', 'Holy See (Vatican City)', '2015-04-14 12:09:36', 'VA', '39', NULL, NULL),
(230, 'B34513B1-18A0-6F0F-9F93-5EBF96B73ADB', 'Saint Vincent and the Grenadines', '2015-04-14 12:09:36', 'VC', '1784', NULL, NULL),
(231, 'B4F3DA05-56D3-25AE-F8A9-8506B67C9004', 'Venezuela', '2015-04-14 12:09:36', 'VE', '58', NULL, NULL),
(232, '301B703B-B60C-4652-FB06-19CD778F0C74', 'British Virgin Islands', '2015-04-14 12:09:36', 'VG', '1284', NULL, NULL),
(233, 'C4ECE65F-CDFC-F50E-DCD9-3DB7CAB7C95E', 'US Virgin Islands', '2015-04-14 12:09:36', 'VI', '1340', NULL, NULL),
(234, 'C7245281-9AEA-4F60-73E4-0582061C77E9', 'Vietnam', '2015-04-14 12:09:36', 'VN', '84', NULL, NULL),
(235, 'BD92A44B-875F-79D2-3E12-D5175612D928', 'Vanuatu', '2015-04-14 12:09:36', 'VU', '678', NULL, NULL),
(236, 'E325ABAA-4150-836C-061D-6679EFEF3595', 'Wallis and Futuna', '2015-04-14 12:09:36', 'WF', '681', NULL, NULL),
(237, 'D8432DE9-535D-E306-0741-835AC0420A5B', 'Samoa', '2015-04-14 12:09:36', 'WS', '685', NULL, NULL),
(238, 'B133FA3B-7130-B4AF-373E-DEB720102D9B', 'Kosovo', '2015-04-14 12:09:36', 'XK', '', NULL, NULL),
(239, '3ABF1436-FAE0-3FD9-8948-501028332B17', 'Yemen', '2015-04-14 12:09:36', 'YE', '967', NULL, NULL),
(240, '7FA28C16-AE62-FBC2-7CEF-A5E4B71B826A', 'Mayotte', '2015-04-14 12:09:36', 'YT', '262', NULL, NULL),
(241, '38690943-EB49-39BB-09C7-1F987A3DDB85', 'South Africa', '2015-04-14 12:09:36', 'ZA', '27', NULL, NULL),
(242, '99795989-6422-28FE-D1A6-054605E86075', 'Zambia', '2015-04-14 12:09:36', 'ZM', '260', NULL, NULL),
(243, 'A6852D18-8C62-9B94-7F4B-2E65FE64EE88', 'Zimbabwe', '2015-04-14 12:09:36', 'ZW', '263', NULL, NULL);
-- --------------------------------------------------------
--
-- Table structure for table `elements`
--
DROP TABLE IF EXISTS `elements`;
CREATE TABLE IF NOT EXISTS `elements` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`SCENE_ID` int(10) NOT NULL DEFAULT '0',
`TITLE` varchar(255) NOT NULL DEFAULT '',
`TYPE` varchar(255) NOT NULL DEFAULT '',
`TOP` int(10) NOT NULL DEFAULT '0',
`LEFT` int(255) NOT NULL DEFAULT '0',
`WIDTH` int(255) NOT NULL DEFAULT '0',
`HEIGHT` int(255) NOT NULL DEFAULT '0',
`CROSS_SCENE` int(3) NOT NULL DEFAULT '0',
`BACKGROUND` int(3) NOT NULL DEFAULT '1',
`JAVASCRIPT` text,
`CSS` text,
`DX` int(10) NOT NULL DEFAULT '0',
`DY` int(10) NOT NULL DEFAULT '0',
`LINKED_ELEMENT_ID` int(10) NOT NULL DEFAULT '0',
`PRIORITY` int(10) NOT NULL DEFAULT '0',
`CSS_STYLE` varchar(255) NOT NULL DEFAULT '',
`POSITION_TYPE` int(3) NOT NULL DEFAULT '0',
`CONTAINER_ID` int(10) NOT NULL DEFAULT '0',
`S3D_SCENE` varchar(255) NOT NULL DEFAULT '',
`SMART_REPEAT` int(3) NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=7 ;
--
-- Dumping data for table `elements`
--
INSERT INTO `elements` (`ID`, `SCENE_ID`, `TITLE`, `TYPE`, `TOP`, `LEFT`, `WIDTH`, `HEIGHT`, `CROSS_SCENE`, `BACKGROUND`, `JAVASCRIPT`, `CSS`, `DX`, `DY`, `LINKED_ELEMENT_ID`, `PRIORITY`, `CSS_STYLE`, `POSITION_TYPE`, `CONTAINER_ID`, `S3D_SCENE`, `SMART_REPEAT`) VALUES
(1, 1, 'Webcam Sample', 'html', 55, 392, 270, 210, 0, 1, NULL, NULL, 0, 0, 0, 0, '', 0, 0, '', 0),
(6, 1, 'Switch 1', 'switch', 405, 465, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 'default', 0, 0, '', 0);
-- --------------------------------------------------------
--
-- Table structure for table `elm_states`
--
DROP TABLE IF EXISTS `elm_states`;
CREATE TABLE IF NOT EXISTS `elm_states` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`ELEMENT_ID` int(10) NOT NULL DEFAULT '0',
`TITLE` varchar(255) NOT NULL DEFAULT '',
`IMAGE` varchar(255) NOT NULL DEFAULT '',
`HTML` text,
`IS_DYNAMIC` int(3) NOT NULL DEFAULT '0',
`CURRENT_STATE` int(3) NOT NULL DEFAULT '0',
`LINKED_OBJECT` varchar(255) NOT NULL DEFAULT '',
`LINKED_PROPERTY` varchar(255) NOT NULL DEFAULT '',
`CONDITION` int(3) NOT NULL DEFAULT '0',
`CONDITION_VALUE` varchar(255) NOT NULL DEFAULT '',
`CONDITION_ADVANCED` text,
`SCRIPT_ID` int(10) NOT NULL DEFAULT '0',
`SWITCH_SCENE` int(3) NOT NULL DEFAULT '0',
`CURRENT_STATUS` int(3) NOT NULL DEFAULT '0',
`ACTION_OBJECT` varchar(255) NOT NULL DEFAULT '',
`ACTION_METHOD` varchar(255) NOT NULL DEFAULT '',
`MENU_ITEM_ID` int(10) NOT NULL DEFAULT '0',
`WINDOW_POSX` int(10) NOT NULL DEFAULT '0',
`WINDOW_POSY` int(10) NOT NULL DEFAULT '0',
`WINDOW_WIDTH` int(10) NOT NULL DEFAULT '0',
`WINDOW_HEIGHT` int(10) NOT NULL DEFAULT '0',
`HOMEPAGE_ID` int(10) NOT NULL DEFAULT '0',
`EXT_URL` varchar(255) NOT NULL DEFAULT '',
`PRIORITY` int(10) NOT NULL DEFAULT '0',
`CODE` text,
`OPEN_SCENE_ID` int(10) NOT NULL DEFAULT '0',
`S3D_OBJECT` varchar(255) NOT NULL DEFAULT '',
`S3D_CAMERA` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=6 ;
--
-- Dumping data for table `elm_states`
--
INSERT INTO `elm_states` (`ID`, `ELEMENT_ID`, `TITLE`, `IMAGE`, `HTML`, `IS_DYNAMIC`, `CURRENT_STATE`, `LINKED_OBJECT`, `LINKED_PROPERTY`, `CONDITION`, `CONDITION_VALUE`, `CONDITION_ADVANCED`, `SCRIPT_ID`, `SWITCH_SCENE`, `CURRENT_STATUS`, `ACTION_OBJECT`, `ACTION_METHOD`, `MENU_ITEM_ID`, `WINDOW_POSX`, `WINDOW_POSY`, `WINDOW_WIDTH`, `WINDOW_HEIGHT`, `HOMEPAGE_ID`, `EXT_URL`, `PRIORITY`, `CODE`, `OPEN_SCENE_ID`, `S3D_OBJECT`, `S3D_CAMERA`) VALUES
(1, 1, 'Default', '', '<img src="http://abclocal.go.com/three/wabc/webcam/skycpk.jpg" width="270">', 0, 1, '', '', 1, '', '', 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, '', 0, NULL, 0, '', ''),
(4, 6, 'off', '', 'Switch 1', 1, 1, 'Switch1', 'status', 4, '1', NULL, 0, 0, 0, 'Switch1', 'turnOn', 0, 0, 0, 0, 0, 0, '', 0, NULL, 0, '', ''),
(5, 6, 'on', '', 'Switch 1', 1, 0, 'Switch1', 'status', 1, '1', NULL, 0, 0, 0, 'Switch1', 'turnOff', 0, 0, 0, 0, 0, 0, '', 0, NULL, 0, '', '');
-- --------------------------------------------------------
--
-- Table structure for table `events`
--
DROP TABLE IF EXISTS `events`;
CREATE TABLE IF NOT EXISTS `events` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`EVENT_TYPE` varchar(10) NOT NULL DEFAULT '',
`TERMINAL_FROM` varchar(255) NOT NULL DEFAULT '',
`TERMINAL_TO` varchar(255) NOT NULL DEFAULT '',
`USER_FROM` varchar(255) NOT NULL DEFAULT '',
`USER_TO` varchar(255) NOT NULL DEFAULT '',
`WINDOW` varchar(255) NOT NULL DEFAULT '',
`DETAILS` text,
`ADDED` datetime DEFAULT NULL,
`EXPIRE` datetime DEFAULT NULL,
`PROCESSED` int(3) NOT NULL DEFAULT '0',
`EVENT_NAME` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=5 ;
--
-- Dumping data for table `events`
--
INSERT INTO `events` (`ID`, `EVENT_TYPE`, `TERMINAL_FROM`, `TERMINAL_TO`, `USER_FROM`, `USER_TO`, `WINDOW`, `DETAILS`, `ADDED`, `EXPIRE`, `PROCESSED`, `EVENT_NAME`) VALUES
(1, 'system', '', '', '', '', '', 'objects', '2014-09-05 13:01:00', '2014-09-07 13:01:00', 1, 'inhouseMovement');
-- --------------------------------------------------------
--
-- Table structure for table `gpsactions`
--
DROP TABLE IF EXISTS `gpsactions`;
CREATE TABLE IF NOT EXISTS `gpsactions` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`LOCATION_ID` int(10) NOT NULL DEFAULT '0',
`USER_ID` int(10) NOT NULL DEFAULT '0',
`ACTION_TYPE` int(255) NOT NULL DEFAULT '0',
`SCRIPT_ID` int(10) NOT NULL DEFAULT '0',
`CODE` text,
`LOG` text,
`EXECUTED` datetime DEFAULT NULL,
PRIMARY KEY (`ID`),
KEY `LOCATION_ID` (`LOCATION_ID`),
KEY `USER_ID` (`USER_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
-- --------------------------------------------------------
--
-- Table structure for table `gpsdevices`
--
DROP TABLE IF EXISTS `gpsdevices`;
CREATE TABLE IF NOT EXISTS `gpsdevices` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`USER_ID` int(10) NOT NULL DEFAULT '0',
`LAT` varchar(255) NOT NULL DEFAULT '',
`LON` varchar(255) NOT NULL DEFAULT '',
`UPDATED` datetime DEFAULT NULL,
`DEVICEID` varchar(255) NOT NULL DEFAULT '',
`TOKEN` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`),
KEY `USER_ID` (`USER_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=3 ;
-- --------------------------------------------------------
--
-- Table structure for table `gpslocations`
--
DROP TABLE IF EXISTS `gpslocations`;
CREATE TABLE IF NOT EXISTS `gpslocations` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`LAT` float NOT NULL DEFAULT '0',
`LON` float NOT NULL DEFAULT '0',
`RANGE` float NOT NULL DEFAULT '0',
`VIRTUAL_USER_ID` int(10) NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;
--
-- Dumping data for table `gpslocations`
--
INSERT INTO `gpslocations` (`ID`, `TITLE`, `LAT`, `LON`, `RANGE`, `VIRTUAL_USER_ID`) VALUES
(11, 'Location 1', 52.9471, 21.668, 500, 0);
-- --------------------------------------------------------
--
-- Table structure for table `gpslog`
--
DROP TABLE IF EXISTS `gpslog`;
CREATE TABLE IF NOT EXISTS `gpslog` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`ADDED` datetime DEFAULT NULL,
`LAT` float NOT NULL DEFAULT '0',
`LON` float NOT NULL DEFAULT '0',
`ALT` float NOT NULL DEFAULT '0',
`PROVIDER` varchar(30) NOT NULL DEFAULT '',
`SPEED` float NOT NULL DEFAULT '0',
`BATTLEVEL` int(3) NOT NULL DEFAULT '0',
`CHARGING` int(3) NOT NULL DEFAULT '0',
`DEVICEID` varchar(255) NOT NULL DEFAULT '',
`DEVICE_ID` int(10) NOT NULL DEFAULT '0',
`LOCATION_ID` int(10) NOT NULL DEFAULT '0',
`ACCURACY` float NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`),
KEY `DEVICE_ID` (`DEVICE_ID`),
KEY `LOCATION_ID` (`LOCATION_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2912 ;
-- --------------------------------------------------------
--
-- Table structure for table `history`
--
DROP TABLE IF EXISTS `history`;
CREATE TABLE IF NOT EXISTS `history` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`ADDED` datetime DEFAULT NULL,
`OBJECT_ID` int(10) NOT NULL DEFAULT '0',
`METHOD_ID` int(10) NOT NULL DEFAULT '0',
`VALUE_ID` int(10) NOT NULL DEFAULT '0',
`OLD_VALUE` varchar(255) NOT NULL DEFAULT '',
`NEW_VALUE` varchar(255) NOT NULL DEFAULT '',
`DETAILS` text,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2521 ;
-- --------------------------------------------------------
--
-- Table structure for table `ignore_updates`
--
DROP TABLE IF EXISTS `ignore_updates`;
CREATE TABLE IF NOT EXISTS `ignore_updates` (
`ID` tinyint(3) unsigned NOT NULL AUTO_INCREMENT,
`NAME` varchar(50) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ;
-- --------------------------------------------------------
--
-- Table structure for table `jobs`
--
DROP TABLE IF EXISTS `jobs`;
CREATE TABLE IF NOT EXISTS `jobs` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`COMMANDS` text NOT NULL,
`RUNTIME` datetime DEFAULT NULL,
`EXPIRE` datetime DEFAULT NULL,
`PROCESSED` int(3) NOT NULL DEFAULT '0',
`STARTED` datetime DEFAULT NULL,
`EXPIRED` int(3) NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=180729 ;
-- --------------------------------------------------------
--
-- Table structure for table `layouts`
--
DROP TABLE IF EXISTS `layouts`;
CREATE TABLE IF NOT EXISTS `layouts` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
`PRIORITY` int(10) NOT NULL DEFAULT '0',
`TYPE` varchar(255) NOT NULL DEFAULT '',
`CODE` text,
`APP` varchar(255) NOT NULL DEFAULT '',
`URL` char(255) NOT NULL DEFAULT '',
`DETAILS` text,
`REFRESH` int(10) NOT NULL DEFAULT '0',
`ICON` varchar(50) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=13 ;
--
-- Dumping data for table `layouts`
--
INSERT INTO `layouts` (`ID`, `TITLE`, `PRIORITY`, `TYPE`, `CODE`, `APP`, `URL`, `DETAILS`, `REFRESH`, `ICON`) VALUES
(6, '<#LANG_APP_PRODUCTS#>', 70, 'app', '', 'app_products', '', '', 0, ''),
(7, '<#LANG_MODULE_SCENES#>', 550, 'app', '', 'scenes', '', '', 0, ''),
(8, '<#LANG_WELCOME_GREETING#>', 1000, 'html', '<div style="padding-left:50px;padding-top:30px">\r\n<h1><#LANG_WELCOME_GREETING#></h1>\r\n \r\n<p style="font-size:14px">\r\n<#LANG_WELCOME_TEXT#>\r\n</p>\r\n</div>', '', '', '', 0, ''),
(9, '<#LANG_APP_CALENDAR#>', 100, 'app', '', 'app_calendar', '', '', 0, ''),
(10, '<#LANG_APP_MEDIA_BROWSER#>', 200, 'app', '', 'app_mediabrowser', '', '', 0, ''),
(12, 'GPS', 0, 'app', '', 'app_gpstrack', '', '', 0, '');
-- --------------------------------------------------------
--
-- Table structure for table `locations`
--
DROP TABLE IF EXISTS `locations`;
CREATE TABLE IF NOT EXISTS `locations` (
`ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
`TITLE` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=11 ;
--
-- Dumping data for table `locations`
--
INSERT INTO `locations` (`ID`, `TITLE`) VALUES
(1, 'Kitchen'),
(4, 'Livingroom'),
(5, 'Bedroom'),
(6, 'Hall'),
(7, 'Bathroom'),
(8, 'Toilet'),
(10, 'Child''s bedroom');
-- --------------------------------------------------------
--
-- Table structure for table `log4php_log`
--
DROP TABLE IF EXISTS `log4php_log`;
CREATE TABLE IF NOT EXISTS `log4php_log` (
`timestamp` datetime DEFAULT NULL,
`logger` varchar(256) DEFAULT NULL,
`level` varchar(32) DEFAULT NULL,
`message` varchar(4000) DEFAULT NULL,
`thread` int(11) DEFAULT NULL,
`file` varchar(255) DEFAULT NULL,
`line` varchar(10) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
-- --------------------------------------------------------
--
-- Table structure for table `media_favorites`
--
DROP TABLE IF EXISTS `media_favorites`;
CREATE TABLE IF NOT EXISTS `media_favorites` (