Help : ( Gradient Material isnt relative to mesh

Hi, Im new to the material system and after watching a tutorial I followed, created a gradient. My problem is that the gradient moves and isnt tied to the object.


Code below