openfoodfacts / power-user-script

User script for your browser, to empower Open Food Facts contribution
GNU Affero General Public License v3.0
12 stars 5 forks source link

List mode seems to be broken #76

Closed teolemon closed 1 year ago

teolemon commented 1 year ago

What

List mode seems to be broken

[22:59](https://openfoodfacts.slack.com/archives/CDC9K6RFT/p1672437596559249)
benbenben
 How to move Open Beauty Facts products into Open Beauty Facts? (I am moderator)
(shift + L seems to not be an option anymore: https://wiki.openfoodfacts.org/Open_Beauty_Facts)
CharlesNepote commented 1 year ago

Power User Script is working well in fact. The "-> OBF" button is just a link: api call-> https://world.openfoodfacts.org/cgi/product_jqm.pl?type=edit&code=0842379199042&new_code=obf

But when a product already exists in OBF, the move fails (and many products you will want to move already exist). When a product do exists, the answer from Product Opener is: { status: 0, status_verbose: "new code is invalid" } but I'm not sure that this means the product already exist or that there are other kinds of issues.

I can change the "Failed!" message by "Existing product. Can't move!" if I'm sure about it.

teolemon commented 9 months ago

I had an obsolete version of the User Script.