fix: 分配目标默认90天后,dropdown文案修正为'指定天数'
This commit is contained in:
@@ -271,11 +271,11 @@
|
||||
<div class="row g-2">
|
||||
<div class="col-auto">
|
||||
<select class="form-select" id="assign-assessment-days">
|
||||
<option value="">指定日期</option>
|
||||
<option value="">指定天数</option>
|
||||
<option value="15">15天后</option>
|
||||
<option value="30">30天后</option>
|
||||
<option value="60">60天后</option>
|
||||
<option value="90">90天后</option>
|
||||
<option value="90" selected>90天后</option>
|
||||
<option value="180">180天后</option>
|
||||
</select>
|
||||
</div>
|
||||
@@ -975,8 +975,13 @@ async function loadGoalOptions() {
|
||||
.map(g => `<option value="${g.id}">${escapeHtml(g.name)} [${g.level || '入门'} - ${g.category || '综合'}]</option>`)
|
||||
.join('');
|
||||
|
||||
// 设置默认开始日期为今天
|
||||
// 设置默认开始日期为今天,默认评估日期为90天后
|
||||
document.getElementById('assign-start-date').value = new Date().toISOString().split('T')[0];
|
||||
document.getElementById('assign-assessment-days').value = '90';
|
||||
// 联动设置评估日期
|
||||
const d = new Date();
|
||||
d.setDate(d.getDate() + 90);
|
||||
document.getElementById('assign-assessment-date').value = d.toISOString().split('T')[0];
|
||||
}
|
||||
|
||||
// 评估日期联动:选择天数后自动计算日期,或直接选日期
|
||||
|
||||
Reference in New Issue
Block a user