This commit is contained in:
2022-01-12 20:04:34 +00:00
parent 62a4d1c4ae
commit 7dbc5a68a5

View File

@@ -138,6 +138,7 @@ function ayRegisterHelpers() {
// Turn a utc date into a displayable // Turn a utc date into a displayable
// short date and time // short date and time
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString
//(PRIVATE NOT DOCUMENTED, FOR HELPER USE)
// //
function utcDateToShortDateAndTimeLocalized(ayValue) { function utcDateToShortDateAndTimeLocalized(ayValue) {
if (!ayValue) { if (!ayValue) {
@@ -165,7 +166,7 @@ function utcDateToShortDateAndTimeLocalized(ayValue) {
/////////////////////////////////////////// ///////////////////////////////////////////
// Turn a utc date into a displayable // Turn a utc date into a displayable
// short date // short date
// //(PRIVATE NOT DOCUMENTED, FOR HELPER USE)
function utcDateToShortDateLocalized(ayValue) { function utcDateToShortDateLocalized(ayValue) {
if (!ayValue) { if (!ayValue) {
return ""; return "";
@@ -190,7 +191,7 @@ function utcDateToShortDateLocalized(ayValue) {
/////////////////////////////////////////// ///////////////////////////////////////////
// Turn a utc date into a displayable // Turn a utc date into a displayable
// short time // short time
// //(PRIVATE NOT DOCUMENTED, FOR HELPER USE)
function utcDateToShortTimeLocalized(ayValue) { function utcDateToShortTimeLocalized(ayValue) {
if (!ayValue) { if (!ayValue) {
return ""; return "";
@@ -216,7 +217,7 @@ function utcDateToShortTimeLocalized(ayValue) {
/////////////////////////////////////////// ///////////////////////////////////////////
// CURRENCY LOCALIZATION // CURRENCY LOCALIZATION
// //(PRIVATE NOT DOCUMENTED, FOR HELPER USE)
// //
function currencyLocalized(ayValue) { function currencyLocalized(ayValue) {
if (!ayValue) { if (!ayValue) {
@@ -233,7 +234,7 @@ function currencyLocalized(ayValue) {
/////////////////////////////////////////// ///////////////////////////////////////////
// DECIMAL LOCALIZATION // DECIMAL LOCALIZATION
// //(PRIVATE NOT DOCUMENTED, FOR HELPER USE)
// //
function decimalLocalized(ayValue) { function decimalLocalized(ayValue) {
if (!ayValue) { if (!ayValue) {
@@ -329,7 +330,7 @@ async function ayPostToAPI(route, data, token) {
///////////////////////////// /////////////////////////////
// attachment download URL // attachment download URL
// // (PRIVATE NOT DOCUMENTED FOR HELPER USE)
function attachmentDownloadUrl(fileId, ctype) { function attachmentDownloadUrl(fileId, ctype) {
//http://localhost:7575/api/v8/attachment/download/100?t=sssss //http://localhost:7575/api/v8/attachment/download/100?t=sssss
//Ctype is optional and is the MIME content type, used to detect image urls at client for drag and drop ops //Ctype is optional and is the MIME content type, used to detect image urls at client for drag and drop ops
@@ -378,10 +379,10 @@ function ayGroupByKey(reportDataArray, groupByKeyName) {
return ret; return ret;
} }
//Utils // //Utils
function ayPad(n, width, z) { // function ayPad(n, width, z) {
z = z || "0"; // z = z || "0";
n = n + ""; // n = n + "";
return n.length >= width ? n : new Array(width - n.length + 1).join(z) + n; // return n.length >= width ? n : new Array(width - n.length + 1).join(z) + n;
} // }