Commit Graph

76 Commits

Author SHA1 Message Date
Kyrylo Kireiev
53174178f3 feat: [FC-0047] Extend mobile API with course progress and primary courses on dashboard view (#34848)
* feat: [AXM-24] Update structure for course enrollments API (#2515)
---------
Co-authored-by: Glib Glugovskiy <glib.glugovskiy@raccoongang.com>

* feat: [AXM-53] add assertions for primary course (#2522)
---------
Co-authored-by: monteri <36768631+monteri@users.noreply.github.com>

* feat: [AXM-297] Add progress to assignments in BlocksInfoInCourseView API (#2546)
---------
Co-authored-by: NiedielnitsevIvan <81557788+NiedielnitsevIvan@users.noreply.github.com>
Co-authored-by: Glib Glugovskiy <glib.glugovskiy@raccoongang.com>
Co-authored-by: monteri <36768631+monteri@users.noreply.github.com>
2024-07-10 20:07:41 +05:00
Glib Glugovskiy
3da85a994e fix: remove trailing whitespace failing quality check 2023-11-20 23:08:56 +02:00
Glib Glugovskiy
95fcb124dd docs: add docstring for the paginator property override 2023-11-20 22:40:28 +02:00
KyryloKireiev
ee4b92ca10 feat: [AXIM-6] Add DefaultPagination for UserCourseEnrollmentsList v3 2023-11-20 22:40:28 +02:00
Moeez Zahid
7ae64a5eb4 refactor: Add logging to mobile_api app (#33064) 2023-08-23 16:20:20 +05:00
Pooja Kulkarni
c452fb3204 refactor: rename descriptor -> block within lms/djangoapps/mobile_api
Co-authored-by: Agrendalath <piotr@surowiec.it>
2023-04-26 17:10:54 +02:00
0x29a
fd191db332 refactor: rename module (or item) -> block within remaining lms
Also, removed `_iter_scorable_xmodules` method from `lms/djangoapps/grades/transformer.py` file.
2023-01-30 18:15:23 +01:00
0x29a
9d8375ff99 refactor: rename module -> block within lms/djangoapps/courseware
Also, removed unused `_has_access_xmodule` methid from `lms/djangoapps/courseware/access.py`.
2023-01-30 18:15:22 +01:00
0x29a
83396ffb07 refactor: convert course_module term to course_block 2022-12-19 17:48:49 +01:00
jawad khan
4f74d8a16a feat: added mobile configs in enrollments api (#31036)
* feat: added mobile configs in enrollments api

Mobile team needs some cnfigs after user has logged in, enrollment api seems to be the best place
to put this data. They can change these flags or values from admin side.
LEARNER-9039
2022-09-26 14:27:23 +05:00
Jawayria
0d63afe840 chore: Applied lint-amnesty on lms/djangoapps (#29394) 2021-12-21 13:36:39 +05:00
jawad khan
ad2f92767b fix: fixed atmoic block error in course_status_info
* fix: fixed atmoic block error in course_status_info

We are getting "An error occurred in the current transaction. You cant execute queries until the end of the atomic block."
error in get course status info on both versions i.e. 0.5 and 1. I was unable to reproduce it locally. But by looking
in django documentation and some other online helps I concluded that it might be because of some db intefrity error
that we didnt handle properly and now the cursor is broken for this transaction. Therefore i am making it non atomic
transaction. Since its a get request we can make transactions run independentantly.

LEARNER-8267
2021-06-17 07:26:11 +05:00
usamasadiq
dc36d0bfe8 Ran pyupgrade on lms/djangoapps
Ran pyupgrade on lms/djangoapps/mailing
Ran pyupgrade on lms/djangoapps/mobile_api
Ran pyupgrade on lms/djangoapps/monitoring
2021-02-19 17:47:37 +05:00
Awais Qureshi
07599e930c BOM-2284
Apply pylint-amnesty.
2021-02-02 11:37:56 +05:00
Kyle McCormick
151bd13666 Use full names for common.djangoapps imports; warn when using old style (#25477)
* Generate common/djangoapps import shims for LMS
* Generate common/djangoapps import shims for Studio
* Stop appending project root to sys.path
* Stop appending common/djangoapps to sys.path
* Import from common.djangoapps.course_action_state instead of course_action_state
* Import from common.djangoapps.course_modes instead of course_modes
* Import from common.djangoapps.database_fixups instead of database_fixups
* Import from common.djangoapps.edxmako instead of edxmako
* Import from common.djangoapps.entitlements instead of entitlements
* Import from common.djangoapps.pipline_mako instead of pipeline_mako
* Import from common.djangoapps.static_replace instead of static_replace
* Import from common.djangoapps.student instead of student
* Import from common.djangoapps.terrain instead of terrain
* Import from common.djangoapps.third_party_auth instead of third_party_auth
* Import from common.djangoapps.track instead of track
* Import from common.djangoapps.util instead of util
* Import from common.djangoapps.xblock_django instead of xblock_django
* Add empty common/djangoapps/__init__.py to fix pytest collection
* Fix pylint formatting violations
* Exclude import_shims/ directory tree from linting
2020-11-10 07:02:01 -05:00
jawad khan
04640bde1e Get last visited block id as user staus with version v1 (#25498)
Get last visited block id as user staus with version v1
VAN-85
2020-11-06 21:57:03 +05:00
Kyle McCormick
d1a775d3cd Use full names for lms.djangoapps imports (#25401)
* Use full LMS imports paths in LMS settings and urls modules
* Use full LMS import paths in Studio settings and urls modules
* Import from lms.djangoapps.badges instead of badges
* Import from lms.djangoapps.branding instead of branding
* Import from lms.djangoapps.bulk_email instead of bulk_email
* Import from lms.djangoapps.bulk_enroll instead of bulk_enroll
* Import from lms.djangoapps.ccx instead of ccx
* Import from lms.djangoapps.course_api instead of course_api
* Import from lms.djangoapps.course_blocks instead of course_blocks
* Import from lms.djangoapps.course_wiki instead of course_wiki
* Import from lms.djangoapps.courseware instead of courseware
* Import from lms.djangoapps.dashboard instead of dashboard
* Import from lms.djangoapps.discussion import discussion
* Import from lms.djangoapps.email_marketing instead of email_marketing
* Import from lms.djangoapps.experiments instead of experiments
* Import from lms.djangoapps.gating instead of gating
* Import from lms.djangoapps.grades instead of grades
* Import from lms.djangoapps.instructor_analytics instead of instructor_analytics
* Import form lms.djangoapps.lms_xblock instead of lms_xblock
* Import from lms.djangoapps.lti_provider instead of lti_provider
* Import from lms.djangoapps.mobile_api instead of mobile_api
* Import from lms.djangoapps.rss_proxy instead of rss_proxy
* Import from lms.djangoapps.static_template_view instead of static_template_view
* Import from lms.djangoapps.survey instead of survey
* Import from lms.djangoapps.verify_student instead of verify_student
* Stop suppressing EdxPlatformDeprecatedImportWarnings
2020-11-04 08:48:33 -05:00
Aarif
98af9ce418 remove useless-supression warnings 2020-05-01 19:42:15 +05:00
Feanil Patel
6e3fe00fff Fix all E303 pep8 errors. 2019-12-30 12:25:38 -05:00
Feanil Patel
9cf2f9f298 Run 2to3 -f future . -w
This will remove imports from __future__ that are no longer needed.

https://docs.python.org/3.5/library/2to3.html#2to3fixer-future
2019-12-30 10:35:30 -05:00
Samuel Walladge
c0b908e02d send user_logged_in signal from my_user_info
A user's last logged in value previously wasn't updated when the user
logs in through the oauth2 flow from the ios mobile app. Here we must
send the user_logged_in signal manually. It's implemented in the
my_user_info mobile rest api endpoint because adding it to where the
oauth2 flow happens is to complex, and the mobile app hits this endpoint
after a successful login anyway.
2019-12-27 09:37:22 +10:30
Ned Batchelder
efba6e45e8 Finally import courseware properly everywhere to get rid of a warning 2019-09-26 09:40:15 -04:00
usama sadiq
79d02a1b67 Python3 Update
Added absolute_import
Changed unicode() with six.text_type()
2019-07-11 19:27:15 +05:00
Amit
15dc31ba6d INCR-456: Make compatible with Python 3.x (#21018) 2019-07-10 10:14:43 -04:00
Matthew Piatetsky
5ef9cf3d49 remove experiment code 2019-04-17 09:30:47 -04:00
Calen Pennington
b295472363 Use generator expressions to make Mobile API constraints clearer 2018-11-21 12:18:10 -05:00
Calen Pennington
0cb48dfe1c Add StackedConfigurationModels for managing content_type_gating and course_duration_limits 2018-11-21 12:18:10 -05:00
Bill Filler
026d574576 mobile-api changes to support gated-content
Change behavior of existing v0.5 mobile api /api/mobile/v0.5/users/{username}/course_enrollments/ to exclude expired courses due to audit duration limits from the result set.
Add v1 version of mobile api /api/mobile/v1/users/{username}/course_enrollments/ that returns all enrollments and includes a field audiit_access_expires that contains expiration date (or null).

REV-495
2018-11-01 10:13:52 -04:00
Matthew Piatetsky
f738e74e7e prevent activation time error 2018-09-19 17:06:15 -04:00
Matthew Piatetsky
e756d002cf update mobile exclusion 2018-08-14 14:07:56 -04:00
Matthew Piatetsky
cfa4dc6945 add course level mobile app exclusion for vop and cgv3 experiments 2018-08-07 17:19:55 -04:00
Matthew Piatetsky
7673ea06b1 Hide experiment courses from dashboard if enrolled but not paid 2018-04-06 10:14:29 -04:00
Andy Armstrong
79acb5c5be Reorder LMS imports using isort 2017-06-11 21:48:06 -04:00
Qubad786
c28d7cd5f9 Add utm parameters to course sharing url 2017-04-24 23:01:21 +05:00
Andy Armstrong
da1ac4664e Implement common redirect logic for all course tabs
LEARNER-76
2017-04-12 16:05:32 -04:00
christopher lee
b5e987ba61 MA-3091: Added mobile_available flag override admin setting 2017-01-23 15:04:40 -05:00
Rene Sorel
1b985a5ce0 fix quality issues and broken order of execution 2016-09-28 15:24:39 +02:00
Rene Sorel
66b32318ff recommitting mobile api org filter 2016-09-28 14:34:31 +02:00
Jesse Zoldak
9c88404304 Revert "mobile api user course enrollments allow filter by org" 2016-09-27 15:33:09 -04:00
Rene Sorel
408bc223e5 requested changes for quality and performance 2016-09-20 11:55:10 +02:00
Rene Sorel
87c3547d41 mobile api user course enrollments allow filter by org 2016-07-26 09:09:09 +02:00
Nimisha Asthagiri
c6954902e3 Create courseware/views folder 2016-05-03 09:02:45 -04:00
Nimisha Asthagiri
2f581448da Refactor Courseware Index
MA-2189
2016-05-03 09:02:44 -04:00
Nimisha Asthagiri
c088df0835 Remove unused Mobile latest_updates field 2016-02-18 12:12:05 -05:00
Nimisha Asthagiri
330120bb7a MA-1712: Update Mobile API to include course_about 2015-11-25 13:48:45 -05:00
wajeeha-khalid
90fe71dbfe MA-1248 - CourseEnrollmentAPI: added discussion URL 2015-10-09 19:04:55 +05:00
Brian Beggs
619768f741 removed course_enrollment hint from UserDetail mobile api view. TNL-3452 2015-10-01 13:50:58 -04:00
Ned Batchelder
8ec2de9359 DRF 3.1 now uses request.data instead of request.DATA 2015-09-29 15:25:55 -04:00
Will Daly
8555630df7 Upgrade djangorestframework to v3.1
* Upgrade edx-submissions
* Upgrade edx-ora2
* Upgrade edx-val
* Upgrade edx-proctoring
* Update all edx-platform code that depends on DRF, including:
  - auth_exchange
  - cors_csrf
  - embargo
  - enrollment
  - util
  - commerce
  - course_structure
  - discussion_api
  - mobile_api
  - notifier_api
  - teams
  - credit
  - profile_images
  - user_api
  - lib/api (OAuth2 and pagination)
2015-09-25 12:40:57 -04:00
Sylvia Pearce
eea3b31105 Delete white spaces that are causing test failures 2015-07-17 16:12:53 +00:00