/source/gl/mb/form/combo.html

http://prosporous.googlecode.com/ · HTML · 181 lines · 178 code · 3 blank · 0 comment · 0 complexity · 5f27a871b02b17bd0c00ee533f5edaa9 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: '??',
  39. itemCls: 'x-check-group-alt',
  40. value:'<{if $fld.width==''}>50<{else}><{$fld.width}><{/if}>',
  41. width:'80px'
  42. },{
  43. xtype: 'textfield',
  44. name: 'ts',
  45. fieldLabel: '???',
  46. value:'<{if $fld.ts==''}><{$fld.name}>????!<{else}><{$fld.ts}><{/if}>',
  47. anchor: '95%'
  48. },{
  49. xtype: 'checkboxgroup',
  50. fieldLabel: '????',
  51. itemCls: 'x-check-group-alt',
  52. items: [
  53. {boxLabel: '????', name: 'yxwk',inputValue:1<{if $fld.yxwk=='1'}>,checked: true<{/if}>},
  54. {boxLabel: '????', name: 'gj',inputValue: 1<{if $fld.gj=='1'}>,checked: true<{/if}>},
  55. {boxLabel: '????', name: 'zy',inputValue: 1<{if $fld.zy=='1'}>,checked: true<{/if}>},
  56. {boxLabel: '????', name: 'xr',inputValue:1<{if $fld.xr=='1'}>,checked: true<{/if}>}
  57. ]
  58. }]
  59. },{
  60. xtype:'fieldset',
  61. title: '??????',
  62. autoHeight: true,
  63. items: [{
  64. itemCls: 'x-check-group-alt',
  65. allowBlank: false,
  66. layout:'form',
  67. items: [{
  68. xtype: 'button',
  69. text: '????',
  70. handler:function(){
  71. parent.xajax_loadUrl('',"./form/fldcfg.php?op=sj&id=<{$fld.id}>",600,330,false,'t<{$fld.id}>');
  72. }
  73. },{
  74. xtype: 'textarea',
  75. fieldLabel: 'STR[JSON]{,??,?????,???EXTJS??JSON??.}',
  76. name:'cfg[STR]',
  77. width:200,
  78. value:'<{$cfg.STR}>'
  79. }]
  80. }]
  81. },{
  82. xtype:'fieldset',
  83. title: '????',
  84. autoHeight: true,
  85. items: [{
  86. itemCls: 'x-check-group-alt',
  87. allowBlank: false,
  88. layout:'column',
  89. items: [{
  90. columnWidth: '.33',
  91. bodyStyle: 'padding:0 10px 0;',
  92. labelWidth:60,
  93. layout:'form',
  94. items: [{
  95. html:"<font color='red'><b>???<hr></b></font>"
  96. },{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'},
  97. {
  98. xtype: 'textfield',
  99. name: 'blm',
  100. fieldLabel: '???',
  101. value:"<{$fld.blm}>",
  102. width:'80px'}]
  103. },{
  104. columnWidth: '.33',
  105. bodyStyle: 'padding:0 10px 0;',
  106. labelWidth:40,
  107. layout:'form',
  108. items: [{
  109. html:"<font color='red'><b>XY??<hr></b></font>"
  110. },{
  111. xtype: 'textfield',
  112. name: 'x',
  113. fieldLabel: 'X?',
  114. value:'<{$fld.x}>',
  115. width:'80px'},
  116. {
  117. xtype: 'textfield',
  118. name: 'y',
  119. fieldLabel: 'Y?',
  120. value:'<{$fld.y}>',
  121. width:'80px'}]
  122. },{
  123. columnWidth: '.33',
  124. bodyStyle: 'padding:0 10px 0;',
  125. labelWidth:40,
  126. layout:'form',
  127. items: [{
  128. html:"<font color='red'><b>Z??<hr></b></font>"
  129. },{
  130. xtype: 'textfield',
  131. name: 'z',
  132. fieldLabel: 'Z?',
  133. value:'<{$fld.z}>',
  134. width:'80px'},{
  135. xtype: 'hidden',
  136. name: 'id',
  137. value:'<{$fld.id}>'},{
  138. xtype: 'hidden',
  139. name: 'type',
  140. value:'<{$fld.type}>'}]
  141. }]
  142. }]
  143. }],
  144. buttons: [{
  145. text: '??',
  146. handler: function(){
  147. if(fp.getForm().isValid()){
  148. //Ext.Msg.alert('Submitted Values',fp.getForm().getValues(true).replace(/&/g,', '));
  149. myMask.show();
  150. fp.form.doAction('submit',{
  151. url:'fldcfg.php',
  152. method:'POST',
  153. params:{op:'save'},
  154. waitMsg:'????....',
  155. success:function (response){
  156. myMask.hide();
  157. parent.Ext.getCmp('<{$fld.id}>').close();
  158. },
  159. failure:function (response){
  160. Ext.MessageBox.alert('????','????');
  161. }
  162. });
  163. }
  164. }
  165. },{
  166. text: 'Reset',
  167. handler: function(){
  168. fp.getForm().reset();
  169. }
  170. }]
  171. });
  172. });
  173. </script>
  174. </head>
  175. <body>
  176. <div id="form-ct"></div>
  177. </body>
  178. </html>