Fix js for marking orders