Browse Source

修改创建货源功能,改为全屏页面打开

pull/1/head
徐飞洋 3 months ago
parent
commit
4d562ca9b5
  1. 2
      pages/create-supply/index.js
  2. 15
      pages/seller/index.js

2
pages/create-supply/index.js

@ -1,5 +1,7 @@
// pages/create-supply/index.js
// 引入API工具
//创建新货源页面
const API = require('../../utils/api.js');
Page({

15
pages/seller/index.js

@ -2561,9 +2561,9 @@ Page({
}, 500)
},
// 显示添加货源弹窗
// 导航到全屏创建货源页面
showAddSupply(e) {
console.log('点击创建新货源按钮');
console.log('点击创建新货源按钮,导航到全屏页面');
// 阻止事件冒泡,防止触发父元素的点击事件
if (e && e.stopPropagation) {
@ -2573,15 +2573,10 @@ Page({
// 从本地存储加载之前保存的货源数据
const savedSupply = wx.getStorageSync('newSupplyDraft') || { name: '', price: '', minOrder: '', yolk: '', spec: '', imageUrls: [] };
// 直接显示创建货源弹窗,无需登录验证
this.setData({
showImagePreview: false,
showModal: true,
newSupply: savedSupply
// 导航到新的全屏创建货源页面
wx.navigateTo({
url: '/pages/create-supply/index'
});
// 锁定页面滚动
this.disablePageScroll();
},
// 隐藏弹窗

Loading…
Cancel
Save