Skip to content

Commit

Permalink
Merge pull request #351 from wcmc-its/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
mrj4001 authored May 23, 2023
2 parents 9769893 + 2f9428c commit 61ba76e
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 13 deletions.
10 changes: 5 additions & 5 deletions controllers/sendNotifications.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ const nodemailer = require("nodemailer");
export async function sendNotification(req) {

let transporter = nodemailer.createTransport(({//smtpTransport({
host: 'smtp.med.cornell.edu',
port: 587,
secure: true, // true for 465, false for other ports
host: process.env.SMTP_HOST_NAME,
port: process.env.SMTP_PORT_NUMBER,
secure: true,
logger: true,
debug: true,
secureConnection: true,
auth: {
user: 'svc_deptdb',
pass: 'Lv173A201!LMtu8Bvp'
user: process.env.SMTP_USER,
pass: process.env.SMTP_PASSWORD
},
tls:{
rejectUnAuthorized:true,
Expand Down
19 changes: 12 additions & 7 deletions src/components/elements/Report/ReportsResultPane.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { infoBubblesConfig } from "../../../../config/report";
import { AuthorsComponent } from "../Common/AuthorsComponent";
import { Author } from "../../../../types/Author";
import { reportConfig } from "../../../../config/report";
import { setHelptextInfo, setReportFilterLabels } from "../../../utils/constants";
import { setHelptextInfo, setReportFilterLabels,setReportFilterDisplayRank } from "../../../utils/constants";

interface ReportsResultPaneProps {
title: string
Expand Down Expand Up @@ -47,27 +47,32 @@ export const ReportsResultPane: React.FC<ReportsResultPaneProps> = ({
{
label: setReportFilterLabels(reportingWebDisplay,"Citation count (NIH)") ,
title: setHelptextInfo(reportingWebDisplay,"Citation count (NIH)"),
value: citationCount
value: citationCount,
displayRank : setReportFilterDisplayRank(reportingWebDisplay,"Citation count (NIH)")
},
{
label: setReportFilterLabels(reportingWebDisplay,"Percentile Rank"),
title: setHelptextInfo(reportingWebDisplay,"Percentile Rank"),
value: percentileRank
value: percentileRank,
displayRank : setReportFilterDisplayRank(reportingWebDisplay,"Percentile Rank")
},
{
label: setReportFilterLabels(reportingWebDisplay,"Relative Citation Ratio (NIH)"),
title: setHelptextInfo(reportingWebDisplay,"Relative Citation Ratio (NIH)"),
value: relativeCitationRatio
value: relativeCitationRatio,
displayRank : setReportFilterDisplayRank(reportingWebDisplay,"Relative Citation Ratio (NIH)")
},
{
label: setReportFilterLabels(reportingWebDisplay,"Journal Rank"),
title: setHelptextInfo(reportingWebDisplay,"Journal Rank"),
value: journalImpactScore1
value: journalImpactScore1,
displayRank : setReportFilterDisplayRank(reportingWebDisplay,"Journal Rank")
},
{
label: setReportFilterLabels(reportingWebDisplay,"TrendingPubs score"),
title: setHelptextInfo(reportingWebDisplay,"TrendingPubs score"),
value: trendingPubsScore
value: trendingPubsScore,
displayRank : setReportFilterDisplayRank(reportingWebDisplay,"TrendingPubs score")
}
]

Expand Down Expand Up @@ -118,7 +123,7 @@ export const ReportsResultPane: React.FC<ReportsResultPaneProps> = ({
<span className={styles.midDot}>{`PMID: `}<a href={`${pubMedUrl}${pmid}`} target="_blank" rel="noreferrer">{pmid}</a>{' '}</span>
{doi && <span className={styles.midDot}>{' '}<a href={`${doiUrl}${doi}`} target="_blank" rel="noreferrer">DOI</a>{' '}</span>}
{
ADDITIONAL_INFO_CONFIGS.map(({ label, title, value}) => {
ADDITIONAL_INFO_CONFIGS.sort((a: any, b: any) => a.displayRank - b.displayRank).map(({ label, title, value}) => {
return (
<DisplayInfo
label={label}
Expand Down
2 changes: 1 addition & 1 deletion src/pages/api/auth/[...nextauth].jsx
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ const options = {
},
async session(session, token,apiResponse) {
session.data = token
//loading adminsettings after creating users specific data as it does not belogs to specific user.
//loading adminsettings after creating users specific data as it does not belongs to specific user.
// if(session || !session.adminSettings)
session.adminSettings = await fetchUpdatedAdminSettings();
return session
Expand Down

0 comments on commit 61ba76e

Please sign in to comment.