Update templates/ltxvideo.html
Browse files- templates/ltxvideo.html +5 -4
templates/ltxvideo.html
CHANGED
|
@@ -1190,12 +1190,13 @@
|
|
| 1190 |
const statusRes = await fetch(`/api/status/${proj.id}`);
|
| 1191 |
const statusData = await statusRes.json();
|
| 1192 |
|
| 1193 |
-
// افزایش مجازی پیشرفت
|
| 1194 |
let currentProgress = proj.progress || 10;
|
| 1195 |
-
if (currentProgress <
|
| 1196 |
-
|
|
|
|
| 1197 |
}
|
| 1198 |
-
proj.progress = Math.min(currentProgress, 98);
|
| 1199 |
|
| 1200 |
if (statusData.status === 'ready') {
|
| 1201 |
proj.status = 'completed';
|
|
|
|
| 1190 |
const statusRes = await fetch(`/api/status/${proj.id}`);
|
| 1191 |
const statusData = await statusRes.json();
|
| 1192 |
|
| 1193 |
+
// افزایش مجازی پیشرفت (طراحی شده برای رسیدن به ۹۸٪ در حدود ۳ دقیقه و توقف در آنجا)
|
| 1194 |
let currentProgress = proj.progress || 10;
|
| 1195 |
+
if (currentProgress < 98) {
|
| 1196 |
+
// افزایش ملایم حدود ۲ درصد در هر نوبت بررسی (هر ۴ ثانیه) جهت توزیع در بازه ۱۸۰ ثانیهای
|
| 1197 |
+
currentProgress += (Math.random() * 1.0) + 1.5;
|
| 1198 |
}
|
| 1199 |
+
proj.progress = Math.min(Math.round(currentProgress), 98);
|
| 1200 |
|
| 1201 |
if (statusData.status === 'ready') {
|
| 1202 |
proj.status = 'completed';
|