Commit graph

2416 commits

Author SHA1 Message Date
Ashish
9238a208ba
Fixes #4601 - 1. Handle possible exceptions in upload file from stash 2. Modify MWException, as error is nullable, update getTitle and getMessage to rever that (#4627) 2021-09-16 17:57:58 +10:00
Josephine Lim
c36aeeedc2 Change "learn more" link to new wiki 2021-09-14 18:17:06 +10:00
Madhur Gupta
55453eef67
Remove duplicate line (#4626) 2021-09-13 15:57:34 +10:00
Madhur Gupta
174b4760ab
Fix empty default lang bug (#4608)
* Fix bug #4583

* Fix empty default lang bug
2021-09-10 17:52:24 +10:00
Josephine Lim
c973114ded Add countries supported by WLM2021 template, except Italy 2021-09-01 20:12:45 +10:00
Ashish
74e8472d91
Update WLM camaign dates [Do not merge now, merge only after alpha release] (#4584)
* Updates dates for WML campaign

* Bug fix- campaign dates

* Fixed logic for WLM enablement - stick to the month of September
2021-09-01 19:59:56 +10:00
Ashish
7deaf8dbae
Fixes #4554 - only use WLM2021 template for countries that are included in it (#4574)
* Fixes #4554
1. For WLM uploads reverse geo code and see if the country code is supported -only then is the WLM upload flow triggered, otherwise usual nearby uploads happen
2. Bug Fix - Current Location marker and area

* Fixed compile error added after rebasing

* Bug fix for country code in reverse geo code
2021-09-01 19:59:00 +10:00
Madhur Gupta
b47ed0546e
Fix bug #4585 by updating kotlin and acra version (#4592) 2021-08-31 19:40:39 +10:00
Madhur Gupta
51746934fc
Fix bug #4583 (#4591) 2021-08-31 19:34:02 +10:00
Josephine Lim
12221df75e
Move WLM template below geolocation template (#4582) 2021-08-25 20:02:48 +05:30
Ashish
e666e768c2
Bug fix- current location marker (#4580) 2021-08-25 16:54:10 +10:00
Josephine Lim
e8556a8ecd Modify parameters for Nearby query 2021-08-24 21:31:18 +10:00
Ashish
678bd33410
Make Single Query for Nearby and WLM pins (#4573)
* Merge nearby and monument queries

* Bug Fix- query resource path change on shouldQueryForMonuments

* Bug Fixes
1. Propagate exceptions for nearby API calls to caller
2. Fix too much work on main thread exception in NearbyParentFragment
2021-08-24 21:25:07 +10:00
Madhur Gupta
cba99ae5e3
Fix notification bug #4547 (#4570) 2021-08-24 02:38:28 +10:00
Ashish
bb3f8f3801
Cherry-Picked NPE fix from master (#4569) 2021-08-23 19:09:52 +10:00
Ashish
6588a6fd0e
Fixes #545 - Add support for campaigns (#4423)
* Integrate WLM
- Show monuments in maps along with nearby

* BugFix in Monuments
1. Single preference for monuments and campaigns
2. Expand collapse chips container in nearby
3. Typo fix in Monuments card in Nearby
4. If a nearby place is a monument as well - do not show them separately, show it as a monument instead
5. Bug fix, monument radius, use the same one as that of nearby

* More bug fixes
1. Possible NPE in nearby
2. Added column location_address in BookmarkLocationDao
3. Bug Fix - Display Date in WLM card
4. WLM card on click takes to nearby

* Use lowercase country code in WLM uploads

* Bug-Fix, WLM Campaign Icon

* 1. Updated monuments query to use any of the following properties for monuments - [P1435, P2186, P1459, P1460, P1216, P709, P718, P5694] 2. Append WikiData QID to descriptions template

* Updated WLM Banner String, Handle NPE in contributions callback

* Added nearby-monuments query log lines

* Handle WLM Query exception : - if an exception is thrown in WLM query, continue showing the nearby items if that succeeds

* Fix BookmarkLocationDaoTest

* Added Column Address in BookmarkLocationDaoTest

* Use fallback description as usual nearby pins even for WLM pins, instead of relying on P6375

* Test fix in BookmarkLocationDao

* Updated template for WLM, removed redundant feilds

* Fixed WLM template

* Removed categories from WLM template

* Fixed BookmarkControllerTest

* Fixed BookmarkLocationFragmentUnitTest

* fix ModelFunctions

* Fixed BookmarksDaoLocationTest

* Fixed WLM template
2021-08-18 18:27:26 +10:00
Nicolas Raoul
344b220ae0 Revert "Removing setText calls which seem prevent text selection (#4520)"
This reverts commit a94a28f743.
2021-08-14 22:11:23 +09:00
neslihanturan
6dff9d674e
Remove unnecessary imports and fix type error (#4535) 2021-08-06 16:32:49 +05:30
gouri-panda
d0df2ffd59
#4005 For images in set removed if user selected one image (#4022)
* #4005 For images in set  removed if user selected one image

* #4005 changed code as suggested

* fixed syntax

* added javadoc

* added more java doc

* refactored to more meaningful documentation

* reverted the Project.xml file

* cleaned  documentations a little bit
2021-08-06 13:18:19 +03:00
benryder1988
a94a28f743
Removing setText calls which seem prevent text selection (#4520) 2021-08-06 11:43:09 +03:00
neslihanturan
a584c8f239
Add nullcheck (#4530) 2021-08-02 19:25:07 +10:00
neslihanturan
ee81877ebb
This error seemed to occur on compositeDisposable.clear() so null checked there (#4525) 2021-07-26 15:17:34 +10:00
benryder1988
2a9ae73750
Fixes #4455 - Warning when pressing "back" in upload wizard (#4519)
* Overrides the back button during upload with dialog

* Removing unneeded import
2021-07-23 20:40:41 +09:00
Ayan Sarkar
3b7aa0376d
Added option for sharing achievements and a back button in ProfileActivity (#4489)
* UI done

* Share added

* Minor modification

* tests added

* tests added

* tests added

* modified

* modifications

* modification

* Entered if

* Entered if

* 97% coverage

* Separate

* Minor modifications

* Minor modifications
2021-07-18 05:40:32 +05:30
neslihanturan
ec89a3377a
Add an else case where crash logs are null means there is no crash (#4506) 2021-07-15 01:05:04 +10:00
Madhur Gupta
8793d45f30
Remove duplicate code which was added during merge (#4504) 2021-07-14 16:19:43 +10:00
Madhur Gupta
1e0d7fb76b Fix #4482 (#4484) 2021-06-30 19:44:10 +10:00
Ayan Sarkar
51d06c1ef4
Tutorial removed from log out state (#4479)
* tutorial removed from log out state

* Issue removed
2021-06-29 18:12:30 +09:00
Ayan Sarkar
e9a2c32527
Added option to show and modify location while uploading (#4475)
* initial commit

* Everything done

* minor modification

* minor modification

* Issues fixed

* minor modifications

* issue fixed

* Issues fixed
2021-06-29 18:02:20 +09:00
Ayan Sarkar
8db381885b
Removed next button in quiz (#4382)
* issues resolved

* modification done

* warning fixed

* issues resolved

* Button added

* don't know function added

* Button added

* modification done

* modification done
2021-06-27 18:34:33 +09:00
Ashar
399d798159
Main activity title is sometimes "Contributions", sometimes "Commons" (#4472)
Fixes #4438  Replace == with equals() in onRestoreInstanceState
2021-06-23 19:15:39 +03:00
Madhur Gupta
7a74549b59
Fix #3792 Missing Column Issue (#4468)
* Fix Missing Column Issue

* Fix tests
2021-06-21 14:01:00 +10:00
Jamie Brown
ca9f6f5e47
Fixes #4437 - Changed indentation on files with 2 spaces to 4 spaces (#4462)
* Edited Project.xml to make indent size 4

* Changed files with 2 space indentation to use 4 space indentation

* Edited Project.xml to make indent size 4

* changed files with 2 space indent to 4 space indent

* fix :Back Pressed Event not work in Explore tab when user not login (#4404)

* fix :Back Pressed Event not work in Explore tab

* minor changes

* fix :Upload count or number of contribution does not get updated when media  is successful uploaded (#4399)

* * fix:Number of Contributions not updated
 * Add javadocs

* minor changes

* made minor changes

* String was nonsense and untranslatible, fixed (#4466)

* Ability to show captions and descriptions in all entered languages (#4355)

* implement Ability to show captions and descriptions in all entered languages
*Add Javadoc

* handle Back event of fragment(mediaDetailFragment)

* fix minor bugs

* add internationalization

* revert previous changes

* fix visibility bug

* resolve conflict

Co-authored-by: Prince kushwaha <65972015+Prince-kushwaha@users.noreply.github.com>
Co-authored-by: neslihanturan <tur.neslihan@gmail.com>
2021-06-21 12:33:11 +09:00
Prince kushwaha
b202f553f0
Ability to show captions and descriptions in all entered languages (#4355)
* implement Ability to show captions and descriptions in all entered languages
*Add Javadoc

* handle Back event of fragment(mediaDetailFragment)

* fix minor bugs

* add internationalization

* revert previous changes

* fix visibility bug

* resolve conflict
2021-06-18 22:30:14 +09:00
Prince kushwaha
13528bcabd
fix :Upload count or number of contribution does not get updated when media is successful uploaded (#4399)
* * fix:Number of Contributions not updated
 * Add javadocs

* minor changes

* made minor changes
2021-06-18 20:01:37 +09:00
Prince kushwaha
2a2d2879a9
fix :Back Pressed Event not work in Explore tab when user not login (#4404)
* fix :Back Pressed Event not work in Explore tab

* minor changes
2021-06-18 18:42:41 +09:00
neslihanturan
6df35e21a9
Fix doom version issue (#4463)
* Update db version

* DBOpenHelper version update
2021-06-17 23:36:36 +10:00
Pratham Pahariya
22f61195b2
fix edit categories ui (#4414)
Co-authored-by: Pratham2305 <Pratham2305@users.noreply.github.com>
2021-06-17 21:49:09 +09:00
Pratham Pahariya
3494fd05a2
fix-issue-4424 (#4445)
Co-authored-by: Pratham2305 <Pratham2305@users.noreply.github.com>
2021-06-17 21:40:32 +09:00
Jamie Brown
a3cbe3659c
Typo fixes (#4461)
* Fixed typo on class documentation of TextUtils

* corrected comma placement in documentation

* Fixed typos in comments
2021-06-17 11:53:17 +09:00
Brigham Byerly
2be828c50e
Fixes #3694 Pre-select places as depictions (#4452)
* WikidataEditService: stop automatically adding WikidataPlace as a depiction

When the user initiates the upload process from Nearby and also manually adds the place as a depiction, the depiction is added twice. Since this behavior is invisible to the user, it is being removed in preparation for auto-selecting the place as a depiction on the DepictsFragment screen.

* DepictsFragment: auto-select place as a depiction

Pass the Place reference from UploadActivity to DepictsFragment and select the corresponding DepictedItem. Using the place id, retrieve the corresponding Entity to create and select a DepictedItem.

* UploadRepository: use Place from UploadItem to obtain a DepictedItem

Instead of passing a Place object from UploadActivity to DepictsFragment and then passing the Place object up the chain to obtain and select a DepictedItem, retrieve the Place object directly within UploadRepository

* DepictsFragment: select Place depiction when fragment becomes visible

* UploadDepictsAdapter: make adapter aware of selection state

Update selection state when recycled list items are automatically selected, preventing automatically selected items from appearing as unselected until they are forced to re-bind (i.e. after scrolling)

* DepictsFragment: pre-select place depictions for all UploadItems

If several images are selected and set to different places, pre-select all place depictions to reinforce the intended upload workflow philosophy (i.e. all images in a set are intended to be from/of the same place). See discussion in commons-app/apps-android-commons#3694

* DepictsFragment: scroll to the top every time list is updated
2021-06-17 10:09:41 +09:00
Ashish
10ed6678b3
Fixes 4344 - Duplicate Uploads (#4442)
* Fixes 4344
- Update the retention policy of the Work Manager to ExistingWorkPolicy.APPEND_OR_REPLACE- which would append the new work to the end of existing one. This helps remove the while loop in UploadWorker which was meant to handle the cases where a new worker would be created for retries. The while loop seemed to have race conditions uploading duplicate entries.

* Update states to IN_PROGRESS before uploads are processed
2021-06-14 14:57:15 +03:00
neslihanturan
70851fa155
Some build issues occured merging release v3.0 are fixed. One paranthesis issue is solved, a method about UploadService is removed, since we don't use it anymore. (#4451) 2021-06-14 16:25:37 +10:00
Ayan Sarkar
20f74a90c4
Added a feature for editing coordinates (#4418)
* not

* Place Picker added

* Pick location and API call linked

* minor warnings resolved

* Code conventions followed

* issue fixed

* Wikitext edited properly

* minor modification

* Location Picker added

* Bottom sheet removed

* Location picker fully implemented

* credit added

* credit added

* issues fixed

* issues fixed

* minor issue fixed
2021-06-13 12:36:47 +09:00
Josephine Lim
ca75f616d2
Merge v3.0.1 into master (#4446)
* Versioning and changelog for v3.0.0 (#4152)

* Versioning for v3.0.0

* Update changelog.md

* Handled migration 8-9-10 in BookmarksLocationDao (#4154)

* #Fixes #4141
- Handled migrations for BookmarkLocationsDao from 8-9-10

* #Fixes #4141
- Handled migrations for BookmarkLocationsDao from 8-9-10

* Fixes #4179 (#4180)

* Handled null pointer exception in MainActivity->ContributionsFragment#backButtonClicked()
* Updated >ContributionsFragment#backButtonClicked() to handle back press properly

* Fixes #4179 (#4181)

* Handled possible null check on MediaDetails in BookmarkListRootFragment#backPressed()

* Cherrypick for hotfix3.1 (#4205)

* Fixes #4159 On Explore Tab, All Available Options on toolbar in media detail view are only targeting the first media in the list.

Fixes #4159 On Explore Tab, All Available Options on toolbar in media detail view are only targeting the first media in the list.

* fixed bug: App crashes on viewing review in Review Fragment #4132 (#4146)

* fixed bug:app crashes on viewing review in Review Fragment #4135

* Fixed the issue with back button in contribution tab. (#4177)

Co-authored-by: Pratham2305 <Pratham2305@users.noreply.github.com>

* Fixed the issue with back navigation button on toolbar in explore tab. (#4175)

* Fix (#4148) Issues on theme change

* fixed themeChange crashes

* fixed comments

* Overlooked the title bar

Co-authored-by: Pratham Pahariya <54663429+Pratham2305@users.noreply.github.com>
Co-authored-by: Shabir Ahmad <56585337+shabar-shab@users.noreply.github.com>
Co-authored-by: Pratham2305 <Pratham2305@users.noreply.github.com>
Co-authored-by: Aditya-Srivastav <54016427+4D17Y4@users.noreply.github.com>

* Fixes #4173 (#4396)

* Fix #4147  Pre-fill desc in Nearby uploads with Wikidata item's label + description (#4390)

* Update query to fetch descriptions

* Make description added to NearbyResultItem

* Make string operations to display description and label in a combined way

* Fix reviews, remove long description from list and swap label and description texts

* Fix repeated information issue

* Fix double information issue

* fix style issues

* Remove douplicated information

* Changes made (#4354)

* Remove nonexistent method

* Fix #4283 IllegalStateException (#4440)

* Fix #4283 IllegalStateException

* Fix flickering issue

* Versioning for v3.0.1

* Update changelog.md

Co-authored-by: Ashish <ashishkumar468@gmail.com>
Co-authored-by: neslihanturan <tur.neslihan@gmail.com>
Co-authored-by: Pratham Pahariya <54663429+Pratham2305@users.noreply.github.com>
Co-authored-by: Shabir Ahmad <56585337+shabar-shab@users.noreply.github.com>
Co-authored-by: Pratham2305 <Pratham2305@users.noreply.github.com>
Co-authored-by: Aditya-Srivastav <54016427+4D17Y4@users.noreply.github.com>
Co-authored-by: Madhur Gupta <30932899+madhurgupta10@users.noreply.github.com>
Co-authored-by: Vinayak Aggarwal <56196007+vinayak0505@users.noreply.github.com>
2021-06-09 20:19:24 +10:00
obsidian-zero
feb75cbb9f
Fixes #4357 After switching to different account, contributions screen shows pictures of previous account (#4421)
* Update UploadMediaDetailFragment.java

* Update LoginActivity.java

Clear CompositeDisposable after logging in successfully. It may help solve the problem of saving the contribution to the previous account

* Revert "Update UploadMediaDetailFragment.java"

This reverts commit b1b4257f20.

Co-authored-by: Obsidian_zero <1198474846@qq.com>
2021-06-07 18:52:19 +03:00
Brigham Byerly
165c375bbd
UploadMediaDetail: replace discreet error toast with more-noticeable dialog (#4433) 2021-06-04 12:34:46 +03:00
Pratham Pahariya
ca18763e4f
Fixes #2815 - Nominating for deletion is cancelled on leaving the media details (#4295)
* fix issue with nominating for deletion

* Fix UI issue

* minor improvements

* fix App crash

* Added Javadoc and other minor improvements

* Updated string name

Co-authored-by: Pratham2305 <Pratham2305@users.noreply.github.com>
2021-06-04 11:15:39 +09:00
Prince kushwaha
4fa18e5e27
In depictions selection screen, suggest recently selected items (#4361)
* implement in depictions selection screen to suggest recently selected items

*use RoomDataBase
* Add Javadoc

* fix an bug

* minar change and remove extra line of code

* minar changes

* improve implemention strategy

* fix unittest

* Add javadoc

* added javadoc
2021-05-31 19:19:55 +09:00
Ayan Sarkar
1408fe5e53
Made locale non dependent on phone OS settings, but choosable on app settings (#4366)
* setLocale added

* localization added

* test complete

* resolved conflicts

* issues resolved

* minor issues fixed

* Made methods concise

* Issues fixed
2021-05-15 23:30:03 +09:00