You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

139 lines
3.5 KiB

12 months ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. <?php
  2. require_once('../ajax_asm.php');
  3. $UID = intval( $CUser->Data['id'] );
  4. $ACCESS = intval( $CUser->Data['access'] );
  5. if( $UID > 1 ){
  6. ob_start();
  7. $ZIGA = array();
  8. foreach( $Site_Languages as $SL ) $ZIGA[] = "[{$SL['id']},'{$SL['name']}']";
  9. $LAN_DATA = implode(',',$ZIGA );
  10. $CUser->Data['ss_timeout'] = $CUser->Data['ss_timeout']/1000;
  11. $BASIC_CONTENT=<<<DATA_BOUNDARY
  12. {
  13. xtype: 'panel',
  14. layout: 'hbox',
  15. items:[{
  16. xtype: 'form',
  17. labelAlign: 'right',
  18. labelWidth: 250,
  19. width: '50%',
  20. height: PanelH - 16,
  21. items:[{
  22. xtype:'panel',
  23. border: false,
  24. frame: false,
  25. html: '<table width="100%" border=0 class="setEd_infoPanel" id="LIBAV_LOGO"><tr><td width="200px"><div class="appis_logo_img"></div></td><td valign="middle">User Profile Settings</td></tr><tr><td colspan=2></td></tr></table><br/>'
  26. },{
  27. xtype: 'spacer',
  28. height: 10
  29. },{
  30. xtype: 'combo',
  31. id: 'pf_language',
  32. fieldLabel: '{$Labels->GetLabel('_LANGUAGE_')}',
  33. editable: false,
  34. typeAhead: true,
  35. triggerAction: 'all',
  36. width: '100%',
  37. lazyRender:true,
  38. mode: 'local',
  39. store: new Ext.data.ArrayStore({
  40. fields: ['cid', 'cnam'],
  41. data: [{$LAN_DATA}]
  42. }),
  43. valueField: 'cid',
  44. displayField: 'cnam',
  45. listeners:{
  46. focus: function( t ){
  47. loadHelpTopic( 'profile_op_small', 1 );
  48. },
  49. select: function( t, r, i ){
  50. doUserOperation( 21, r.data.cid, true );
  51. }
  52. },
  53. value: '{$CUser->Data['language']}'
  54. },{
  55. xtype: 'spacer',
  56. height: 10
  57. },{
  58. xtype: 'numberfield',
  59. fieldLabel: 'Screen Saver Time',
  60. editable: true,
  61. width: 250,
  62. value: '{$CUser->Data['ss_timeout']}',
  63. listeners:{
  64. focus: function( t ){
  65. loadHelpTopic( 'profile_op_small', 2 );
  66. },
  67. change: function( t, r, i ){
  68. doUserOperation( 28, r, true );
  69. }
  70. }
  71. },{
  72. xtype: 'spacer',
  73. height: 10
  74. },{
  75. xtype: 'combo',
  76. id: 'pf_theme',
  77. fieldLabel: '{$Labels->GetLabel('_UI_THEME_')}',
  78. editable: false,
  79. typeAhead: true,
  80. triggerAction: 'all',
  81. width: '100%',
  82. lazyRender:true,
  83. mode: 'local',
  84. store: new Ext.data.ArrayStore({
  85. fields: ['cid', 'cnam'],
  86. data: [[0,'Dark'],[1,'Gray'],[2,'Blue'],[3,'Default']]
  87. }),
  88. valueField: 'cid',
  89. displayField: 'cnam',
  90. listeners:{
  91. focus: function( t ){
  92. loadHelpTopic( 'profile_op_small', 3 );
  93. },
  94. select: function( t, r, i ){
  95. doUserOperation( 29, r.data.cid, true );
  96. }
  97. },
  98. value: '{$CUser->Data['ui_theme']}'
  99. }]
  100. },{
  101. xtype: 'panel',
  102. id: 'profile_op_small',
  103. flex: 1,
  104. height: PanelH-15,
  105. layout: 'fit',
  106. items:[{
  107. html: "<div class='setEd_infoPanel' id='NUNU'>{$Labels->GetLabel('_PLS_SEL_LEFT_ITEM_')}</div>"
  108. }]
  109. }]
  110. }
  111. DATA_BOUNDARY;
  112. $Data['status'] = 'ok';
  113. if( $CUser->Data['access'] < 6 ){
  114. $TAB_CTX = '';
  115. $MAIN_A_6 = '';
  116. if( $CUser->Data['access'] < 5 ){
  117. $MAIN_A_5 = '';
  118. if( $CUser->Data['access'] < 4 ){
  119. $MAIN_A_4 = '';
  120. };
  121. };
  122. };
  123. $Data['content'] = $BASIC_CONTENT;
  124. $Data['content'] = str_ireplace( '%%CTX_ACCESS_4%%', $MAIN_A_4, $Data['content'] );
  125. $Data['content'] = str_ireplace( '%%CTX_ACCESS_5%%', $MAIN_A_5, $Data['content'] );
  126. $Data['content'] = str_ireplace( '%%CTX_ACCESS_6%%', $MAIN_A_6, $Data['content'] );
  127. $Data['content'] = str_ireplace( '%%TAB_CTX%%%', $TAB_CTX, $Data['content'] );
  128. $Data['messages'] = ob_get_clean();
  129. } else {
  130. header('location: /');
  131. exit();
  132. };
  133. echo json_encode( $Data );
  134. ?>