Commit aff410aa authored by 高宇's avatar 高宇

调整预览图片初始大小

parent e272a38c
...@@ -4,6 +4,8 @@ ENV = 'development' ...@@ -4,6 +4,8 @@ ENV = 'development'
# base api # base api
VUE_APP_BASE_API = '/dev-api' VUE_APP_BASE_API = '/dev-api'
// 图片路径
VUE_APP_BASE_IMG_API = 'http://49.232.167.247:20010/eduServer/'
# workFlow链接地址 # workFlow链接地址
# VUE_APP_WORKFLOW = 'http://106.2.17.219:10180' # VUE_APP_WORKFLOW = 'http://106.2.17.219:10180'
VUE_APP_WORKFLOW = '/workFlow' VUE_APP_WORKFLOW = '/workFlow'
......
...@@ -4,6 +4,8 @@ ENV = 'production' ...@@ -4,6 +4,8 @@ ENV = 'production'
# 私有环境 # 私有环境
# base api # base api
#VUE_APP_BASE_API = 'http://zt.51newsoftware.com:10184' #VUE_APP_BASE_API = 'http://zt.51newsoftware.com:10184'
// 图片路径
VUE_APP_BASE_IMG_API = 'http://49.232.167.247:20010/eduServer/'
# workFlow链接地址 # workFlow链接地址
#VUE_APP_WORKFLOW = 'http://zt.51newsoftware.com:10184/workFlow' #VUE_APP_WORKFLOW = 'http://zt.51newsoftware.com:10184/workFlow'
# internal链接地址 # internal链接地址
......
...@@ -4,6 +4,8 @@ ENV = 'test' ...@@ -4,6 +4,8 @@ ENV = 'test'
# 测试环境 # 测试环境
# base api # base api
VUE_APP_BASE_API = 'http://192.144.239.97:20070/' VUE_APP_BASE_API = 'http://192.144.239.97:20070/'
// 图片路径
VUE_APP_BASE_IMG_API = 'http://49.232.167.247:20010/eduServer/'
#workFlow链接地址 #workFlow链接地址
VUE_APP_WORKFLOW = 'http://zt.91isoft.com:10184/workFlow' VUE_APP_WORKFLOW = 'http://zt.91isoft.com:10184/workFlow'
#internal链接地址 #internal链接地址
......
...@@ -617,17 +617,23 @@ export default { ...@@ -617,17 +617,23 @@ export default {
approveStatus: '0' approveStatus: '0'
}, },
imgList: [ imgList: [
{ // {
businessId: 1, // businessId: 2,
url: 'http://49.232.167.247:20010/eduServer/11/20240301/CD7D683B1CF24D8DBD933F0C60D5D8ED.png', // url: 'http://49.232.167.247:20010/eduServer/123/20240306/1790EB2DF6A84945B7E09EF4CACE2DF5.jpg',
srcList: ['http://49.232.167.247:20010/eduServer/11/20240301/CD7D683B1CF24D8DBD933F0C60D5D8ED.png'] // srcList: ['http://49.232.167.247:20010/eduServer/123/20240306/1790EB2DF6A84945B7E09EF4CACE2DF5.jpg']
} // },
// {
// businessId: 3,
// url: 'http://49.232.167.247:20010/eduServer/123/20240306/1790EB2DF6A84945B7E09EF4CACE2DF5.jpg',
// srcList: ['http://49.232.167.247:20010/eduServer/123/20240306/1790EB2DF6A84945B7E09EF4CACE2DF5.jpg']
// }
// { // {
// businessId: 2, // businessId: 2,
// url: require('@/assets/image/cadTwo.png'), // url: require('@/assets/image/cadTwo.png'),
// srcList: [require('@/assets/image/cadTwo.png')] // srcList: [require('@/assets/image/cadTwo.png')]
// } // }
], ],
imageBaseUrl: process.env.VUE_APP_BASE_IMG_API,
imgUrlForm: {}, imgUrlForm: {},
activeName: 'first', activeName: 'first',
initialImgPreviewIndex: 0, // 预览打开看到的图片下标 initialImgPreviewIndex: 0, // 预览打开看到的图片下标
...@@ -756,7 +762,6 @@ export default { ...@@ -756,7 +762,6 @@ export default {
this.getJcCode() this.getJcCode()
}, },
methods: { methods: {
/** 清空表格里的数据*/ /** 清空表格里的数据*/
clearForm(index) { clearForm(index) {
this.recode1[index].recordData = undefined this.recode1[index].recordData = undefined
...@@ -887,6 +892,15 @@ export default { ...@@ -887,6 +892,15 @@ export default {
getRecordInfo(id) { getRecordInfo(id) {
getIncomeInspectInfo(id).then(response => { getIncomeInspectInfo(id).then(response => {
console.log(response) console.log(response)
if (response.data.transportOSSVoList && response.data.transportOSSVoList !== '' && response.data.transportOSSVoList.length > 0 ) {
response.data.transportOSSVoList.forEach(item => {
item.url =this.imageBaseUrl + item.url
console.log('url',item.url)
item.srcList = []
item.srcList.push(item.url)
})
this.imgList = response.data.transportOSSVoList
}
this.inspectInfoList.businessId = id this.inspectInfoList.businessId = id
this.inspectInfoList.jcPn = response.data.jcPn this.inspectInfoList.jcPn = response.data.jcPn
this.inspectInfoList.jcCj = response.data.jcCj this.inspectInfoList.jcCj = response.data.jcCj
...@@ -1406,17 +1420,34 @@ export default { ...@@ -1406,17 +1420,34 @@ export default {
limitData: undefined limitData: undefined
} }
}, },
/**
* @description: 获取拍照后的图片id集合
* @author: gaoyu
* @param:
* @return: ossIdlist
**/
getOssIdList() {
let ossIdList = []
if (this.imgList && this.imgList.length > 0 && this.imgList !== '') {
this.imgList.forEach(item => {
ossIdList.push(item.businessId)
})
}
return ossIdList
},
submitControl() { submitControl() {
this.inspectJbAl2o3List.standardOneData = this.getStringByArray(this.recode1) this.inspectJbAl2o3List.standardOneData = this.getStringByArray(this.recode1)
this.inspectJbAl2o3List.standardTwoData = this.getStringByArray(this.recode2) this.inspectJbAl2o3List.standardTwoData = this.getStringByArray(this.recode2)
this.inspectJbAl2o3List.limitData = this.getStringByArray(this.recode3) this.inspectJbAl2o3List.limitData = this.getStringByArray(this.recode3)
this.inspectInfoList.approveStatus = '0' this.inspectInfoList.approveStatus = '0'
// const businessId = this.$route.query.businessId // const businessId = this.$route.query.businessId
let ossIdList = this.getOssIdList()
const obj = { const obj = {
incomeInspectInfo: this.inspectInfoList, incomeInspectInfo: this.inspectInfoList,
incomeInspectJbAl2o3: this.inspectJbAl2o3List incomeInspectJbAl2o3: this.inspectJbAl2o3List,
ossIdList: ossIdList
} }
console.log(obj) console.log('要保持的数据',obj)
addIncomeInspectInfo(obj).then(response => { addIncomeInspectInfo(obj).then(response => {
console.log('re', response) console.log('re', response)
if (response.code === 200) { if (response.code === 200) {
...@@ -1432,9 +1463,11 @@ export default { ...@@ -1432,9 +1463,11 @@ export default {
this.inspectJbAl2o3List.standardTwoData = this.getStringByArray(this.recode2) this.inspectJbAl2o3List.standardTwoData = this.getStringByArray(this.recode2)
this.inspectJbAl2o3List.limitData = this.getStringByArray(this.recode3) this.inspectJbAl2o3List.limitData = this.getStringByArray(this.recode3)
this.inspectInfoList.approveStatus = '1' this.inspectInfoList.approveStatus = '1'
let ossIdList = this.getOssIdList()
var obj = { var obj = {
incomeInspectInfo: this.inspectInfoList, incomeInspectInfo: this.inspectInfoList,
incomeInspectJbAl2o3: this.inspectJbAl2o3List incomeInspectJbAl2o3: this.inspectJbAl2o3List,
ossIdList: ossIdList
} }
console.log('obj', obj) console.log('obj', obj)
addIncomeInspectInfo(obj).then(response => { addIncomeInspectInfo(obj).then(response => {
......
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