refined queries by case type

This commit is contained in:
2022-01-17 19:05:56 +00:00
parent 04dfa2e7ab
commit 6ae14cb04e
6 changed files with 66 additions and 1 deletions
@@ -3,6 +3,7 @@ import https from "https";
import CryptoJS from "crypto-js";
import _ from "lodash";
import { getToken, azureHeadersPaged } from "../../../actions";
import { getSelectQuery } from "../../../actions/selectQueryTypes";
const WORDKEY = process.env.HASHKEY;
@@ -31,6 +32,8 @@ export default async function ApiProxy(req, res) {
caseReference +
"'&$count=true";
queryUrl = queryUrl + getSelectQuery("pinswg_dnses");
var apiResponse = _.isEmpty(req.query)
? res.status(400).json()
: typeof caseReference != "undefined" && caseReference.length > 0