forked from github/dataease
refactor: 代码结构优化
This commit is contained in:
parent
b400d42513
commit
57961f6ca9
@ -50,7 +50,6 @@ export default {
|
||||
background: 'gray',
|
||||
position: 'absolute'
|
||||
}
|
||||
// console.log('style=>' + JSON.stringify(style))
|
||||
return style
|
||||
},
|
||||
...mapState([
|
||||
|
@ -661,7 +661,6 @@ export default {
|
||||
this.maxH = val
|
||||
},
|
||||
w(val) {
|
||||
// console.log('changeWidthCK:' + this.resizing)
|
||||
|
||||
if (this.resizing || this.dragging) {
|
||||
return
|
||||
@ -669,7 +668,6 @@ export default {
|
||||
if (this.parent) {
|
||||
this.bounds = this.calcResizeLimits()
|
||||
}
|
||||
// console.log('changeWidth:' + val)
|
||||
this.changeWidth(val)
|
||||
},
|
||||
h(val) {
|
||||
@ -1051,7 +1049,6 @@ export default {
|
||||
const tmpDeltaY = axis && axis !== 'x' ? mouseClickPosition.mouseY - mY : 0
|
||||
// mY 鼠标指针移动的点 mY - this.latestMoveY 是计算向下移动还是向上移动
|
||||
const offsetY = mY - this.latestMoveY
|
||||
// console.log('mY:' + mY + ';latestMoveY=' + this.latestMoveY + ';offsetY=' + offsetY)
|
||||
this.$emit('canvasDragging', mY, offsetY)
|
||||
this.latestMoveY = mY
|
||||
const [deltaX, deltaY] = snapToGrid(grid, tmpDeltaX, tmpDeltaY, this.scaleRatio)
|
||||
@ -1237,7 +1234,6 @@ export default {
|
||||
newH = restrictToBounds(newH, this.miniHeight || 0, this.maxH)
|
||||
// 纵横比
|
||||
if (this.lockAspectRatio) {
|
||||
// console.log(this.lockAspectRatio, this.aspectFactor)
|
||||
if (newW / newH > this.aspectFactor) {
|
||||
newW = newH * this.aspectFactor
|
||||
} else {
|
||||
@ -1245,7 +1241,6 @@ export default {
|
||||
}
|
||||
}
|
||||
this.width = newW
|
||||
// console.log('width2:' + this.width)
|
||||
this.height = newH
|
||||
|
||||
// this.$emit('resizing', this.left, this.top, this.width, this.height)
|
||||
@ -1256,8 +1251,6 @@ export default {
|
||||
this.element.propValue && this.element.propValue.viewId && eventBus.$emit('resizing', this.element.propValue.viewId)
|
||||
},
|
||||
changeWidth(val) {
|
||||
// console.log('parentWidth', this.parentWidth)
|
||||
// console.log('parentHeight', this.parentHeight)
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
const [newWidth, _] = snapToGrid(this.grid, val, 0, this.scale)
|
||||
// const right = restrictToBounds(this.parentWidth - newWidth - this.left, this.bounds.minRight, this.bounds.maxRight)
|
||||
@ -1272,7 +1265,6 @@ export default {
|
||||
this.right = right
|
||||
this.bottom = bottom
|
||||
this.width = width
|
||||
// console.log('width3:' + this.width)
|
||||
this.height = height
|
||||
},
|
||||
changeHeight(val) {
|
||||
@ -1291,7 +1283,6 @@ export default {
|
||||
this.right = right
|
||||
this.bottom = bottom
|
||||
this.width = width
|
||||
// console.log('width4:' + this.width)
|
||||
this.height = height
|
||||
},
|
||||
// 从控制柄松开
|
||||
@ -1309,7 +1300,6 @@ export default {
|
||||
this.lastMouseY = mouseY
|
||||
if (this.resizing) {
|
||||
this.resizing = false
|
||||
// console.log('resizing2:' + this.resizing)
|
||||
this.conflictCheck()
|
||||
this.$emit('refLineParams', refLine)
|
||||
// this.$emit('resizestop', this.left, this.top, this.width, this.height)
|
||||
@ -1396,7 +1386,6 @@ export default {
|
||||
this.top = this.mouseClickPosition.top
|
||||
this.left = this.mouseClickPosition.left
|
||||
this.width = this.mouseClickPosition.width
|
||||
// console.log('width5:' + this.width)
|
||||
this.height = this.mouseClickPosition.height
|
||||
}
|
||||
}
|
||||
@ -1580,7 +1569,6 @@ export default {
|
||||
let groupLeft = 0
|
||||
let groupTop = 0
|
||||
for (const item of nodes) {
|
||||
// console.log('===' + typeof item.tagName)
|
||||
// 修复判断条件
|
||||
// if (item.className !== undefined && item.className.split(' ').includes(this.classNameActive)) {
|
||||
if (item.tagName !== 'svg' && item.className !== undefined && item.className.split(' ').includes(this.classNameActive)) {
|
||||
@ -1680,7 +1668,6 @@ export default {
|
||||
style.height = height
|
||||
style.rotate = this.rotate
|
||||
// this.hasMove = true
|
||||
// console.log('recordMatrixCurShadowStyle:t1:' + JSON.stringify(style))
|
||||
|
||||
this.$store.commit('setShapeStyle', style)
|
||||
|
||||
@ -1710,7 +1697,6 @@ export default {
|
||||
this.aspectFactor = this.outsideAspectRatio
|
||||
}
|
||||
this.width = this.w !== 'auto' ? this.w : width
|
||||
// console.log('width1:' + this.width)
|
||||
this.height = this.h !== 'auto' ? this.h : height
|
||||
this.right = this.parentWidth - this.width - this.left
|
||||
this.bottom = this.parentHeight - this.height - this.top
|
||||
|
@ -11,16 +11,12 @@ export default {
|
||||
name: 'Shadow',
|
||||
computed: {
|
||||
styleInfo() {
|
||||
// console.log('styleInfo==>')
|
||||
// console.log('dragComponentInfo==>' + this.dragComponentInfo.shadowStyle.x)
|
||||
let left = 0
|
||||
let top = 0
|
||||
let width = 0
|
||||
let height = 0
|
||||
let transition = 0
|
||||
// if (this.dragComponentInfo && !this.dragComponentInfo.auxiliaryMatrix) {
|
||||
if (this.dragComponentInfo) {
|
||||
// console.log('shadowDrag=')
|
||||
// 组件移入
|
||||
if (this.dragComponentInfo.auxiliaryMatrix) {
|
||||
left = (this.dragComponentInfo.x - 1) * this.curCanvasScale.matrixStyleWidth
|
||||
@ -36,7 +32,6 @@ export default {
|
||||
height = this.dragComponentInfo.style.height
|
||||
}
|
||||
|
||||
// console.log('left:' + left + 'top:' + top + 'width:' + width + 'height:' + height)
|
||||
} else {
|
||||
// temp 临时测试
|
||||
// left = this.curComponent.style.left * this.curCanvasScale.scaleWidth / 100
|
||||
@ -49,12 +44,10 @@ export default {
|
||||
if (this.curComponent.optStatus.dragging) {
|
||||
transition = 0.1
|
||||
}
|
||||
// console.log('curComponent left:' + left + 'top:' + top + 'width:' + width + 'height:' + height)
|
||||
}
|
||||
|
||||
// 防止阴影区超出边界
|
||||
const xGap = left + width - this.canvasWidth
|
||||
// console.log('canvasWidth:' + this.canvasWidth + ';xGap:' + xGap)
|
||||
if (xGap > 0) {
|
||||
left = left - xGap
|
||||
}
|
||||
@ -66,7 +59,6 @@ export default {
|
||||
if (transition > 0) {
|
||||
style.transition = transition + 's'
|
||||
}
|
||||
// console.log('style=>' + JSON.stringify(style))
|
||||
// 记录外部拖拽进入仪表板时阴影区域宽高
|
||||
if (this.dragComponentInfo) {
|
||||
this.recordShadowStyle(left, top, width, height)
|
||||
|
@ -107,7 +107,6 @@ export default {
|
||||
})
|
||||
|
||||
bus.$on('web-msg-topic-call', msg => {
|
||||
console.log('收到websocket消息')
|
||||
this.count = (this.count || this.paginationConfig.total) + 1
|
||||
// this.queryCount()
|
||||
// this.search()
|
||||
|
@ -121,7 +121,6 @@ export default {
|
||||
},
|
||||
mounted() {
|
||||
tinymce.init({})
|
||||
// console.log(this.toolbar,'======')
|
||||
},
|
||||
methods: {
|
||||
onClick(e) {
|
||||
|
@ -108,7 +108,6 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
styleKeys() {
|
||||
// console.log(this.$store.state.curComponent.style)
|
||||
return this.$store.state.curComponent ? Object.keys(this.$store.state.curComponent.style) : []
|
||||
},
|
||||
curComponent() {
|
||||
|
@ -129,7 +129,6 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
styleKeys() {
|
||||
// console.log(this.$store.state.curComponent.style)
|
||||
return this.$store.state.curComponent ? Object.keys(this.$store.state.curComponent.style) : []
|
||||
},
|
||||
curComponent() {
|
||||
|
@ -148,13 +148,6 @@ export default {
|
||||
closePreview() {
|
||||
this.$emit('closePreview')
|
||||
},
|
||||
createTimer() {
|
||||
if (!this.timer) {
|
||||
this.timer = setInterval(() => {
|
||||
console.log('t=' + this.curComponent.auxiliaryMatrix)
|
||||
}, 5000)
|
||||
}
|
||||
},
|
||||
destroyTimer() {
|
||||
if (this.timer) {
|
||||
clearInterval(this.timer)
|
||||
@ -277,11 +270,9 @@ export default {
|
||||
if (val) {
|
||||
// push
|
||||
this.$store.commit('addCurBatchComponent', this.element.propValue.viewId)
|
||||
console.log('push')
|
||||
} else {
|
||||
// remove
|
||||
this.$store.commit('removeCurBatchComponentWithId', this.element.propValue.viewId)
|
||||
console.log('remove')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -108,7 +108,6 @@ export default {
|
||||
mounted() {
|
||||
// 初始化映射关系 如果当前是相同的数据集且没有关联关系,则自动补充映射关系
|
||||
checkSameDataSet(this.curLinkageView.propValue.viewId, this.element.propValue.viewId).then(res => {
|
||||
console.log('linkageFields:' + JSON.stringify(this.linkageInfo.linkageFields))
|
||||
if (res.data === 'YES' && this.linkageInfo.linkageFields.length === 0) {
|
||||
this.sourceLinkageInfo.targetViewFields.forEach(item => {
|
||||
this.addLinkageField(item.id, item.id)
|
||||
|
@ -104,7 +104,6 @@ export default {
|
||||
message: this.$t('panel.outer_param_decode_error'),
|
||||
type: 'error'
|
||||
})
|
||||
console.log('outerParams Decode error:', e)
|
||||
}
|
||||
}
|
||||
if (tempParam) {
|
||||
@ -129,7 +128,6 @@ export default {
|
||||
if (--loadingCount === 0) {
|
||||
this.dataLoading = false
|
||||
}
|
||||
console.log('queryTargetPanelJumpInfo error:', e)
|
||||
}
|
||||
}
|
||||
if (loadingCount === 0) {
|
||||
|
@ -339,7 +339,6 @@ export default {
|
||||
curPoint,
|
||||
symmetricPoint
|
||||
})
|
||||
// console.log('this is test:' + JSON.stringify(this.element.propValue.viewId))
|
||||
this.$store.commit('setShapeStyle', style)
|
||||
this.element.propValue && this.element.propValue.viewId && eventBus.$emit('resizing', this.element.propValue.viewId)
|
||||
}
|
||||
|
@ -264,11 +264,9 @@ function debounce(func, time) {
|
||||
|
||||
function scrollScreen(e) {
|
||||
if (e.clientY + 50 >= window.innerHeight) {
|
||||
// console.log('scrollScreen+')
|
||||
const body = $(document.body)
|
||||
body.scrollTop(body.scrollTop() + 20)
|
||||
} else if (e.clientY <= 150) {
|
||||
// console.log('scrollScreen-')
|
||||
const body = $(document.body)
|
||||
body.scrollTop(body.scrollTop() - 20)
|
||||
}
|
||||
@ -312,7 +310,6 @@ function addItemToPositionBox(item) {
|
||||
}
|
||||
} catch (e) {
|
||||
// igonre
|
||||
console.log('addItemToPositionBox failed')
|
||||
}
|
||||
}
|
||||
|
||||
@ -514,7 +511,6 @@ function removeItem(index) {
|
||||
})
|
||||
this.yourList.splice(index, 1, {})
|
||||
} catch (e) {
|
||||
console.log('removeItem have some ignore error')
|
||||
}
|
||||
}
|
||||
|
||||
@ -527,7 +523,6 @@ function initPosition(_this) {
|
||||
}
|
||||
|
||||
function addItem(item, index) {
|
||||
// console.log('addItem')
|
||||
if (index < 0) {
|
||||
index = this.yourList.length
|
||||
}
|
||||
@ -1057,7 +1052,6 @@ export default {
|
||||
if (newVal.length !== this.lastComponentDataLength) {
|
||||
this.lastComponentDataLength = newVal.length
|
||||
this.initMatrix()
|
||||
// console.log('componentData-initMatrix')
|
||||
}
|
||||
},
|
||||
deep: true
|
||||
@ -1300,7 +1294,6 @@ export default {
|
||||
this.baseHeight = this.matrixStyle.height
|
||||
this.cellWidth = this.matrixStyle.width
|
||||
this.cellHeight = this.matrixStyle.height
|
||||
// console.log('.initMatrix1')
|
||||
this.initMatrix()
|
||||
|
||||
this.scaleWidth = this.outStyle.width * 100 / this.canvasStyleData.width
|
||||
@ -1339,7 +1332,6 @@ export default {
|
||||
}
|
||||
if (prop === 'top') {
|
||||
const top = this.format(style['top'], this.scaleHeight)
|
||||
// console.log('top:' + top)
|
||||
return top
|
||||
}
|
||||
},
|
||||
@ -1467,7 +1459,6 @@ export default {
|
||||
infoBox.oldSizeY = item.sizey
|
||||
},
|
||||
onMouseUp(e) {
|
||||
// console.log('onMouseUp')
|
||||
const vm = this
|
||||
if (_.isEmpty(vm.infoBox)) return
|
||||
if (vm.infoBox.cloneItem) {
|
||||
@ -1510,9 +1501,7 @@ export default {
|
||||
newY = newY > 0 ? newY : 1
|
||||
debounce((function(newX, oldX, newY, oldY, addSizex, addSizey) {
|
||||
return function() {
|
||||
// console.log('move1')
|
||||
if (newX !== oldX || oldY !== newY) {
|
||||
// console.log('move2')
|
||||
movePlayer.call(vm, resizeItem, {
|
||||
x: newX,
|
||||
y: newY
|
||||
@ -1545,9 +1534,7 @@ export default {
|
||||
newY = newY > 0 ? newY : 1
|
||||
debounce((function(newX, oldX, newY, oldY) {
|
||||
return function() {
|
||||
// console.log('move1')
|
||||
if (newX !== oldX || oldY !== newY) {
|
||||
// console.log('move2')
|
||||
movePlayer.call(vm, moveItem, {
|
||||
x: newX,
|
||||
y: newY
|
||||
@ -1598,8 +1585,6 @@ export default {
|
||||
* @returns
|
||||
*/
|
||||
getMaxCell() {
|
||||
// console.log('getMaxCell:')
|
||||
|
||||
return this.maxCell
|
||||
},
|
||||
/**
|
||||
@ -1608,8 +1593,6 @@ export default {
|
||||
* @returns
|
||||
*/
|
||||
getRenderState() {
|
||||
// console.log('getRenderState:')
|
||||
|
||||
return this.moveAnimate
|
||||
},
|
||||
addItem: addItem,
|
||||
@ -1624,7 +1607,6 @@ export default {
|
||||
}, 100)
|
||||
},
|
||||
addItemBox(item) {
|
||||
// console.log('addItemBox:' + JSON.stringify(item))
|
||||
this.yourList.push(item)
|
||||
|
||||
this.$nextTick(function() {
|
||||
@ -1632,7 +1614,6 @@ export default {
|
||||
})
|
||||
},
|
||||
removeLastItem() {
|
||||
// console.log('rlI:' + JSON.stringify(this.yourList))
|
||||
if (this.canvasStyleData.auxiliaryMatrix) {
|
||||
this.removeItem(this.yourList.length - 1)
|
||||
}
|
||||
|
@ -139,7 +139,6 @@ export default {
|
||||
}
|
||||
// 防止toolbar超出边界
|
||||
const xGap = ps + 295 - this.canvasWidth
|
||||
// console.log('canvasWidth:' + this.canvasWidth + ';xGap:' + xGap)
|
||||
if (xGap > 0) {
|
||||
return ps - xGap
|
||||
} else {
|
||||
|
@ -191,7 +191,6 @@ export default {
|
||||
}
|
||||
// 防止toolbar超出边界
|
||||
const xGap = ps + 345 - this.canvasWidth
|
||||
// console.log('canvasWidth:' + this.canvasWidth + ';xGap:' + xGap)
|
||||
if (xGap > 0) {
|
||||
return ps - xGap
|
||||
} else {
|
||||
|
@ -394,7 +394,6 @@ export default {
|
||||
this.$nextTick(() => {
|
||||
this.init()
|
||||
})
|
||||
// console.log('curComponent change')
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -417,14 +416,11 @@ export default {
|
||||
} else {
|
||||
this.mainWidthOffset = document.getElementById('main-attr').offsetWidth - 50
|
||||
}
|
||||
// console.log('mainWidthOffset:' + this.mainWidthOffset)
|
||||
},
|
||||
attrTabShow(attr) {
|
||||
// console.log('attr:' + attr + this[this.curComponent.type].includes(attr))
|
||||
return this.curActiveTabInner && this[this.curActiveTabInner.type] && this[this.curActiveTabInner.type].includes(attr)
|
||||
},
|
||||
attrShow(attr) {
|
||||
// console.log('attr:' + attr + this[this.curComponent.type].includes(attr))
|
||||
return this[this.curComponent.type].includes(attr)
|
||||
},
|
||||
goColor() {
|
||||
|
@ -76,10 +76,8 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
loaded(e) {
|
||||
console.log('loaded:', e)
|
||||
},
|
||||
onError(e) {
|
||||
console.log('onError:', e)
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -109,40 +109,29 @@ export default {
|
||||
},
|
||||
// listen event
|
||||
onPlayerPlay(player) {
|
||||
// console.log('player play!', player)
|
||||
},
|
||||
onPlayerEnded(player) {
|
||||
// console.log('player ended!', player)
|
||||
},
|
||||
onPlayerLoadeddata(player) {
|
||||
// console.log('player Loadeddata!', player)
|
||||
},
|
||||
onPlayerWaiting(player) {
|
||||
// console.log('player Waiting!', player)
|
||||
},
|
||||
onPlayerPlaying(player) {
|
||||
// console.log('player Playing!', player)
|
||||
},
|
||||
onPlayerTimeupdate(player) {
|
||||
// console.log('player Timeupdate!', player.currentTime())
|
||||
},
|
||||
onPlayerCanplay(player) {
|
||||
// console.log('player Canplay!', player)
|
||||
},
|
||||
onPlayerCanplaythrough(player) {
|
||||
// console.log('player Ca
|
||||
// console.log('example 01nplaythrough!', player)
|
||||
},
|
||||
|
||||
// or listen state event
|
||||
playerStateChanged(playerCurrentState) {
|
||||
// console.log('player current update state', playerCurrentState)
|
||||
},
|
||||
|
||||
// player is ready
|
||||
playerReadied(player) {
|
||||
// seek to 10s
|
||||
// console.log('example player 1 readied', player)
|
||||
// player.currentTime(10): the player is readied', player)
|
||||
}
|
||||
}
|
||||
|
@ -112,7 +112,6 @@ export default {
|
||||
this.watchSize()
|
||||
},
|
||||
created() {
|
||||
// console.log('aaaaaa')
|
||||
},
|
||||
methods: {
|
||||
|
||||
|
@ -37,7 +37,6 @@ export default {
|
||||
|
||||
methods: {
|
||||
chartResize() {
|
||||
// console.log('11111')
|
||||
this.$nextTick(() => {
|
||||
this.$refs[this.element.id] && this.$refs[this.element.id].resize && this.$refs[this.element.id].resize()
|
||||
})
|
||||
|
@ -378,7 +378,6 @@ export default {
|
||||
},
|
||||
|
||||
setComponentInfo() {
|
||||
console.log('aaa')
|
||||
},
|
||||
|
||||
editCurTitle(param) {
|
||||
|
@ -192,7 +192,6 @@ export default {
|
||||
uploadFileResult(file, (fileUrl) => {
|
||||
_this.curComponent.commonBackground.outerImage = fileUrl
|
||||
})
|
||||
// console.log('this is upload')
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -223,7 +223,6 @@ export default {
|
||||
} else if (chart.type === 'chart-mix') {
|
||||
chart_option = baseMixOption(JSON.parse(JSON.stringify(BASE_MIX)), chart)
|
||||
}
|
||||
// console.log(JSON.stringify(chart_option))
|
||||
if (this.myChart && this.searchCount > 0) {
|
||||
chart_option.animation = false
|
||||
}
|
||||
|
@ -191,7 +191,6 @@ export default {
|
||||
},
|
||||
|
||||
antVAction(param) {
|
||||
console.log(param)
|
||||
if (this.chart.type === 'treemap') {
|
||||
this.pointParam = param.data.data
|
||||
} else {
|
||||
|
@ -213,10 +213,8 @@ export default {
|
||||
},
|
||||
|
||||
antVAction(param) {
|
||||
console.log(param, 'param')
|
||||
const cell = this.myChart.getCell(param.target)
|
||||
const meta = cell.getMeta()
|
||||
console.log(meta, 'meta')
|
||||
|
||||
let xAxis = []
|
||||
if (this.chart.xaxis) {
|
||||
@ -251,7 +249,6 @@ export default {
|
||||
dimensionList: dimensionList
|
||||
}
|
||||
}
|
||||
console.log(this.pointParam, 'pointParam')
|
||||
|
||||
if (this.trackMenu.length < 2) { // 只有一个事件直接调用
|
||||
this.trackClick(this.trackMenu[0])
|
||||
|
@ -177,7 +177,6 @@ export default {
|
||||
}
|
||||
},
|
||||
sort(param) {
|
||||
// console.log(param)
|
||||
this.item.sort = param.type
|
||||
this.$emit('onItemChange', this.item)
|
||||
},
|
||||
@ -187,7 +186,6 @@ export default {
|
||||
}
|
||||
},
|
||||
summary(param) {
|
||||
// console.log(param)
|
||||
this.item.summary = param.type
|
||||
this.$emit('onItemChange', this.item)
|
||||
},
|
||||
@ -202,7 +200,6 @@ export default {
|
||||
},
|
||||
|
||||
dateStyle(param) {
|
||||
// console.log(param)
|
||||
this.item.dateStyle = param.type
|
||||
this.$emit('onItemChange', this.item)
|
||||
},
|
||||
@ -212,7 +209,6 @@ export default {
|
||||
}
|
||||
},
|
||||
datePattern(param) {
|
||||
// console.log(param)
|
||||
this.item.datePattern = param.type
|
||||
this.$emit('onItemChange', this.item)
|
||||
},
|
||||
|
@ -157,7 +157,6 @@ export default {
|
||||
}
|
||||
},
|
||||
sort(param) {
|
||||
// console.log(param)
|
||||
this.item.sort = param.type
|
||||
this.$emit('onDimensionItemChange', this.item)
|
||||
},
|
||||
@ -167,7 +166,6 @@ export default {
|
||||
}
|
||||
},
|
||||
dateStyle(param) {
|
||||
// console.log(param)
|
||||
this.item.dateStyle = param.type
|
||||
this.$emit('onDimensionItemChange', this.item)
|
||||
},
|
||||
|
@ -181,7 +181,6 @@ export default {
|
||||
}
|
||||
},
|
||||
sort(param) {
|
||||
// console.log(param)
|
||||
if (param.type === 'custom_sort') {
|
||||
const item = {
|
||||
index: this.index,
|
||||
@ -201,7 +200,6 @@ export default {
|
||||
}
|
||||
},
|
||||
dateStyle(param) {
|
||||
// console.log(param)
|
||||
this.item.dateStyle = param.type
|
||||
this.$emit('onDimensionItemChange', this.item)
|
||||
},
|
||||
@ -211,7 +209,6 @@ export default {
|
||||
}
|
||||
},
|
||||
datePattern(param) {
|
||||
// console.log(param)
|
||||
this.item.datePattern = param.type
|
||||
this.$emit('onDimensionItemChange', this.item)
|
||||
},
|
||||
|
@ -232,7 +232,6 @@ export default {
|
||||
},
|
||||
|
||||
summary(param) {
|
||||
// console.log(param)
|
||||
this.item.summary = param.type
|
||||
this.$emit('onQuotaItemChange', this.item)
|
||||
},
|
||||
@ -243,7 +242,6 @@ export default {
|
||||
},
|
||||
|
||||
switchChartType(param) {
|
||||
// console.log(param)
|
||||
this.item.chartType = param.type
|
||||
this.$emit('onQuotaItemChange', this.item)
|
||||
},
|
||||
@ -273,7 +271,6 @@ export default {
|
||||
},
|
||||
|
||||
sort(param) {
|
||||
// console.log(param)
|
||||
this.item.sort = param.type
|
||||
this.$emit('onQuotaItemChange', this.item)
|
||||
},
|
||||
|
@ -228,7 +228,6 @@ export default {
|
||||
},
|
||||
|
||||
summary(param) {
|
||||
// console.log(param)
|
||||
this.item.summary = param.type
|
||||
this.$emit('onQuotaItemChange', this.item)
|
||||
},
|
||||
@ -239,7 +238,6 @@ export default {
|
||||
},
|
||||
|
||||
switchChartType(param) {
|
||||
// console.log(param)
|
||||
this.item.chartType = param.type
|
||||
this.$emit('onQuotaItemChange', this.item)
|
||||
},
|
||||
@ -269,7 +267,6 @@ export default {
|
||||
},
|
||||
|
||||
sort(param) {
|
||||
// console.log(param)
|
||||
this.item.sort = param.type
|
||||
this.$emit('onQuotaItemChange', this.item)
|
||||
},
|
||||
|
@ -235,7 +235,6 @@ export default {
|
||||
value: 0
|
||||
}
|
||||
}
|
||||
console.log(this.pointParam)
|
||||
this.$refs['textData'].offsetTop
|
||||
if (this.trackMenu.length < 2) { // 只有一个事件直接调用
|
||||
this.trackClick(this.trackMenu[0])
|
||||
|
@ -280,12 +280,10 @@ export default {
|
||||
const table = document.getElementsByClassName(this.chart.id)
|
||||
for (let i = 0; i < table.length; i++) {
|
||||
const s_table = table[i].getElementsByClassName('elx-table--footer')
|
||||
// console.log(s_table)
|
||||
let s = ''
|
||||
for (const i in this.table_header_class) {
|
||||
s += (i === 'fontSize' ? 'font-size' : i) + ':' + this.table_header_class[i] + ';'
|
||||
}
|
||||
// console.log(s_table)
|
||||
for (let i = 0; i < s_table.length; i++) {
|
||||
s_table[i].setAttribute('style', s)
|
||||
}
|
||||
|
@ -1203,7 +1203,6 @@ export default {
|
||||
if (val && this.param.id !== this.preChartId) {
|
||||
this.preChartId = this.param.id
|
||||
this.chartInit()
|
||||
// console.log('fromwatch:' + JSON.stringify(val))
|
||||
}
|
||||
},
|
||||
'param': function(val) {
|
||||
@ -1212,7 +1211,6 @@ export default {
|
||||
} else if (this.param.id !== this.preChartId && this.editStatue) {
|
||||
this.preChartId = this.param.id
|
||||
this.chartInit()
|
||||
// console.log('fromwatch:' + JSON.stringify(val))
|
||||
}
|
||||
},
|
||||
searchField(val) {
|
||||
@ -1247,7 +1245,6 @@ export default {
|
||||
this.bindPluginEvent()
|
||||
this.initFromPanel()
|
||||
this.chartInit()
|
||||
// console.log('mounted')
|
||||
},
|
||||
activated() {
|
||||
},
|
||||
@ -1261,7 +1258,6 @@ export default {
|
||||
this.pluginRenderOptions = [...this.renderOptions, ...pluginOptions]
|
||||
},
|
||||
emptyTableData(id) {
|
||||
console.log('emptyTableData:' + id)
|
||||
this.table = {}
|
||||
this.dimension = []
|
||||
this.quota = []
|
||||
@ -1570,7 +1566,6 @@ export default {
|
||||
// 将视图传入echart组件
|
||||
// this.chart = response.data
|
||||
// this.data = response.data.data
|
||||
// // console.log(JSON.stringify(this.chart))
|
||||
// this.httpRequest.status = true
|
||||
// if (this.chart.privileges) {
|
||||
// this.param.privileges = this.chart.privileges
|
||||
@ -1677,7 +1672,6 @@ export default {
|
||||
// 将视图传入echart组件
|
||||
this.chart = response.data
|
||||
this.data = response.data.data
|
||||
// console.log(JSON.stringify(this.chart))
|
||||
this.httpRequest.status = true
|
||||
if (this.chart.privileges) {
|
||||
this.param.privileges = this.chart.privileges
|
||||
@ -1742,7 +1736,6 @@ export default {
|
||||
|
||||
// move回调方法
|
||||
onMove(e, originalEvent) {
|
||||
// console.log(e)
|
||||
this.moveId = e.draggedContext.element.id
|
||||
return true
|
||||
},
|
||||
|
@ -94,7 +94,6 @@ export default {
|
||||
}
|
||||
},
|
||||
'checkedList': function() {
|
||||
// console.log(this.checkedList)
|
||||
this.getUnionData()
|
||||
}
|
||||
},
|
||||
@ -119,11 +118,9 @@ export default {
|
||||
},
|
||||
|
||||
getTable(table) {
|
||||
// console.log(table)
|
||||
this.table = table
|
||||
},
|
||||
getChecked(tableCheckedField) {
|
||||
// console.log(tableCheckedField)
|
||||
if (tableCheckedField.checkedFields && tableCheckedField.checkedFields.length > 0) {
|
||||
if (!this.checkedList.some(ele => ele.tableId === tableCheckedField.tableId)) {
|
||||
this.checkedList.push(tableCheckedField)
|
||||
@ -146,7 +143,6 @@ export default {
|
||||
this.checkedList.splice(index, 1)
|
||||
}
|
||||
}
|
||||
// console.log(this.checkedList)
|
||||
this.getData()
|
||||
},
|
||||
getData() {
|
||||
@ -162,7 +158,6 @@ export default {
|
||||
info: '{"list":' + JSON.stringify(this.checkedList) + '}'
|
||||
}
|
||||
post('/dataset/table/customPreview', table).then(response => {
|
||||
// console.log(response)
|
||||
this.fields = response.data.fields
|
||||
this.data = response.data.data
|
||||
const datas = this.data
|
||||
@ -179,7 +174,6 @@ export default {
|
||||
if (this.checkedList && this.checkedList.length > 0) {
|
||||
// 根据第一个选择的数据集找到关联视图
|
||||
post('dataset/union/listByTableId/' + this.checkedList[0].tableId, {}).then(response => {
|
||||
// console.log(response)
|
||||
this.unionData = response.data
|
||||
})
|
||||
} else {
|
||||
|
@ -321,10 +321,8 @@ export default {
|
||||
this.codemirror.setSize('-webkit-fill-available', 'auto')
|
||||
},
|
||||
onCmFocus(cm) {
|
||||
// console.log('the editor is focus!', cm)
|
||||
},
|
||||
onCmCodeChange(newCode) {
|
||||
// console.log(newCode)
|
||||
this.sql = newCode
|
||||
this.$emit('codeChange', this.sql)
|
||||
},
|
||||
|
@ -306,7 +306,6 @@ export default {
|
||||
// this.expandedArray.splice(index, 1)
|
||||
// }
|
||||
// }
|
||||
// console.log(this.expandedArray);
|
||||
},
|
||||
|
||||
back() {
|
||||
|
@ -301,10 +301,8 @@ export default {
|
||||
this.codemirror.setSize('-webkit-fill-available', 'auto')
|
||||
},
|
||||
onCmFocus(cm) {
|
||||
// console.log('the editor is focus!', cm)
|
||||
},
|
||||
onCmCodeChange(newCode) {
|
||||
// console.log(newCode)
|
||||
this.fieldForm.originName = newCode
|
||||
},
|
||||
insertParamToCodeMirror(param) {
|
||||
|
@ -334,7 +334,6 @@ export default {
|
||||
})
|
||||
},
|
||||
saveEdit(item) {
|
||||
// console.log(this.tableFields)
|
||||
// const list = this.tableFields.dimensionListData.concat(this.tableFields.quotaListData)
|
||||
// batchEdit(list).then(response => {
|
||||
// // this.closeEdit()
|
||||
|
@ -160,7 +160,6 @@ export default {
|
||||
},
|
||||
pageChange(val) {
|
||||
this.currentPage.page = val
|
||||
// console.log(this.currentPage)
|
||||
this.$emit('reSearch', { form: this.form, page: this.currentPage })
|
||||
}
|
||||
}
|
||||
|
@ -210,7 +210,6 @@ export default {
|
||||
this.customType = ['db', 'sql', 'excel', 'api']
|
||||
}
|
||||
post('dataset/union/listByTableId/' + this.table.id, {}).then(response => {
|
||||
// console.log(response)
|
||||
this.unionData = response.data
|
||||
})
|
||||
}
|
||||
@ -235,7 +234,6 @@ export default {
|
||||
// })
|
||||
},
|
||||
saveUnion() {
|
||||
// console.log(this.union)
|
||||
if (!this.union.sourceTableFieldId || !this.union.sourceUnionRelation || !this.union.targetTableId || !this.union.targetTableFieldId) {
|
||||
this.$message({
|
||||
type: 'error',
|
||||
@ -298,7 +296,6 @@ export default {
|
||||
})
|
||||
},
|
||||
getTable(param) {
|
||||
// console.log(param)
|
||||
if (param.id === this.table.id) {
|
||||
this.$message({
|
||||
type: 'error',
|
||||
|
@ -739,10 +739,8 @@ export default {
|
||||
this.codemirror.setSize('-webkit-fill-available', 'auto')
|
||||
},
|
||||
onCmFocus(cm) {
|
||||
// console.log('the editor is focus!', cm)
|
||||
},
|
||||
onCmCodeChange(newCode) {
|
||||
// console.log(newCode)
|
||||
this.sql = newCode
|
||||
this.$emit('codeChange', this.sql)
|
||||
},
|
||||
|
@ -214,7 +214,6 @@ export default {
|
||||
},
|
||||
|
||||
clickEditExcel(param) {
|
||||
// console.log(param);
|
||||
switch (param.type) {
|
||||
case '0':
|
||||
this.$emit('switchComponent', {
|
||||
|
@ -177,11 +177,9 @@ export default {
|
||||
this.$emit('close-grant', 0)
|
||||
},
|
||||
authNodeClick (val) {
|
||||
console.log('authNodeClick')
|
||||
this.authCondition = val
|
||||
},
|
||||
clickAuth (auth) {
|
||||
console.log('clickAuth')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -162,7 +162,6 @@ export default {
|
||||
})
|
||||
},
|
||||
nodeClick(data, node) {
|
||||
// console.log(data)
|
||||
},
|
||||
getAllKidId(node, ids) {
|
||||
if (node.children && node.children.length > 0) {
|
||||
@ -190,7 +189,6 @@ export default {
|
||||
channelId: channelId,
|
||||
enable
|
||||
}
|
||||
// console.log(param)
|
||||
batchUpdate(param).then(res => {
|
||||
this.loadSettingData()
|
||||
})
|
||||
|
@ -130,7 +130,6 @@ export default {
|
||||
return data
|
||||
},
|
||||
expandMsgNode(panelIds) {
|
||||
// console.log(panelIds)
|
||||
this.$nextTick(() => {
|
||||
this.getMsgNodes(panelIds)
|
||||
})
|
||||
|
@ -317,7 +317,6 @@ export default {
|
||||
})
|
||||
},
|
||||
panelNodeClick(data, node) {
|
||||
// console.log('panelNodeClick:' + JSON.stringify(data))
|
||||
this.linkJumpInfo.targetViewInfoList = []
|
||||
this.getPanelViewList(data.id)
|
||||
},
|
||||
|
@ -292,7 +292,6 @@ export default {
|
||||
})
|
||||
},
|
||||
panelNodeClick(data, node) {
|
||||
// console.log('panelNodeClick:' + JSON.stringify(data))
|
||||
this.outerParamsInfo.targetViewInfoList = []
|
||||
this.getPanelViewList(data.id)
|
||||
},
|
||||
|
@ -169,7 +169,6 @@ export default {
|
||||
})
|
||||
},
|
||||
move(offset, direction, speed) {
|
||||
// console.log(speed)
|
||||
if (!this.transitionEnd) return
|
||||
this.transitionEnd = false
|
||||
direction === -1 ? this.currentIndex += offset / this.sliderWidth : this.currentIndex -= offset / this.sliderWidth
|
||||
|
@ -205,7 +205,6 @@ export default {
|
||||
this.$emit('templateEdit', this.template)
|
||||
},
|
||||
handleDelete() {
|
||||
// console.log('handleDelete')
|
||||
},
|
||||
// 双击事件
|
||||
setEdit() {
|
||||
|
@ -168,7 +168,6 @@ export default {
|
||||
this.$emit('templateEdit', this.template)
|
||||
},
|
||||
handleDelete() {
|
||||
// console.log('handleDelete')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -154,7 +154,6 @@ export default {
|
||||
eventBus.$emit('startMoveIn')
|
||||
},
|
||||
dragEnd() {
|
||||
// console.log('dragEnd')
|
||||
this.$store.commit('clearDragComponentInfo')
|
||||
},
|
||||
// 判断节点能否被拖拽
|
||||
|
@ -1060,7 +1060,6 @@ export default {
|
||||
recordStyleChange(index) {
|
||||
if (index === this.$store.state.styleChangeTimes) {
|
||||
this.timeMachine = setTimeout(() => {
|
||||
// console.log('recordSnapshot')
|
||||
this.$store.commit('recordSnapshot')
|
||||
this.$store.state.styleChangeTimes = 0
|
||||
this.destroyTimeMachine()
|
||||
|
@ -84,7 +84,6 @@ export default {
|
||||
return result
|
||||
})
|
||||
}
|
||||
// console.log('this.widgetSubjects=>' + JSON.stringify(this.widgetSubjects))
|
||||
},
|
||||
|
||||
methods: {
|
||||
|
@ -42,7 +42,6 @@ export default {
|
||||
},
|
||||
watch: {
|
||||
// $route(to, from) {
|
||||
// console.log('route change')
|
||||
// }
|
||||
},
|
||||
mounted() {
|
||||
|
@ -760,7 +760,6 @@ export default {
|
||||
children: res.data
|
||||
}
|
||||
]
|
||||
// console.log('tGroupData=>' + JSON.stringify(_this.tGroupData))
|
||||
} else {
|
||||
_this.tGroupData = res.data
|
||||
}
|
||||
|
@ -50,7 +50,6 @@ export default {
|
||||
this.$emit('templateEdit', this.template)
|
||||
},
|
||||
handleDelete() {
|
||||
// console.log('handleDelete')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -71,7 +71,6 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
handleClick(tab, event) {
|
||||
// console.log(tab, event)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -104,7 +104,6 @@ export default {
|
||||
getLicenseInfo() {
|
||||
// validate({}).then(res => {
|
||||
// this.license = this.getLicense(res.data)
|
||||
// console.log(this.license)
|
||||
// })
|
||||
this.validateHandler({}, res => {
|
||||
this.license = this.getLicense(res.data)
|
||||
@ -150,7 +149,6 @@ export default {
|
||||
window.open(url, '_blank')
|
||||
},
|
||||
beforeUpload(file) {
|
||||
// console.log(file)
|
||||
this.importLic(file)
|
||||
return false
|
||||
}
|
||||
|
@ -172,11 +172,9 @@ export default {
|
||||
this.$emit('close-grant', 0)
|
||||
},
|
||||
authNodeClick(val) {
|
||||
// console.log('authNodeClick')
|
||||
this.authCondition = val
|
||||
},
|
||||
clickAuth(auth) {
|
||||
// console.log('clickAuth')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -148,11 +148,9 @@ export default {
|
||||
this.$emit('close-grant', 0)
|
||||
},
|
||||
authNodeClick(val) {
|
||||
// console.log('authNodeClick')
|
||||
this.authCondition = val
|
||||
},
|
||||
clickAuth(auth) {
|
||||
// console.log('clickAuth')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -33,7 +33,6 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
handleClick() {
|
||||
// console.log('===>handleClick')
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -53,7 +53,6 @@ export default {
|
||||
created() {
|
||||
if (this.jsname && this.menuid) {
|
||||
this.showAsync = true
|
||||
// console.log(this.jsname)
|
||||
this.url = this.baseUrl + this.menuid
|
||||
// this.url = 'http://localhost:8081/PluginDemo.js'
|
||||
// this.url = 'http://localhost:8081/SystemParam.js'
|
||||
@ -89,8 +88,6 @@ export default {
|
||||
this.backName = backName
|
||||
},
|
||||
pluginCallBack(param) {
|
||||
// console.log(param)
|
||||
|
||||
const { eventName, eventParam } = param
|
||||
bus.$emit(eventName, eventParam)
|
||||
}
|
||||
|
@ -227,7 +227,6 @@ export default {
|
||||
this.depts = null
|
||||
this.formType = 'add'
|
||||
this.form = Object.assign({}, this.defaultForm)
|
||||
// console.log(this.form)
|
||||
},
|
||||
edit(row) {
|
||||
this.depts = null
|
||||
|
@ -1,13 +1,10 @@
|
||||
<script>
|
||||
export default {
|
||||
onLaunch: function() {
|
||||
console.log('App Launch')
|
||||
},
|
||||
onShow: function() {
|
||||
console.log('App Show')
|
||||
},
|
||||
onHide: function() {
|
||||
console.log('App Hide')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue
Block a user