mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-06-17 10:27:34 +00:00
add locales and more clearly defined profiling duration
This commit is contained in:
parent
4d7db53f28
commit
ca06c5f68f
@ -404,5 +404,7 @@ const msg = {
|
||||
customDuration: "Custom Duration",
|
||||
maxDuration: "Max Duration",
|
||||
minutes: "Minutes",
|
||||
invalidProfilingDurationRange: "Please enter a valid duration between 1 and 900 seconds",
|
||||
taskCreatedSuccessfully: "Task created successfully",
|
||||
};
|
||||
export default msg;
|
||||
|
@ -404,5 +404,7 @@ const msg = {
|
||||
customDuration: "Duración Personalizada",
|
||||
maxDuration: "Duración Máxima",
|
||||
minutes: "Minutos",
|
||||
invalidProfilingDurationRange: "Por favor ingrese una duración válida entre 1 y 900 segundos",
|
||||
taskCreatedSuccessfully: "Tarea creada exitosamente",
|
||||
};
|
||||
export default msg;
|
||||
|
@ -402,5 +402,7 @@ const msg = {
|
||||
customDuration: "自定义时长",
|
||||
maxDuration: "最大时长",
|
||||
minutes: "分钟",
|
||||
invalidProfilingDurationRange: "请输入1到900秒之间的有效时长",
|
||||
taskCreatedSuccessfully: "任务创建成功",
|
||||
};
|
||||
export default msg;
|
||||
|
@ -156,12 +156,12 @@ limitations under the License. -->
|
||||
|
||||
if (duration.value === DurationOptions[5].value) {
|
||||
if (!customDurationSeconds.value || customDurationSeconds.value < 1 || customDurationSeconds.value > 900) {
|
||||
ElMessage.error("Please enter a valid duration between 1 and 900 seconds");
|
||||
ElMessage.error(t("invalidProfilingDurationRange"));
|
||||
return;
|
||||
}
|
||||
finalDuration = customDurationSeconds.value;
|
||||
} else {
|
||||
finalDuration = Number(duration.value) * 60;
|
||||
finalDuration = Number(duration.value);
|
||||
}
|
||||
|
||||
const params = {
|
||||
@ -184,7 +184,7 @@ limitations under the License. -->
|
||||
return;
|
||||
}
|
||||
emits("close");
|
||||
ElMessage.success("Task created successfully");
|
||||
ElMessage.success(t("taskCreatedSuccessfully"));
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
@ -16,11 +16,11 @@
|
||||
*/
|
||||
|
||||
export const DurationOptions = [
|
||||
{ value: "0.5", label: "30 sec" },
|
||||
{ value: "1", label: "1 min" },
|
||||
{ value: "5", label: "5 min" },
|
||||
{ value: "10", label: "10 min" },
|
||||
{ value: "15", label: "15 min" },
|
||||
{ value: "30", label: "30 sec" },
|
||||
{ value: "60", label: "1 min" },
|
||||
{ value: "300", label: "5 min" },
|
||||
{ value: "600", label: "10 min" },
|
||||
{ value: "900", label: "15 min" },
|
||||
{ value: "custom", label: "Custom" },
|
||||
];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user