Skip to content

DOCINFRA-2341_merged_using_automation #460

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
let gData = [
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 2 },
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 3 },
{ 'Date': '1/5/2015 20:19:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 3 },
{ 'Date': '2/2/2015 10:22:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 4 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 6 },
{ 'Date': '2/20/2015 11:25:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 8 },
{ 'Date': '3/07/2015 05:11:50 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 4 },
{ 'Date': '3/13/2015 05:11:55 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '2/19/2018 18:51:14 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1006, 'Sold': 1 },
{ 'Date': '3/20/2018 06:31:12 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 5 },
{ 'Date': '3/06/2018 06:31:20 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '5/04/2018 21:41:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 1 },
{ 'Date': '5/11/2018 21:45:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '6/17/2018 07:09:27 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 4 },
{ 'Date': '7/1/2018 03:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '7/2/2018 05:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1007, 'Sold': 5 },
{ 'Date': '9/8/2018 11:50:17 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1008, 'Sold': 2 },
{ 'Date': '12/2/2018 16:05:33 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
];
export let Group_Data = getGroupData(gData);
function getGroupData(data) {
let date;
let products = ['', 'Bottles and Cages', 'Cleaners', 'Fenders', 'Mountain Bikes', 'Road Bikes', 'Touring Bikes', 'Gloves', 'Jerseys', 'Shorts', 'Vests'];
let amount = [0, 2, 3, 8, 60, 75, 65, 3, 5, 4, 2]
for (let ln = 0, lt = data.length; ln < lt; ln++) {
date = new Date(data[ln].Date.toString());
data[ln].Date = date.toString();
data[ln].Products = products[data[ln].Product_ID - 1000];
data[ln].Sold = data[ln].Sold * (date.getFullYear() === 2015 ? 3 : date.getFullYear() === 2016 ? 4 : date.getFullYear() === 2017 ? 2 : 5);
data[ln].Amount = ((date.getFullYear() === 2018 ? 2 : 0) + data[ln].Sold) * amount[data[ln].Product_ID - 1000];
}
return data;
}
6,389 changes: 22 additions & 6,367 deletions ej2-react/code-snippet/pivot-table/default-cs146/app/datasource.tsx

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
let gData = [
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 2 },
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 3 },
{ 'Date': '1/5/2015 20:19:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 3 },
{ 'Date': '2/2/2015 10:22:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 4 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 6 },
{ 'Date': '2/20/2015 11:25:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 8 },
{ 'Date': '3/07/2015 05:11:50 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 4 },
{ 'Date': '3/13/2015 05:11:55 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '2/19/2018 18:51:14 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1006, 'Sold': 1 },
{ 'Date': '3/20/2018 06:31:12 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 5 },
{ 'Date': '3/06/2018 06:31:20 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '5/04/2018 21:41:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 1 },
{ 'Date': '5/11/2018 21:45:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '6/17/2018 07:09:27 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 4 },
{ 'Date': '7/1/2018 03:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '7/2/2018 05:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1007, 'Sold': 5 },
{ 'Date': '9/8/2018 11:50:17 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1008, 'Sold': 2 },
{ 'Date': '12/2/2018 16:05:33 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
];
export let Group_Data = getGroupData(gData);
function getGroupData(data) {
let date;
let products = ['', 'Bottles and Cages', 'Cleaners', 'Fenders', 'Mountain Bikes', 'Road Bikes', 'Touring Bikes', 'Gloves', 'Jerseys', 'Shorts', 'Vests'];
let amount = [0, 2, 3, 8, 60, 75, 65, 3, 5, 4, 2]
for (let ln = 0, lt = data.length; ln < lt; ln++) {
date = new Date(data[ln].Date.toString());
data[ln].Date = date.toString();
data[ln].Products = products[data[ln].Product_ID - 1000];
data[ln].Sold = data[ln].Sold * (date.getFullYear() === 2015 ? 3 : date.getFullYear() === 2016 ? 4 : date.getFullYear() === 2017 ? 2 : 5);
data[ln].Amount = ((date.getFullYear() === 2018 ? 2 : 0) + data[ln].Sold) * amount[data[ln].Product_ID - 1000];
}
return data;
}
6,389 changes: 22 additions & 6,367 deletions ej2-react/code-snippet/pivot-table/default-cs147/app/datasource.tsx

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
let gData = [
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 2 },
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 3 },
{ 'Date': '1/5/2015 20:19:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 3 },
{ 'Date': '2/2/2015 10:22:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 4 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 6 },
{ 'Date': '2/20/2015 11:25:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 8 },
{ 'Date': '3/07/2015 05:11:50 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 4 },
{ 'Date': '3/13/2015 05:11:55 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '2/19/2018 18:51:14 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1006, 'Sold': 1 },
{ 'Date': '3/20/2018 06:31:12 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 5 },
{ 'Date': '3/06/2018 06:31:20 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '5/04/2018 21:41:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 1 },
{ 'Date': '5/11/2018 21:45:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '6/17/2018 07:09:27 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 4 },
{ 'Date': '7/1/2018 03:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '7/2/2018 05:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1007, 'Sold': 5 },
{ 'Date': '9/8/2018 11:50:17 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1008, 'Sold': 2 },
{ 'Date': '12/2/2018 16:05:33 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
];
export let Group_Data = getGroupData(gData);
function getGroupData(data) {
let date;
let products = ['', 'Bottles and Cages', 'Cleaners', 'Fenders', 'Mountain Bikes', 'Road Bikes', 'Touring Bikes', 'Gloves', 'Jerseys', 'Shorts', 'Vests'];
let amount = [0, 2, 3, 8, 60, 75, 65, 3, 5, 4, 2]
for (let ln = 0, lt = data.length; ln < lt; ln++) {
date = new Date(data[ln].Date.toString());
data[ln].Date = date.toString();
data[ln].Products = products[data[ln].Product_ID - 1000];
data[ln].Sold = data[ln].Sold * (date.getFullYear() === 2015 ? 3 : date.getFullYear() === 2016 ? 4 : date.getFullYear() === 2017 ? 2 : 5);
data[ln].Amount = ((date.getFullYear() === 2018 ? 2 : 0) + data[ln].Sold) * amount[data[ln].Product_ID - 1000];
}
return data;
}
6,389 changes: 22 additions & 6,367 deletions ej2-react/code-snippet/pivot-table/default-cs148/app/datasource.tsx

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
let gData = [
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 2 },
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 3 },
{ 'Date': '1/5/2015 20:19:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 3 },
{ 'Date': '2/2/2015 10:22:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 4 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 6 },
{ 'Date': '2/20/2015 11:25:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 8 },
{ 'Date': '3/07/2015 05:11:50 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 4 },
{ 'Date': '3/13/2015 05:11:55 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '2/19/2018 18:51:14 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1006, 'Sold': 1 },
{ 'Date': '3/20/2018 06:31:12 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 5 },
{ 'Date': '3/06/2018 06:31:20 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '5/04/2018 21:41:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 1 },
{ 'Date': '5/11/2018 21:45:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '6/17/2018 07:09:27 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 4 },
{ 'Date': '7/1/2018 03:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '7/2/2018 05:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1007, 'Sold': 5 },
{ 'Date': '9/8/2018 11:50:17 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1008, 'Sold': 2 },
{ 'Date': '12/2/2018 16:05:33 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
];
export let Group_Data = getGroupData(gData);
function getGroupData(data) {
let date;
let products = ['', 'Bottles and Cages', 'Cleaners', 'Fenders', 'Mountain Bikes', 'Road Bikes', 'Touring Bikes', 'Gloves', 'Jerseys', 'Shorts', 'Vests'];
let amount = [0, 2, 3, 8, 60, 75, 65, 3, 5, 4, 2]
for (let ln = 0, lt = data.length; ln < lt; ln++) {
date = new Date(data[ln].Date.toString());
data[ln].Date = date.toString();
data[ln].Products = products[data[ln].Product_ID - 1000];
data[ln].Sold = data[ln].Sold * (date.getFullYear() === 2015 ? 3 : date.getFullYear() === 2016 ? 4 : date.getFullYear() === 2017 ? 2 : 5);
data[ln].Amount = ((date.getFullYear() === 2018 ? 2 : 0) + data[ln].Sold) * amount[data[ln].Product_ID - 1000];
}
return data;
}
6,389 changes: 22 additions & 6,367 deletions ej2-react/code-snippet/pivot-table/default-cs149/app/datasource.tsx

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
let gData = [
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 2 },
{ 'Date': '1/1/2015 20:18:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 3 },
{ 'Date': '1/5/2015 20:19:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 3 },
{ 'Date': '2/2/2015 10:22:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 4 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
{ 'Date': '2/10/2015 10:23:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 6 },
{ 'Date': '2/20/2015 11:25:07 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 8 },
{ 'Date': '3/07/2015 05:11:50 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1001, 'Sold': 4 },
{ 'Date': '3/13/2015 05:11:55 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '9/1/2015 04:14:43 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '2/19/2018 18:51:14 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1006, 'Sold': 1 },
{ 'Date': '3/20/2018 06:31:12 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 5 },
{ 'Date': '3/06/2018 06:31:20 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1004, 'Sold': 1 },
{ 'Date': '5/04/2018 21:41:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 1 },
{ 'Date': '5/11/2018 21:45:15 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1010, 'Sold': 2 },
{ 'Date': '6/17/2018 07:09:27 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1003, 'Sold': 4 },
{ 'Date': '7/1/2018 03:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Bikes', 'Product_ID': 1005, 'Sold': 2 },
{ 'Date': '7/2/2018 05:47:38 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1007, 'Sold': 5 },
{ 'Date': '9/8/2018 11:50:17 GMT+0530 (India Standard Time)', 'Product_Categories': 'Clothings', 'Product_ID': 1008, 'Sold': 2 },
{ 'Date': '12/2/2018 16:05:33 GMT+0530 (India Standard Time)', 'Product_Categories': 'Accessories', 'Product_ID': 1002, 'Sold': 1 },
];
export let Group_Data = getGroupData(gData);
function getGroupData(data) {
let date;
let products = ['', 'Bottles and Cages', 'Cleaners', 'Fenders', 'Mountain Bikes', 'Road Bikes', 'Touring Bikes', 'Gloves', 'Jerseys', 'Shorts', 'Vests'];
let amount = [0, 2, 3, 8, 60, 75, 65, 3, 5, 4, 2]
for (let ln = 0, lt = data.length; ln < lt; ln++) {
date = new Date(data[ln].Date.toString());
data[ln].Date = date.toString();
data[ln].Products = products[data[ln].Product_ID - 1000];
data[ln].Sold = data[ln].Sold * (date.getFullYear() === 2015 ? 3 : date.getFullYear() === 2016 ? 4 : date.getFullYear() === 2017 ? 2 : 5);
data[ln].Amount = ((date.getFullYear() === 2018 ? 2 : 0) + data[ln].Sold) * amount[data[ln].Product_ID - 1000];
}
return data;
}
6,389 changes: 22 additions & 6,367 deletions ej2-react/code-snippet/pivot-table/default-cs150/app/datasource.tsx

Large diffs are not rendered by default.

Loading