ountSelector) {
            const tableBody = $(tableSelector);
            tableBody.empty();

            try {
                if (history && history.length > 0) {
                    $(countSelector).text(history.length);
                    let count = 0;

                    $.each(history, function(index, position) {
                        if (position) {
                            count++;
                            // 輸出調試信息
                            console.log(`歷史記錄 ${ind