Skip to content

[New] Add items to portal #586

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

Open
wants to merge 14 commits into
base: v.next
Choose a base branch
from
Open

[New] Add items to portal #586

wants to merge 14 commits into from

Conversation

yo1995
Copy link
Collaborator

@yo1995 yo1995 commented May 2, 2025

Description

This PR implements Add items to portal in Cloud and Portal category.
URL to README

Linked Issue(s)

  • swift/issues/6820
  • swift/issues/6785

How To Test

You have to use the latest daily to test the add item feature, as there is a fix in 6785.

  1. Cancel OAuth login, and the sample will be in a content unavailable state
  2. Login with OAuth to your account
  3. Browse the portal items
  4. Tap add button to add an image type portal item
  5. If tap add button again, it will show an error alert
  6. Swipe to delete the portal item. It will show a separate alert for confirmation

Screenshots

image

To Discuss

The sample design was dated and only Qt has implemented it. Therefore, I made some enhancements comparing to the Qt implementation while trying to keep consistent with the design to showcase the addItem and deleteItem endpoints.

@yo1995 yo1995 self-assigned this May 2, 2025
@yo1995 yo1995 requested review from a team, mhdostal and pgruenler and removed request for a team May 2, 2025 17:11
@yo1995 yo1995 marked this pull request as draft May 7, 2025 22:09
@yo1995 yo1995 marked this pull request as ready for review May 8, 2025 23:01
@yo1995 yo1995 requested review from a team, dfeinzimer and des12437 and removed request for mhdostal, pgruenler and a team May 8, 2025 23:02
@yo1995
Copy link
Collaborator Author

yo1995 commented May 8, 2025

@mhdostal @pgruenler I've reset the reviewers… no need to review if you haven't started yet, but feel free to add comments if you have already done some.

}
}
.task {
try? await item.thumbnail?.load()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I never seem to get the thumbnail. Looks like this throws the following error. Expected?

ArcGIS.IllegalStateError(details: "Loadable image doesn't have a URI.")

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let me ask around to see if this is a known issue…

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haven't heard an confirmative response yet… will request review again once I hear back.

Copy link
Contributor

@des12437 des12437 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested out the sample and cannot add a portal item due to a service error: invalid file content type detected.

Nevermind, the add button is working now using latest daily build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants