This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function readImage (file) { | |
var reader = new FileReader(); | |
reader.addEventListener("load", function (e) { | |
$(".guide-fu-fileItemList").hide(); | |
var image = new Image(); | |
$(".photo-upload .preview .imageP").remove(); | |
$(".photo-upload .preview .text").remove(); | |
image.width = 170;image.height = 220; | |
image.className = "imageP"; | |
image.addEventListener("load", function () { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function readImage (file) { | |
var reader = new FileReader(); | |
reader.addEventListener("load", function (e) { | |
$(".guide-fu-fileItemList").hide(); | |
var image = new Image(); | |
$(".photo-upload .preview .imageP").remove(); | |
$(".photo-upload .preview .text").remove(); | |
image.width = 170;image.height = 220; | |
image.className = "imageP"; | |
image.addEventListener("load", function () { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".photo-upload").prepend(" <div class='preview'' style='border:2px solid;height:225px;width:175px;text-align:center'><br><br><div class='text'>3.5mm * 4.5mm<br>2Mb max<br>Min 600dpi</div></div><br>"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Refer to the detailed working of autocomplete widget, if you are lost with the below javascript code. | |
//addressLookup is the name of widget | |
//Creating a widget extending the textfield. | |
$.widget( "xfaWidget.addressLookup", $.xfaWidget.textField, { | |
_widgetName:"addressLookup", | |
//overriding render function of text field. | |
render : function() { | |
var $control = $.xfaWidget.defaultWidget.prototype.render.apply(this, arguments); | |
if($control){ | |
$control.autocomplete({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var classesToValidate = ["guideNumericBox"]; //add "," separated widget classes you want to validate on focus/tap out | |
this.visit(function(cmp) { | |
if(classesToValidate.indexOf(cmp.className) !== -1) { | |
$("." + cmp.name + " input").focusout(function() { | |
guideBridge.resolveNode(cmp.name).validate(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".numericbox1518941620523 input").focusout(function() { | |
guideBridge.resolveNode("numericbox1518941620523").validate(); //replace numericbox1518941620523 by the name of your text field | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var c = { | |
b : { | |
interest : function(p,r,t) { | |
return p * r * t /100; | |
} | |
} | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var interest; | |
interest = function(p,r,t) { | |
return p * r * t /100; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** JS DOC goes here*/ | |
function interest(p,r,t) { | |
return p * r * t /100; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
*Returns the simple interest | |
@name interest Simple Interest | |
@param {number} p Principal Amount | |
@param {number} r Rate Of Interest | |
@param {number} t Time of Loan (in Years) | |
@returns {number} calculated Simple Interest for the inputs | |
*/ |
NewerOlder