How to affectionately call someone who is always moaning/whinging?
I imagine the Yiddish kvetch is sometimes used affectionately. And here's some other possibilities I can picture being said with appropriate warmth:
bellyacher
codger
crab
crankypants
croaker
curmudgeon
sorehead
squawker
I think the gentlest term I could think up of, was "bear":
You have been a bear all morning! Let's be happy now.
How about "Moaner"? As in:
Come, come, don't be a moaner!
There's also "whiner", or "groucho", or "grumpy" which is very gentle:
Let's not be grumpy shall we?
Scots would use the term stropper or stroppy:
My, you're being a wee bit stroppy this morning!