Thailand is a country run by a military junta posing as a democracy (but which dissolves straight back into a dictatorship at the slightest sign of political unrest), with provinces that are mostly Muslim, wherein there is a desire for separation from the military state.
Not entirely dissimilar from the Philippines... in which some islands and regions are almost wholly Muslim, and which seek autonomy from the current government. The difference is, the Philippines pays more than lip service to democracy, and some of the regions seeking autonomy have been granted just that.
We've also had communist rebels (both Thailand and the Philippines), who have, on occassion, formed alliances with islamic insurgents against our governments... all supported by China... in its bid to extend its influence over Southeast Asia... which is why I find conspiracy theories (in the other thread) regarding Muslim involvement in the Tianjin explosion ludicrous. (And note, China's insurgency problem is more ethnic, than anything else).
It's hard to know what purpose this attack was meant to serve, at this point. No one has claimed responsibility yet.