What is happening with you is unfortunate but from whatever you have written, it can be deduced that your employer had developed a strong distaste for you. While you have written the effect, but your post falls short of mentioning the causes of it.
What about your performance? Is it Average or Good or Very Good or Excellent? Did you have any clash with anyone? Did you rub any senior authority in a wrong way? There must be some reason.
Employees can be assigned any work as deemed fit by the employers. Most of the companies mention a clause on this in the appointment letter. Check your appointment what it says. Secondly, the change of department is one of the usual tactics of the employers to force the employee to submit resignation.
2nd June 2019 From India, Bangalore
It gives an impression that your employer did not find suitable during the probation for which they did not confirm your service.
The service of notice period is as per the terms of offer letter issued to you. You can fight if there is no clause of serving notice period in your offer letter.
3rd June 2019 From India, Mumbai