Created
November 3, 2016 13:43
-
-
Save harsaharsa/202b3cd92c31163a34a0de4b8fbb4a03 to your computer and use it in GitHub Desktop.
Scan barcode and open new window with default values
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
corodva.plugins.barcodeScanner.scan(function(result) { | |
if (result.cancelled != null) { | |
return; | |
} else { | |
var prefills = { | |
scanned_code: result | |
} | |
supersonic.module.layers.push("data.ConsultantRequest.new", { | |
"default-values": JSON.stringify(prefills) | |
}); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment