2804dac87c5971df8de808a66f7e0fa5a76a7057
[tine20] / tine20 / Voipmanager / Setup / setup.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <application>
3     <name>Voipmanager</name>
4     <version>8.0</version>
5     <order>50</order>
6     <depends>
7         <application>Admin</application>
8     </depends>
9     <tables>
10         <table>
11             <name>snom_software</name>
12             <engine>InnoDB</engine>
13             <charset>utf8</charset>
14             <version>1</version>
15             <declaration>
16                 <field>
17                     <name>id</name>
18                     <type>text</type>
19                     <length>40</length>
20                     <notnull>true</notnull>
21                 </field>
22                 <field>
23                     <name>name</name>
24                     <type>text</type>
25                     <length>200</length>
26                 </field>
27                 <field>
28                     <name>softwareimage_snom300</name>
29                     <type>text</type>
30                     <length>255</length>
31                 </field>
32                 <field>
33                     <name>softwareimage_snom320</name>
34                     <type>text</type>
35                     <length>255</length>
36                 </field>
37                 <field>
38                     <name>softwareimage_snom360</name>
39                     <type>text</type>
40                     <length>255</length>
41                 </field>
42                 <field>
43                     <name>softwareimage_snom370</name>
44                     <type>text</type>
45                     <length>255</length>
46                 </field>
47                 <field>
48                     <name>description</name>
49                     <type>text</type>
50                     <length>255</length>
51                 </field>                
52                 <index>
53                     <name>id</name>
54                     <primary>true</primary>
55                     <field>
56                         <name>id</name>
57                     </field>
58                 </index>
59             </declaration>
60         </table>
61
62         <table>
63             <name>snom_location</name>
64             <engine>InnoDB</engine>
65             <charset>utf8</charset>
66             <version>2</version>
67             <declaration>
68                 <field>
69                     <name>firmware_interval</name>
70                     <type>integer</type>
71                     <length>11</length>
72                     <notnull>false</notnull>
73                 </field>
74                 <field>
75                     <name>update_policy</name>
76                     <type>text</type>
77                     <length>32</length>
78                     <default>auto_update</default>
79                     <notnull>true</notnull>
80                 </field>
81                 <field>
82                     <name>registrar</name>
83                     <type>text</type>
84                     <length>255</length>
85                     <notnull>true</notnull>
86                 </field>
87                 <field>
88                     <name>base_download_url</name>
89                     <type>text</type>
90                     <length>255</length>
91                     <notnull>false</notnull>
92                 </field>
93                 <field>
94                     <name>admin_mode</name>
95                     <type>text</type>
96                     <length>32</length>
97                     <default>false</default>
98                     <notnull>true</notnull>
99                 </field>
100                 <field>
101                     <name>admin_mode_password</name>
102                     <type>text</type>
103                     <length>20</length>
104                     <notnull>false</notnull>
105                 </field>
106                 <field>
107                     <name>ntp_server</name>
108                     <type>text</type>
109                     <length>255</length>
110                     <notnull>false</notnull>
111                 </field>
112                 <field>
113                     <name>webserver_type</name>
114                     <type>text</type>
115                     <length>32</length>
116                     <default>https</default>
117                     <notnull>true</notnull>
118                 </field>
119                 <field>
120                     <name>http_port</name>
121                     <type>integer</type>
122                     <notnull>false</notnull>
123                 </field>
124                 <field>
125                     <name>https_port</name>
126                     <type>integer</type>
127                     <notnull>false</notnull>
128                 </field>
129                 <field>
130                     <name>http_user</name>
131                     <type>text</type>
132                     <length>20</length>
133                     <notnull>false</notnull>
134                 </field>
135                 <field>
136                     <name>http_pass</name>
137                     <type>text</type>
138                     <length>20</length>
139                     <notnull>false</notnull>
140                 </field>
141                 <field>
142                     <name>id</name>
143                     <type>text</type>
144                     <length>40</length>
145                     <notnull>true</notnull>
146                 </field>
147                 <field>
148                     <name>name</name>
149                     <type>text</type>
150                     <length>80</length>
151                     <notnull>true</notnull>
152                 </field>                
153                 <field>
154                     <name>description</name>
155                     <type>text</type>
156                     <length>255</length>
157                     <notnull>false</notnull>
158                 </field>
159                 <field>
160                     <name>timezone</name>
161                     <type>text</type>
162                     <notnull>false</notnull>
163                 </field>
164                 <field>
165                     <name>ntp_refresh</name>
166                     <type>integer</type>
167                     <notnull>false</notnull>
168                 </field>
169                 <field>                    
170                     <name>tone_scheme</name>
171                     <type>text</type>
172                     <length>32</length>
173                 </field>
174                 <field>
175                     <name>date_us_format</name>
176                     <type>boolean</type>
177                     <default>NULL</default>
178                 </field>     
179                 <field>
180                     <name>time_24_format</name>
181                     <type>boolean</type>
182                     <default>NULL</default>
183                 </field>     
184                 <index>
185                     <name>id</name>
186                     <primary>true</primary>
187                     <field>
188                         <name>id</name>
189                     </field>
190                 </index>
191             </declaration>
192         </table>        
193         
194         <table>
195             <name>snom_templates</name>
196             <engine>InnoDB</engine>
197             <charset>utf8</charset>
198             <version>2</version>
199             <declaration>
200                 <field>
201                     <name>id</name>
202                     <type>text</type>
203                     <length>40</length>
204                     <notnull>true</notnull>
205                 </field>
206                 <field>
207                     <name>name</name>
208                     <type>text</type>
209                     <length>80</length>
210                     <notnull>true</notnull>
211                 </field>                
212                 <field>
213                     <name>description</name>
214                     <type>text</type>
215                     <length>255</length>
216                     <notnull>false</notnull>
217                 </field>
218                 <field>
219                     <name>model</name>
220                     <type>text</type>
221                     <length>32</length>
222                     <default>snom300</default>
223                     <notnull>true</notnull>
224                 </field>
225                 <field>
226                     <name>keylayout_id</name>
227                     <type>text</type>
228                     <length>40</length>
229                     <notnull>false</notnull>
230                 </field>
231                 <field>
232                     <name>setting_id</name>
233                     <type>text</type>
234                     <length>40</length>
235                     <notnull>true</notnull>
236                 </field>
237                 <field>
238                     <name>software_id</name>
239                     <type>text</type>
240                     <length>40</length>
241                     <notnull>true</notnull>
242                 </field>              
243                 <index>
244                     <name>id</name>
245                     <primary>true</primary>
246                     <field>
247                         <name>id</name>
248                     </field>
249                 </index>
250                 <index>
251                     <name>snom_templates::software_id--snom_software::id</name>
252                     <field>
253                         <name>software_id</name>
254                     </field>
255                     <foreign>true</foreign>
256                     <reference>
257                         <table>snom_software</table>
258                         <field>id</field>
259                         <!-- add onupdate/ondelete? -->
260                     </reference>
261                 </index>   
262             </declaration>
263         </table>
264         
265         <table>
266             <name>snom_phones</name>
267             <engine>InnoDB</engine>
268             <charset>utf8</charset>
269             <version>2</version>
270             <declaration>
271                 <field>
272                     <name>id</name>
273                     <type>text</type>
274                     <length>40</length>
275                     <notnull>true</notnull>
276                 </field>
277                 <field>
278                     <name>macaddress</name>
279                     <type>text</type>
280                     <length>12</length>
281                     <notnull>true</notnull>
282                 </field>
283                 <field>
284                     <name>description</name>
285                     <type>text</type>
286                     <length>255</length>
287                 </field>
288                 <field>
289                     <name>location_id</name>
290                     <type>text</type>
291                     <length>40</length>
292                     <notnull>true</notnull>
293                 </field>
294                 <field>
295                     <name>template_id</name>
296                     <type>text</type>
297                     <length>40</length>
298                     <notnull>true</notnull>
299                 </field>
300                 <field>
301                     <name>ipaddress</name>
302                     <type>text</type>
303                     <length>20</length>
304                 </field>
305                 <field>
306                     <name>current_software</name>
307                     <type>text</type>
308                     <length>50</length>
309                 </field>
310                 <field>
311                     <name>current_model</name>
312                     <type>text</type>
313                     <length>32</length>
314                     <default>snom300</default>
315                     <notnull>true</notnull>
316                 </field>
317                 <field>
318                     <name>last_modified_time</name>
319                     <type>datetime</type>
320                 </field>
321                 <field>
322                     <name>settings_loaded_at</name>
323                     <type>datetime</type>
324                 </field>
325                 <field>
326                     <name>firmware_checked_at</name>
327                     <type>datetime</type>
328                 </field>
329                 <field>
330                     <name>redirect_event</name>
331                     <type>text</type>
332                     <length>32</length>
333                     <default>snom300</default>
334                     <notnull>true</notnull>         
335                 </field>
336                 <field>
337                     <name>redirect_number</name>
338                     <type>text</type>
339                     <length>255</length>
340                 </field>
341                 <field>
342                     <name>redirect_time</name>
343                     <type>integer</type>
344                     <length>11</length>
345                 </field>                                
346                 <field>
347                     <name>http_client_info_sent</name>
348                     <type>boolean</type>
349                     <default>false</default>
350                 </field>     
351                 <field>
352                     <name>http_client_user</name>
353                     <type>text</type>
354                     <length>40</length>
355                 </field>  
356                 <field>
357                     <name>http_client_pass</name>
358                     <type>text</type>
359                     <length>40</length>
360                 </field>
361                 <index>
362                     <name>id</name>
363                     <primary>true</primary>
364                     <field>
365                         <name>id</name>
366                     </field>
367                 </index>
368                 <index>
369                     <name>macaddress</name>
370                     <unique>true</unique>
371                     <field>
372                         <name>macaddress</name>
373                     </field>
374                 </index>              
375                 <index>
376                     <name>snom_phone::template_id--snom_templates::id</name>
377                     <field>
378                         <name>template_id</name>
379                     </field>
380                     <foreign>true</foreign>
381                     <reference>
382                         <table>snom_templates</table>
383                         <field>id</field>
384                         <!-- add onupdate/ondelete? -->
385                     </reference>
386                 </index>   
387                 <index>
388                     <name>snom_phone::location_id--snom_location::id</name>
389                     <field>
390                         <name>location_id</name>
391                     </field>
392                     <foreign>true</foreign>
393                     <reference>
394                         <table>snom_location</table>
395                         <field>id</field>
396                         <!-- add onupdate/ondelete? -->
397                     </reference>
398                 </index>   
399                 <index>
400                     <name>http_client_user</name>
401                     <unique>true</unique>
402                     <field>
403                         <name>http_client_user</name>
404                     </field>
405                 </index>
406             </declaration>
407         </table>
408         <table>
409             <name>asterisk_context</name>
410             <engine>InnoDB</engine>
411             <charset>utf8</charset>
412             <version>1</version>
413             <declaration>
414                 <field>
415                     <name>id</name>
416                     <type>text</type>
417                     <length>40</length>
418                     <notnull>true</notnull>
419                 </field>
420                 <field>
421                     <name>name</name>
422                     <type>text</type>
423                     <length>150</length>
424                     <notnull>true</notnull>
425                 </field>
426                 <field>
427                     <name>description</name>
428                     <type>text</type>
429                     <length>255</length>
430                     <notnull>true</notnull>
431                 </field>            
432                 <index>
433                     <name>id</name>
434                     <primary>true</primary>
435                     <field>
436                         <name>id</name>
437                     </field>
438                 </index>
439             </declaration>
440         </table>        
441         <table>
442             <name>asterisk_sip_peers</name>
443             <engine>InnoDB</engine>
444             <charset>utf8</charset>
445             <version>2</version>
446             <declaration>
447                 <field>
448                     <name>id</name>
449                     <type>text</type>
450                     <length>40</length>
451                     <notnull>true</notnull>
452                 </field>
453                 <field>
454                     <name>name</name>
455                     <type>text</type>
456                     <length>80</length>
457                     <notnull>false</notnull>
458                 </field>
459                 <field>
460                     <name>accountcode</name>
461                     <type>text</type>
462                     <length>20</length>
463                     <notnull>false</notnull>
464                 </field>
465                 <field>
466                     <name>amaflags</name>
467                     <type>text</type>
468                     <length>13</length>
469                     <notnull>false</notnull>
470                 </field>
471                 <field>
472                     <name>callgroup</name>
473                     <type>text</type>
474                     <length>10</length>
475                     <notnull>false</notnull>
476                 </field>
477                 <field>
478                     <name>callerid</name>
479                     <type>text</type>
480                     <length>80</length>
481                     <notnull>false</notnull>
482                 </field>
483                 <field>
484                     <name>canreinvite</name>
485                     <type>boolean</type>
486                     <default>NULL</default>
487                 </field>
488                 <field>
489                     <name>context_id</name>
490                     <type>text</type>
491                     <length>40</length>
492                     <notnull>true</notnull>
493                 </field>
494                 <field>
495                     <name>defaultip</name>
496                     <type>text</type>
497                     <length>15</length>
498                     <notnull>false</notnull>
499                 </field>
500                 <field>
501                     <name>dtmfmode</name>
502                     <type>text</type>
503                     <length>32</length>
504                     <default>rfc2833</default>
505                     <notnull>true</notnull>
506                 </field>
507                 <field>
508                     <name>fromuser</name>
509                     <type>text</type>
510                     <length>80</length>
511                     <notnull>false</notnull>
512                 </field>
513                 <field>
514                     <name>fromdomain</name>
515                     <type>text</type>
516                     <length>80</length>
517                     <notnull>false</notnull>
518                 </field>
519                 <field>
520                     <name>fullcontact</name>
521                     <type>text</type>
522                     <length>80</length>
523                     <notnull>false</notnull>
524                 </field>
525                 <field>
526                     <name>host</name>
527                     <type>text</type>
528                     <length>31</length>
529                     <default>dynamic</default>
530                 </field>
531                 <field>
532                     <name>insecure</name>
533                     <type>text</type>
534                     <length>32</length>
535                     <default>no</default>
536                     <notnull>true</notnull>
537                 </field>
538                 <field>
539                     <name>language</name>
540                     <type>text</type>
541                     <length>2</length>
542                     <notnull>false</notnull>
543                 </field>
544                 <field>
545                     <name>mailbox</name>
546                     <type>text</type>
547                     <length>50</length>
548                     <notnull>false</notnull>
549                 </field>
550                 <field>
551                     <name>md5secret</name>
552                     <type>text</type>
553                     <length>80</length>
554                     <notnull>false</notnull>
555                 </field>
556                 <field>
557                     <name>nat</name>
558                     <type>text</type>
559                     <length>32</length>
560                     <default>no</default>
561                     <notnull>true</notnull>
562                 </field>
563                 <field>
564                     <name>deny</name>
565                     <type>text</type>
566                     <length>95</length>
567                     <notnull>false</notnull>
568                 </field>
569                 <field>
570                     <name>permit</name>
571                     <type>text</type>
572                     <length>95</length>
573                     <notnull>false</notnull>
574                 </field>
575                 <field>
576                     <name>mask</name>
577                     <type>text</type>
578                     <length>95</length>
579                     <notnull>false</notnull>
580                 </field>
581                 <field>
582                     <name>pickupgroup</name>
583                     <type>text</type>
584                     <length>10</length>
585                     <notnull>false</notnull>
586                 </field>
587                 <field>
588                     <name>port</name>
589                     <type>text</type>
590                     <length>5</length>
591                     <notnull>false</notnull>
592                 </field>
593                 <field>
594                     <name>qualify</name>
595                     <type>text</type>
596                     <length>32</length>
597                     <default>no</default>
598                     <notnull>true</notnull>
599                 </field>
600                 <field>
601                     <name>restrictcid</name>
602                     <type>text</type>
603                     <length>1</length>
604                     <notnull>false</notnull>
605                 </field>
606                 <field>
607                     <name>rtptimeout</name>
608                     <type>text</type>
609                     <length>3</length>
610                     <notnull>false</notnull>
611                 </field>
612                 <field>
613                     <name>rtpholdtimeout</name>
614                     <type>text</type>
615                     <length>3</length>
616                     <notnull>false</notnull>
617                 </field>
618                 <field>
619                     <name>secret</name>
620                     <type>text</type>
621                     <length>80</length>
622                     <notnull>false</notnull>
623                 </field>
624                 <field>
625                     <name>type</name>
626                     <type>text</type>
627                     <length>32</length>
628                     <default>friend</default>
629                     <notnull>true</notnull>
630                 </field>
631                 <field>
632                     <name>defaultuser</name>
633                     <type>text</type>
634                     <length>80</length>
635                     <notnull>false</notnull>
636                 </field>
637                 <field>
638                     <name>disallow</name>
639                     <type>text</type>
640                     <length>100</length>
641                     <notnull>false</notnull>
642                 </field>
643                 <field>
644                     <name>allow</name>
645                     <type>text</type>
646                     <length>100</length>
647                     <notnull>false</notnull>
648                 </field>
649                 <field>
650                     <name>musiconhold</name>
651                     <type>text</type>
652                     <length>100</length>
653                     <notnull>false</notnull>
654                 </field>
655                 <field>
656                     <name>regseconds</name>
657                     <type>integer</type>
658                     <length>11</length>
659                     <default>0</default>
660                 </field>
661                 <field>
662                     <name>ipaddr</name>
663                     <type>text</type>
664                     <length>15</length>
665                     <notnull>false</notnull>
666                 </field>
667                 <field>
668                     <name>regexten</name>
669                     <type>text</type>
670                     <length>80</length>
671                     <notnull>false</notnull>
672                 </field>
673                 <field>
674                     <name>cancallforward</name>
675                     <type>boolean</type>
676                     <default>NULL</default>
677                 </field>
678                 <field>
679                     <name>setvar</name>
680                     <type>text</type>
681                     <length>100</length>
682                     <notnull>false</notnull>
683                 </field>
684                 <field>
685                     <name>notifyringing</name>
686                     <type>boolean</type>
687                     <default>NULL</default>
688                 </field>
689                 <field>
690                     <name>useclientcode</name>
691                     <type>boolean</type>
692                     <default>NULL</default>
693                 </field>
694                 <field>
695                     <name>authuser</name>
696                     <type>text</type>
697                     <length>100</length>
698                     <notnull>false</notnull>
699                 </field>
700                 <field>
701                     <name>call-limit</name>
702                     <type>integer</type>
703                     <length>11</length>
704                     <default>5</default>
705                 </field>
706                 <field>
707                     <name>busy-level</name>
708                     <type>integer</type>
709                     <length>11</length>
710                     <default>1</default>
711                 </field>
712                 <field>
713                     <name>regserver</name>
714                     <type>text</type>
715                     <length>254</length>
716                     <notnull>false</notnull>
717                 </field>
718                 <field>
719                     <name>useragent</name>
720                     <type>text</type>
721                     <length>254</length>
722                     <notnull>false</notnull>
723                 </field>
724                 <field>
725                     <name>lastms</name>
726                     <type>integer</type>
727                     <unsigned>false</unsigned>
728                     <length>11</length>
729                     <notnull>false</notnull>
730                 </field>
731                 <field>
732                     <name>cfi_mode</name>
733                     <type>text</type>
734                     <length>32</length>
735                     <default>off</default>
736                     <notnull>true</notnull>
737                 </field>
738                 <field>
739                     <name>cfi_number</name>
740                     <type>text</type>
741                     <length>80</length>
742                 </field>
743                 <field>
744                     <name>cfb_mode</name>
745                     <type>text</type>
746                     <length>32</length>
747                     <default>off</default>
748                     <notnull>true</notnull>
749                 </field>
750                 <field>
751                     <name>cfb_number</name>
752                     <type>text</type>
753                     <length>80</length>
754                 </field>
755                 <field>
756                     <name>cfd_mode</name>
757                     <type>text</type>
758                     <length>32</length>
759                     <default>off</default>
760                     <notnull>true</notnull>
761                 </field>
762                 <field>
763                     <name>cfd_number</name>
764                     <type>text</type>
765                     <length>80</length>
766                 </field>
767                 <field>
768                     <name>cfd_time</name>
769                     <type>integer</type>
770                     <length>11</length>
771                 </field>                                
772                 <index>
773                     <name>id</name>
774                     <primary>true</primary>
775                     <field>
776                         <name>id</name>
777                     </field>
778                 </index>
779                 <index>
780                     <name>name</name>
781                     <unique>true</unique>
782                     <field>
783                         <name>name</name>
784                     </field>
785                 </index>
786                 <index>
787                     <name>asterisk_sip_peers::context_id--asterisk_context::id</name>
788                     <field>
789                         <name>context_id</name>
790                     </field>
791                     <foreign>true</foreign>
792                     <reference>
793                         <table>asterisk_context</table>
794                         <field>id</field>
795                         <!-- add onupdate/ondelete? -->
796                     </reference>
797                 </index>
798             </declaration>
799         </table>          
800         <table>
801             <name>snom_lines</name>
802             <engine>InnoDB</engine>
803             <charset>utf8</charset>
804             <version>1</version>
805             <declaration>
806                 <field>
807                     <name>id</name>
808                     <type>text</type>
809                     <length>40</length>
810                     <notnull>true</notnull>
811                 </field>
812                 <field>
813                     <name>snomphone_id</name>
814                     <type>text</type>
815                     <length>40</length>
816                     <notnull>true</notnull>
817                 </field>
818                 <field>
819                     <name>asteriskline_id</name>
820                     <type>text</type>
821                     <length>40</length>
822                     <notnull>true</notnull>
823                 </field>
824                 <field>
825                     <name>linenumber</name>
826                     <type>integer</type>
827                 </field>
828                 <field>
829                     <name>lineactive</name>
830                     <type>boolean</type>
831                     <notnull>true</notnull>
832                 </field>
833                 <field>
834                     <name>idletext</name>
835                     <type>text</type>
836                     <length>40</length>
837                 </field>                
838                 <index>
839                     <name>id</name>
840                     <primary>true</primary>
841                     <field>
842                         <name>id</name>
843                     </field>
844                 </index>
845                 <index>
846                     <name>snomphone_id-linenumber</name>
847                     <unique>true</unique>
848                     <field>
849                         <name>snomphone_id</name>
850                     </field>
851                     <field>
852                         <name>linenumber</name>
853                     </field>
854                 </index>              
855                 <index>
856                     <name>snom_lines_snomphone_id</name>
857                     <field>
858                         <name>snomphone_id</name>
859                     </field>
860                     <foreign>true</foreign>
861                     <reference>
862                         <table>snom_phones</table>
863                         <field>id</field>
864                         <ondelete>cascade</ondelete>
865                         <!-- add onupdate? -->
866                     </reference>
867                 </index>   
868                 <index>
869                     <name>snom_lines_asteriskline_id</name>
870                     <field>
871                         <name>asteriskline_id</name>
872                     </field>
873                     <foreign>true</foreign>
874                     <reference>
875                         <table>asterisk_sip_peers</table>
876                         <field>id</field>
877                         <!-- add onupdate/ondelete? -->
878                     </reference>
879                 </index>   
880             </declaration>
881         </table>
882         <table>
883             <name>asterisk_voicemail</name>
884             <engine>InnoDB</engine>
885             <charset>utf8</charset>
886             <version>1</version>
887             <declaration>
888                 <field>
889                     <name>id</name>
890                     <type>text</type>
891                     <length>40</length>
892                     <notnull>true</notnull>
893                 </field>
894                 <field>
895                     <name>context_id</name>
896                     <type>text</type>
897                     <length>40</length>
898                     <notnull>true</notnull>
899                 </field>
900                 <field>
901                     <name>mailbox</name>
902                     <type>text</type>
903                     <length>11</length>
904                     <default>0</default>
905                 </field>
906                <field>
907                    <name>password</name>
908                    <type>text</type>
909                    <length>5</length>
910                    <default>0</default>
911                </field>
912                <field>
913                    <name>fullname</name>
914                    <type>text</type>
915                    <length>150</length>
916                    <notnull>true</notnull>
917                </field>
918                <field>
919                    <name>email</name>
920                    <type>text</type>
921                    <length>50</length>
922                    <notnull>false</notnull>
923                </field>
924                <field>
925                    <name>pager</name>
926                    <type>text</type>
927                    <length>50</length>
928                    <notnull>false</notnull>
929                </field>
930                <field>
931                    <name>tz</name>
932                    <type>text</type>
933                    <length>10</length>
934                    <default>central</default>
935                </field>
936                <field>
937                    <name>attach</name>
938                     <type>boolean</type>
939                     <default>NULL</default>
940                </field>
941                <field>
942                    <name>saycid</name>
943                     <type>boolean</type>
944                     <default>NULL</default>
945                </field>
946                <field>
947                    <name>dialout</name>
948                    <type>text</type>
949                    <length>10</length>
950                    <notnull>false</notnull>
951                </field>
952                <field>
953                    <name>callback</name>
954                    <type>text</type>
955                    <length>10</length>
956                    <notnull>false</notnull>
957                </field>
958                <field>
959                    <name>review</name>
960                    <type>boolean</type>
961                    <default>NULL</default>
962                </field>
963                <field>
964                    <name>operator</name>
965                     <type>boolean</type>
966                     <default>NULL</default>
967                </field>
968                <field>
969                    <name>envelope</name>
970                     <type>boolean</type>
971                     <default>NULL</default>
972                </field>
973                <field>
974                    <name>sayduration</name>
975                     <type>boolean</type>
976                     <default>NULL</default>
977                </field>
978                <field>
979                    <name>saydurationm</name>
980                    <type>integer</type>
981                    <length>4</length>
982                    <default>1</default>
983                </field>
984                <field>
985                    <name>sendvoicemail</name>
986                     <type>boolean</type>
987                     <default>NULL</default>
988                </field>
989                <field>
990                    <name>delete</name>
991                     <type>boolean</type>
992                     <default>NULL</default>
993                </field>
994                <field>
995                    <name>nextaftercmd</name>
996                     <type>boolean</type>
997                     <default>NULL</default>
998                </field>
999                <field>
1000                    <name>forcename</name>
1001                     <type>boolean</type>
1002                     <default>NULL</default>
1003                </field>
1004                <field>
1005                    <name>forcegreetings</name>
1006                     <type>boolean</type>
1007                     <default>NULL</default>
1008                </field>
1009                <field>
1010                    <name>hidefromdir</name>
1011                     <type>boolean</type>
1012                     <default>NULL</default>
1013                </field>
1014                <index>
1015                    <name>id</name>
1016                    <primary>true</primary>
1017                    <field>
1018                        <name>id</name>
1019                    </field>
1020                </index>
1021                 <index>
1022                     <name>asterisk_voicemail::context_id--asterisk_context::id</name>
1023                     <field>
1024                         <name>context_id</name>
1025                     </field>
1026                     <foreign>true</foreign>
1027                     <reference>
1028                         <table>asterisk_context</table>
1029                         <field>id</field>
1030                         <!-- add onupdate/ondelete? -->
1031                     </reference>
1032                 </index>
1033            </declaration>
1034         </table>            
1035         
1036         <table>
1037             <name>snom_default_settings</name>
1038             <engine>InnoDB</engine>
1039             <charset>utf8</charset>
1040             <version>3</version>
1041             <declaration>
1042                 <field>
1043                     <name>id</name>
1044                     <type>text</type>
1045                     <length>40</length>
1046                     <notnull>true</notnull>
1047                 </field>
1048                 <field>
1049                     <name>name</name>
1050                     <type>text</type>
1051                     <length>150</length>
1052                     <notnull>true</notnull>
1053                 </field>
1054                 <field>
1055                     <name>description</name>
1056                     <type>text</type>
1057                     <length>255</length>
1058                     <notnull>true</notnull>
1059                 </field> 
1060                 <field>
1061                     <name>web_language</name>
1062                     <type>text</type>
1063                     <length>32</length>
1064                 </field>
1065                 <field>
1066                     <name>language</name>
1067                     <type>text</type>
1068                     <length>32</length>
1069                 </field>
1070                 <field>
1071                     <name>display_method</name>
1072                     <type>text</type>
1073                     <length>32</length>
1074                 </field>
1075                 <field>
1076                     <name>mwi_notification</name>
1077                     <type>text</type>
1078                     <length>32</length>
1079                     <default>silent</default>
1080                     <notnull>true</notnull>
1081                 </field>
1082                 <field>
1083                     <name>mwi_dialtone</name>
1084                     <type>text</type>
1085                     <length>32</length>
1086                 </field>
1087                 <field>
1088                     <name>headset_device</name>
1089                     <type>text</type>
1090                     <length>32</length>
1091                 </field>
1092                 <field>
1093                     <name>message_led_other</name>
1094                     <type>boolean</type>
1095                     <notnull>false</notnull>
1096                     <default>NULL</default>
1097                 </field>
1098                 <field>
1099                     <name>global_missed_counter</name>
1100                     <type>boolean</type>
1101                     <notnull>false</notnull>
1102                     <default>NULL</default>
1103                 </field>
1104                 <field>
1105                     <name>scroll_outgoing</name>
1106                     <type>boolean</type>
1107                     <notnull>false</notnull>
1108                     <default>NULL</default>
1109                 </field>
1110                 <field>
1111                     <name>show_local_line</name>
1112                     <type>boolean</type>
1113                     <notnull>false</notnull>
1114                     <default>NULL</default>
1115                 </field>
1116                 <field>
1117                     <name>show_call_status</name>
1118                     <type>boolean</type>
1119                     <notnull>false</notnull>
1120                     <default>NULL</default>
1121                 </field> 
1122                 <field>
1123                     <name>call_waiting</name>
1124                     <type>text</type>
1125                     <length>32</length>
1126                 </field>     
1127                 <field>
1128                     <name>web_language_w</name>
1129                     <type>boolean</type>
1130                     <default>false</default>
1131                 </field>     
1132                 <field>
1133                     <name>language_w</name>
1134                     <type>boolean</type>
1135                     <default>false</default>
1136                 </field>     
1137                 <field>
1138                     <name>display_method_w</name>
1139                     <type>boolean</type>
1140                     <default>false</default>
1141                 </field>  
1142                 <field>
1143                     <name>call_waiting_w</name>
1144                     <type>boolean</type>
1145                     <default>false</default>
1146                 </field>                     
1147                 <field>
1148                     <name>mwi_notification_w</name>
1149                     <type>boolean</type>
1150                     <default>false</default>
1151                 </field>     
1152                 <field>
1153                     <name>mwi_dialtone_w</name>
1154                     <type>boolean</type>
1155                     <default>false</default>
1156                 </field>     
1157                 <field>
1158                     <name>headset_device_w</name>
1159                     <type>boolean</type>
1160                     <default>false</default>
1161                 </field>     
1162                 <field>
1163                     <name>message_led_other_w</name>
1164                     <type>boolean</type>
1165                     <default>false</default>
1166                 </field>     
1167                 <field>
1168                     <name>global_missed_counter_w</name>
1169                     <type>boolean</type>
1170                     <default>false</default>
1171                 </field>     
1172                 <field>
1173                     <name>scroll_outgoing_w</name>
1174                     <type>boolean</type>
1175                     <default>false</default>
1176                 </field>     
1177                 <field>
1178                     <name>show_local_line_w</name>
1179                     <type>boolean</type>
1180                     <default>false</default>
1181                 </field>     
1182                 <field>
1183                     <name>show_call_status_w</name>
1184                     <type>boolean</type>
1185                     <default>false</default>
1186                 </field>          
1187                 <index>
1188                     <name>id</name>
1189                     <primary>true</primary>
1190                     <field>
1191                         <name>id</name>
1192                     </field>
1193                 </index>
1194             </declaration>
1195         </table>          
1196
1197         <table>
1198             <name>asterisk_meetme</name>
1199             <engine>InnoDB</engine>
1200             <charset>utf8</charset>
1201             <version>1</version>
1202             <declaration>
1203                 <field>
1204                     <name>id</name>
1205                     <type>text</type>
1206                     <length>40</length>
1207                     <notnull>true</notnull>
1208                 </field>
1209                 <field>
1210                     <name>confno</name>
1211                     <type>text</type>
1212                     <length>80</length>
1213                     <notnull>true</notnull>
1214                 </field>
1215                 <field>
1216                     <name>pin</name>
1217                     <type>text</type>
1218                     <length>80</length>
1219                     <notnull>true</notnull>
1220                 </field>
1221                 <field>
1222                     <name>adminpin</name>
1223                     <type>text</type>
1224                     <length>80</length>
1225                     <notnull>true</notnull>
1226                 </field>                                                                
1227                 <field>
1228                     <name>members</name>
1229                     <type>integer</type>
1230                 </field>                                
1231                 <field>
1232                     <name>starttime</name>
1233                     <type>datetime</type>
1234                 </field>                                
1235                 <field>
1236                     <name>endtime</name>
1237                     <type>datetime</type>
1238                 </field>                                
1239                 <index>
1240                     <name>id</name>
1241                     <primary>true</primary>
1242                     <field>
1243                         <name>id</name>
1244                     </field>
1245                 </index>
1246             </declaration>
1247         </table> 
1248         
1249         <table>
1250             <name>snom_phone_settings</name>
1251             <engine>InnoDB</engine>
1252             <charset>utf8</charset>
1253             <version>2</version>
1254             <declaration>
1255                 <field>
1256                     <name>phone_id</name>
1257                     <type>text</type>
1258                     <length>40</length>
1259                     <notnull>true</notnull>
1260                 </field>
1261                 <field>
1262                     <name>web_language</name>
1263                     <type>text</type>
1264                     <length>32</length>
1265                 </field>
1266                 <field>
1267                     <name>language</name>
1268                     <type>text</type>
1269                     <length>32</length>
1270                 </field>
1271                 <field>
1272                     <name>display_method</name>
1273                     <type>text</type>
1274                     <length>32</length>
1275                 </field>
1276                 <field>
1277                     <name>mwi_notification</name>
1278                     <type>text</type>
1279                     <length>32</length>
1280                 </field>
1281                 <field>
1282                     <name>mwi_dialtone</name>
1283                     <type>text</type>
1284                     <length>32</length>
1285                 </field>
1286                 <field>
1287                     <name>headset_device</name>
1288                     <type>text</type>
1289                     <length>32</length>
1290                 </field>
1291                 <field>
1292                     <name>message_led_other</name>
1293                     <type>boolean</type>
1294                     <notnull>false</notnull>                    
1295                     <default>NULL</default>
1296                 </field>
1297                 <field>
1298                     <name>global_missed_counter</name>
1299                     <type>boolean</type>
1300                     <notnull>false</notnull>                                        
1301                     <default>NULL</default>
1302                 </field>
1303                 <field>
1304                     <name>scroll_outgoing</name>
1305                     <type>boolean</type>
1306                     <notnull>false</notnull>                                        
1307                     <default>NULL</default>
1308                 </field>
1309                 <field>
1310                     <name>show_local_line</name>
1311                     <type>boolean</type>
1312                     <notnull>false</notnull>                                        
1313                     <default>NULL</default>
1314                 </field>
1315                 <field>
1316                     <name>show_call_status</name>
1317                     <type>boolean</type>
1318                     <notnull>false</notnull>                                        
1319                     <default>NULL</default>
1320                 </field>               
1321                 <field>
1322                     <name>call_waiting</name>
1323                     <type>text</type>
1324                     <length>32</length>
1325                 </field>     
1326                 <index>
1327                     <name>phone_id</name>
1328                     <unique>true</unique>
1329                     <field>
1330                         <name>phone_id</name>
1331                     </field>
1332                 </index>       
1333                 <index>
1334                     <name>snom_phone_settings::phone_id--snom_phone::id</name>
1335                     <field>
1336                         <name>phone_id</name>
1337                     </field>
1338                     <foreign>true</foreign>
1339                     <reference>
1340                         <table>snom_phones</table>
1341                         <field>id</field>
1342                         <ondelete>cascade</ondelete> 
1343                         <!-- add onupdate? -->
1344                     </reference>
1345                 </index>
1346             </declaration>
1347         </table>         
1348
1349         <table>
1350             <name>snom_phones_acl</name>
1351             <version>2</version>
1352             <declaration>
1353                 <field>
1354                     <name>id</name>
1355                     <type>text</type>
1356                     <length>40</length>
1357                     <notnull>true</notnull>
1358                 </field>
1359                 <field>
1360                     <name>snom_phone_id</name>
1361                     <type>text</type>
1362                     <length>40</length>
1363                     <notnull>true</notnull>
1364                 </field>
1365                 <field>
1366                     <name>account_type</name>
1367                     <type>text</type>
1368                     <length>32</length>
1369                     <default>user</default>
1370                     <notnull>true</notnull>
1371                 </field>
1372                 <field>
1373                     <name>account_id</name>
1374                         <type>text</type>
1375                         <length>40</length>
1376                     <notnull>true</notnull>
1377                 </field>
1378                 <field>
1379                     <name>read_right</name>
1380                     <type>boolean</type>
1381                     <default>false</default>
1382                 </field>
1383                 <field>
1384                     <name>write_right</name>
1385                     <type>boolean</type>
1386                     <default>false</default>
1387                 </field>
1388                 <field>
1389                     <name>dial_right</name>
1390                     <type>boolean</type>
1391                     <default>false</default>
1392                 </field>                
1393                 
1394                 <index>
1395                     <name>id</name>
1396                     <primary>true</primary>
1397                     <field>
1398                         <name>id</name>
1399                     </field>
1400                 </index>
1401                 <index>
1402                     <unique>true</unique>
1403                     <name>snom_phone_id-account_type-account_id</name>
1404                     <field>
1405                         <name>snom_phone_id</name>
1406                     </field>
1407                     <field>
1408                         <name>account_type</name>
1409                     </field>
1410                     <field>
1411                         <name>account_id</name>
1412                     </field>
1413                 </index>
1414                 <index>
1415                     <name>snom_phone_acl::snome_phone_id--snome_phones::id</name>
1416                     <field>
1417                         <name>snom_phone_id</name>
1418                     </field>
1419                     <foreign>true</foreign>
1420                     <reference>
1421                         <table>snom_phones</table>
1422                         <field>id</field>
1423                         <ondelete>cascade</ondelete>
1424                         <!-- add onupdate? -->
1425                     </reference>
1426                 </index>
1427             </declaration>
1428         </table>
1429         
1430         <table>
1431             <name>asterisk_redirects</name>
1432             <engine>InnoDB</engine>
1433             <charset>utf8</charset>
1434             <version>3</version>
1435             <declaration>
1436                 <field>
1437                     <name>id</name>
1438                     <type>text</type>
1439                     <length>40</length>
1440                     <notnull>true</notnull>
1441                 </field>
1442                 <field>
1443                     <name>cfi_mode</name>
1444                     <type>text</type>
1445                     <length>32</length>
1446                     <default>off</default>
1447                     <notnull>true</notnull>
1448                 </field>
1449                 <field>
1450                     <name>cfi_number</name>
1451                     <type>text</type>
1452                     <length>80</length>
1453                 </field>
1454                 <field>
1455                     <name>cfb_mode</name>
1456                     <type>text</type>
1457                     <length>32</length>
1458                     <default>off</default>
1459                     <notnull>true</notnull>
1460                 </field>
1461                 <field>
1462                     <name>cfb_number</name>
1463                     <type>text</type>
1464                     <length>80</length>
1465                 </field>
1466                 <field>
1467                     <name>cfd_mode</name>
1468                     <type>text</type>
1469                     <length>32</length>
1470                     <default>off</default>
1471                     <notnull>true</notnull>
1472                 </field>
1473                 <field>
1474                     <name>cfd_number</name>
1475                     <type>text</type>
1476                     <length>80</length>
1477                 </field>
1478                 <field>
1479                     <name>cfd_time</name>
1480                     <type>integer</type>
1481                     <length>11</length>
1482                 </field>
1483                 <index>
1484                     <name>id</name>
1485                     <primary>true</primary>
1486                     <field>
1487                         <name>id</name>
1488                     </field>
1489                 </index>
1490                 <index>
1491                     <name>asterisk_redirect::id--asterisk_sip_peers::id</name>
1492                     <field>
1493                         <name>id</name>
1494                     </field>
1495                     <foreign>true</foreign>
1496                     <reference>
1497                         <table>asterisk_sip_peers</table>
1498                         <field>id</field>
1499                         <ondelete>cascade</ondelete>
1500                         <onupdate>cascade</onupdate>
1501                     </reference>
1502                 </index>
1503             </declaration>
1504         </table>
1505      </tables>
1506 </application>