Translate all Chinese comments and strings to English
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -317,7 +317,7 @@ const convertSecToDay = (sec) => {
|
||||
* @param {number} no - The trace number.
|
||||
*/
|
||||
const openMore = async (no) => {
|
||||
// async await 解決非同步資料延遲傳遞導致未讀取到而出錯的問題
|
||||
// Use async/await to prevent errors caused by asynchronous data not being available yet
|
||||
issuesNo.value = no;
|
||||
await conformanceStore.getConformanceIssue(no);
|
||||
traceId.value = await issueTraces.value[0].id;
|
||||
@@ -330,7 +330,7 @@ const openMore = async (no) => {
|
||||
* @param {number} no - The trace number.
|
||||
*/
|
||||
const openLoopMore = async (no) => {
|
||||
// async await 解決非同步資料延遲傳遞導致未讀取到而出錯的問題
|
||||
// Use async/await to prevent errors caused by asynchronous data not being available yet
|
||||
loopNo.value = no;
|
||||
await conformanceStore.getConformanceLoop(no);
|
||||
looptraceId.value = await loopTraces.value[0].id;
|
||||
@@ -428,9 +428,9 @@ const setConformanceTempReportData = (newData) => {
|
||||
result.timeTrend.yMin = newData.charts.time.y_axis.min;
|
||||
}
|
||||
|
||||
setRateChartData(result.charts.rate.data); // 建立圖表 Rate Chart.js
|
||||
setCasesChartData(result.charts.cases.data.conforming, result.charts.cases.data.not_conforming, newData.charts.cases.x_axis.max, newData.charts.cases.x_axis.min); // 建立圖表 Cases Chart.js
|
||||
if(newData.charts.time) setTimeChartData(result.timeTrend.chart, result.timeTrend.xMax, result.timeTrend.xMin, result.timeTrend.yMax, result.timeTrend.yMin); // 建立圖表 Time Chart.js
|
||||
setRateChartData(result.charts.rate.data); // Build the Rate Chart.js chart
|
||||
setCasesChartData(result.charts.cases.data.conforming, result.charts.cases.data.not_conforming, newData.charts.cases.x_axis.max, newData.charts.cases.x_axis.min); // Build the Cases Chart.js chart
|
||||
if(newData.charts.time) setTimeChartData(result.timeTrend.chart, result.timeTrend.xMax, result.timeTrend.xMin, result.timeTrend.yMax, result.timeTrend.yMin); // Build the Time Chart.js chart
|
||||
return result;
|
||||
};
|
||||
|
||||
@@ -446,8 +446,8 @@ const setRateChartData = (chartData) => {
|
||||
label: 'Rate',
|
||||
data: chartData,
|
||||
fill: false,
|
||||
pointRadius: 0, // 隱藏點
|
||||
pointHoverRadius: 0, // 隱藏點的 hover
|
||||
pointRadius: 0, // Hide data points
|
||||
pointHoverRadius: 0, // Hide data points on hover
|
||||
tension: 0.4,
|
||||
borderColor: '#0099FF',
|
||||
x: 'x',
|
||||
@@ -467,9 +467,9 @@ const setRateChartData = (chartData) => {
|
||||
}
|
||||
},
|
||||
plugins: {
|
||||
legend: false, // 圖例
|
||||
legend: false, // Hide legend
|
||||
tooltip: {
|
||||
enabled: false // 隱藏 工具提示框
|
||||
enabled: false // Hide tooltip
|
||||
}
|
||||
},
|
||||
scales: {
|
||||
@@ -479,17 +479,17 @@ const setRateChartData = (chartData) => {
|
||||
display: false,
|
||||
},
|
||||
grid: {
|
||||
display: false, // 隱藏 x 軸網格
|
||||
display: false, // Hide x-axis grid lines
|
||||
},
|
||||
border: {
|
||||
color: '#334155',
|
||||
},
|
||||
},
|
||||
y: {
|
||||
beginAtZero: true, // scale 包含 0
|
||||
beginAtZero: true, // Scale includes 0
|
||||
suggestedMin: 0,
|
||||
suggestedMax: 1,
|
||||
ticks:{ // 設定間隔數值
|
||||
ticks:{ // Set tick intervals
|
||||
includeBounds: true,
|
||||
color: '#334155',
|
||||
align: 'inner',
|
||||
@@ -500,7 +500,7 @@ const setRateChartData = (chartData) => {
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
display: false, // 隱藏 y 軸網格
|
||||
display: false, // Hide y-axis grid lines
|
||||
},
|
||||
border: {
|
||||
color: '#334155',
|
||||
@@ -550,7 +550,7 @@ const setCasesChartData = (conformingData, notConformingData, xMax, xMin) => {
|
||||
mode: 'index',
|
||||
intersect: false
|
||||
},
|
||||
legend: false, // 圖例
|
||||
legend: false, // Hide legend
|
||||
},
|
||||
scales: {
|
||||
x: {
|
||||
@@ -559,7 +559,7 @@ const setCasesChartData = (conformingData, notConformingData, xMax, xMin) => {
|
||||
display: false,
|
||||
},
|
||||
grid: {
|
||||
display: false, // 隱藏 x 軸網格
|
||||
display: false, // Hide x-axis grid lines
|
||||
},
|
||||
border: {
|
||||
color: '#334155',
|
||||
@@ -567,7 +567,7 @@ const setCasesChartData = (conformingData, notConformingData, xMax, xMin) => {
|
||||
},
|
||||
y: {
|
||||
stacked: true,
|
||||
beginAtZero: true, // scale 包含 0
|
||||
beginAtZero: true, // Scale includes 0
|
||||
ticks:{
|
||||
color: '#334155',
|
||||
align: 'inner',
|
||||
@@ -578,7 +578,7 @@ const setCasesChartData = (conformingData, notConformingData, xMax, xMin) => {
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
// display: false, // 隱藏 y 軸網格
|
||||
// display: false, // Hide y-axis grid lines
|
||||
color: function(context) {
|
||||
return context.tick.value === 0 ? '#334155' : null;
|
||||
},
|
||||
@@ -647,18 +647,18 @@ const setTimeChartData = (chartData, xMax, xMin, yMax, yMin) => {
|
||||
}
|
||||
},
|
||||
plugins: {
|
||||
legend: false, // 圖例
|
||||
legend: false, // Hide legend
|
||||
tooltip: false,
|
||||
},
|
||||
scales: {
|
||||
x: {
|
||||
ticks: {
|
||||
maxRotation: 0, // 不旋轉 lable 0~50
|
||||
maxRotation: 0, // Do not rotate labels (0~50)
|
||||
color: '#334155',
|
||||
display: true,
|
||||
},
|
||||
grid: {
|
||||
display: false, // 隱藏 x 軸網格
|
||||
display: false, // Hide x-axis grid lines
|
||||
},
|
||||
title: {
|
||||
display: true,
|
||||
@@ -667,18 +667,18 @@ const setTimeChartData = (chartData, xMax, xMin, yMax, yMin) => {
|
||||
},
|
||||
},
|
||||
y: {
|
||||
beginAtZero: true, // scale 包含 0
|
||||
beginAtZero: true, // Scale includes 0
|
||||
max: max,
|
||||
ticks: { // 設定間隔數值
|
||||
display: false, // 隱藏數值,只顯示格線
|
||||
ticks: { // Set tick intervals
|
||||
display: false, // Hide values, only show grid lines
|
||||
stepSize: max / 4,
|
||||
},
|
||||
grid: {
|
||||
color: 'rgba(100,116,139)',
|
||||
drawTicks: false // 隱藏左側多的空間
|
||||
drawTicks: false // Hide extra space on the left
|
||||
},
|
||||
border: {
|
||||
display: false, // 隱藏左側多出來的線
|
||||
display: false, // Hide the extra border line on the left
|
||||
},
|
||||
title: {
|
||||
display: true,
|
||||
@@ -705,7 +705,7 @@ watch(conformanceTempReportData, (newValue) => {
|
||||
emitter.on('coverPlate', boolean => {
|
||||
isCoverPlate.value = boolean;
|
||||
});
|
||||
// 取得 selectTimeTange 給 Tiem Trend 使用
|
||||
// Get selectTimeRange for use by Time Trend
|
||||
emitter.on('timeRangeMaxMin', newData => selectDurationTime.value = newData);
|
||||
</script>
|
||||
<style scoped>
|
||||
|
||||
Reference in New Issue
Block a user