fixed chart error

used view.json.php