forked from simonmartyr/MxPushNotifications
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[UIA-811] Update module and test project to v7.3.0 for React client s…
…upport (#115) * [UIA-811] Support for React client * [UIA-811] Support for React client * [UIA-811] Support for React client
- Loading branch information
Showing
252 changed files
with
18,948 additions
and
12,726 deletions.
There are no files selected for viewing
This file contains 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
Binary file not shown.
79 changes: 79 additions & 0 deletions
79
test/javascriptsource/datawidgets/actions/Export_To_Excel.js
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
// This file was generated by Mendix Studio Pro. | ||
// | ||
// WARNING: Only the following code will be retained when actions are regenerated: | ||
// - the import list | ||
// - the code between BEGIN USER CODE and END USER CODE | ||
// - the code between BEGIN EXTRA CODE and END EXTRA CODE | ||
// Other code you write will be lost the next time you deploy the project. | ||
import "mx-global"; | ||
import { Big } from "big.js"; | ||
import { utils, writeFileXLSX } from './xlsx-export-tools.js'; | ||
|
||
// BEGIN EXTRA CODE | ||
// END EXTRA CODE | ||
|
||
/** | ||
* @param {string} datagridName | ||
* @param {string} fileName | ||
* @param {string} sheetName | ||
* @param {boolean} includeColumnHeaders | ||
* @param {Big} chunkSize - The number of items fetched and exported per request. | ||
* @returns {Promise.<boolean>} | ||
*/ | ||
export async function Export_To_Excel(datagridName, fileName, sheetName, includeColumnHeaders, chunkSize) { | ||
// BEGIN USER CODE | ||
if (!fileName || !datagridName || !sheetName) { | ||
return false; | ||
} | ||
|
||
return new Promise((resolve, reject) => { | ||
const stream = | ||
window[window.DATAGRID_DATA_EXPORT][datagridName].create(); | ||
|
||
let worksheet; | ||
let headers; | ||
const streamOptions = { limit: chunkSize }; | ||
stream.process((msg) => { | ||
if (!msg) { | ||
return; | ||
} | ||
|
||
switch (msg.type) { | ||
case "columns": | ||
headers = msg.payload.map(column => column.name); | ||
if (includeColumnHeaders) { | ||
worksheet = utils.aoa_to_sheet([headers]); | ||
} | ||
break; | ||
case "data": | ||
if (worksheet === undefined) { | ||
worksheet = utils.aoa_to_sheet(msg.payload) | ||
} else { | ||
utils.sheet_add_aoa(worksheet, msg.payload, { origin: -1 }); | ||
} | ||
break; | ||
case "end": | ||
if (worksheet) { | ||
// Set character width for each column | ||
// https://docs.sheetjs.com/docs/csf/sheet#worksheet-object | ||
worksheet["!cols"] = headers.map(header => ({ | ||
wch: header.length + 10 | ||
})); | ||
const workbook = utils.book_new(); | ||
utils.book_append_sheet(workbook, worksheet, sheetName === "" ? "Data" : sheetName); | ||
writeFileXLSX(workbook, `${fileName}.xlsx`); | ||
resolve(true); | ||
} else { | ||
resolve(false); | ||
} | ||
break; | ||
case "aborted": | ||
resolve(false); | ||
break; | ||
} | ||
}, streamOptions); | ||
|
||
stream.start(); | ||
}); | ||
// END USER CODE | ||
} |
25 changes: 25 additions & 0 deletions
25
test/javascriptsource/datawidgets/actions/Reset_All_Filters.js
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// This file was generated by Mendix Studio Pro. | ||
// | ||
// WARNING: Only the following code will be retained when actions are regenerated: | ||
// - the import list | ||
// - the code between BEGIN USER CODE and END USER CODE | ||
// - the code between BEGIN EXTRA CODE and END EXTRA CODE | ||
// Other code you write will be lost the next time you deploy the project. | ||
import { Big } from "big.js"; | ||
import "mx-global"; | ||
|
||
// BEGIN EXTRA CODE | ||
// END EXTRA CODE | ||
|
||
/** | ||
* @param {string} targetName - Name of the widget for which filters should be reset. Valid targets are: Data grid 2, Gallery. You can find filter name in widget settings in the "Common" group (Properties>Common>Name). | ||
* @returns {Promise.<void>} | ||
*/ | ||
export async function Reset_All_Filters(targetName) { | ||
// BEGIN USER CODE | ||
const plugin = window["com.mendix.widgets.web.plugin.externalEvents"]; | ||
if (plugin) { | ||
plugin.emit(targetName, "reset.filters"); | ||
} | ||
// END USER CODE | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// This file was generated by Mendix Studio Pro. | ||
// | ||
// WARNING: Only the following code will be retained when actions are regenerated: | ||
// - the import list | ||
// - the code between BEGIN USER CODE and END USER CODE | ||
// - the code between BEGIN EXTRA CODE and END EXTRA CODE | ||
// Other code you write will be lost the next time you deploy the project. | ||
import "mx-global"; | ||
import { Big } from "big.js"; | ||
|
||
// BEGIN EXTRA CODE | ||
// END EXTRA CODE | ||
|
||
/** | ||
* @param {string} targetName - Name of the filter to reset. Valid targets are: Number filter, Date filter, Text filter, Drop-down filter. You can find filter name in widget settings in the "Common" group (Properties>Common>Name). | ||
* @returns {Promise.<void>} | ||
*/ | ||
export async function Reset_Filter(targetName) { | ||
// BEGIN USER CODE | ||
const plugin = window["com.mendix.widgets.web.plugin.externalEvents"]; | ||
if (plugin) { | ||
plugin.emit(targetName, "reset.value"); | ||
} | ||
// END USER CODE | ||
} |
3 changes: 3 additions & 0 deletions
3
test/javascriptsource/datawidgets/actions/xlsx-export-tools.js
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/CancelAllScheduledNotifications.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-push-notification": "6.1.3", | ||
"react-native-push-notification": "8.1.1", | ||
"@react-native-community/push-notification-ios": "1.10.1" | ||
} | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/CancelScheduledNotification.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-push-notification": "6.1.3", | ||
"react-native-push-notification": "8.1.1", | ||
"@react-native-community/push-notification-ios": "1.10.1" | ||
} | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/ClearAllDeliveredNotifications.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-push-notification": "6.1.3", | ||
"react-native-push-notification": "8.1.1", | ||
"@react-native-community/push-notification-ios": "1.10.1" | ||
} | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/DisplayNotification.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-push-notification": "6.1.3", | ||
"react-native-push-notification": "8.1.1", | ||
"@react-native-community/push-notification-ios": "1.10.1" | ||
} | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/GetDeviceInfo.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-localize": "1.3.4" | ||
"react-native-localize": "1.4.2" | ||
} | ||
} |
6 changes: 3 additions & 3 deletions
6
test/javascriptsource/nativemobileresources/actions/GetPushNotificationToken.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"nativeDependencies": { | ||
"@react-native-firebase/messaging": "15.7.0", | ||
"@react-native-firebase/app": "15.7.0", | ||
"@expo/config-plugins": "5.0.3" | ||
"@react-native-firebase/messaging": "17.3.0", | ||
"@react-native-firebase/app": "17.3.0", | ||
"@expo/config-plugins": "5.0.4" | ||
} | ||
} |
This file contains 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
6 changes: 3 additions & 3 deletions
6
test/javascriptsource/nativemobileresources/actions/RequestNotificationPermission.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"nativeDependencies": { | ||
"@react-native-firebase/messaging": "15.7.0", | ||
"@react-native-firebase/app": "15.7.0", | ||
"@expo/config-plugins": "5.0.3" | ||
"@react-native-firebase/messaging": "17.3.0", | ||
"@react-native-firebase/app": "17.3.0", | ||
"@expo/config-plugins": "5.0.4" | ||
} | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/ScheduleNotification.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-push-notification": "6.1.3", | ||
"react-native-push-notification": "8.1.1", | ||
"@react-native-community/push-notification-ios": "1.10.1" | ||
} | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
test/javascriptsource/nativemobileresources/actions/SetBadgeNumber.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-push-notification": "6.1.3", | ||
"react-native-push-notification": "8.1.1", | ||
"@react-native-community/push-notification-ios": "1.10.1" | ||
} | ||
} |
This file contains 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
4 changes: 2 additions & 2 deletions
4
test/javascriptsource/nativemobileresources/actions/TakePicture.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"nativeDependencies": { | ||
"react-native-image-picker": "4.0.3", | ||
"react-native-localize": "1.3.4", | ||
"react-native-image-picker": "5.0.1", | ||
"react-native-localize": "1.4.2", | ||
"react-native-permissions": "3.3.1" | ||
} | ||
} |
Oops, something went wrong.