FourierTransform a differental-equations [duplicate]

This question already has an answer here:

I want to use the command FourierTransform to transform a differential equations from time - domain to complex frequency domain but it don't works. My code is

eq = {a'[t] == -κ/2 a[t] - I g b[t] E^(I Ω t) +
Sqrt[κ] ain ,
b'[t] == -Γ/2 b[t] - I Ω b[t] -
I g a[t] E^(- I Ω t) + Sqrt[Γ] bin}
ff = FourierTransform[eq, t, ω]

The Result is

(* {FourierTransform[
Derivative[a][t] ==
ain Sqrt[κ] - 1/2 κ a[t] -
I E^(I t Ω) g b[t], t, ω],
FourierTransform[
Derivative[b][t] ==
bin Sqrt[Γ] - I E^(-I t Ω) g a[t] -
1/2 Γ b[t] - I Ω b[t], t, ω]} *)

Then I try use Map to make it works

Clear["Global*"]
eq = {a'[t] == -κ/2 a[t] - I g b[t] E^(I Ω t) +
Sqrt[κ] ain ,
b'[t] == -Γ/2 b[t] - I Ω b[t] -
I g a[t] E^(- I Ω t) + Sqrt[Γ] bin}
ff = FourierTransform[#, t, ω] &
Map[ff, eq, {2}]

But it doesn't work, either:

(*{-I ω FourierTransform[a[t],t,ω]==FourierTransform[ain Sqrt[κ]-1/2 κ a[t]-I E^(I t Ω) g b[t],t,ω],-I ω FourierTransform[b[t],t,ω]==FourierTransform[bin Sqrt[Γ]-I E^(-I t Ω) g a[t]-1/2 Γ b[t]-I Ω b[t],t,ω]}*)

How can I make Mathematica apply FourierTransForm in every term of a differential equation

With the method of Workarounds for a possible bug in the linearity of FourierTransform I define a shell but it dosen't work well for some term.

(*Clear["Global*"]
ft[(h : List | Plus | Equal)[a__], t_, w_] := ft[#, t, w] & /@ h[a]
ft[a_ b_, t_, w_] /; FreeQ[b, t] := b ft[a, t, w]
ft[a_ E^(-I b_ t_) , t_, w_] /; FreeQ[b, t] := ft[a + b, t, w]
ft[a_, t_, w_] := FourierTransform[a, t, w]
eq = { eq = {a'[t] == -κ/2 a[t] - I g b[t] E^(I Ω t) +
Sqrt[κ] ain ,
b'[t] == -Γ/2 b[t] - I Ω b[t] -
I g a[t] E^(- I Ω t) + Sqrt[Γ] bin}}
ft[eq, t, ω]*)

Then I get a result

(*{-I ω FourierTransform[a[t],  t, ω] == -(1/2) κ FourierTransform[a[t],t,ω]+ Sqrt[κ] FourierTransform[ain[t], t, ω] - I g FourierTransform[E^(I t Ω) b[t], t, ω],                 -I ωFourierTransform[b[t], t, ω] == -I g FourierTransform[E^(-I t Ω) a[t], t,ω]- 1/2 Γ FourierTransform[b[t], t, ω] - I Ω FourierTransform[b[t], t, ω] +Sqrt[Γ] FourierTransform[bin[t], t, ω]}*)

The term "FourierTransform[ E^(-I t Ω) a[t], t, ω]" is uncalculated. It is improper to direct added a "Times" command in the first shell. And even more, I wonder how can I deal with the nonlinear conditional with a term "a[t] b[t]" ?