let nextStatusIds = [37, 38];
let allowed_status = ['38', '36', '37'];

// Use the filter() method to get the included IDs
let includedIds = nextStatusIds.filter(id => allowed_status.includes(id.toString()));

console.log("Included IDs:", includedIds);