jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/367029 )
Change subject: Add wbcheckconstraints example for constraintid parameter ...................................................................... Add wbcheckconstraints example for constraintid parameter Now that constraints have been migrated to statements, constraint IDs are statement IDs and therefore sufficiently stable for an example. (Previously, they were random GUIDs chosen anew on each constraint template import.) The constraint chosen is the “item requires claim: country” constraint on Wikidata’s population property, which is violated on Q2 (Earth). Change-Id: I87b01aed3e76f544063223032e36e7fc47c104bf --- M api/CheckConstraints.php M i18n/en.json M i18n/qqq.json 3 files changed, 5 insertions(+), 2 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/api/CheckConstraints.php b/api/CheckConstraints.php index 6715bba..49f7f57 100644 --- a/api/CheckConstraints.php +++ b/api/CheckConstraints.php @@ -409,8 +409,9 @@ 'action=wbcheckconstraints&id=Q5|Q42' => 'apihelp-wbcheckconstraints-example-1', 'action=wbcheckconstraints&claimid=q42%248419C20C-8EF8-4EC0-80D6-AF1CA55E7557' - => 'apihelp-wbcheckconstraints-example-2' - // TODO add more examples, at least one for the constraintid parameter + => 'apihelp-wbcheckconstraints-example-2', + 'action=wbcheckconstraints&format=json&id=Q2&constraintid=P1082%24DA39C2DA-47DA-48FB-8A9A-DA80200FB2DB' + => 'apihelp-wbcheckconstraints-example-3', ]; } diff --git a/i18n/en.json b/i18n/en.json index 7801d81..40cece6 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -52,6 +52,7 @@ "apihelp-wbcheckconstraints-example-1": "Check all constraints on the items Q5 and Q42.", "apihelp-wbcheckconstraints-example-2": "Check all constraints on a single statement.", + "apihelp-wbcheckconstraints-example-3": "Check one particular constraint on the item Q2.", "apihelp-wbcheckconstraintparameters-example-propertyid-1": "Check constraint parameters of all constraints on a property.", "apihelp-wbcheckconstraintparameters-example-constraintid-2": "Check constraint parameters of two particular constraints.", diff --git a/i18n/qqq.json b/i18n/qqq.json index e126c80..09454e6 100644 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -51,6 +51,7 @@ "apihelp-wbcheckconstraintparameters-param-constraintid": "{{doc-apihelp-param|wbcheckconstraintparameters|constraintid}}", "apihelp-wbcheckconstraints-example-1": "{{doc-apihelp-example|wbcheckconstraints}}", "apihelp-wbcheckconstraints-example-2": "{{doc-apihelp-example|wbcheckconstraints}}", + "apihelp-wbcheckconstraints-example-3": "{{doc-apihelp-example|wbcheckconstraints}}", "apihelp-wbcheckconstraintparameters-example-propertyid-1": "{{doc-apihelp-example|wbcheckconstraintparameters}}", "apihelp-wbcheckconstraintparameters-example-constraintid-2": "{{doc-apihelp-example|wbcheckconstraintparameters}}", "wbq-subextension-name-wbqc": "Name of this subextension. Is shown in special page that lists all the violations.\n{{Identical|Constraint}}", -- To view, visit https://gerrit.wikimedia.org/r/367029 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I87b01aed3e76f544063223032e36e7fc47c104bf Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/WikibaseQualityConstraints Gerrit-Branch: master Gerrit-Owner: Lucas Werkmeister (WMDE) <lucas.werkmeis...@wikimedia.de> Gerrit-Reviewer: Aude <aude.w...@gmail.com> Gerrit-Reviewer: Jonas Kress (WMDE) <jonas.kr...@wikimedia.de> Gerrit-Reviewer: Siebrand <siebr...@kitano.nl> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits