Page MenuHomePhabricator

Extract value for edit link from entity data (getter)
Closed, ResolvedPublic

Description

After we’ve downloaded the entity data (T227185), we need to extract the corresponding string value(s?) for a certain edit link from it.

This could be implemented as a getter on a store that contains the entity data (T227186).

Patch-For-Review:

Details

Related Gerrit Patches:
mediawiki/extensions/Wikibase : masterbridge: add getter for main value to edit
mediawiki/extensions/Wikibase : masterbridge: add getter for entity’s main statement for property
mediawiki/extensions/Wikibase : masterbridge: extract getterTypes as constants
mediawiki/extensions/Wikibase : masterbridge: add statements to EntityState in entity store

Event Timeline

Note: we’ll likely show the Vue component using this getter very early, before we have a response from Wikidata. So it also has to handle the case that entity data is not yet present, as well as the case that there was an error in this case.

Rough sketch:

<ContainerComponent>
  <StatusComponent>Loading spinner / error message / empty on success</StatusComponent>
  <RealComponent>String value / empty on error/loading</RealComponent>
</ContainerComponent>
Pablo-WMDE renamed this task from Extract value for edit link from entity data to Extract value for edit link from entity data (getter).Jul 3 2019, 11:57 AM

I think I effectively ended up doing this with my Vuex experiments, so claiming the task. The patches are already on Gerrit, but I’ll amend their commit messages to attach them to this task.

Change 523764 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/Wikibase@master] bridge: add statements to EntityState in entity store

https://gerrit.wikimedia.org/r/523764

Change 523765 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/Wikibase@master] bridge: extract getterTypes as constants

https://gerrit.wikimedia.org/r/523765

Change 523766 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/Wikibase@master] bridge: add getter for entity’s main statement for property

https://gerrit.wikimedia.org/r/523766

Change 523767 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[mediawiki/extensions/Wikibase@master] bridge: add getter for main value to edit

https://gerrit.wikimedia.org/r/523767

Change 523764 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] bridge: add statements to EntityState in entity store

https://gerrit.wikimedia.org/r/523764

Change 523765 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] bridge: extract getterTypes as constants

https://gerrit.wikimedia.org/r/523765

Change 523766 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] bridge: add getter for entity’s main statement for property

https://gerrit.wikimedia.org/r/523766

Change 523767 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] bridge: add getter for main value to edit

https://gerrit.wikimedia.org/r/523767

Michael closed this task as Resolved.Jul 23 2019, 9:16 AM