Hello, welcome to the forums...
Was it a tail amputation? Not that it matters really what the surgery was. How old is your Dragon?
Is he active now, moving around normally? The fact that he's willing to eat greens and mealworms, just not the crickets, probably means he's bored with crickets. They do go through phases of not eating certain insects.
Did you start feeding him the mealworms before the surgery, or did you just start offering him the mealworms when he stopped eating the crickets? If that's the case, then what has happened is you fed him junkfood (the mealworms) and now that's all he wants, the junkfood. That's very common. I will tell you that you should not be feeding him mealworms on a daily basis, I don't know how old your Dragon is, but if he's under a year old and still eating a lot of live insects every day, feeding him mealworms that often is going to result in bowel problems, along with Fatty Liver Disease. Bearded Dragons bodies are not able to properly digest the hard, chitlin shells that mealworms have, and in addition to the shells causing bowel impactions and obstructions, they contain very little protein and are loaded with fat. So mealworms are basically nothing but fat and hard shell that they cannot digest, and you need to find an appropriate, healthy staple insect to feed him.
As I already said, sometimes when a dragon gets bored with their healthy, staple insects, like crickets, roaches, BSFL, etc. people will immediately start feeding them mealworms, wax worms, or superworms, which are basically junk food and should not be fed as a daily feeder. So what happens is when the owner then tries to feed them the healthy staple feeder again, the dragon goes "Hell with those crickets, I want the junkfood!" I suspect that's what is going on with your dragon.
The only way to remedy this is to completely stop feeding him the mealworms, you cannot keep giving them to him or he'll never get switched back over. So get rid of the mealworms, and just keep giving him his fresh salad every day, and keep offering him the live crickets every day. As long as he's not getting filled-up on the mealworms anymore, eventually he'll start eating the crickets again. That's the first thing you can do, and the easiest.
The second thing you can do is order or buy (if you have a store near you that sells different feeder insects) another healthy, appropriate staple insect, like Dubia Roaches or Phoenix Worms/BSFL. your best bet is always ordering your live insects in bulk online anyway, you can order 1,000 large BSFL/Phoenix Worms for like $24 shipped, and you can get the same amount of Dubia Roaches for much less than that, if you order from
http://www.dubiaroaches.com They have both, and I think they have crickets too, all sizes of all healthy feeders, and dirt cheap. Usually they absolutely love Dubia Roaches or BSFL. So again, completely stop the mealworms and offer him the roaches or the BSFL.
Either way, as long as you completely stop the mealworms and just keep offering him a nice, fresh salad and the crickets, roaches, or BSFL, as long as he's no longer getting the mealworms, he'll eventually get hungry and start eating the healthy bugs.
It's up to you to be strong here, you absolutely cannot give-in and feed him the mealworms when he refuses the crickets, I promise you that he won't starve himself, he may refuse them for a few days or so, but eventually he'll start eating them again. But ONLY if you completely stop the mealworms and he realizes that he's not going to get any more junk food!
The good news is that since he's been eating the mealworms and the greens, that means that he's not still feeling badly from the surgery, he's just gotten spoiled by the junkfood you've been feeding him and he's decided that he'd rather have the mealworms instead of the healthy crickets, you just have to put your foot down...Also, if you could buy some different types of fresh, healthy greens and veggies to mix into his salad, that will also help to get him more interested in eating more salad. Try adding different fresh greens, like Collard Greens, Mustard Greens, Turnip Greens, Dandelion Greens, Escarole, Endive, Bok Choy, Arugula/Rocket, or Swiss Chard. And adding some different veggies and finding out which ones he really likes will also help, such as any type of Squash, like Butternut Squash, Acorn Squash, Spaghetti Squash, Yellow Squash, etc., along with all colors of Bell Pepper, like Red, Green, Orange, or Yellow (NO hot peppers, only the Bell Peppers), along with fresh Green Beans, fresh Peas in the Pod, and a little Broccoli or Carrot.