/source/gl/mb/form/colorpickerfield.html

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