/source/gl/mb/form/htmleditor.html

http://prosporous.googlecode.com/ · HTML · 177 lines · 174 code · 3 blank · 0 comment · 0 complexity · b68a1ac7fbba8b867a3fa1aba022a93d MD5 · raw file

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <title>??????-combo</title>
  6. <{$showjs}>
  7. <link rel="stylesheet" type="text/css" href="../css/main1.css" />
  8. <style>
  9. .x-check-group-alt {
  10. background: #D1DDEF;
  11. border-top:1px dotted #B5B8C8;
  12. border-bottom:1px dotted #B5B8C8;
  13. }
  14. </style>
  15. <script language="javascript">
  16. Ext.onReady(function(){
  17. Ext.QuickTips.init();
  18. Ext.form.Field.prototype.msgTarget = 'side';
  19. var myMask = new Ext.LoadMask(Ext.getBody(), {
  20. msg: '???...',
  21. removeMask: true //?????
  22. });
  23. var fp = new Ext.FormPanel({
  24. frame: true,
  25. // title:'????? [Right Group Config]',
  26. labelWidth: 110,
  27. width: Ext.getBody().getWidth(),
  28. renderTo:'form-ct',
  29. bodyStyle: 'padding:0 10px 0;',
  30. items: [{
  31. xtype:'fieldset',
  32. title: '????',
  33. autoHeight: true,
  34. layout: 'form',
  35. items: [{
  36. xtype: 'textfield',
  37. name: 'width',
  38. fieldLabel: '??{TM??????,??}',
  39. itemCls: 'x-check-group-alt',
  40. value:'<{if $fld.width==''}>400<{else}><{$fld.width}><{/if}>',
  41. width:'80px'
  42. },{
  43. xtype: 'textfield',
  44. name: 'cfg[height]',
  45. fieldLabel: '??{??TM??}',
  46. itemCls: 'x-check-group-alt',
  47. value:'<{if $cfg.height==''}>200<{else}><{$cfg.height}><{/if}>',
  48. width:'80px'
  49. },{
  50. xtype: 'checkboxgroup',
  51. fieldLabel: '????',
  52. itemCls: 'x-check-group-alt',
  53. items: [
  54. {boxLabel: '????', name: 'bt',inputValue: 1<{if $fld.bt=='1'}>,checked: true<{/if}>},
  55. {boxLabel: '????', name: 'gj',inputValue: 1<{if $fld.gj=='1'}>,checked: true<{/if}>},
  56. {boxLabel: '????', name: 'zy',inputValue: 1<{if $fld.zy=='1'}>,checked: true<{/if}>},
  57. {boxLabel: '????', name: 'xr',inputValue:1<{if $fld.xr=='1'}>,checked: true<{/if}>}
  58. ]
  59. }]
  60. },{
  61. xtype:'fieldset',
  62. title: '??????',
  63. autoHeight: true,
  64. items: [{
  65. itemCls: 'x-check-group-alt',
  66. allowBlank: false,
  67. layout:'form',
  68. items: [{
  69. xtype: 'textarea',
  70. fieldLabel: 'STR[JSON]{,??,?????,???EXTJS??JSON??.}',
  71. name:'cfg[STR]',
  72. width:200,
  73. value:'<{$cfg.STR}>'
  74. }]
  75. }]
  76. },{
  77. xtype:'fieldset',
  78. title: '????',
  79. autoHeight: true,
  80. items: [{
  81. itemCls: 'x-check-group-alt',
  82. allowBlank: false,
  83. layout:'column',
  84. items: [{
  85. columnWidth: '.33',
  86. bodyStyle: 'padding:0 10px 0;',
  87. labelWidth:60,
  88. layout:'form',
  89. items: [{
  90. html:"<font color='red'><b>???<hr></b></font>"
  91. },{xtype: 'combo',value:'<{if $fld.qzfs==''}>1<{else}><{$fld.qzfs}><{/if}>',fieldLabel:'????',blankText:'...????',style:'text-align:left',mode: 'local',forceSelection: true,triggerAction: 'all',width: 90,editable: false,emptyText:'???...',valueField :'yinv',displayField:'xianv',store:new Ext.data.SimpleStore({fields:['yinv','xianv'],data:[['0','???'],['1','????'],['function','function'],['$_GET','$_GET'],['$_POST','$_POST'],['$_SESSION','$_SESSION'],['$_COOKIE','$_COOKIE'],['$_SERVER','$_SERVER'],['$_ENV','$_ENV'],['$_FILES','$_FILES']]}),hiddenName: 'qzfs'},
  92. {
  93. xtype: 'textfield',
  94. name: 'blm',
  95. fieldLabel: '???',
  96. value:"<{$fld.blm}>",
  97. width:'80px'}]
  98. },{
  99. columnWidth: '.33',
  100. bodyStyle: 'padding:0 10px 0;',
  101. labelWidth:40,
  102. layout:'form',
  103. items: [{
  104. html:"<font color='red'><b>XY??<hr></b></font>"
  105. },{
  106. xtype: 'textfield',
  107. name: 'x',
  108. fieldLabel: 'X?',
  109. value:'<{$fld.x}>',
  110. width:'80px'},
  111. {
  112. xtype: 'textfield',
  113. name: 'y',
  114. fieldLabel: 'Y?',
  115. value:'<{$fld.y}>',
  116. width:'80px'}]
  117. },{
  118. columnWidth: '.33',
  119. bodyStyle: 'padding:0 10px 0;',
  120. labelWidth:40,
  121. layout:'form',
  122. items: [{
  123. html:"<font color='red'><b>Z??<hr></b></font>"
  124. },{
  125. xtype: 'textfield',
  126. name: 'z',
  127. fieldLabel: 'Z?',
  128. value:'<{$fld.z}>',
  129. width:'80px'},{
  130. xtype: 'hidden',
  131. name: 'id',
  132. value:'<{$fld.id}>'},{
  133. xtype: 'hidden',
  134. name: 'type',
  135. value:'<{$fld.type}>'}]
  136. }]
  137. }]
  138. }],
  139. buttons: [{
  140. text: '??',
  141. handler: function(){
  142. if(fp.getForm().isValid()){
  143. //Ext.Msg.alert('Submitted Values',fp.getForm().getValues(true).replace(/&/g,', '));
  144. myMask.show();
  145. fp.form.doAction('submit',{
  146. url:'fldcfg.php',
  147. method:'POST',
  148. params:{op:'save'},
  149. waitMsg:'????....',
  150. success:function (response){
  151. myMask.hide();
  152. parent.Ext.getCmp('<{$fld.id}>').close();
  153. Ext.MessageBox.alert('????','????');
  154. },
  155. failure:function (response){
  156. Ext.MessageBox.alert('????','????');
  157. }
  158. });
  159. }
  160. }
  161. },{
  162. text: 'Reset',
  163. handler: function(){
  164. fp.getForm().reset();
  165. }
  166. }]
  167. });
  168. });
  169. </script>
  170. </head>
  171. <body>
  172. <div id="form-ct"></div>
  173. </body>
  174. </html>