Skip to content
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

mark elephpants as prototypes #174

Open
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

JonPurvis
Copy link
Contributor

@JonPurvis JonPurvis commented Jul 29, 2023

Fixes #126

Following on from a discussion started by @asgrim in #126, this PR adds the ability to be able to mark Elephpants as "prototypes", which will then prevent them from being able to be added to collections and offered up for trade. This will mark the following as Prototypes:

  • Golden elePHPant
  • HaPHPy
  • PHPlashy

Prototype Elephpants will only show on the following pages:

Prototype Elephpants will be excluded from:

Lastly, I've added an extra migration to remove any Prototype Elephpants from collections.

@teiling88
Copy link
Collaborator

I think the Vegas Elephpant didn't reached the kickstarter goal, or?

Will test your PR at the end of the week when everything works out.

@JonPurvis
Copy link
Contributor Author

Yeah pretty much, it was done on Indiegogo which is pretty much the same thing. It only reached 27% of the target so the prototype is the only one that exists 😄

https://www.indiegogo.com/projects/phplashy-the-official-php-vegas-elephpant#/

However, on the statistics page, it's apparently in 2 herds:

image

I'll tidy up this branch this evening and resolve any conflicts, ready for review later this week.

Thanks

@cookieguru
Copy link
Contributor

However, on the statistics page, it's apparently in 2 herds

This one is real

@JonPurvis
Copy link
Contributor Author

Such a shame it didn't get the funding it needed 😢

@JonPurvis
Copy link
Contributor Author

Hey @teiling88 👋

I've resolved the conflicts on this branch so it's ready whenever you are for a test :)

@JonPurvis
Copy link
Contributor Author

Hey @teiling88 👋

Activity on this repo seems to have dried up a little, so I'd like to kickstart it!

Have you got some time to give this PR a road test? The Kickstarter page for the Sylius Elephpant is launching soon and that's what made me remember about this PR!

Thanks

@JonPurvis
Copy link
Contributor Author

@teiling88

I just realised this branch had a merge conflict, I've sorted this now.

@JonPurvis JonPurvis force-pushed the mark-elephpants-as-prototypes branch from 70ec0f5 to 9cbcebb Compare January 30, 2024 20:08
@JonPurvis
Copy link
Contributor Author

Pushed an update which removes the Prototype flag from the Sylius Elephpant as it reached its funding goal yesterday so it can go into production.

@cookieguru
Copy link
Contributor

Might be a bit premature since manufacturing hasn't even started

@JonPurvis JonPurvis force-pushed the mark-elephpants-as-prototypes branch from a75934e to 9cbcebb Compare February 4, 2024 22:57
@JonPurvis
Copy link
Contributor Author

Yeah I've reverted that commit, I guess the excitement of a new Elephpant got the better of me 😆

@cookieguru
Copy link
Contributor

The original batch of one of the Symonfy elePHPants (I don't remember which one) was shipped from the factory to France. French customs didn't like them and disposed of them the way they do with anything else they don't want to let in the country: the incinerator.

@JonPurvis
Copy link
Contributor Author

Poor Elephpants! I didn't know that happened! Thanks for the info!

@JonPurvis
Copy link
Contributor Author

Hey @teiling88 👋

I'd quite like to re-visit this PR. Would you be able to have a look over it please?

@JonPurvis
Copy link
Contributor Author

Thanks @cookieguru - I forgot that Elephpant was supposedly coming, I haven't seen any info about it aside from the initial picture on Twitter

*/
public function up()
{
DB::statement('DELETE FROM elephpant_user WHERE elephpant_id IN (52,53,55,62,77)');
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
DB::statement('DELETE FROM elephpant_user WHERE elephpant_id IN (52,53,55,62,77)');
DB::statement("
DELETE
FROM elephpant_user eu
LEFT JOIN users u ON eu.user_id = u.id
WHERE elephpant_id IN (52,53,55,62,77)
AND u.twitter != 'OGProgrammer';
");

@OGProgrammer is active on the site and owns the prototype for 62. His herd doesn't list any other prototypes so I've kept the query simple: delete prototypes from all collections except his

@@ -12,6 +12,9 @@
</div>
<div class="container">
@include('partials._search')
<p class="mb-4">
ElePHPants marked as <strong>Prototype Only</strong> are for reference and cannot be added to your herd or traded with other users as they were never mass produced.
Copy link
Contributor

Choose a reason for hiding this comment

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

This disclaimer is less important than the search results so I think it should come after the results. Also, there is no need to show this text when there are no results, so this could go between the @endforeach and @else

@cookieguru
Copy link
Contributor

Thanks @cookieguru - I forgot that Elephpant was supposedly coming, I haven't seen any info about it aside from the initial picture on Twitter

https://phpc.social/@OndrejMirtes/113231986093230892

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.

Sylius elePHPant is not actually done yet
3 participants