Closed kashifch closed 5 years ago
@kashifch re: link the only link on the receipt page currently just takes you to the dashboard. If journals integration is turned on for the LMS (see below), their will be a "My Journals" section as part of the dashboard and the purchased journal will be displayed there..
Currently Journals integration is not enabled for stage.edx.org, but is enabled for stage.mitxpro.mit.edu. We might want to run the tests against stage.mitxpro.mit.edu for now and possible enabled for stage.edx.org in the future. Not sure we want to enable it for edx stage yet as we don't have any edx.org customers of Journals yet.
For future, steps to enable journals in LMS for a site in django_admin:
journals.enable_journal_integration
set to active"JOURNALS_ENABLED":true,
"JOURNALS_FRONTEND_URL":"https://journals.stage.edx.org",
"COURSE_CATALOG_URL_BASE":"https://stage-edx-discovery.edx.org",
Thanks @bill-filler
I have configured the tests to run both on MIT and stage, in cypress we can pass a configure file which contains all vars on run time like "cypress open --env configFile=journals_mit_stage" or "cypress open --env configFile=journals_edx_stage"
I will add all this information in readme
@kashifch @ziafazal I figured out the issue with journals not showing up on dashboard. Turns out ecommerce was not configured correctly on stage and prod. There is a setting in ecommerce SiteConfiguration for "Journals Service API URL" which was not set.
See: https://stage-edx-ecommerce-internal.edx.org/admin/core/siteconfiguration/8/change/
Both stage and prod should be configured correctly now for edx and mitxpro.
This was preventing ecommerce from communicating with Journal Service to fufill the order. The user should NOT have had access to the Journal in this case as Journal Service never created an access_record. So perhaps in your test you are using a Staff user? That would explain why the user could still access their Journal even though fulfillment failed. You should be testing with a non-staff user.
Yes, Zia and myself looked into this and figured out the same issue, my user was also a staff so he could see the journal, for normal users the purchase is not happening.
Thanks for fixing it
@bill-filler @ziafazal
Here is the enrollment process, I have one question though, there is no link on receipt page to take user to journal, are we planning to add the link?
Also journal does not appear on dashboard when user clicks the dashboard link from receipt button, shouldn't there be a way for user to move to journals after payment?