Commit 3a0fdf84 authored by Morson's avatar Morson

Merge branch 'dev' of https://git.banshouhui.com/lijundan/self-support into dev

parents 26a9c377 abb9f771
...@@ -11,6 +11,6 @@ const UNI_APP = { ...@@ -11,6 +11,6 @@ const UNI_APP = {
qn_base_url: 'https://qn-static.banshouhui.com/self-support/', qn_base_url: 'https://qn-static.banshouhui.com/self-support/',
qn_asset_url: 'http://deudn.c.pp.cc/', qn_asset_url: 'http://deudn.c.pp.cc/',
argoDebugMode: 1, argoDebugMode: 1,
version: 'v1.3.6' version: 'v1.3.9'
} }
module.exports = UNI_APP; module.exports = UNI_APP;
(function () { (function () {
let NODE_ENV = 'dev'; // dev:开发环境 | test:测试环境 | prod:生产环境 let NODE_ENV = 'dev'; // dev:开发环境 | test:测试环境 | prod:生产环境
let ENV_VAR = null; let ENV_VAR = null;
let VERSION_NUMBER = '1.3.6';//版本号 let VERSION_NUMBER = '1.3.9';//版本号
//小程序是否审核通过,参数配置在ucenter库version表,对应版本号的is_audit设置为1,将显示学习视频 //小程序是否审核通过,参数配置在ucenter库version表,对应版本号的is_audit设置为1,将显示学习视频
if (process.env.NODE_ENV === "development") { if (process.env.NODE_ENV === "development") {
if (NODE_ENV === 'dev') { if (NODE_ENV === 'dev') {
ENV_VAR = require('./.env.dev.js'); ENV_VAR = require('./.env.dev.js');
......
...@@ -10,7 +10,7 @@ const UNI_APP = { ...@@ -10,7 +10,7 @@ const UNI_APP = {
qn_base_url: 'https://qn-static.banshouhui.com/self-support/', qn_base_url: 'https://qn-static.banshouhui.com/self-support/',
qn_asset_url: 'https://qn-static.banshouhui.com', qn_asset_url: 'https://qn-static.banshouhui.com',
argoDebugMode: 0, argoDebugMode: 0,
version: 'v1.3.6' version: 'v1.3.9'
} }
module.exports = UNI_APP; module.exports = UNI_APP;
...@@ -10,6 +10,6 @@ const UNI_APP = { ...@@ -10,6 +10,6 @@ const UNI_APP = {
qn_base_url: 'https://qn-static.banshouhui.com/self-support/', qn_base_url: 'https://qn-static.banshouhui.com/self-support/',
qn_asset_url: 'https://qn-static.banshouhui.com', qn_asset_url: 'https://qn-static.banshouhui.com',
argoDebugMode: 1, argoDebugMode: 1,
version: 'v1.3.6' version: 'v1.3.9'
} }
module.exports = UNI_APP; module.exports = UNI_APP;
...@@ -567,6 +567,8 @@ ...@@ -567,6 +567,8 @@
// 提交订单 // 提交订单
orderFinish(){ orderFinish(){
const param = this.handleSaveData() const param = this.handleSaveData()
// 完工事件埋点
getApp().track('order_finish', {id: this.vuex_user.id, mobile: this.vuex_user.mobile, orderId: Number(this.orderId)})
this.$u.api.saveCompleteData(param,this.orderId).then((res)=>{ this.$u.api.saveCompleteData(param,this.orderId).then((res)=>{
if (res.code == 200) {//完工项信息保存成功再次完工工单 if (res.code == 200) {//完工项信息保存成功再次完工工单
if(this.inGuaranteePeriod === 'Y'){ if(this.inGuaranteePeriod === 'Y'){
......
...@@ -162,6 +162,10 @@ ...@@ -162,6 +162,10 @@
let dataList = [] let dataList = []
var flag = false; var flag = false;
res.data.forEach(item=>{ res.data.forEach(item=>{
item.key = item.orderImages ? item.orderImages.map(v => {
const key = v.split('com/')
return key[1]
}) : []
if(dataList.length===0 ){ if(dataList.length===0 ){
var dataItem = {type:'',list:[]} var dataItem = {type:'',list:[]}
dataItem.type = item.type dataItem.type = item.type
...@@ -246,10 +250,9 @@ ...@@ -246,10 +250,9 @@
}, },
async closeTake(img) { async closeTake(img) {
if(img !== undefined){ if(img !== undefined){
// 复制一份 用于保存
if (!this.currentItemDate.orderImages) this.currentItemDate.orderImages = [] if (!this.currentItemDate.orderImages) this.currentItemDate.orderImages = []
let saveList = this.currentItemDate.orderImages.slice(0) // 真实地址key
let saveList = this.currentItemDate.key
const files = img.map(v => v.path) const files = img.map(v => v.path)
const value = await this.saveToTask(files) const value = await this.saveToTask(files)
value.forEach(item =>{ value.forEach(item =>{
...@@ -258,19 +261,16 @@ ...@@ -258,19 +261,16 @@
// step1 添加缓存图片 到显示 // step1 添加缓存图片 到显示
this.currentItemDate.orderImages.push(item.path) this.currentItemDate.orderImages.push(item.path)
}) })
// step2 保存图片 // // step2 保存图片
var data = { const data = {
type: this.currentItemDate.type, type: this.currentItemDate.type,
images: saveList, images: saveList,
fieldsName: this.currentItemDate.fieldName fieldsName: this.currentItemDate.fieldName
} }
console.log("data", data) console.log("data", data)
this.$u.api.saveImage(data,this.orderId).then((res) => { this.$u.api.saveImage(data,this.orderId).then((res) => {
if (res.code == 200) { if (res.code !== 200) console.log("保存图片异常",res.data.message)
} else { })
console.log("保存图片异常",res.data.message)
}
});
} }
this.takeStatus = false this.takeStatus = false
}, },
......
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