Commit a444077b authored by linwenqing's avatar linwenqing

Merge branch 'fix-photo-upload' into test

parents 514025b4 0547e32c
;(function() {
let NODE_ENV = 'prod' // dev:开发环境 | test:测试环境 | prod:生产环境
let NODE_ENV = 'test' // dev:开发环境 | test:测试环境 | prod:生产环境
let ENV_VAR = null
let VERSION_NUMBER = '1.4.8' //版本号
//小程序是否审核通过,参数配置在ucenter库version表,对应版本号的is_audit设置为1,将显示学习视频
......
......@@ -138,7 +138,7 @@ let orderApiFun = function(vm){
/**
* 保存售后记录
*/
let saveCompleteData = async (params = {},orderId) => await vm.$u.post(prefix + vm.vuex_token+'/order/'+ orderId +'/maintain/saveMaintainInfoV2', params);
let saveCompleteData = async (params = {},orderId) => await vm.$u.post(prefix + vm.vuex_token+'/order/'+ orderId +'/maintain/saveMaintainInfoV3', params);
/**
* 保内工单完工
......
......@@ -9,7 +9,7 @@ const randomChar = function(l, url = "") {
tmp += x.charAt(Math.ceil(Math.random() * 100000000) % x.length);
}
return (
"file/" +
"scn/file/" +
url +
time.getTime() +
tmp
......
......@@ -6,7 +6,7 @@ export default {
data() {
return {
domain: 'https://upload-z2.qiniup.com', // 七牛上传域名地址
uptokenURL: globalUrl.systemUrl.apiUrl + '/wxh-cloud-rest/rest/qiniu/token', // 上传token地址
uptokenURL: globalUrl.systemUrl.apiUrl + '/wxh-cloud-rest/rest/qiniu/token/2', // 上传token地址
files:[], // 上传文件
fileMaps:[], // 上传文件返回对象
keys:[], // 七牛返回key
......
......@@ -13,7 +13,7 @@
</view>
<view class="upload-container">
<view class="img-container" v-for="(item, index) in imgList[key].desc" :key="index">
<image class="upload-img" @click="handleClick(type, index)" :src="imgs[index]" mode="widthFix">
<image class="upload-img" @click="handleClick(type, index)" :src="imgs[index]" mode="aspectFit">
</image>
<text class="img-desc">{{ item }}</text>
</view>
......@@ -230,6 +230,7 @@
.upload-img {
margin-top: 30rpx;
width: 100%;
height: 400rpx !important;
}
.two {
......
......@@ -924,6 +924,7 @@ export default {
maintainFields: this.handleSaveData(),
currentStep: this.list[this.tabIndex].panelFieldsName,
nextStep: this.list[this.tabIndex + 1].panelFieldsName,
version: 2
}
uni.showLoading({
title: '加载中',
......
......@@ -812,6 +812,7 @@ export default {
? this.dataValue[0] + ',' + this.dataValue[1]
: ''
data.url = this.errorSignUrl ? this.errorSignUrl : ''
data.version = 2
} else if (this.submitType === 'toFilish') {
// 去完工
if (this.order.categoryName != '充电桩') {
......
......@@ -274,9 +274,9 @@
const data = {
type: this.currentItemDate.type,
images: saveList,
fieldsName: this.currentItemDate.fieldName
fieldsName: this.currentItemDate.fieldName,
version: 2
}
console.log("data", data)
this.$u.api.saveImage(data,this.orderId).then((res) => {
if (res.code !== 200) console.log("保存图片异常",res.data.message)
})
......
......@@ -4,13 +4,13 @@ let baseOptions = {
baseUrl: '', // 接口请求地址,用于图片上传域名配置
fileUrl: '', //服务器本地上传文件地址
defaultUploadUrl: "api/common/v1/upload_image", // 服务器上传图片默认url
qiniuUploadUrl: globalUrl.systemUrl.apiUrl + '/wxh-cloud-rest/rest/qiniu/token',
qiniuUploadUrl: globalUrl.systemUrl.apiUrl + '/wxh-cloud-rest/rest/qiniu/token/2',
//设置请求头(如果使用报错跨域问题,可能是content-type请求类型和后台那边设置的不一致)
header: {
'content-type': 'application/json;charset=UTF-8'
},
// 请求超时时间(默认6000)
timeout: 6000,
timeout: 10000,
// 默认配置(可不写)
config: {
// 是否自动提示错误
......
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