{ "name" : "Pman.Dialog.BAdminProject", "parent" : "", "title" : "", "path" : "/home/alan/gitlive/Pman.BAdmin/Pman.Dialog.BAdminProject.bjs", "permname" : "", "modOrder" : "001", "strings" : { "ce8ae9da5b7cd6c3df2929543a9af92d" : "Email", "adcd03ae20497ceeaae58901f1e67b53" : "Add / Edit Project", "ae3a26601c99fb65404a473134b81b38" : "Job No / Code", "577d7068826de925ea2aec01dbadf5e4" : "Client", "3ec365dd533ddb7ef3d1c111186ce872" : "Details", "ea4788705e6873b424c65e91c2846b19" : "Cancel", "ac848fa228f49ba2b8a5fbd76596817d" : "Team", "d9c693d3309dbee7de27e00f5ffa3993" : "Permission Group (only members of this group can view/edit)", "49ee3087348e8d44e1feda1917443987" : "Name", "bbbabdbe1b262f75d99d62880b953be1" : "Role", "245fe794333c2b0d5c513129b346b93f" : "Project Type", "c9cc8cce247e49bae79f15173ce97354" : "Save" }, "named_strings" : { "email_placeholder" : "ce8ae9da5b7cd6c3df2929543a9af92d", "name_placeholder" : "49ee3087348e8d44e1feda1917443987", "role_fieldLabel" : "245fe794333c2b0d5c513129b346b93f", "name_fieldLabel" : "ae3a26601c99fb65404a473134b81b38", "role_placeholder" : "bbbabdbe1b262f75d99d62880b953be1", "phone_fieldLabel" : "d9c693d3309dbee7de27e00f5ffa3993", "email_fieldLabel" : "577d7068826de925ea2aec01dbadf5e4" }, "items" : [ { "listeners" : { "render" : "function (_self)\n{\n _this.dialog = this;\n}" }, "String cls" : "add-user-dialog", "String size" : "xl", "string fit_content" : true, "xtype" : "Modal", "int max_width" : 650, "string max_height" : 680, "$ xns" : "Roo.bootstrap", "String title" : "Add / Edit Project", "items" : [ { "listeners" : { "render" : "function (_self)\n{\n _this.layout = _self;\n}" }, "xtype" : "Border", "$ xns" : "Roo.bootstrap.layout", "items" : [ { "xtype" : "Region", "Boolean hideTabs" : true, "$ xns" : "Roo.bootstrap.layout", "* prop" : "center" }, { "listeners" : { "render" : "function (_self)\n{\n _this.detail_tab = _self;\n}" }, "id" : "DetailPanel", "Boolean fitContainer" : true, "xtype" : "Content", "Boolean fitToFrame" : true, "$ xns" : "Roo.bootstrap.panel", "String region" : "center", "String title" : "Details", "Boolean autoScroll" : true, "Boolean background" : false, "items" : [ { "String cls" : "col-md-12", "xtype" : "Container", "$ xns" : "Roo.bootstrap", "items" : [ { "listeners" : { "actioncomplete" : "function (_self, action)\n{\n if(action.type == 'setdata'){\n \n \n _this.dialog.resize();\n \n return;\n }\n \n if (action.type == 'load') {\n \n _this.data = action.result.data;\n \n \n return;\n }\n \n if (action.type == 'submit') { // only submitted here if we are \n \n _this.dialog.hide();\n \n if (_this.callback) {\n _this.callback.call(this, action.result.data);\n }\n \n return;\n }\n}", "render" : "function (_self)\n{\n _this.form = this;\n}" }, "$ url" : "baseURL + '/Roo/core_person' ", "String cls" : "p-4", "xtype" : "Form", "style" : "margin-top: 20px;", "String labelAlign" : "top", "$ xns" : "Roo.bootstrap", "string errorMask" : true, "items" : [ { "String name" : "name", "xtype" : "Input", "string placeholder" : "Name", "String labelAlign" : "left", "string fieldLabel" : "Job No / Code", "$ xns" : "Roo.bootstrap", "Number labelWidth" : 150 }, { "String name" : "role", "xtype" : "Input", "string placeholder" : "Role", "string fieldLabel" : "Name", "String labelAlign" : "left", "$ xns" : "Roo.bootstrap", "Number labelWidth" : 150 }, { "String name" : "role", "xtype" : "Input", "string placeholder" : "Role", "string fieldLabel" : "Project Type", "String labelAlign" : "left", "$ xns" : "Roo.bootstrap", "Number labelWidth" : 150 }, { "String name" : "email", "xtype" : "Input", "string placeholder" : "Email", "String labelAlign" : "left", "string fieldLabel" : "Client", "$ xns" : "Roo.bootstrap", "Number labelWidth" : 150 }, { "String name" : "phone", "xtype" : "Input", "string fieldLabel" : "Team", "String labelAlign" : "left", "$ xns" : "Roo.bootstrap", "Number labelWidth" : 150 }, { "String name" : "phone", "xtype" : "Input", "string fieldLabel" : "Permission Group (only members of this group can view/edit)", "String labelAlign" : "top", "$ xns" : "Roo.bootstrap", "Number labelWidth" : 150 }, { "listeners" : { "render" : "function (_self)\n{\n _this.userID = _self;\n}" }, "String name" : "id", "xtype" : "Input", "String labelAlign" : "left", "String inputType" : "hidden", "$ xns" : "Roo.bootstrap" } ] } ] } ] } ] }, { "listeners" : { "click" : "function (_self, e)\n{\n _this.dialog.hide(); \n}" }, "xtype" : "Button", "$ xns" : "Roo.bootstrap", "String html" : "Cancel", "* prop" : "buttons[]" }, { "listeners" : { "click" : "function (_self, e)\n{\n if(!_this.form.isValid()){\n //Roo.bootstrap.MessageBox.alert('Error', 'Please Correct all the errors in red');\n return;\n }\n \n var myID = _this.form.findField('id').getValue() * 1;\n var myName = _this.form.findField('name').getValue();\n\n if (_this.form.findField('company_id') && !_this.form.findField('company_id').getValue()) {\n Roo.bootstrap.MessageBox.alert(\"Error\", \"Select a Company\");\n return;\n }\n \n // validate password match (only needed if we are not using generated one..\n if (_this.form.findField('passwd1') \n && _this.form.findField('passwd1').getValue().length > 0 \n && _this.form.findField('passwd1').inputEl().dom.type == \"password\") {\n \n var p1 = _this.form.findField('passwd1').getValue();\n var p2 = _this.form.findField('passwd2').getValue();\n \n \n if (Pman.Login.authUser.id < 0 && !p1.length) {\n Roo.bootstrap.MessageBox.alert(\"Error\", \"You must create a password for the admin account\");\n return;\n }\n \n \n if (p1.length || p2.length) {\n if (p1 != p2) {\n Roo.bootstrap.MessageBox.alert(\"Error\", \"Passwords do not match\");\n return;\n }\n }\n \n \n }\n \n // get the list of record with tick\n \n _this.form.doAction(\"submit\");\n \n return;\n\n}" }, "String weight" : "primary", "xtype" : "Button", "$ xns" : "Roo.bootstrap", "String html" : "Save", "* prop" : "buttons[]" } ] } ] }