|
|
@@ -976,7 +976,7 @@ export class CanvasPhotoEditor {
|
|
|
...imgItem,
|
|
|
...pagePhotos.item[itemIndex],
|
|
|
}
|
|
|
- console.log('this.dragPageData', imgItem)
|
|
|
+ console.log('this.s', imgItem)
|
|
|
this.renderSinglePhoto(ctx, pageX, itemY, layout, pagePhotos.item[itemIndex])
|
|
|
})
|
|
|
})
|
|
|
@@ -1012,7 +1012,6 @@ export class CanvasPhotoEditor {
|
|
|
*/
|
|
|
renderSinglePhoto(ctx, pageX, itemY, layout, photo = {}) {
|
|
|
// if (!photo) return
|
|
|
- console.log('this.dragPageData', ctx, pageX, itemY, layout, photo)
|
|
|
|
|
|
let img = this.imgCache.get(photo.id)
|
|
|
if (!img && photo && photo.url) {
|
|
|
@@ -1058,6 +1057,7 @@ export class CanvasPhotoEditor {
|
|
|
// 4. 恢复上下文(裁剪失效)
|
|
|
// 图片未加载完成则跳过
|
|
|
const jxx = pageX + layout.x;
|
|
|
+ console.log('this.dragPageData', img, photo)
|
|
|
if (!img || !img.complete || img.width === 0 || img.height === 0) {//无图
|
|
|
|
|
|
} else {
|
|
|
@@ -1187,6 +1187,7 @@ export class CanvasPhotoEditor {
|
|
|
newPages.forEach((ele, index) => {
|
|
|
if(index == this.selectedPageIndex){
|
|
|
ele.list[this.selectedPageItem.index] = null
|
|
|
+ ele.item[this.selectedPageItem.index] = null
|
|
|
// ele.list.splice(this.selectedPageItem.index, 1)
|
|
|
}
|
|
|
})
|