apply price changing logic in front end