Pman.Tab.AdminEnum.bjs
authorMicheal <micheal@roojs.com>
Thu, 29 Jan 2015 05:57:27 +0000 (13:57 +0800)
committerMicheal <micheal@roojs.com>
Thu, 29 Jan 2015 05:57:27 +0000 (13:57 +0800)
Pman.Tab.AdminEnum.js

Pman.Tab.AdminEnum.bjs
Pman.Tab.AdminEnum.js

index 8900201..b5eb0ca 100644 (file)
                                             "items" : [
                                                 {
                                                     "listeners" : {
-                                                        "|click" : "function()\n{\n    \n    Roo.MessageBox.prompt (\"Create a new Enum type\",\n        \"Enter the name for a new enum type, \" + \n        \"this is only relivant if you  know how it is going to be used\",\n        function(btn,txt) {\n            if (btn != 'ok') {\n                return; \n            }\n            new Pman.Request({\n                url : baseURL + '/Roo/Core_enum.php',\n                method : 'POST',\n                params : {\n                    etype : '',\n                    name : txt,\n                    active : 1\n                }, \n                success : function() {\n                    Roo.MessageBox.alert(\"Created\", \"You can now select it from the type list on the left\");\n                }\n            });\n                    \n            \n             \n             \n        }\n    ); \n         \n         \n\n}\n"
+                                                        "|click" : "function()\n{\n    \n    //var rec = _this.egrid.ds.getAt(rowIndex);\n    Pman.Dialog.AdminEnumType.show(null,function(){\n        \n        _this.egrid.footer.onClick('first');\n    });\n         \n         \n\n}\n"
                                                     },
                                                     "text" : "Add new pulldown list",
                                                     "xtype" : "Button",
index c146a25..2d40c3d 100644 (file)
@@ -154,31 +154,11 @@ Pman.Tab.AdminEnum = new Roo.XComponent({
                                                click : function()
                                                   {
                                                       
-                                                      Roo.MessageBox.prompt ("Create a new Enum type",
-                                                          "Enter the name for a new enum type, " + 
-                                                          "this is only relivant if you  know how it is going to be used",
-                                                          function(btn,txt) {
-                                                              if (btn != 'ok') {
-                                                                  return; 
-                                                              }
-                                                              new Pman.Request({
-                                                                  url : baseURL + '/Roo/Core_enum.php',
-                                                                  method : 'POST',
-                                                                  params : {
-                                                                      etype : '',
-                                                                      name : txt,
-                                                                      active : 1
-                                                                  }, 
-                                                                  success : function() {
-                                                                      Roo.MessageBox.alert("Created", "You can now select it from the type list on the left");
-                                                                  }
-                                                              });
-                                                                      
-                                                              
-                                                               
-                                                               
-                                                          }
-                                                      ); 
+                                                      //var rec = _this.egrid.ds.getAt(rowIndex);
+                                                      Pman.Dialog.AdminEnumType.show(null,function(){
+                                                          
+                                                          _this.egrid.footer.onClick('first');
+                                                      });