It depends on what you want to do with your Haunter.
Whatever you do, it will never be a top pokémon for gym attack or raids; for those you want fully-evolved pokémon for max power. You could still power it up to max but it won’t be helpful against most opponents.
You could use it in gym defence as a show-off pokémon, but people won’t notice it knows shadow ball unless they fight it—and if they do, their Tyranitar will probably crunch it before it has a chance to set off its first shadow ball. Still, if this is your intention, you would probably want to power it up to full.
As its max CP go over 1500 but not close to 2500, you can use it in Great League PvP or in Great League fights against team leaders. That requires powering up as close as possible to 1500 CP.
You can keep it for trading in case somebody else wants the legacy move. You might be able to trade it for a pokémon that has ‘more value’ for you. In that case, you might not want to power up at all as trading rerolls the IVs which might push it above the 1500 Great League viability CP limit.
Finally, you can just keep it in your pokémon list as a trophy to remind yourself of your achievement. In this case it is fully up to you how high to power it up although I personally would want top level just because.
Tl;dr: to whatever level you want it to go.