Pman.Dialog.VerifyAccess.bjs
[Pman.Core] / Pman.Dialog.VerifyAccess.js
index a9e8d96..ef4056a 100644 (file)
@@ -101,7 +101,8 @@ Roo.apply(Pman.Dialog.VerifyAccess.prototype, {
             if(!_this.form.isValid()){
                 return;
             }
-            
+            Roo.log('submit');
+            return;
             _this.dialog.el.mask('Sending...');
             _this.form.doAction('submit');
             
@@ -228,7 +229,13 @@ Roo.apply(Pman.Dialog.VerifyAccess.prototype, {
             listeners : {
              select : function (combo, record, index)
               {
+                  _this.expire_dt.allowBlank = true;
+                  _this.expire_dt.el.hide();
                   
+                  if(record.data.code == '-2'){
+                      _this.expire_dt.allowBlank = false;
+                      _this.expire_dt.el.show();
+                  }
               }
             },
             xns : Roo.bootstrap,
@@ -264,6 +271,11 @@ Roo.apply(Pman.Dialog.VerifyAccess.prototype, {
               {
                   _this.expire_dt = this;
                   
+                  var d = new Date();
+                  d.setDate(d.getDate() - 1);
+              
+                  this.setStartDate(d);
+                  
                   this.el.setVisibilityMode(Roo.Element.DISPLAY);
                   
                   this.el.hide();