-
Notifications
You must be signed in to change notification settings - Fork 6
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
Fetch notifications #20
base: main
Are you sure you want to change the base?
Conversation
On my end its showing |
It's because there are no notifications in the last 30 days. I have checked the site. You can try using _from and _to.. |
I see, as these are archived notices. So what you can do is that if there's no date is passed in argument just give all the important alerts which is showed in the pop when we open rgpv homepage + archived notice if its within one month range. If dates are passed and there are no notifications just give all the important alerts which is showed in the pop when we open rgpv homepage, here remember there can be case like i passed 01-08-2024 & 02-8-2024 there are notification between them but after these dates archived notifications are available in this case it shoud return []. In a bit i will be sharing some examples which will show how it should work. |
Archived case is fine, but it doesn't have any date info. |
Yea its cool but just add a key of date and write the value as "NOT AVAILABLE", |
Also please make sure all the notification have the links to it (even with archived notification) as without link they will be useless. |
Example 4: Argument Passed (_from: 01-09-2024, _to: 03-09-2024) |
Also add this functionality in |
Can you please share the Output of the all 5 Examples which i have given above |
Example 5: Argument Passed (_from: 01-08-2024, _to: 01-09-2024) |
What should I do with the archived notifications? As it's using js we cannot use requests. Using selenium will increase the project's complexity. |
I meant the links in the archived notifications. |
I see, let me check what be done here. |
Did you check? |
Yea I checked, so just give this link https://www.rgpv.ac.in/Uni/ImpNoticeArchive.aspx for the archived notification |
Added final modification. archive notifications page url added to the output json for the same.
The last change done. Please approve. And please let me know if there are any important features to be added more in the project. |
PLease merge this |
Hey So Sorry, I am still busy. I will review and merge it within 48 hours. |
Thank you |
I have tested the Code from my Side too and it works well. Before merging it please Move this notification code to the info_api.py file instead of result_api.py file and also modify the init.py file and at last the Alert from the rgpv homepage title also shows "Click here to View" along with the title so remove that too. |
Modified according to requirements |
|
Fix #19
I have added the notification fetching function "get_notification"
If _from and _to are given the notifications are fetched.
If only _from is given, from that date notifications are fetched
If none is given, previous 30 days notification are fetched