|
| xqd
@@ -7,6 +7,7 @@ import setPrice from './draw/price.js'
|
|
|
|
|
|
import ContactModal from './draw/ContactModal.js'
|
|
|
import ProductModal from './draw/ProductModal.js'
|
|
|
+import SizeModal from './draw/SizeModal.js'
|
|
|
//import canvas from './libs/weapp-adapter.js'
|
|
|
|
|
|
var url = 'https://t6.9026.com/api/album/cat?parent_id=0&store_id=1'//初始顶级目录url
|
|
| xqd
@@ -846,26 +847,28 @@ wx.onTouchStart(((e) => {
|
|
|
&& y >= DetailbtnArea[4].startY
|
|
|
&& y <= DetailbtnArea[4].endY) {
|
|
|
attrFlag = true
|
|
|
- Buttonstatus = false
|
|
|
- let img = new wx.createImage()
|
|
|
- img.src = GoodsDetail.upload_img
|
|
|
- img.onload = function () {
|
|
|
- let ratio = img.width / img.height
|
|
|
- context.drawImage(img, (screenWidth - (screenHeight - 100) * ratio), 120, (screenHeight - 100) * 2 * ratio, (screenHeight - 100) * 2)
|
|
|
- context.fillStyle = '#F5F5F5'
|
|
|
- context.fillRect((screenWidth - (screenHeight - 100) * ratio), 60, (screenHeight - 100) * 2 * ratio, 60)
|
|
|
- context.fillStyle = '#FFA500'
|
|
|
- context.fillRect((screenWidth - (screenHeight - 100) * ratio), 118, (screenHeight - 100) * ratio, 2)
|
|
|
- context.fillStyle = '#696969'
|
|
|
- context.font = '30px Arial'
|
|
|
- context.fillText('安装图', screenWidth - 280, 100)
|
|
|
- context.fillText('尺寸图', screenWidth + 190, 100)
|
|
|
- let closeImg = wx.createImage()
|
|
|
- closeImg.src = 'images/close.png'
|
|
|
- closeImg.onload = function () {
|
|
|
- context.drawImage(closeImg, screenWidth + (screenHeight - 100) * ratio - 60, 60, 60, 60)
|
|
|
- }
|
|
|
- }
|
|
|
+ if (Buttonstatus == true) Buttonstatus = false
|
|
|
+ else Buttonstatus = true
|
|
|
+ // let img = new wx.createImage()
|
|
|
+ // img.src = GoodsDetail.upload_img
|
|
|
+ // img.onload = function () {
|
|
|
+ // let ratio = img.width / img.height
|
|
|
+ // context.drawImage(img, (screenWidth - (screenHeight - 100) * ratio), 120, (screenHeight - 100) * 2 * ratio, (screenHeight - 100) * 2)
|
|
|
+ // context.fillStyle = '#F5F5F5'
|
|
|
+ // context.fillRect((screenWidth - (screenHeight - 100) * ratio), 60, (screenHeight - 100) * 2 * ratio, 60)
|
|
|
+ // context.fillStyle = '#FFA500'
|
|
|
+ // context.fillRect((screenWidth - (screenHeight - 100) * ratio), 118, (screenHeight - 100) * ratio, 2)
|
|
|
+ // context.fillStyle = '#696969'
|
|
|
+ // context.font = '30px Arial'
|
|
|
+ // context.fillText('安装图', screenWidth - 280, 100)
|
|
|
+ // context.fillText('尺寸图', screenWidth + 190, 100)
|
|
|
+ // let closeImg = wx.createImage()
|
|
|
+ // closeImg.src = 'images/close.png'
|
|
|
+ // closeImg.onload = function () {
|
|
|
+ // context.drawImage(closeImg, screenWidth + (screenHeight - 100) * ratio - 60, 60, 60, 60)
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ new SizeModal(context, GoodsDetail).draw()
|
|
|
}
|
|
|
//上一张
|
|
|
if (x >= DetailbtnArea[5].startX
|