Pman.Dialog.AdminWatch.bjs
[Pman.Admin] / old / Pman.Tab.AdminPermMembers.bjs
index 7d0d8eb..dcba1e3 100644 (file)
@@ -36,7 +36,7 @@
      "items" : [
       {
        "listeners" : {
-        "update" : "function (_self, record, operation)\n{\n    if (operation != 'commit') {\n        return;\n    }\n    // only used to change active status.\n    \n    new Pman.Request({\n        url : baseURL + '/Roo/Person.php',\n        method :'POST',\n        params : {\n            id : record.data.id,\n            active: record.data.active\n            \n        },\n        success : function() {\n            // do nothing\n            \n            _this.grid.ds.remove(record);\n            \n        },\n        failure : function() \n        {\n            Roo.MessageBox.alert(\"Error\", \"saving failed\", function() {\n                _this.grid.footer.onClick('first');\n            });\n        }\n    });\n}",
+        "update" : "function (_self, record, operation)\n{\n    if (operation != 'commit') {\n        return;\n    }\n    // only used to change active status.\n    \n    new Pman.Request({\n        url : baseURL + '/Roo/core_person',\n        method :'POST',\n        params : {\n            id : record.data.id,\n            active: record.data.active\n            \n        },\n        success : function() {\n            // do nothing\n            \n            _this.grid.ds.remove(record);\n            \n        },\n        failure : function() \n        {\n            Roo.MessageBox.alert(\"Error\", \"saving failed\", function() {\n                _this.grid.footer.onClick('first');\n            });\n        }\n    });\n}",
         "beforeload" : "function (_self, o)\n{\n  \n   // technically we may allow non-owner's to be in the group..\n   // need to work out how that will work...\n   // \n   \n    //o.params['company_id_comptype'] = 'OWNER';\n    o.params['query[search]'] = _this.searchBox.getValue();\n    \n    if (!_this.activeButton) {return; false;}\n    \n    \n    o.params.active = _this.activeButton.pressed ? 0 : 1;\n    if (!Pman.Tab.AdminPermManager) { \n        return false;\n    }\n    \n    \n    if (Pman.Tab.AdminPermManager && Pman.Tab.AdminPermManager.grid) {\n        var tms = Pman.Tab.AdminPermManager.grid.getSelectionModel().getSelected();\n        \n        if (!tms) {\n            return false;\n        }\n        o.params['query[in_group]'] = tms.data.id;\n        o.params['query[type]'] = 0; // group type..\n        \n    }\n    //o.params['query[name]'] = _this.searchBox.getValue();\n  \n    \n}"
        },
        "xtype" : "Store",
@@ -46,7 +46,7 @@
        "* prop" : "dataSource",
        "items" : [
         {
-         "$ url" : "baseURL + '/Roo/Person.php'",
+         "$ url" : "baseURL + '/Roo/core_person'",
          "xtype" : "HttpProxy",
          "method" : "GET",
          "$ xns" : "Roo.data",