From 90aee34b10e90524e33b0ebb5864fd509bc22579 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Fri, 17 Feb 2012 15:50:07 +0530 Subject: [PATCH] password type issue --- js/all-app.js | 6 ++---- js/all-web.js | 3 +-- version.num | 2 +- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/js/all-app.js b/js/all-app.js index 53c25e5179..2b03e1fe18 100644 --- a/js/all-app.js +++ b/js/all-app.js @@ -575,8 +575,7 @@ this.format_input();} if(this.input.focus){try{this.input.focus();}catch(e){}}} if(this.txt){try{this.txt.focus();}catch(e){} this.txt.field_object=this;}} -function DataField(){}DataField.prototype=new Field();DataField.prototype.make_input=function(){var me=this;this.input=$a(this.input_area,'input');if(this.df.fieldtype=='Password'){$(this.input).attr('type','password');} -this.get_value=function(){var v=this.input.value;if(this.validate)v=this.validate(v);return v;} +function DataField(){}DataField.prototype=new Field();DataField.prototype.make_input=function(){var me=this;this.input=$a_input(this.input_area,this.df.fieldtype=='Password'?'password':'text');this.get_value=function(){var v=this.input.value;if(this.validate)v=this.validate(v);return v;} this.input.name=this.df.fieldname;this.input.onchange=function(){if(!me.last_value)me.last_value='';if(me.validate) me.input.value=me.validate(me.input.value);me.set(me.input.value);if(me.format_input) me.format_input();if(in_list(['Currency','Float','Int'],me.df.fieldtype)){if(flt(me.last_value)==flt(me.input.value)){me.last_value=me.input.value;return;}} @@ -1506,8 +1505,7 @@ this.format_input();} if(this.input.focus){try{this.input.focus();}catch(e){}}} if(this.txt){try{this.txt.focus();}catch(e){} this.txt.field_object=this;}} -function DataField(){}DataField.prototype=new Field();DataField.prototype.make_input=function(){var me=this;this.input=$a(this.input_area,'input');if(this.df.fieldtype=='Password'){$(this.input).attr('type','password');} -this.get_value=function(){var v=this.input.value;if(this.validate)v=this.validate(v);return v;} +function DataField(){}DataField.prototype=new Field();DataField.prototype.make_input=function(){var me=this;this.input=$a_input(this.input_area,this.df.fieldtype=='Password'?'password':'text');this.get_value=function(){var v=this.input.value;if(this.validate)v=this.validate(v);return v;} this.input.name=this.df.fieldname;this.input.onchange=function(){if(!me.last_value)me.last_value='';if(me.validate) me.input.value=me.validate(me.input.value);me.set(me.input.value);if(me.format_input) me.format_input();if(in_list(['Currency','Float','Int'],me.df.fieldtype)){if(flt(me.last_value)==flt(me.input.value)){me.last_value=me.input.value;return;}} diff --git a/js/all-web.js b/js/all-web.js index e03c3783c4..7b659fd60a 100644 --- a/js/all-web.js +++ b/js/all-web.js @@ -484,8 +484,7 @@ this.format_input();} if(this.input.focus){try{this.input.focus();}catch(e){}}} if(this.txt){try{this.txt.focus();}catch(e){} this.txt.field_object=this;}} -function DataField(){}DataField.prototype=new Field();DataField.prototype.make_input=function(){var me=this;this.input=$a(this.input_area,'input');if(this.df.fieldtype=='Password'){$(this.input).attr('type','password');} -this.get_value=function(){var v=this.input.value;if(this.validate)v=this.validate(v);return v;} +function DataField(){}DataField.prototype=new Field();DataField.prototype.make_input=function(){var me=this;this.input=$a_input(this.input_area,this.df.fieldtype=='Password'?'password':'text');this.get_value=function(){var v=this.input.value;if(this.validate)v=this.validate(v);return v;} this.input.name=this.df.fieldname;this.input.onchange=function(){if(!me.last_value)me.last_value='';if(me.validate) me.input.value=me.validate(me.input.value);me.set(me.input.value);if(me.format_input) me.format_input();if(in_list(['Currency','Float','Int'],me.df.fieldtype)){if(flt(me.last_value)==flt(me.input.value)){me.last_value=me.input.value;return;}} diff --git a/version.num b/version.num index a8114de9cf..495ae252f0 100644 --- a/version.num +++ b/version.num @@ -1 +1 @@ -462 \ No newline at end of file +464 \ No newline at end of file