adding offer add and edit function