Commit 0ec01ddc authored by linxin's avatar linxin

add

parent 38759ebc
...@@ -8,9 +8,9 @@ module.exports = merge(prodEnv, { ...@@ -8,9 +8,9 @@ module.exports = merge(prodEnv, {
debug: true, debug: true,
isMobilePlatform: false, isMobilePlatform: false,
loginPath: '"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=appadmin&password=" ', loginPath: '"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=appadmin&password=" ',
basePath: '"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_DEV&apiName="', basePath: '"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_UAT&apiName="',
rootPath: '"http://180.104.121.66:8088/r/api"', rootPath: '"http://180.104.121.66:8088/r/api"',
filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_DEV&apiName=file_view&"', filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_UAT&apiName=file_view&"',
ocrPath: '"http://180.104.121.66:8088/r/api"', ocrPath: '"http://180.104.121.66:8088/r/api"',
appId: '"com.xcmg.app.dev"', appId: '"com.xcmg.app.dev"',
currentVersion: '"1.9.0"', currentVersion: '"1.9.0"',
......
...@@ -102,19 +102,21 @@ export default { ...@@ -102,19 +102,21 @@ export default {
let eleHeight = vm.getOffsetTop(event.target) let eleHeight = vm.getOffsetTop(event.target)
let scrollTop = Math.floor(dom.scrollTop) let scrollTop = Math.floor(dom.scrollTop)
let result = Math.floor(veiwHeight - (eleHeight - scrollTop)) let result = Math.floor(veiwHeight - (eleHeight - scrollTop))
if (result >= 256) { let fontS = parseFloat(document.documentElement.style.fontSize) * 5
console.log(fontS)
if (result >= fontS) {
} else { } else {
let ele = document.createElement('div') let ele = document.createElement('div')
ele.setAttribute('class', 'add-height') ele.setAttribute('class', 'add-height')
ele.style.height = (256 - result) + 'px' ele.style.height = (fontS - result + 44) + 'px'
ele.style.background = '#fff' ele.style.background = '#fff'
// setTimeout(() => { // setTimeout(() => {
dom.appendChild(ele) dom.appendChild(ele)
// }, 100) // }, 100)
dom.scrollTop = scrollTop + (256 - result) dom.scrollTop = scrollTop + (fontS - result + 44)
// dom.scrollTo(dom.scrollLeft, scrollTop + (256 - result)) // dom.scrollTo(dom.scrollLeft, scrollTop + (256 - result))
} }
console.log(veiwHeight, eleHeight, scrollTop, result) console.log(veiwHeight, eleHeight, scrollTop, result, fontS)
event.target.type = 'text' event.target.type = 'text'
event.target.focus() event.target.focus()
}, 0) }, 0)
......
...@@ -98,16 +98,18 @@ export default { ...@@ -98,16 +98,18 @@ export default {
let eleHeight = vm.getOffsetTop(event.target) let eleHeight = vm.getOffsetTop(event.target)
let scrollTop = Math.floor(dom.scrollTop) let scrollTop = Math.floor(dom.scrollTop)
let result = Math.floor(veiwHeight - (eleHeight - scrollTop)) let result = Math.floor(veiwHeight - (eleHeight - scrollTop))
if (result >= 256) { let fontS = parseFloat(document.documentElement.style.fontSize) * 5
console.log(fontS)
if (result >= fontS) {
} else { } else {
let ele = document.createElement('div') let ele = document.createElement('div')
ele.setAttribute('class', 'add-height') ele.setAttribute('class', 'add-height')
ele.style.height = (256 - result) + 'px' ele.style.height = (fontS - result + 44) + 'px'
ele.style.background = '#fff' ele.style.background = '#fff'
// setTimeout(() => { // setTimeout(() => {
dom.appendChild(ele) dom.appendChild(ele)
// }, 100) // }, 100)
dom.scrollTop = scrollTop + (256 - result) dom.scrollTop = scrollTop + (fontS - result + 44)
// dom.scrollTo(dom.scrollLeft, scrollTop + (256 - result)) // dom.scrollTo(dom.scrollLeft, scrollTop + (256 - result))
} }
console.log(veiwHeight, eleHeight, scrollTop, result) console.log(veiwHeight, eleHeight, scrollTop, result)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment