瀏覽代碼

Merge branch 'develop3.0-tmd' into develop3.0

CrazyIter 4 年之前
父節點
當前提交
8a241309b9
共有 1 個文件被更改,包括 16 次插入5 次删除
  1. 16 5
      TEAMModelOS/ClientApp/src/view/schoolmgmt/SystemSetting/SystemSetting.vue

+ 16 - 5
TEAMModelOS/ClientApp/src/view/schoolmgmt/SystemSetting/SystemSetting.vue

@@ -80,7 +80,7 @@
                                                 <span class="time-inner-dot" :style="{backgroundColor: timeLineColor(index).color}"></span>
                                                 <span class="time-line-tail"></span>
                                             </span>
-                                            <div v-show="timeLineColor(index).color != '#606060'">
+                                            <div v-show="timeLineColor(index).showArrow">
                                                 <Icon class="first-arrow" size="20" :style="{color: timeLineColor(index).color}" type="ios-arrow-back" />
                                                 <Icon class="second-arrow" size="20" :style="{color: timeLineColor(index).color}" type="ios-arrow-back" />
                                             </div>
@@ -239,28 +239,39 @@
                         }
                     }
                 }
+                let curMonth = this.schoolSetting.period[this.curPriodIndex].semesters[this.curSemIndex].month
+                let nextMonth = -1
+                if (this.curSemIndex == len - 1) {
+                    nextMonth = this.schoolSetting.period[this.curPriodIndex].semesters[0].month
+                } else {
+                    nextMonth = this.schoolSetting.period[this.curPriodIndex].semesters[this.curSemIndex + 1].month
+                }
                 if (curIndex != -1) {
                     return {
                         color: this.colorList[curIndex],
-                        text: this.schoolSetting.period[this.curPriodIndex].semesters[curIndex].name
+                        text: this.schoolSetting.period[this.curPriodIndex].semesters[curIndex].name,
+                        showArrow: (index + 1) == curMonth || (index + 2) == nextMonth
                     }
                 } else if (this.curSemIndex == len - 1) {
                     if (this.schoolSetting.period[this.curPriodIndex].semesters[0].month > (index + 1) || this.schoolSetting.period[this.curPriodIndex].semesters[this.curSemIndex].month <= (index + 1)) {
                         curIndex = this.curSemIndex
                         return {
                             color: this.colorList[curIndex],
-                            text: this.schoolSetting.period[this.curPriodIndex].semesters[curIndex].name
+                            text: this.schoolSetting.period[this.curPriodIndex].semesters[curIndex].name,
+                            showArrow: (index + 1) == curMonth || (index + 2) == nextMonth
                         }
                     } else {
                         return {
                             color: '#606060',
-                            text: ''
+                            text: '',
+                            showArrow: (index + 1) == curMonth || (index + 2) == nextMonth
                         }
                     }
                 } else {
                     return {
                         color: '#606060',
-                        text: ''
+                        text: '',
+                        showArrow: (index + 1) == curMonth || (index + 2) == nextMonth
                     }
                 }