Commit ce49bcff authored by Damon's avatar Damon

数据错乱问题

parent 6cde5207
......@@ -2,7 +2,7 @@
<view class="backView">
<view class="ph-pr-arr" v-for="(dataItem, index) in list" :key="index">
<template v-if="dataItem.data.length > 0">
<view class="topTitle"><text class="topFont">{{ dataItem.title }}</text><text>(不同系统对应不同模板)</text></view>
<view class="topTitle"><text class="topFont">{{ dataItem.title }}</text><text>(不同系统对应不同水印)</text></view>
<view class="ph-pr-content">
<view v-for="(item,ikey) in dataItem.data"
:class="param[dataItem.type] === item.id ? 'select-item-view' : 'item-view'"
......@@ -111,13 +111,12 @@
//选择 点击
itemClick: function(type, item, ikey) {
switch (type) {
case 'classifyId':
this.param = {
classifyId: item.id,
systemId: '',
brandId: ''
brandId: '',
}
this.selectedAll = false
this.systemList = this.classifyList[ikey].child
......
......@@ -111,14 +111,14 @@
const currentItem = photo.currentItem
currentItem.imageList.unshift(path)
// 从缓存数据中找到修改对象并替换
const data = cache.getCache(currentItem.system_id)
const data = cache.getCache(photo.product.systemId)
data.result.forEach(v => {
const index = v.list.findIndex(item => item._id === currentItem._id)
if (index > -1) {
v.list[index] = currentItem
}
})
cache.setCache(currentItem.system_id, data)
cache.setCache(photo.product.systemId, data)
},
saveLocal(path){
return new Promise((resolve,reject)=>{
......
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