refactor phase 3a api-endpoint chunk 5a targeted actions imports
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
import axios from "axios";
|
||||
import CryptoJS from "crypto-js";
|
||||
import { azureHeaders, consoleLogger, getToken } from "../../../actions";
|
||||
import { azureHeaders } from "../../../actions/core/headers";
|
||||
import { consoleLogger } from "../../../actions/core/logger";
|
||||
import { getToken } from "../../../actions/core/token";
|
||||
|
||||
const WORDKEY = process.env.HASHKEY;
|
||||
|
||||
@@ -11,7 +13,7 @@ const WEBAPI_URL =
|
||||
const hashAPIPath = (queryPath) => {
|
||||
var hashlink = CryptoJS.HmacSHA256(
|
||||
queryPath,
|
||||
CryptoJS.enc.Hex.parse(WORDKEY),
|
||||
CryptoJS.enc.Hex.parse(WORDKEY)
|
||||
);
|
||||
hashlink = hashlink.toString(CryptoJS.enc.Hex);
|
||||
|
||||
@@ -70,7 +72,7 @@ export default function ApiProx(req, res) {
|
||||
"pinswg_mediaLinkEN":
|
||||
"https://www.youtube.com/watch?v=H7S6CfF_7PI",
|
||||
"pinswg_mediaLinkCY":
|
||||
"https://www.youtube.com/watch?v=H7S6CfF_7PI",
|
||||
"https://www.youtube.com/watch?v=H7S6CfF_7PI"
|
||||
},
|
||||
{
|
||||
"pinswg_publishtoweb@OData.Community.Display.V1.FormattedValue":
|
||||
@@ -93,7 +95,7 @@ export default function ApiProx(req, res) {
|
||||
"pinswg_mediaLinkEN":
|
||||
"https://www.youtube.com/watch?v=OhxeLV_jPyE",
|
||||
"pinswg_mediaLinkCY":
|
||||
"https://www.youtube.com/watch?v=OhxeLV_jPyE",
|
||||
"https://www.youtube.com/watch?v=OhxeLV_jPyE"
|
||||
},
|
||||
{
|
||||
"pinswg_publishtoweb@OData.Community.Display.V1.FormattedValue":
|
||||
@@ -117,7 +119,7 @@ export default function ApiProx(req, res) {
|
||||
"pinswg_mediaLinkEN":
|
||||
"https://www.youtube.com/watch?v=9nsmadjgW94",
|
||||
"pinswg_mediaLinkCY":
|
||||
"https://www.youtube.com/watch?v=9nsmadjgW94",
|
||||
"https://www.youtube.com/watch?v=9nsmadjgW94"
|
||||
},
|
||||
{
|
||||
"pinswg_publishtoweb@OData.Community.Display.V1.FormattedValue":
|
||||
@@ -141,9 +143,9 @@ export default function ApiProx(req, res) {
|
||||
"pinswg_mediaLinkEN":
|
||||
"https://www.youtube.com/watch?v=tRW3tm2Mby8",
|
||||
"pinswg_mediaLinkCY":
|
||||
"https://www.youtube.com/watch?v=tRW3tm2Mby8",
|
||||
},
|
||||
],
|
||||
"https://www.youtube.com/watch?v=tRW3tm2Mby8"
|
||||
}
|
||||
]
|
||||
};
|
||||
return res.status(200).json(data);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user