|
@@ -166,6 +166,9 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
this.$nextTick(() => {
|
|
|
+ setTimeout(() => {
|
|
|
+ this.setIcon()
|
|
|
+ }, 2000)
|
|
|
this.$emit('change', calendarApi.view)
|
|
|
})
|
|
|
this.calendarTitle = calendarApi.view.title
|
|
@@ -175,6 +178,24 @@ export default {
|
|
|
this.todayClassName = 'today'
|
|
|
}
|
|
|
},
|
|
|
+ setIcon() {
|
|
|
+ const eleList = document.getElementsByClassName('fc-title')
|
|
|
+ Array.prototype.forEach.call(eleList, item => {
|
|
|
+ // const grandParent = item.parentElement.parentElement
|
|
|
+ // const color = grandParent.style.color
|
|
|
+ const div = document.createElement('div')
|
|
|
+ div.style.display = 'inline-block'
|
|
|
+ div.style.paddingTop = '2px'
|
|
|
+ const icon = document.createElement('i')
|
|
|
+ if (item.innerText.match(/排期/)) {
|
|
|
+ icon.className = 'el-icon-document'
|
|
|
+ } else {
|
|
|
+ icon.className = 'el-icon-date'
|
|
|
+ }
|
|
|
+ div.appendChild(icon)
|
|
|
+ item.parentElement.insertBefore(div, item)
|
|
|
+ })
|
|
|
+ },
|
|
|
select(selectionInfo) { // 滑动多选时候返回的数据
|
|
|
this.$emit('select', selectionInfo)
|
|
|
},
|
|
@@ -226,6 +247,10 @@ export default {
|
|
|
display: flex;
|
|
|
padding-top: 2px;
|
|
|
}
|
|
|
+>>>.fc-title {
|
|
|
+ line-height: 20px;
|
|
|
+ padding-left: 4px;
|
|
|
+}
|
|
|
>>>.fc-event-container .fc-content {
|
|
|
text-overflow: inherit;
|
|
|
}
|