Commit 340b0f1b authored by Jennie Shi's avatar Jennie Shi

fixConflict

parents 7eff53f8 8fd979ee
Pipeline #4629 canceled with stages
...@@ -13,5 +13,5 @@ module.exports = merge(prodEnv, { ...@@ -13,5 +13,5 @@ module.exports = merge(prodEnv, {
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_DEV&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"', appId: '"com.xcmg.app"',
currentVersion: '"1.5.1"', currentVersion: '"1.5.3"',
}) })
...@@ -27,7 +27,15 @@ module.exports = { ...@@ -27,7 +27,15 @@ module.exports = {
// Paths // Paths
assetsSubDirectory: 'static', assetsSubDirectory: 'static',
assetsPublicPath: '/', assetsPublicPath: '/',
proxyTable: {}, proxyTable: {
// '/xcmg_file': {
// target: 'http://lichee.iask.in',
// changeOrigin: true,
// pathRewrite: {
// '^/xcmg_file': '/xcmg_file'
// }
// },
},
// Various Dev Server settings // Various Dev Server settings
host: 'localhost', // can be overwritten by process.env.HOST host: 'localhost', // can be overwritten by process.env.HOST
......
...@@ -7,9 +7,9 @@ module.exports = { ...@@ -7,9 +7,9 @@ module.exports = {
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_PROD&apiName="', basePath: '"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_PROD&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_PROD&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"',
fileUploadSvcPath:'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_PROD&apiName="', fileUploadSvcPath:'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_UAT&apiName="',
appId: '"com.xcmg.app"', appId: '"com.xcmg.app"',
currentVersion: '"0.0.1"' currentVersion: '"0.0.1"'
} }
...@@ -11,5 +11,5 @@ module.exports = { ...@@ -11,5 +11,5 @@ module.exports = {
ocrPath:'"http://180.104.121.66:8088/r/api"', ocrPath:'"http://180.104.121.66:8088/r/api"',
fileUploadSvcPath:'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_DEV&apiName="', fileUploadSvcPath:'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_DEV&apiName="',
appId: '"com.xcmg.app.dev"', appId: '"com.xcmg.app.dev"',
currentVersion: '"1.1.3"' currentVersion: '"1.5.7"'
} }
This diff is collapsed.
src/assets/login/reg-logo.png

11.4 KB | W: | H:

src/assets/login/reg-logo.png

11.7 KB | W: | H:

src/assets/login/reg-logo.png
src/assets/login/reg-logo.png
src/assets/login/reg-logo.png
src/assets/login/reg-logo.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/login/title.png

53.7 KB | W: | H:

src/assets/login/title.png

54.4 KB | W: | H:

src/assets/login/title.png
src/assets/login/title.png
src/assets/login/title.png
src/assets/login/title.png
  • 2-up
  • Swipe
  • Onion skin
import PDF from './PDF'
var $vm
export default {
install (Vue, options) {
if (!$vm) {
const PDFPlugin = Vue.extend(PDF)
$vm = new PDFPlugin().$mount()
document.body.appendChild($vm.$el)
}
Vue.prototype.$showPDF = function (url) {
$vm.showPDF(url)
}
},
}
<template>
<div id="containers" class="containers">
<!-- <div class='pdf-page'> -->
<canvas id="the-canvas"/>
<div v-if="pdfDoc" class="foot">
<button v-if="pageNum>1" class="left" @click="onPrevPage">上一页</button>
<button v-if="pageNum<pdfDoc.numPages" class="right" @click="onNextPage">下一页</button>
</div>
<!-- </div> -->
</div>
</template>
<script>
import PDFJS from 'pdfjs-dist'
export default {
data () {
return {
pdfDoc: null,
pageNum: 1,
pageRendering: false,
pageNumPending: null,
scale: 0.9,
}
},
methods: {
showPDF (url) {
let _this = this
PDFJS.getDocument(url).then(function (pdf) {
_this.pdfDoc = pdf
_this.renderPage(1)
})
},
renderPage (num) {
this.pageRendering = true
let _this = this
this.pdfDoc.getPage(num).then(function (page) {
var viewport = page.getViewport(_this.scale)
let canvas = document.getElementById('the-canvas')
canvas.height = viewport.height
canvas.width = viewport.width
// Render PDF page into canvas context
var renderContext = {
canvasContext: canvas.getContext('2d'),
viewport: viewport,
}
var renderTask = page.render(renderContext)
// Wait for rendering to finish
renderTask.promise.then(function () {
_this.pageRendering = false
if (_this.pageNumPending !== null) {
// New page rendering is pending
this.renderPage(_this.pageNumPending)
_this.pageNumPending = null
}
})
})
},
queueRenderPage (num) {
if (this.pageRendering) {
this.pageNumPending = num
} else {
this.renderPage(num)
}
},
onPrevPage () {
if (this.pageNum <= 1) {
return
}
this.pageNum--
this.queueRenderPage(this.pageNum)
},
onNextPage () {
if (this.pageNum >= this.pdfDoc.numPages) {
return
}
this.pageNum++
this.queueRenderPage(this.pageNum)
},
},
}
</script>
<style scoped>
#containers.containers {
/* background-color: rgba(0,0,0,0.75); */
position:fixed;
width: 100%;
height: 100%;
top: 0;
left: 0;
text-align: center;
padding: 5px;
}
.pdf-page {
}
.foot {
position: fixed;
transform: translate(-50%,0);
left: 50%;
}
</style>
...@@ -62,7 +62,6 @@ if (process.env.CONFIG_ENV === 'uat') { ...@@ -62,7 +62,6 @@ if (process.env.CONFIG_ENV === 'uat') {
const VConsole = require('vconsole') const VConsole = require('vconsole')
new VConsole() // eslint-disable-line new VConsole() // eslint-disable-line
} }
Vue.use(componentInstall) Vue.use(componentInstall)
Vue.use(components) Vue.use(components)
Vue.use(appStyle) Vue.use(appStyle)
......
...@@ -175,7 +175,7 @@ ...@@ -175,7 +175,7 @@
<img v-if="item.read_status === 'N'" class="unread" src="@/assets/constractSigning/unread.png" > <img v-if="item.read_status === 'N'" class="unread" src="@/assets/constractSigning/unread.png" >
<img v-if="item.read_status === 'Y'" class="unread" src="@/assets/constractSigning/read.png" > <img v-if="item.read_status === 'Y'" class="unread" src="@/assets/constractSigning/read.png" >
</div> </div>
<div slot="content" class="in-detail" @click="goContent(item)"> <div slot="content" class="in-detail" @click="goContent(item,index)">
<img src="@/assets/constractSigning/detail.png" alt > <img src="@/assets/constractSigning/detail.png" alt >
</div> </div>
</item> </item>
...@@ -195,6 +195,7 @@ ...@@ -195,6 +195,7 @@
<script> <script>
import Tab from '@/pages/carConfirm/tab' import Tab from '@/pages/carConfirm/tab'
import bodyCheck from './body-check' import bodyCheck from './body-check'
export default { export default {
components: { components: {
Tab, Tab,
...@@ -298,7 +299,7 @@ export default { ...@@ -298,7 +299,7 @@ export default {
} }
}) })
}, },
goContent (item) { goContent (item, index) {
// 详情 // 详情
// 合同状态更新保存 // 合同状态更新保存
let vm = this let vm = this
...@@ -317,7 +318,10 @@ export default { ...@@ -317,7 +318,10 @@ export default {
vm.hlsHttp.post(url, param).then(res => { vm.hlsHttp.post(url, param).then(res => {
hlsPopup.hideLoading() hlsPopup.hideLoading()
if (res.result === 'S') { if (res.result === 'S') {
let temp = vm.attachArray[index]
temp.read_status = 'Y'
vm.$router.push({name: 'previewPdf', params: {attachUrl: vm.attachUrl}}) vm.$router.push({name: 'previewPdf', params: {attachUrl: vm.attachUrl}})
vm.attachArray.splice(vm.attachArray[index], 1, temp)
} else { } else {
vm.hlsPopup.showLongCenter(res.message) vm.hlsPopup.showLongCenter(res.message)
} }
......
...@@ -126,7 +126,7 @@ ...@@ -126,7 +126,7 @@
<img v-if="item.read_status === 'N'" class="unread" src="@/assets/constractSigning/unread.png" > <img v-if="item.read_status === 'N'" class="unread" src="@/assets/constractSigning/unread.png" >
<img v-if="item.read_status === 'Y'" class="unread" src="@/assets/constractSigning/read.png" > <img v-if="item.read_status === 'Y'" class="unread" src="@/assets/constractSigning/read.png" >
</div> </div>
<div slot="content" class="in-detail" @click="goContent(item)"> <div slot="content" class="in-detail" @click="goContent(item,index)">
<img src="@/assets/constractSigning/detail.png" alt > <img src="@/assets/constractSigning/detail.png" alt >
</div> </div>
</item> </item>
...@@ -435,7 +435,7 @@ export default { ...@@ -435,7 +435,7 @@ export default {
// vm.hlsPopup.showLongCenter(res.message) // vm.hlsPopup.showLongCenter(res.message)
} }
}, },
goContent (item) { goContent (item, index) {
// 详情 // 详情
// 合同状态更新保存 // 合同状态更新保存
let vm = this let vm = this
...@@ -454,7 +454,10 @@ export default { ...@@ -454,7 +454,10 @@ export default {
vm.hlsHttp.post(url, param).then(res => { vm.hlsHttp.post(url, param).then(res => {
hlsPopup.hideLoading() hlsPopup.hideLoading()
if (res.result === 'S') { if (res.result === 'S') {
let temp = vm.attachArray[index]
temp.read_status = 'Y'
vm.$router.push({name: 'previewPdf', params: {attachUrl: vm.attachUrl}}) vm.$router.push({name: 'previewPdf', params: {attachUrl: vm.attachUrl}})
vm.attachArray.splice(vm.attachArray[index], 1, temp)
} else { } else {
vm.hlsPopup.showLongCenter(res.message) vm.hlsPopup.showLongCenter(res.message)
} }
......
...@@ -6,19 +6,73 @@ ...@@ -6,19 +6,73 @@
<span>合同预览</span> <span>合同预览</span>
</div> </div>
</h-header> </h-header>
<iframe <h-content>
:src="attachUrl" <canvas v-for="page in pages" :id="'the-canvas'+page" :key="page"/>
frameborder="0" scrolling="yes" width="100%" </h-content>
height="100%" />
</h-view> </h-view>
</template> </template>
<script> <script>
import PDFJS from 'pdfjs-dist'
// const Base64 = require('js-base64').Base64
export default { export default {
data () { data () {
return { return {
attachUrl: this.$route.params.attachUrl, attachUrl: this.$route.params.attachUrl,
pages: 0,
pdfDoc: null,
} }
}, },
mounted () {
let vm = this
// let attachUrl = vm.attachUrl.substr(vm.attachUrl.indexOf('/xcmg_file'))
vm.hlsPopup.showLoading('请稍候...')
// debugger
// let url = Base64.decode(vm.attachUrl)
console.log('vm.attachUrl === ' + vm.attachUrl)
vm._loadFile(vm.attachUrl)
vm.hlsPopup.hideLoading()
},
methods: {
_renderPage (num) {
this.pdfDoc.getPage(num).then((page) => {
let canvas = document.getElementById('the-canvas' + num)
let ctx = canvas.getContext('2d')
let dpr = window.devicePixelRatio || 1
let bsr = ctx.webkitBackingStorePixelRatio ||
ctx.mozBackingStorePixelRatio ||
ctx.msBackingStorePixelRatio ||
ctx.oBackingStorePixelRatio ||
ctx.backingStorePixelRatio || 1
let ratio = dpr / bsr
let viewport = page.getViewport(screen.availWidth / page.getViewport(1).width)
canvas.width = viewport.width * ratio
canvas.height = viewport.height * ratio
canvas.style.width = viewport.width + 'px'
canvas.style.height = viewport.height + 'px'
ctx.setTransform(ratio, 0, 0, ratio, 0, 0)
let renderContext = {
canvasContext: ctx,
viewport: viewport,
}
page.render(renderContext)
if (this.pages > num) {
this._renderPage(num + 1)
}
})
},
_loadFile (url) {
console.log('URL ==== ' + url)
PDFJS.getDocument(url).then((pdf) => {
this.pdfDoc = pdf
console.log('pdf ==== ' + pdf)
this.pages = this.pdfDoc.numPages
this.$nextTick(() => {
this._renderPage(1)
})
})
},
},
} }
</script> </script>
<style lang="less" rel="stylesheet"> <style lang="less" rel="stylesheet">
......
export default { export default {
city: { city: {
......
File added
<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no,width=device-width,viewport-fit=cover"><meta name=format-detection content="telephone=no"><meta name=format-detection content="email=no"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><script type=text/javascript src=./static/vuePlatform.js></script><script type=text/javascript src=./static/prototype.js></script><script type=text/javascript src=cordova.js></script><script type=text/javascript src="http://api.map.baidu.com/api?v=2.0&ak=o7fTnpVAGzXKN7SirV8xGU2xzWQS2NrI"></script><title>徐工融租</title><link href=./static/css/app.319a48f0ae278016467a36c7c8fdc1b9.css rel=stylesheet></head><body><div id=app-box></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.3f20fa93928dc721ea21.js></script><script type=text/javascript src=./static/js/app.edf254bec46da36c7032.js></script></body></html> <!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no,width=device-width,viewport-fit=cover"><meta name=format-detection content="telephone=no"><meta name=format-detection content="email=no"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><script type=text/javascript src=./static/vuePlatform.js></script><script type=text/javascript src=./static/prototype.js></script><script type=text/javascript src=cordova.js></script><script type=text/javascript src="http://api.map.baidu.com/api?v=2.0&ak=o7fTnpVAGzXKN7SirV8xGU2xzWQS2NrI"></script><title>徐工金服</title><link href=./static/css/app.c5a0a4712f1e7c4b252de740728ebea8.css rel=stylesheet></head><body><div id=app-box></div><script type=text/javascript src=./static/js/manifest.6a178e8d77c32e3c385d.js></script><script type=text/javascript src=./static/js/vendor.8e9b41cc6bccffe5885b.js></script><script type=text/javascript src=./static/js/app.8182be05992a1744e71e.js></script></body></html>
\ No newline at end of file \ No newline at end of file
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