Browse Source

first commit

LiuShu_0203 2 months ago
commit
2ec39ed84b
83 changed files with 4267 additions and 0 deletions
  1. 25 0
      .gitignore
  2. 34 0
      app.js
  3. 121 0
      app.json
  4. 11 0
      app.wxss
  5. BIN
      image/gouwuche.png
  6. BIN
      image/gouwuche_1.png
  7. BIN
      image/me.png
  8. BIN
      image/my_1.png
  9. BIN
      image/shouye.png
  10. BIN
      image/shouye_1.png
  11. BIN
      image/tuangou.png
  12. BIN
      image/tuangou_1.png
  13. 16 0
      package-lock.json
  14. 6 0
      package.json
  15. 96 0
      pages/groupbuying/groupbuying.js
  16. 4 0
      pages/groupbuying/groupbuying.json
  17. 37 0
      pages/groupbuying/groupbuying.wxml
  18. 129 0
      pages/groupbuying/groupbuying.wxss
  19. 106 0
      pages/index/index.js
  20. 4 0
      pages/index/index.json
  21. 58 0
      pages/index/index.wxml
  22. 92 0
      pages/index/index.wxss
  23. 67 0
      pages/login/login.js
  24. 4 0
      pages/login/login.json
  25. 32 0
      pages/login/login.wxml
  26. 73 0
      pages/login/login.wxss
  27. 123 0
      pages/me/me.js
  28. 4 0
      pages/me/me.json
  29. 65 0
      pages/me/me.wxml
  30. 159 0
      pages/me/me.wxss
  31. 102 0
      pages/shoppingcart/shoppingcart.js
  32. 4 0
      pages/shoppingcart/shoppingcart.json
  33. 54 0
      pages/shoppingcart/shoppingcart.wxml
  34. 152 0
      pages/shoppingcart/shoppingcart.wxss
  35. 42 0
      project.config.json
  36. 23 0
      project.private.config.json
  37. 7 0
      sitemap.json
  38. 60 0
      subpackages/addresslist/addresslist.js
  39. 4 0
      subpackages/addresslist/addresslist.json
  40. 29 0
      subpackages/addresslist/addresslist.wxml
  41. 114 0
      subpackages/addresslist/addresslist.wxss
  42. 66 0
      subpackages/changename/changename.js
  43. 4 0
      subpackages/changename/changename.json
  44. 15 0
      subpackages/changename/changename.wxml
  45. 53 0
      subpackages/changename/changename.wxss
  46. 66 0
      subpackages/changephone/changephone.js
  47. 4 0
      subpackages/changephone/changephone.json
  48. 16 0
      subpackages/changephone/changephone.wxml
  49. 53 0
      subpackages/changephone/changephone.wxss
  50. 88 0
      subpackages/dahome/dahome.js
  51. 4 0
      subpackages/dahome/dahome.json
  52. 39 0
      subpackages/dahome/dahome.wxml
  53. 143 0
      subpackages/dahome/dahome.wxss
  54. 82 0
      subpackages/imghome/imghome.js
  55. 4 0
      subpackages/imghome/imghome.json
  56. 35 0
      subpackages/imghome/imghome.wxml
  57. 126 0
      subpackages/imghome/imghome.wxss
  58. 50 0
      subpackages/logoff/logoff.js
  59. 4 0
      subpackages/logoff/logoff.json
  60. 32 0
      subpackages/logoff/logoff.wxml
  61. 55 0
      subpackages/logoff/logoff.wxss
  62. 145 0
      subpackages/order/order.js
  63. 4 0
      subpackages/order/order.json
  64. 48 0
      subpackages/order/order.wxml
  65. 159 0
      subpackages/order/order.wxss
  66. 36 0
      subpackages/orderdetails/orderdetails.js
  67. 4 0
      subpackages/orderdetails/orderdetails.json
  68. 66 0
      subpackages/orderdetails/orderdetails.wxml
  69. 122 0
      subpackages/orderdetails/orderdetails.wxss
  70. 63 0
      subpackages/productdetails/productdetails.js
  71. 4 0
      subpackages/productdetails/productdetails.json
  72. 64 0
      subpackages/productdetails/productdetails.wxml
  73. 157 0
      subpackages/productdetails/productdetails.wxss
  74. 124 0
      subpackages/purchasehistory/purchasehistory.js
  75. 4 0
      subpackages/purchasehistory/purchasehistory.json
  76. 31 0
      subpackages/purchasehistory/purchasehistory.wxml
  77. 111 0
      subpackages/purchasehistory/purchasehistory.wxss
  78. 87 0
      subpackages/submitorder/submitorder.js
  79. 4 0
      subpackages/submitorder/submitorder.json
  80. 51 0
      subpackages/submitorder/submitorder.wxml
  81. 155 0
      subpackages/submitorder/submitorder.wxss
  82. 13 0
      utils/cloudbase.js
  83. 19 0
      utils/util.js

+ 25 - 0
.gitignore

@@ -0,0 +1,25 @@
+# 忽略 node_modules 依赖目录
+node_modules/
+miniprogram_npm/
+
+# 编译产物
+dist/
+build/
+*.log
+
+# VSCode 编辑器配置
+.vscode/
+.idea/
+
+# 临时文件、系统文件
+.DS_Store
+Thumbs.db
+
+# Mac/Linux 临时文件
+*.swp
+*.tmp
+
+# 其他缓存
+*.bak
+*.log
+*.tgz

+ 34 - 0
app.js

@@ -0,0 +1,34 @@
+// app.js
+App({
+  globalData: {
+    isLoggedIn: false, // 登录状态
+  },
+  // 检查登录状态并弹出提示框
+  checkLoginStatus() {
+    const isLoggedIn = wx.getStorageSync('isLoggedIn') || false;
+    if (!isLoggedIn) {
+      wx.showModal({
+        title: '绑定手机号',
+        content: '防止账号丢失以及方便找回,建议您绑定手机号码',
+        confirmText: '立即绑定',
+        cancelText: '取消',
+        success: (res) => {
+          if (res.confirm) {
+            // 跳转到绑定手机号页面
+            wx.navigateTo({
+              url: '/pages/login/login',
+            });
+          }
+        },
+      });
+    }
+    return isLoggedIn;
+  },
+  
+  onLaunch() {
+    // wx.cloud.init({
+    //   env: 'cloud1-6g98iw7i28b01747',
+    //   traceUser: true
+    // })
+  }
+})

+ 121 - 0
app.json

@@ -0,0 +1,121 @@
+{
+  "usingComponents": {
+    "van-button": "vant-weapp/button",
+    "van-stepper": "vant-weapp/stepper/index",
+    "van-dialog": "vant-weapp/dialog/index"
+  },
+  "pages": [
+    "pages/index/index",
+    "pages/groupbuying/groupbuying",
+    "pages/shoppingcart/shoppingcart",
+    "pages/me/me",
+    "pages/login/login"
+  ],
+  "window": {
+    "navigationBarTextStyle": "black",
+    "navigationBarTitleText": "红孩儿智慧教育",
+    "navigationBarBackgroundColor": "#ffffff"
+  },
+  "tabBar": {
+    "custom": false,
+    "selectedColor": "#409eff",
+    "list": [
+      {
+        "pagePath": "pages/index/index",
+        "text": "教学",
+        "iconPath": "image/shouye.png",
+        "selectedIconPath": "image/shouye_1.png"
+      },
+      {
+        "pagePath": "pages/groupbuying/groupbuying",
+        "text": "团购",
+        "iconPath": "image/tuangou.png",
+        "selectedIconPath": "image/tuangou_1.png"
+      },
+      {
+        "pagePath": "pages/shoppingcart/shoppingcart",
+        "text": "购物车",
+        "iconPath": "image/gouwuche.png",
+        "selectedIconPath": "image/gouwuche_1.png"
+      },
+      {
+        "pagePath": "pages/me/me",
+        "text": "我的",
+        "iconPath": "image/me.png",
+        "selectedIconPath": "image/my_1.png"
+      }
+    ]
+  },
+  "subPackages": [
+    {
+      "root": "subpackages/dahome",
+      "pages": [
+        "dahome"
+      ]
+    },
+    {
+      "root": "subpackages/imghome",
+      "pages": [
+        "imghome"
+      ]
+    },
+    {
+      "root": "subpackages/purchasehistory",
+      "pages": [
+        "purchasehistory"
+      ]
+    },
+    {
+      "root": "subpackages/logoff",
+      "pages": [
+        "logoff"
+      ]
+    },
+    {
+      "root": "subpackages/order",
+      "pages": [
+        "order"
+      ]
+    },
+    {
+      "root": "subpackages/productdetails",
+      "pages": [
+        "productdetails"
+      ]
+    },
+    {
+      "root": "subpackages/submitorder",
+      "pages": [
+        "submitorder"
+      ]
+    },
+    {
+      "root": "subpackages/addresslist",
+      "pages": [
+        "addresslist"
+      ]
+    },
+    {
+      "root": "subpackages/orderdetails",
+      "pages": [
+        "orderdetails"
+      ]
+    },
+    {
+      "root": "subpackages/changephone",
+      "pages": [
+        "changephone"
+      ]
+    },
+    {
+      "root": "subpackages/changename",
+      "pages": [
+        "changename"
+      ]
+    }
+  ],
+  "style": "v2",
+  "componentFramework": "glass-easel",
+  "sitemapLocation": "sitemap.json",
+  "lazyCodeLoading": "requiredComponents"
+}

+ 11 - 0
app.wxss

@@ -0,0 +1,11 @@
+/**app.wxss**/
+.container {
+  height: calc(100vh - 40rpx);
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  /* justify-content: space-between; */
+  padding: 200rpx 0;
+  box-sizing: border-box;
+  background: #f5f5f5;
+} 

BIN
image/gouwuche.png


BIN
image/gouwuche_1.png


BIN
image/me.png


BIN
image/my_1.png


BIN
image/shouye.png


BIN
image/shouye_1.png


BIN
image/tuangou.png


BIN
image/tuangou_1.png


+ 16 - 0
package-lock.json

@@ -0,0 +1,16 @@
+{
+  "requires": true,
+  "lockfileVersion": 1,
+  "dependencies": {
+    "@cloudbase/wx-cloud-client-sdk": {
+      "version": "1.6.1",
+      "resolved": "https://registry.npmmirror.com/@cloudbase/wx-cloud-client-sdk/-/wx-cloud-client-sdk-1.6.1.tgz",
+      "integrity": "sha512-TeLhz+LMlTe1bZiCbwflU2nXX4FHXnLk1ojbrOfY9ki1gO1gYll9Snl2g3zBhiTGye/OfhzBEDCwVhGxzOxs4Q=="
+    },
+    "vant-weapp": {
+      "version": "0.5.29",
+      "resolved": "https://registry.npmmirror.com/vant-weapp/-/vant-weapp-0.5.29.tgz",
+      "integrity": "sha512-RMc0Ga914XFwspw2WuOMU8bOHlIkua8X1DoQ/KPnGQzjwT1uEL4S7W186EmaHF1wN2krB9BVd0LdRRt39dGh6Q=="
+    }
+  }
+}

+ 6 - 0
package.json

@@ -0,0 +1,6 @@
+{
+  "dependencies": {
+    "@cloudbase/wx-cloud-client-sdk": "^1.6.1",
+    "vant-weapp": "^0.5.29"
+  }
+}

+ 96 - 0
pages/groupbuying/groupbuying.js

@@ -0,0 +1,96 @@
+Page({
+  data: {
+    categoriesindex: 1,
+    categories: [
+      {
+        title: '全部',
+        type: 1,
+      },{
+        title: '益智玩具',
+        type: 2,
+      },{
+        title: '绘本图书',
+        type: 3,
+      },{
+        title: '文具用品',
+        type: 4,
+      },{
+        title: '健康零食',
+        type: 5,
+      }
+    ],
+    goods: [
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '儿童大颗粒积木 安全无毒 益智玩具',
+        price: '68.00',
+        originalPrice: '88.00',
+        sold: 256
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '幼儿启蒙绘本 10册套装',
+        price: '68.00',
+        originalPrice: '88.00',
+        sold: 256
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '防摔儿童保温水杯 350ml',
+        price: '68.00',
+        originalPrice: '88.00',
+        sold: 256
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '可水洗儿童彩笔24色套装',
+        price: '68.00',
+        originalPrice: '88.00',
+        sold: 256
+      }
+    ],
+    souimg: '',
+    gouwucimg: '',
+  },
+  onLoad(options) {
+    // const title = options.title ? decodeURIComponent(options.title) : '商品列表';
+    // this.setData({ title });
+    // wx.setNavigationBarTitle({ title });
+
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/gouwuc_img.png'
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        souimg: tempFilePaths[0],
+        gouwucimg: tempFilePaths[1]
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+  tabcategories(e) {
+    const type = e.currentTarget.dataset.type;
+    this.setData({
+      categoriesindex: type
+    });
+  },
+
+  navigateToDetail(e) {
+    const index = e.currentTarget.dataset.index;
+    const item = this.data.goods[index];
+    wx.navigateTo({
+      url: '/subpackages/productdetails/productdetails?data=' + encodeURIComponent(JSON.stringify(item))
+    });
+
+    console.log('走进来了');
+  }
+});

+ 4 - 0
pages/groupbuying/groupbuying.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "团购专区"
+}

+ 37 - 0
pages/groupbuying/groupbuying.wxml

@@ -0,0 +1,37 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="goodslist_boxs">
+    <view class="search-bar">
+      <input class="search-input" placeholder="搜索商品" />
+      <image class="search-icon" src="{{souimg}}" />
+    </view>
+    <view class="title_1">商品分类</view>
+    <view class="category-tabs">
+      <view wx:for="{{categories}}" wx:key="index">
+        <view class="category-tab {{item.type === categoriesindex ? 'active' : ''}}" bindtap="tabcategories" data-type="{{item.type}}">{{item.title}}</view>
+      </view>
+    </view>
+    <view class="goods-list">
+      <block wx:for="{{goods}}" wx:key="index">
+        <view class="goods-item" bindtap="navigateToDetail" data-index="{{index}}">
+          <image class="goods-image" src="{{item.image}}" mode="aspectFill"></image>
+          <view class="goods-info">
+            <view class="goods-title">{{item.title}}</view>
+            <view class="goods-price">
+              <text>¥{{item.price}}</text>
+              <text class="goods-status">已拼 {{item.sold}}件</text>
+            </view>
+            <view class="original-price">¥{{item.originalPrice}}</view>
+            <view class="gw_boxs">
+              <view class="gw_imgboxs">
+                <image style="width: 55rpx;height: 55rpx;padding-top: 6rpx;" src="{{gouwucimg}}" />
+              </view>
+              <view class="gw_button">
+                <button class="buy-button">立即购买</button>
+              </view>
+            </view>
+          </view>
+        </view>
+      </block>
+    </view>
+  </view>
+</view>

+ 129 - 0
pages/groupbuying/groupbuying.wxss

@@ -0,0 +1,129 @@
+.goodslist_boxs {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+}
+
+.search-bar {
+  width: calc(100% - 50rpx);
+  position: relative;
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  padding-right: 60rpx;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.title_1 {
+  font-size: 38rpx;
+  font-weight: bold;
+  color: #333333;
+  margin: 20rpx 0;
+}
+
+.category-tabs {
+  display: flex;
+  justify-content: space-between;
+  margin-bottom: 20rpx;
+}
+
+.category-tab {
+  padding: 13rpx 20rpx;
+  font-size: 26rpx;
+  color: #666;
+  border-radius: 25rpx;
+}
+
+.category-tab.active {
+  color: #409eff;
+  background: #ecf5ff;
+  border: 1rpx solid #d9ecff;
+}
+
+.goods-list {
+  display: flex;
+  flex-wrap: wrap;
+  gap: 20rpx;
+}
+
+.goods-item {
+  width: calc(50% - 10rpx);
+  background-color: #fff;
+  border-radius: 10rpx;
+  overflow: hidden;
+}
+
+.goods-image {
+  width: 100%;
+  height: 300rpx;
+}
+
+.goods-info {
+  padding: 6rpx 20rpx 20rpx 20rpx;
+}
+
+.goods-title {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.goods-price {
+  font-size: 34rpx;
+  color: #ff5722;
+}
+
+.original-price {
+  font-size: 28rpx;
+  color: #999;
+  text-decoration: line-through;
+  margin-left: 10rpx;
+}
+
+.goods-status {
+  font-size: 28rpx;
+  color: #666;
+  margin-top: 10rpx;
+  float: right;
+}
+
+.gw_boxs {
+  width: 100%;
+  display: flex;
+  justify-content: space-between;
+  margin-top: 20rpx;
+}
+
+/* .gw_imgboxs {
+  width: 30%;
+} */
+
+.gw_button {
+  width: 100%;
+}
+
+.buy-button {
+  width: 87% !important;
+  height: 70rpx;
+  background-color: #007aff;
+  color: #fff;
+  font-size: 28rpx;
+  border-radius: 40rpx;
+  text-align: center;
+}

+ 106 - 0
pages/index/index.js

@@ -0,0 +1,106 @@
+// index.js
+// const db=wx.cloud.database()
+import { models, db } from '../../utils/cloudbase.js'
+const app = getApp();
+
+Page({
+  data: {
+    carousellist: [],
+    homepage_8: '',
+    homepage_9: '',
+    souimg: '',
+  },
+
+  onShow() {
+    // 检查登录状态
+    // app.checkLoginStatus();
+  },
+
+  onLoad() {
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/banner/carousel_1.jpg',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/banner/carousel_2.jpg',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/banner/carousel_3.jpg',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/homepage/homepage_8.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/homepage/homepage_9.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        carousellist: tempFilePaths.slice(0, 2),
+        homepage_8: tempFilePaths[3],
+        homepage_9: tempFilePaths[4],
+        souimg: tempFilePaths[5]
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  // 页面跳转  二级页面
+  selectGroupOption(e) {
+    const option = e.currentTarget.dataset.option;
+    let url = '';
+  
+    switch (option) {
+      case 'dahome':
+        url = '/subpackages/dahome/dahome';
+        break;
+      case 'imghome':
+        url = '/subpackages/imghome/imghome';
+        break;
+      // case 'teaching':
+      //   url = '/subpackages/jxhome/jxhome';
+      //   break;
+      // case 'large':
+      //   url = '/subpackages/zshome/zshome';
+      //   break;
+      default:
+        return;
+    }
+  
+    wx.navigateTo({
+      url: url
+    });
+  },
+
+  // async 
+  getData() {
+    // const { data } = await models.login.list({
+    //   filter: {
+    //     where: {}
+    //   },
+    //   pageSize: 10, // 分页大小,建议指定,如需设置为其它值,需要和 pageNumber 配合使用,两者同时指定才会生效
+    //   pageNumber: 1, // 第几页
+    //   getCount: true, // 开启用来获取总数
+    //   // envType: pre 体验环境, prod 正式环境
+    //   envType: "prod",
+    // });
+    
+    // // 返回查询到的数据列表 records 和 总数 total
+    // console.log(data);
+    // const { data } = await models.login.create({
+    //   data: {
+    //       name: "王五",  // 名字
+    //     },
+    //   // envType: pre 体验环境, prod 正式环境
+    //   envType: "prod",
+    // });
+    
+    // // 返回创建的数据 id
+    // console.log(data);
+
+    // db.collection("homelist").get().then(res => {
+    //   console.log(res);
+    // }).catch(err => {
+    //   console.log(err);
+    // })
+  },
+})

+ 4 - 0
pages/index/index.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "首页"
+}

+ 58 - 0
pages/index/index.wxml

@@ -0,0 +1,58 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <!-- 搜索 -->
+    <view class="search-bar">
+      <input class="search-input" placeholder="搜索课件" />
+      <image class="search-icon" src="{{souimg}}" />
+    </view>
+    
+    <!-- 空白区域 -->
+    <view class="empty-space">
+      <swiper style="width: 100%; height: 100%;" autoplay="true" interval="3000" circular>
+        <block wx:for="{{carousellist}}" wx:key="index">
+          <swiper-item>
+            <image style="width: 100%; height: 100%;" src="{{item}}" mode="aspectFill" />
+          </swiper-item>
+        </block>
+      </swiper>
+      </view>
+
+    <!-- 课程分类按钮 -->
+    <view class="course-buttons">
+      <view class="course-button1" bindtap="selectGroupOption" data-option="dahome" style="background-image: url({{homepage_8}}); background-size: cover;">
+        <view class="nr_boxs">
+          <text>全脑智能开发答案</text>
+          <text>course</text>
+        </view>
+      </view>
+      <view class="course-button1" bindtap="selectGroupOption" data-option="imghome" style="margin-left: 20rpx; background-image: url({{homepage_9}}); background-size: cover;">
+        <view class="nr_boxs">
+          <text>动手动脑图库</text>
+          <text>course</text>
+        </view>
+      </view>
+      <!-- <view class="course-buttonstow">
+        <view class="course-button2" bindtap="selectGroupOption" data-option="training">
+          <view class="nr_boxs">
+            <text>培训</text>
+            <text>course</text>
+          </view>
+        </view>
+        <view class="course-button3">
+          <view class="course-button" bindtap="selectGroupOption" data-option="teaching">
+            <view class="nr_boxs">
+              <text>教学</text>
+              <text>course</text>
+            </view>
+          </view>
+          <view class="course-button" bindtap="selectGroupOption" data-option="large" style="margin-left: 20rpx;">
+            <view class="nr_boxs">
+              <text>展示</text>
+              <text>course</text>
+            </view>
+          </view>
+        </view>
+      </view> -->
+    </view>
+  </view>
+</view>

+ 92 - 0
pages/index/index.wxss

@@ -0,0 +1,92 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  /* height: calc(100vh - 40rpx); */
+  padding: 0 0;
+}
+
+.search-bar {
+  width: calc(100% - 50rpx);
+  position: relative;
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  padding-right: 60rpx;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.empty-space {
+  width: 100%;
+  height: 390rpx;
+  background-color: #e0e0e0;
+  margin-top: 20rpx;
+  border-radius: 12rpx;
+  overflow: hidden;
+}
+
+.course-buttons {
+  width: 100%;
+  display: flex;
+  margin-top: 20rpx;
+}
+
+.course-button1 {
+  width: calc( 500% - 10rpx);
+  height: 430rpx;
+  background-color: #e0e0e0;
+  margin: 5rpx;
+  border-radius: 12rpx;
+  color: #fff;
+}
+
+.course-buttonstow {
+  margin-left: 20rpx;
+  width: calc( 100% - 36% - 20rpx);
+  height: 430rpx;
+}
+
+.course-button2 {
+  width: 100%;
+  height: calc(50% - 10rpx);
+  background-color: #e0e0e0;
+  margin: 5rpx;
+  border-radius: 12rpx;
+}
+
+.course-button3 {
+  margin-top: 20rpx;
+  width: 100%;
+  height: calc(50% - 10rpx);
+  display: flex;
+}
+
+.course-button {
+  width: calc(50% - 10rpx);
+  height: 100%;
+  background-color: #e0e0e0;
+  margin: 5rpx;
+  border-radius: 12rpx;
+}
+
+.nr_boxs {
+  display: flex;
+  flex-direction: column;
+  padding: 20rpx;
+}

+ 67 - 0
pages/login/login.js

@@ -0,0 +1,67 @@
+// pages/login/login.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+    levelOptions: ['小班', '中班', '大班'],
+    selectedLevelIndex: 0,
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad(options) {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面初次渲染完成
+   */
+  onReady() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面显示
+   */
+  onShow() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面隐藏
+   */
+  onHide() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面卸载
+   */
+  onUnload() {
+
+  },
+
+  /**
+   * 页面相关事件处理函数--监听用户下拉动作
+   */
+  onPullDownRefresh() {
+
+  },
+
+  /**
+   * 页面上拉触底事件的处理函数
+   */
+  onReachBottom() {
+
+  },
+
+  /**
+   * 用户点击右上角分享
+   */
+  onShareAppMessage() {
+
+  }
+})

+ 4 - 0
pages/login/login.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "绑定手机号"
+}

+ 32 - 0
pages/login/login.wxml

@@ -0,0 +1,32 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="goodslist_boxs">
+    <view class="input-group">
+      <label>园所</label>
+      <input type="text" placeholder="请输入园所名称" />
+    </view>
+    <view class="input-group">
+      <view style="display: flex;">
+        <view style="width: 40%;">
+          <picker mode="selector" range="{{levelOptions}}" value="{{selectedLevelIndex}}" bindchange="handleLevelChange">
+            <view class="dropdown-item">{{levelOptions[selectedLevelIndex]}} <image class="xiala_boxs" src="../../image/imgs/xiala.png" /></view>
+          </picker>
+        </view>
+        <input style="width: 60%;margin-left: 3%;" type="text" placeholder="请输入姓名" />
+      </view>
+    </view>
+    <view class="input-group">
+      <label>手机号码</label>
+      <view>
+        <input type="text" placeholder="请输入常用的手机号码" />
+      </view>
+    </view>
+    <view class="input-group">
+      <label>验证码</label>
+      <view style="display: flex;">
+        <input style="width: 95%;margin-right: 3%;" type="text" placeholder="请输入验证码" />
+        <button class="get-code-btn">获取验证码</button>
+      </view>
+    </view>
+    <button class="confirm-btn">确定</button>
+  </view>
+</view>

+ 73 - 0
pages/login/login.wxss

@@ -0,0 +1,73 @@
+.goodslist_boxs {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  height: calc( 100vh - 40rpx);
+}
+.input-group {
+  display: flex;
+  flex-direction: column;
+  margin-bottom: 20rpx;
+}
+
+.input-group label {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.input-group input {
+  height: 80rpx;
+  background: #fff;
+  border: 1px solid #ddd;
+  border-radius: 4rpx;
+  padding: 0 20rpx;
+  font-size: 28rpx;
+  border-radius: 12rpx;
+}
+
+.get-code-btn {
+  width: 300rpx !important;
+  height: 80rpx;
+  background-color: #fff;
+  color: #409eff;
+  border: 1rpx solid #409eff;
+  border-radius: 4rpx;
+  padding: 20rpx 0rpx;
+  /* margin-left: 20rpx; */
+  margin-top: 1rpx;
+  font-size: 28rpx;
+  border-radius: 12rpx;
+}
+
+.confirm-btn {
+  background-color: #409eff;
+  color: white;
+  border: none;
+  border-radius: 40rpx;
+  width: calc( 100% - 60rpx) !important;
+  height: 80rpx;
+  font-size: 30rpx;
+  margin-top: 50rpx;
+  position: fixed;
+  bottom: 40rpx;
+}
+
+.dropdown-item {
+  margin-left: 20rpx;
+  margin-top: 4rpx;
+  padding: 17rpx 16rpx;
+  background-color: #409eff;
+  color: #fff;
+  border-radius: 8rpx;
+  font-size: 32rpx;
+  display: flex;
+  align-content: center;
+  justify-content: center;
+}
+
+.xiala_boxs {
+  width: 45rpx;
+  height: 45rpx;
+  margin: 0;
+  padding: 0rpx;
+}

+ 123 - 0
pages/me/me.js

@@ -0,0 +1,123 @@
+// pages/me/me.js
+Page({
+  data: {
+      // role: "teacher",
+      userInfo: {
+          avatar: '../../image/imgs/avatar.jpg',
+          name: '',
+          role: '',
+          phone: ''
+      },
+      orderStatus: [],
+      historyItems: [
+          {
+              id: 1,
+              thumbnail: '../../image/imgs/item1.jpg',
+              name: '趣味识字卡片',
+              date: '2023-10-15 14:30'
+          },
+          {
+              id: 2,
+              thumbnail: '../../image/imgs/item2.jpg',
+              name: '趣味识字卡片',
+              date: '2023-10-15 14:30'
+          },
+          // 更多历史记录...
+      ],
+      xiugaiimg: '',
+      xiangjiimg: '',
+  },
+
+  onLoad(options) {
+      this.getUserInfo();
+
+      const orderStatus = [
+        { text: '全部订单', type: 1 },
+        { text: '待付款', type: 2 },
+        { text: '待收货', type: 3 },
+        { text: '已完成', type: 4 }
+    ]
+
+      const fileIDs = [
+        'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/ding_1.png',
+        'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/ding_2.png',
+        'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/ding_3.png',
+        'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/ding_4.png',
+        'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/xiugai.png',
+        'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/xiangji.png'
+      ];
+      
+      // 并发下载多个 fileID
+      Promise.all(
+        fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+      ).then(results => {
+        // 每个 result 对应一个下载结果
+        const tempFilePaths = results.map(r => r.tempFilePath);
+        console.log('全部下载成功:', tempFilePaths);
+
+        // 将 tempFilePaths.slice(0, 3) 分配到 orderStatus 中
+        const updatedOrderStatus = orderStatus.map((item, index) => {
+          return {
+            ...item,
+            url: tempFilePaths[index] // 为每个对象添加 url 属性
+          };
+        });
+
+        console.log(updatedOrderStatus, 'updatedOrderStatus');
+
+        this.setData({
+          orderStatus: updatedOrderStatus,
+          xiugaiimg: tempFilePaths[4],
+          xiangjiimg: tempFilePaths[5]
+        });
+      }).catch(err => {
+        console.error('有文件下载失败:', err);
+      });
+  },
+
+  getUserInfo() {
+      // 模拟获取用户信息的逻辑
+      const userInfo = {
+          avatar: '../../image/imgs/avatar.jpg',
+          name: '琳琳家长',
+          role: '家长',
+          phone: '131****9345'
+      };
+      this.setData({ userInfo });
+  },
+
+  handleLogout() {
+
+    wx.navigateTo({
+          url: `/subpackages/logoff/logoff`
+        });
+      // 处理用户注销的逻辑
+      // wx.showModal({
+      //     title: '提示',
+      //     content: '确定要注销吗?',
+      //     success: (res) => {
+      //         if (res.confirm) {
+      //             // 注销成功后的处理逻辑
+      //             wx.showToast({
+      //                 title: '已注销',
+      //                 icon: 'success'
+      //             });
+      //         }
+      //     }
+      // });
+  },
+
+  // 跳转
+  goToGoodsList(e) {
+    const type = e.currentTarget.dataset.type;
+    wx.navigateTo({
+      url: `/subpackages/order/order?type=${type}`
+    });
+  },
+
+  goToGoodsLists() {
+    wx.navigateTo({
+      url: `/subpackages/changename/changename`
+    });
+  }
+});

+ 4 - 0
pages/me/me.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "个人中心"
+}

+ 65 - 0
pages/me/me.wxml

@@ -0,0 +1,65 @@
+<!-- pages/me/me.wxml -->
+<view class="containerss">
+    <!-- 用户信息 -->
+    <view class="user-info">
+        <!-- <image class="avatar" src="{{userInfo.avatar}}" mode="aspectFill"></image> -->
+        <view class="avatar"></view>
+        <!-- <image style="width: 35rpx;height: 35rpx;margin-left: 20rpx;" src="{{xiangjiimg}}" mode=""/> -->
+        <view class="info">
+            <view style="display: flex; align-items: center;">
+              <text class="name">{{userInfo.name}}</text>
+              <image bindtap="goToGoodsLists" style="width: 35rpx;height: 35rpx;margin-left: 20rpx;" src="{{xiugaiimg}}" mode=""/>
+            </view>
+            <view class="info_view2">
+              阳光幼儿园
+            </view>
+        </view>
+    </view>
+
+    <!-- 绑定手机号 -->
+    <view class="phone-binding">
+        <text style="margin-right: 20rpx;">绑定手机号:{{userInfo.phone ? userInfo.phone : '未绑定'}}</text>
+        <navigator url="/subpackages/changephone/changephone" open-type="navigate" wx:if="{{userInfo.phone}}">更改手机号</navigator>
+    </view>
+
+    <!-- 订单状态 -->
+    <view class="order-status">
+        <view class="status-item" wx:for="{{orderStatus}}" wx:key="index">
+            <view style="display: flex; align-items: center; flex-direction: column;" bindtap="goToGoodsList" data-type="{{ item.type }}">
+              <view class="circle">
+                <image style="width: 100%; height: 100%;" src="{{item.url}}" mode=""/>
+              </view>
+              <view style="margin-top: 16rpx;">{{item.text}}</view>
+            </view>
+        </view>
+    </view>
+
+    <!-- 购买历史 -->
+    <view class="history">
+        <view class="title">
+            <text>购买历史</text>
+            <navigator url="/subpackages/purchasehistory/purchasehistory" open-type="navigate">查看更多</navigator>
+        </view>
+        <view class="items">
+            <block wx:for="{{historyItems}}" wx:key="id">
+                <view class="item">
+                    <!-- <image mode="aspectFill"></image> -->
+                    <view class="thumbnail"></view>
+                    <view class="details">
+                        <view class="name">{{item.name}}</view>
+                        <view class="date">{{item.date}}</view>
+                    </view>
+                    <!-- <view class="xiazai_img">
+                      <image class="search-icon" src="../../image/imgs/xiazai.png" />
+                    </view> -->
+                </view>
+            </block>
+        </view>
+    </view>
+
+    <!-- 用户注销 -->
+    <button class="logout-btn" size="default" bindtap="handleLogout">用户注销</button>
+
+    <!-- <custom-tabbar role="{{role}}" selected="{{2}}" /> -->
+</view>
+

+ 159 - 0
pages/me/me.wxss

@@ -0,0 +1,159 @@
+/* pages/me/me.wxss */
+.containerss {
+  padding: 20rpx 30rpx;
+  background-color: #f5f5f5;
+  height: calc(100vh - 40rpx);
+}
+
+.user-info {
+  display: flex;
+  align-items: center;
+  margin-bottom: 20rpx;
+}
+
+.avatar {
+  width: 140rpx;
+  height: 140rpx;
+  border-radius: 50%;
+  margin-right: 20rpx;
+  background-color: palegreen
+}
+
+.info .name {
+  font-size: 34rpx;
+  color: #333;
+}
+
+.info .role {
+  font-size: 24rpx;
+  color: #999;
+  margin-top: 10rpx;
+  margin-left: 40rpx;
+}
+
+.info_view2 {
+  font-size: 22rpx;
+  padding: 10rpx 16rpx;
+  background: #ecf5ff;
+  border-radius: 30rpx;
+  border: 1rpx solid #d9ecff;
+  display: inline-block;
+  color: #409eff;
+  margin-top: 16rpx;
+}
+
+.phone-binding {
+  display: flex;
+  background-color: #fff;
+  padding: 40rpx 20rpx;
+  border-radius: 16rpx;
+  margin: 20rpx 0;
+}
+
+.phone-binding text {
+  font-size: 28rpx;
+  color: #666;
+}
+
+.phone-binding navigator {
+  font-size: 24rpx;
+  color: #007aff;
+  margin-left: 10rpx;
+}
+
+.order-status {
+  display: flex;
+  justify-content: space-between;
+  margin: 40rpx 0;
+}
+
+.status-item {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  text-align: center;
+}
+
+.circle {
+  width: 110rpx;
+  height: 110rpx;
+  overflow: hidden;
+  /* background-color: #ccc; */
+  border-radius: 50%;
+  margin-right: 10rpx;
+}
+
+.history {
+  background-color: #fff;
+  padding: 20rpx;
+  border-radius: 16rpx;
+  margin-bottom: 20rpx;
+}
+
+.title {
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  margin-bottom: 20rpx;
+}
+
+.title text {
+  font-size: 32rpx;
+  color: #333;
+}
+
+.title navigator {
+  font-size: 28rpx;
+  color: #007aff;
+}
+
+.items {
+margin-top: 30rpx;
+}
+
+.items .item {
+  display: flex;
+  align-items: center;
+  margin-bottom: 20rpx;
+}
+
+.thumbnail {
+  width: 130rpx;
+  height: 130rpx;
+  margin-right: 20rpx;
+  background: palegreen;
+  border-radius: 12rpx;
+}
+
+.details .name {
+  font-size: 32rpx;
+  color: #333;
+}
+.details {
+  width: 440rpx;
+}
+.details .date {
+  font-size: 28rpx;
+  color: #999;
+  margin-top: 10rpx;
+}
+
+.logout-btn {
+  width: 100%;
+  height: 80rpx;
+  background-color: #007aff;
+  color: #fff;
+  font-size: 32rpx;
+  border-radius: 40rpx;
+}
+
+.xiazai_img {
+  width: 45rpx;
+  height: 35rpx;
+  float: right;
+}
+
+.search-icon {
+  width: 100%;
+  height: 100%;
+}

+ 102 - 0
pages/shoppingcart/shoppingcart.js

@@ -0,0 +1,102 @@
+Page({
+  data: {
+    cartItems: [
+      {
+        id: '1',
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '幼儿启蒙绘本 10册套装',
+        description: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        quantity: 1,
+        checked: true
+      },
+      {
+        id: '2',
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '幼儿启蒙绘本 10册套装',
+        description: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        quantity: 1,
+        checked: true
+      }
+    ],
+    souimg: '',
+  },
+
+  onLoad() {
+    this.updateTotalPrice();
+
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        souimg: tempFilePaths[0],
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  handleCheckboxChange(e) {
+    const { value } = e.detail;
+    const cartItems = this.data.cartItems.map(item => ({
+      ...item,
+      checked: value.includes(item.id)
+    }));
+    this.setData({ cartItems });
+    this.updateTotalPrice();
+  },
+
+  handleAllCheckboxChange(e) {
+    const { value } = e.detail;
+    const allChecked = value.includes('all');
+    const cartItems = this.data.cartItems.map(item => ({
+      ...item,
+      checked: allChecked
+    }));
+    this.setData({ cartItems, allChecked });
+    this.updateTotalPrice();
+  },
+
+  updateTotalPrice() {
+    const totalPrice = this.data.cartItems.reduce((total, item) => {
+      if (item.checked) {
+        return total + item.price * item.quantity;
+      }
+      return total;
+    }, 0);
+    this.setData({ totalPrice });
+  },
+
+  handleCheckout() {
+    // 处理结算逻辑
+    console.log('结算');
+    wx.navigateTo({
+      url: '/subpackages/submitorder/submitorder'
+    });
+  },
+  
+
+  onChange(e) {
+    const { id } = e.currentTarget.dataset;
+    const { detail } = e;
+    const cartItems = this.data.cartItems.map(item => {
+      if (item.id === id) {
+        return { ...item, quantity: detail };
+      }
+      return item;
+    });
+  
+    this.setData({ cartItems }, () => {
+      this.updateTotalPrice();
+    });
+  }
+});

+ 4 - 0
pages/shoppingcart/shoppingcart.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "购物车"
+}

+ 54 - 0
pages/shoppingcart/shoppingcart.wxml

@@ -0,0 +1,54 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <!-- 购物车标题 -->
+    <view class="cart-header">
+      <text style="font-size: 36rpx;">购物车 <text style="font-size: 24rpx;">({{cartItems.length}})</text></text>
+      <view class="search-bar">
+        <input class="search-input" placeholder="搜索购物车商品" />
+        <image class="search-icon" src="{{souimg}}" />
+      </view>
+      <button class="manage-btn">管理</button>
+    </view>
+
+    <!-- 商品列表 -->
+    <view class="cart-items">
+      <block wx:for="{{cartItems}}" wx:key="index">
+        <view class="cart-item">
+          <checkbox-group bindchange="handleCheckboxChange">
+            <label class="cart-checkbox">
+              <checkbox value="{{item.id}}" checked="{{item.checked}}" />
+            </label>
+          </checkbox-group>
+          <image class="cart-image" src="{{item.image}}" mode="aspectFill"></image>
+          <view class="cart-info">
+            <view class="cart-title">{{item.title}}</view>
+            <view class="cart-description">{{item.description}}</view>
+            <view style="display: flex;justify-content: space-between; margin-top: 30rpx;">
+              <view class="cart-price">¥{{item.price}}</view>
+              <van-stepper
+                value="{{item.quantity}}"
+                data-id="{{item.id}}"
+                bind:change="onChange"
+              />
+            </view>
+          </view>
+        </view>
+      </block>
+    </view>
+
+    <!-- 底部工具栏 -->
+    <view class="cart-footer">
+      <view style="display: flex; align-items: center;">
+        <checkbox-group bindchange="handleAllCheckboxChange">
+          <label class="all-checkbox">
+            <checkbox value="all" checked="{{allChecked}}" />全选
+          </label>
+        </checkbox-group>
+      </view>
+      <view style="display: flex; align-items: center;">
+        <view class="total-price">合计:¥{{totalPrice}}</view>
+        <button class="checkout-btn" bindtap="handleCheckout">结算</button>
+      </view>
+    </view>
+  </view>
+</view>

+ 152 - 0
pages/shoppingcart/shoppingcart.wxss

@@ -0,0 +1,152 @@
+/* pages/shoppingcart/shoppingcart.wxss */
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  padding: 0 0;
+}
+
+.cart-header {
+  width: 100%;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  margin-bottom: 20rpx;
+}
+
+.search-bar {
+  width: calc(100% - 330rpx);
+  position: relative;
+  display: flex;
+  align-items: center;
+  /* height: 70rpx; */
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.manage-btn {
+  width: 70rpx !important;
+  padding: 0 !important;
+  margin: 0 !important;
+  font-size: 32rpx;
+  font-weight: 500;
+  /* color: #007aff; */
+}
+
+.cart-items {
+  width: 100%;
+  margin-bottom: 20rpx;
+}
+
+.cart-item {
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border-radius: 8rpx;
+  padding: 20rpx;
+  margin-bottom: 20rpx;
+}
+
+.cart-checkbox {
+  margin-right: 20rpx;
+}
+
+.cart-image {
+  width: 200rpx;
+  height: 200rpx;
+  margin-right: 20rpx;
+}
+
+.cart-info {
+  flex: 1;
+  width: 33.33%;
+}
+
+.cart-title {
+  font-size: 34rpx;
+  font-weight: bold;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.cart-description {
+  font-size: 28rpx;
+  color: #666;
+  margin-bottom: 10rpx;
+}
+
+.cart-price {
+  font-size: 32rpx;
+  color: #ff5722;
+  margin-bottom: 10rpx;
+}
+
+.quantity-controls {
+  display: flex;
+  align-items: center;
+}
+
+.quantity-btn {
+  width: 60rpx !important;
+  height: 60rpx !important;
+  background-color: #f5f5f5;
+  border: 1rpx solid #ccc;
+  border-radius: 8rpx;
+  font-size: 32rpx;
+  color: #666;
+}
+
+.quantity-text {
+  font-size: 32rpx;
+  color: #333;
+}
+
+.cart-footer {
+  width: 100%;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  background-color: #fff;
+  padding: 20rpx;
+  position: fixed;
+  bottom: 0;
+  left: 0;
+  right: 0;
+  font-size: 38rpx;
+}
+
+.all-checkbox {
+  margin-right: 20rpx;
+  font-size: 36rpx;
+}
+
+.total-price {
+  font-size: 36rpx;
+  color: #333;
+}
+
+.checkout-btn {
+  width: 200rpx !important;
+  height: 80rpx !important;
+  background-color: #007aff;
+  color: #fff;
+  font-size: 32rpx;
+  border-radius: 38rpx;
+  margin: 0 40rpx 0 30rpx !important;
+}

+ 42 - 0
project.config.json

@@ -0,0 +1,42 @@
+{
+  "compileType": "miniprogram",
+  "cloudfunctionRoot": "cloud/",
+  "libVersion": "trial",
+  "packOptions": {
+    "ignore": [],
+    "include": []
+  },
+  "setting": {
+    "coverView": true,
+    "es6": true,
+    "postcss": true,
+    "minified": true,
+    "enhance": true,
+    "showShadowRootInWxmlPanel": true,
+    "packNpmRelationList": [],
+    "babelSetting": {
+      "ignore": [],
+      "disablePlugins": [],
+      "outputPath": ""
+    },
+    "compileWorklet": false,
+    "uglifyFileName": false,
+    "uploadWithSourceMap": true,
+    "packNpmManually": false,
+    "minifyWXSS": true,
+    "minifyWXML": true,
+    "localPlugins": false,
+    "condition": false,
+    "swc": false,
+    "disableSWC": true,
+    "disableUseStrict": false,
+    "useCompilerPlugins": false
+  },
+  "condition": {},
+  "editorSetting": {
+    "tabIndent": "auto",
+    "tabSize": 2
+  },
+  "appid": "wx06f2b1b09ac5684f",
+  "simulatorPluginLibVersion": {}
+}

+ 23 - 0
project.private.config.json

@@ -0,0 +1,23 @@
+{
+  "description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html",
+  "projectname": "jz-admin",
+  "setting": {
+    "compileHotReLoad": true,
+    "urlCheck": true,
+    "coverView": true,
+    "lazyloadPlaceholderEnable": false,
+    "skylineRenderEnable": false,
+    "preloadBackgroundData": false,
+    "autoAudits": false,
+    "useApiHook": true,
+    "useApiHostProcess": true,
+    "showShadowRootInWxmlPanel": true,
+    "useStaticServer": false,
+    "useLanDebug": false,
+    "showES6CompileOption": false,
+    "bigPackageSizeSupport": false,
+    "checkInvalidKey": true,
+    "ignoreDevUnusedFiles": true
+  },
+  "libVersion": "3.8.10"
+}

+ 7 - 0
sitemap.json

@@ -0,0 +1,7 @@
+{
+  "desc": "关于本文件的更多信息,请参考文档 https://developers.weixin.qq.com/miniprogram/dev/framework/sitemap.html",
+  "rules": [{
+  "action": "allow",
+  "page": "*"
+  }]
+}

+ 60 - 0
subpackages/addresslist/addresslist.js

@@ -0,0 +1,60 @@
+Page({
+  data: {
+    addresses: [
+      {
+        address: '宁夏青铜峡市秦岭路846号'
+      },
+      {
+        address: '浙江省永康市红旗桥湖滨大道124号'
+      }
+    ],
+    souimg: '',
+    shanchu: '',
+    xiugaiimg: '',
+    dingweiimg: '',
+  },
+
+  onLoad(options) {
+    // const title = options.title ? decodeURIComponent(options.title) : '商品列表';
+    // this.setData({ title });
+    // wx.setNavigationBarTitle({ title });
+
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/shanchu.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/xiugai.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/dingwei.png'
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        souimg: tempFilePaths[0],
+        shanchu: tempFilePaths[1],
+        xiugaiimg: tempFilePaths[2],
+        dingweiimg: tempFilePaths[3],
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  handleEdit(e) {
+    const index = e.currentTarget.dataset.index;
+    // 处理编辑逻辑
+  },
+
+  handleDelete(e) {
+    const index = e.currentTarget.dataset.index;
+    // 处理删除逻辑
+  },
+
+  handleAddAddress() {
+    // 处理添加地址逻辑
+  }
+});

+ 4 - 0
subpackages/addresslist/addresslist.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "选择地址"
+}

+ 29 - 0
subpackages/addresslist/addresslist.wxml

@@ -0,0 +1,29 @@
+<view>
+  <view class="top_boxs">
+    <view class="diz">北京市 ▼</view>
+    <view class="search-bar">
+      <input class="search-input" placeholder="搜索商品" />
+      <image class="search-icon" src="{{souimg}}" />
+    </view>
+  </view>
+  <view class="container">
+    <!-- 地址选择 -->
+    <view class="address_list">
+      <block wx:for="{{addresses}}" wx:key="index">
+        <view class="address_item">
+          <image src="{{dingweiimg}}" class="location_icon"></image>
+          <text class="address_text">{{item.address}}</text>
+          <view class="action_buttons">
+            <image class="search-icons" style="padding-right: 25rpx;" src="{{xiugaiimg}}" />
+            <image class="search-icons" src="{{shanchu}}" />
+          </view>
+        </view>
+      </block>
+    </view>
+
+    <!-- 添加地址按钮 -->
+    <view class="buttons_boxs">
+      <button class="add_address_button" bindtap="handleAddAddress">添加地址</button>
+    </view>
+  </view>
+</view>

+ 114 - 0
subpackages/addresslist/addresslist.wxss

@@ -0,0 +1,114 @@
+.top_boxs {
+  width: calc(100% - 60rpx);
+  padding: 20rpx 30rpx;
+  background-color: #fff;
+  display: flex;
+  justify-content: space-between;
+  align-content: center;
+}
+
+.diz {
+  width: 25%;
+  padding: 16rpx 0rpx;
+}
+
+.search-bar {
+  width: 75%;
+  position: relative;
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  padding-right: 60rpx;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.container {
+  background-color: #f5f5f5;
+  padding: 20rpx 30rpx;
+}
+
+.address_list {
+  width: 100%;
+  margin-bottom: 20rpx;
+}
+
+.address_item {
+  background-color: #fff;
+  border-radius: 10rpx;
+  padding: 20rpx;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  margin-bottom: 10rpx;
+}
+
+.location_icon {
+  width: 30rpx;
+  height: 30rpx;
+  margin-right: 10rpx;
+}
+
+.address_text {
+  font-size: 28rpx;
+  color: #333;
+  flex: 1;
+  margin-left: 10rpx;
+}
+
+.action_buttons {
+  width: 15%;
+  display: flex;
+  /* align-items: center; */
+}
+
+.search-icons {
+  width: 35rpx;
+  height: 35rpx;
+}
+
+.edit_button, .delete_button {
+  width: 40rpx;
+  height: 40rpx;
+  background-color: #f5f5f5;
+  border-radius: 50%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  font-size: 28rpx;
+  color: #333;
+  margin-left: 10rpx;
+}
+
+.add_address_button {
+  width: calc(100% - 40rpx) !important;
+  height: 80rpx;
+  background-color: #3b8cff;
+  color: #fff;
+  font-size: 32rpx;
+  border-radius: 40rpx;
+  margin-top: 20rpx;
+}
+
+.buttons_boxs {
+  position: fixed;
+  bottom: 40rpx;
+  left: 0;
+  width: 100%;
+}

+ 66 - 0
subpackages/changename/changename.js

@@ -0,0 +1,66 @@
+// subpackages/changename/changename.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad(options) {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面初次渲染完成
+   */
+  onReady() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面显示
+   */
+  onShow() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面隐藏
+   */
+  onHide() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面卸载
+   */
+  onUnload() {
+
+  },
+
+  /**
+   * 页面相关事件处理函数--监听用户下拉动作
+   */
+  onPullDownRefresh() {
+
+  },
+
+  /**
+   * 页面上拉触底事件的处理函数
+   */
+  onReachBottom() {
+
+  },
+
+  /**
+   * 用户点击右上角分享
+   */
+  onShareAppMessage() {
+
+  }
+})

+ 4 - 0
subpackages/changename/changename.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "设置用户名"
+}

+ 15 - 0
subpackages/changename/changename.wxml

@@ -0,0 +1,15 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="goodslist_boxs">
+    <view class="input-group">
+      <label>原用户名</label>
+      <input type="text" placeholder="请输入原用户名" />
+    </view>
+    <view class="input-group">
+      <label>新用户名</label>
+      <view>
+        <input type="text" placeholder="请输入用户名" />
+      </view>
+    </view>
+    <button class="confirm-btn">确定修改</button>
+  </view>
+</view>

+ 53 - 0
subpackages/changename/changename.wxss

@@ -0,0 +1,53 @@
+.goodslist_boxs {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  height: calc( 100vh - 40rpx);
+}
+.input-group {
+  display: flex;
+  flex-direction: column;
+  margin-bottom: 20rpx;
+}
+
+.input-group label {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.input-group input {
+  height: 80rpx;
+  background: #fff;
+  border: 1px solid #ddd;
+  border-radius: 4rpx;
+  padding: 0 20rpx;
+  font-size: 28rpx;
+  border-radius: 12rpx;
+}
+
+.get-code-btn {
+  width: 300rpx !important;
+  height: 80rpx;
+  background-color: #fff;
+  color: #409eff;
+  border: 1rpx solid #409eff;
+  border-radius: 4rpx;
+  padding: 20rpx 0rpx;
+  /* margin-left: 20rpx; */
+  margin-top: 1rpx;
+  font-size: 28rpx;
+  border-radius: 12rpx;
+}
+
+.confirm-btn {
+  background-color: #409eff;
+  color: white;
+  border: none;
+  border-radius: 40rpx;
+  width: calc( 100% - 60rpx) !important;
+  height: 80rpx;
+  font-size: 30rpx;
+  margin-top: 50rpx;
+  position: fixed;
+  bottom: 40rpx;
+}

+ 66 - 0
subpackages/changephone/changephone.js

@@ -0,0 +1,66 @@
+// subpackages/changephone/changephone.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad(options) {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面初次渲染完成
+   */
+  onReady() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面显示
+   */
+  onShow() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面隐藏
+   */
+  onHide() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面卸载
+   */
+  onUnload() {
+
+  },
+
+  /**
+   * 页面相关事件处理函数--监听用户下拉动作
+   */
+  onPullDownRefresh() {
+
+  },
+
+  /**
+   * 页面上拉触底事件的处理函数
+   */
+  onReachBottom() {
+
+  },
+
+  /**
+   * 用户点击右上角分享
+   */
+  onShareAppMessage() {
+
+  }
+})

+ 4 - 0
subpackages/changephone/changephone.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "更改手机号"
+}

+ 16 - 0
subpackages/changephone/changephone.wxml

@@ -0,0 +1,16 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="goodslist_boxs">
+    <view class="input-group">
+      <label>手机号码</label>
+      <input type="text" placeholder="请输入手机号码" />
+    </view>
+    <view class="input-group">
+      <label>验证码</label>
+      <view style="display: flex;">
+        <input style="width: 95%;margin-right: 3%;" type="text" placeholder="请输入验证码" />
+        <button class="get-code-btn">获取验证码</button>
+      </view>
+    </view>
+    <button class="confirm-btn">确定</button>
+  </view>
+</view>

+ 53 - 0
subpackages/changephone/changephone.wxss

@@ -0,0 +1,53 @@
+.goodslist_boxs {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  height: calc( 100vh - 40rpx);
+}
+.input-group {
+  display: flex;
+  flex-direction: column;
+  margin-bottom: 20rpx;
+}
+
+.input-group label {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.input-group input {
+  height: 80rpx;
+  background: #fff;
+  border: 1px solid #ddd;
+  border-radius: 4rpx;
+  padding: 0 20rpx;
+  font-size: 28rpx;
+  border-radius: 12rpx;
+}
+
+.get-code-btn {
+  width: 300rpx !important;
+  height: 80rpx;
+  background-color: #fff;
+  color: #409eff;
+  border: 1rpx solid #409eff;
+  border-radius: 4rpx;
+  padding: 20rpx 0rpx;
+  /* margin-left: 20rpx; */
+  margin-top: 1rpx;
+  font-size: 28rpx;
+  border-radius: 12rpx;
+}
+
+.confirm-btn {
+  background-color: #409eff;
+  color: white;
+  border: none;
+  border-radius: 40rpx;
+  width: calc( 100% - 60rpx) !important;
+  height: 80rpx;
+  font-size: 30rpx;
+  margin-top: 50rpx;
+  position: fixed;
+  bottom: 40rpx;
+}

+ 88 - 0
subpackages/dahome/dahome.js

@@ -0,0 +1,88 @@
+// subpackages/dahome/dahome.js
+Page({
+  data: {
+    levelOptions: ['初级', '中级', '高级'],
+    selectedLevelIndex: 0,
+    typeOptions: ['1', '2', '3'],
+    selectedTypeIndex: 0,
+    items: [
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },{
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },{
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },{
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },
+    ],
+    souimg: '',
+    xiaziimg: '',
+    showimg: '',
+    xialaimg: '',
+    goods_9: '',
+  },
+
+  onLoad() {
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/xiazi.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/show_1.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/xiala.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/goods/goods_9.jpg'
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        souimg: tempFilePaths[0],
+        xiaziimg: tempFilePaths[1],
+        showimg: tempFilePaths[2],
+        xialaimg: tempFilePaths[3],
+        goods_9: tempFilePaths[4],
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  handleLevelChange(e) {
+    this.setData({
+      selectedLevelIndex: e.detail.value
+    });
+  },
+  handleTypeChange(e) {
+    this.setData({
+      selectedTypeIndex: e.detail.value
+    });
+  }
+})

+ 4 - 0
subpackages/dahome/dahome.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "全脑智能开发答案"
+}

+ 39 - 0
subpackages/dahome/dahome.wxml

@@ -0,0 +1,39 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <view class="top_boxs">
+      <!-- 搜索 -->
+      <view class="search-bar">
+        <input class="search-input" placeholder="搜索课件" />
+        <image class="search-icon" src="{{souimg}}" />
+      </view>
+      <!-- 下拉框 -->
+      <view class="dropdown-box">
+        <picker mode="selector" range="{{levelOptions}}" value="{{selectedLevelIndex}}" bindchange="handleLevelChange">
+          <view class="dropdown-item">{{levelOptions[selectedLevelIndex]}} <image class="xiala_boxs" src="{{xialaimg}}" /></view>
+        </picker>
+        <picker mode="selector" range="{{typeOptions}}" value="{{selectedTypeIndex}}" bindchange="handleTypeChange">
+          <view class="dropdown-item">{{typeOptions[selectedTypeIndex]}} <image class="xiala_boxs" src="{{xialaimg}}" /></view>
+        </picker>
+      </view>
+    </view>
+    <!-- 列表 -->
+    <view class="list-box">
+        <block wx:for="{{items}}" wx:key="index">
+          <view class="item">
+            <image class="item-image" src="{{goods_9}}" />
+            <view class="item-content">
+              <view class="item-title">{{item.title}}</view>
+              <view style="display: flex; justify-content: space-between;">
+                <view class="item-subtitle">{{item.subtitle}}</view>
+                <view class="item-download-count">已有{{item.downloadCount}}人下载</view>
+              </view>
+              <view class="item-buttons">
+                <button class="preview-button"><image class="download-icons" src="{{showimg}}" />在线预览</button>
+                <image class="download-icon" src="{{xiaziimg}}" />
+              </view>
+            </view>
+          </view>
+        </block>
+      </view>
+  </view>
+</view>

+ 143 - 0
subpackages/dahome/dahome.wxss

@@ -0,0 +1,143 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  /* height: calc(100vh - 40rpx); */
+  padding: 0 0;
+}
+
+.top_boxs {
+  width: 100%;
+  height: 80rpx;
+  display: flex;
+  justify-content: space-between;
+}
+
+.search-bar {
+  width: 55%;
+  position: relative;
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  padding-right: 60rpx;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.dropdown-box {
+  display: flex;
+  align-items: center;
+}
+
+.dropdown-item {
+  margin-left: 20rpx;
+  padding: 12rpx 16rpx;
+  background-color: #409eff;
+  color: #fff;
+  border-radius: 8rpx;
+  font-size: 32rpx;
+  display: flex;
+  align-content: center;
+  justify-content: center;
+}
+
+.xiala_boxs {
+  width: 45rpx;
+  height: 45rpx;
+  margin: 0;
+  padding: 0rpx;
+}
+
+.list-box {
+  margin-top: 20rpx;
+  display: flex;
+  flex-wrap: wrap;
+}
+
+.item {
+  width: 48%;
+  margin-right: 4%;
+  margin-bottom: 20rpx;
+  background-color: #fff;
+  border-radius: 12rpx;
+  overflow: hidden;
+  box-shadow: 0 2rpx 6rpx rgba(0, 0, 0, 0.1);
+}
+
+.item:nth-child(2n) {
+  margin-right: 0;
+}
+
+.item-image {
+  width: 100%;
+  height: 300rpx;
+  object-fit: cover;
+}
+
+.item-content {
+  padding: 20rpx;
+}
+
+.item-title {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.item-subtitle {
+  font-size: 28rpx;
+  color: #666;
+  margin-bottom: 10rpx;
+}
+
+.item-download-count {
+  font-size: 24rpx;
+  color: #999;
+  margin-bottom: 20rpx;
+}
+
+.item-buttons {
+  display: flex;
+  align-items: center;
+  align-content: center;
+}
+
+.preview-button {
+  flex: 1;
+  background-color: #409eff;
+  color: #fff;
+  border: none;
+  border-radius: 40rpx;
+  padding: 12rpx 0;
+  font-size: 32rpx;
+  display: flex;
+  justify-content: center;
+  align-content: center;
+}
+
+.download-icon {
+  width: 45rpx;
+  height: 40rpx;
+  margin-left: 20rpx;
+}
+
+.download-icons {
+  width: 45rpx;
+  height: 40rpx;
+  margin-right: 20rpx;
+}

+ 82 - 0
subpackages/imghome/imghome.js

@@ -0,0 +1,82 @@
+// subpackages/dahome/dahome.js
+Page({
+  data: {
+    // levelOptions: ['初级', '中级', '高级'],
+    // selectedLevelIndex: 0,
+    typeOptions: ['1段', '2段', '3段'],
+    selectedTypeIndex: 0,
+    items: [
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },{
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },{
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },{
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '全脑智能开发答案',
+        subtitle: '初级1',
+        downloadCount: 128
+      },
+    ],
+    souimg: '',
+    xialaimg: '',
+    goods_9: '',
+  },
+
+  onLoad() {
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/xiala.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/goods/goods_9.jpg'
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        souimg: tempFilePaths[0],
+        xialaimg: tempFilePaths[1],
+        goods_9: tempFilePaths[2],
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  // handleLevelChange(e) {
+  //   this.setData({
+  //     selectedLevelIndex: e.detail.value
+  //   });
+  // },
+  handleTypeChange(e) {
+    this.setData({
+      selectedTypeIndex: e.detail.value
+    });
+  }
+})

+ 4 - 0
subpackages/imghome/imghome.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "动手动脑图库"
+}

+ 35 - 0
subpackages/imghome/imghome.wxml

@@ -0,0 +1,35 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <view class="top_boxs">
+      <!-- 搜索 -->
+      <view class="search-bar">
+        <input class="search-input" placeholder="搜索课件" />
+        <image class="search-icon" src="{{souimg}}" />
+      </view>
+      <!-- 下拉框 -->
+      <view class="dropdown-box">
+        <!-- <picker mode="selector" range="{{levelOptions}}" value="{{selectedLevelIndex}}" bindchange="handleLevelChange">
+          <view class="dropdown-item">{{levelOptions[selectedLevelIndex]}} <image class="xiala_boxs" src="../../image/imgs/xiala.png" /></view>
+        </picker> -->
+        <picker mode="selector" range="{{typeOptions}}" value="{{selectedTypeIndex}}" bindchange="handleTypeChange">
+          <view class="dropdown-item">{{typeOptions[selectedTypeIndex]}} <image class="xiala_boxs" src="{{xialaimg}}" /></view>
+        </picker>
+      </view>
+    </view>
+
+    <!-- 列表 -->
+    <view class="list-box">
+        <block wx:for="{{items}}" wx:key="index">
+          <view class="item">
+            <image class="item-image" src="{{goods_9}}" />
+            <view class="item-content">
+              <view class="item-title">{{item.title}}</view>
+              <view style="display: flex; justify-content: space-between;">
+                <view class="item-subtitle">{{item.subtitle}}</view>
+              </view>
+            </view>
+          </view>
+        </block>
+      </view>
+  </view>
+</view>

+ 126 - 0
subpackages/imghome/imghome.wxss

@@ -0,0 +1,126 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  /* height: calc(100vh - 40rpx); */
+  padding: 0 0;
+}
+
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  /* height: calc(100vh - 40rpx); */
+  padding: 0 0;
+}
+
+.top_boxs {
+  width: 100%;
+  height: 80rpx;
+  display: flex;
+  justify-content: space-between;
+}
+
+.search-bar {
+  width: 73%;
+  position: relative;
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  padding-right: 60rpx;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.dropdown-box {
+  display: flex;
+  align-items: center;
+}
+
+.dropdown-item {
+  margin-left: 20rpx;
+  padding: 12rpx 16rpx;
+  background-color: #409eff;
+  color: #fff;
+  border-radius: 8rpx;
+  font-size: 32rpx;
+  display: flex;
+  align-content: center;
+  justify-content: center;
+}
+
+.xiala_boxs {
+  width: 45rpx;
+  height: 45rpx;
+  margin: 0;
+  padding: 0rpx;
+}
+
+.list-box {
+  margin-top: 20rpx;
+  display: flex;
+  flex-wrap: wrap;
+}
+
+.item {
+  width: 48%;
+  margin-right: 4%;
+  margin-bottom: 20rpx;
+  background-color: #fff;
+  border-radius: 12rpx;
+  overflow: hidden;
+  box-shadow: 0 2rpx 6rpx rgba(0, 0, 0, 0.1);
+}
+
+.item:nth-child(2n) {
+  margin-right: 0;
+}
+
+.item-image {
+  width: 100%;
+  height: 300rpx;
+  object-fit: cover;
+}
+
+.item-content {
+  padding: 20rpx;
+}
+
+.item-title {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.item-subtitle {
+  font-size: 28rpx;
+  color: #666;
+  margin-bottom: 10rpx;
+}
+
+.item-download-count {
+  font-size: 24rpx;
+  color: #999;
+  margin-bottom: 20rpx;
+}
+
+.item-buttons {
+  display: flex;
+  align-items: center;
+  align-content: center;
+}
+

+ 50 - 0
subpackages/logoff/logoff.js

@@ -0,0 +1,50 @@
+Page({
+  data: {
+    selectedReasons: []
+  },
+
+  onLoad(options) {
+    // 页面加载时的初始化操作
+  },
+
+  handleCheckboxChange(e) {
+    const { value } = e.detail;
+    let selectedReasons = this.data.selectedReasons;
+
+    if (value.includes('use_inconvenience')) {
+      selectedReasons.includes('use_inconvenience') ? selectedReasons.splice(selectedReasons.indexOf('use_inconvenience'), 1) : selectedReasons.push('use_inconvenience');
+    }
+    if (value.includes('security_privacy')) {
+      selectedReasons.includes('security_privacy') ? selectedReasons.splice(selectedReasons.indexOf('security_privacy'), 1) : selectedReasons.push('security_privacy');
+    }
+    if (value.includes('other_reasons')) {
+      selectedReasons.includes('other_reasons') ? selectedReasons.splice(selectedReasons.indexOf('other_reasons'), 1) : selectedReasons.push('other_reasons');
+    }
+
+    this.setData({ selectedReasons });
+  },
+
+  confirmLogout() {
+    const { selectedReasons } = this.data;
+    if (selectedReasons.length === 0) {
+      wx.showToast({
+        title: '请选择注销原因',
+        icon: 'none'
+      });
+      return;
+    }
+
+    wx.showModal({
+      title: '提示',
+      content: '确定要注销吗?',
+      success(res) {
+        if (res.confirm) {
+          // 执行注销操作
+          console.log('用户点击确定');
+        } else if (res.cancel) {
+          console.log('用户点击取消');
+        }
+      }
+    });
+  }
+});

+ 4 - 0
subpackages/logoff/logoff.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "用户注销"
+}

+ 32 - 0
subpackages/logoff/logoff.wxml

@@ -0,0 +1,32 @@
+<view style="background: #f5f5f5; padding: 20rpx;">
+  <view class="container">
+    <!-- 注销须知 -->
+    <view class="notice">
+      <view class="title">注销须知</view>
+      <view>1. 注销成功账号将无法登录</view>
+      <view>2. 注销成功将无法查看所有课件信息</view>
+    </view>
+
+    <!-- 请选择注销用户的原因 -->
+    <view class="reasons">
+      <view class="title">请选择注销用户的原因</view>
+      <label class="checkbox-item">
+        <checkbox value="use_inconvenience" /> 使用不便
+      </label>
+      <label class="checkbox-item">
+        <checkbox value="security_privacy" /> 安全或隐私顾虑
+      </label>
+      <label class="checkbox-item">
+        <checkbox value="other_reasons" /> 其他原因
+      </label>
+    </view>
+
+    <!-- 请输入您的意见或建议 -->
+    <view class="feedback">
+      <textarea placeholder="请输入您的意见或建议" />
+    </view>
+
+    <!-- 确认注销按钮 -->
+    <button class="confirm-button">确认注销</button>
+  </view>
+</view>

+ 55 - 0
subpackages/logoff/logoff.wxss

@@ -0,0 +1,55 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  /* height: calc(100vh - 40rpx); */
+  padding: 0 0;
+}
+
+.notice, .reasons, .feedback {
+  padding: 20rpx;
+  background: #fff;
+  width: 100%;
+  margin-bottom: 20rpx;
+  border-radius: 16rpx;
+}
+
+.notice view, .reasons view {
+  font-size: 28rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.title {
+  font-size: 36rpx !important;
+  margin-bottom: 20rpx !important;
+}
+
+.checkbox-item {
+  display: flex;
+  align-items: center;
+  margin-bottom: 10rpx;
+}
+
+.checkbox-item checkbox {
+  margin-right: 10rpx;
+}
+
+.feedback textarea {
+  width: 100%;
+  height: 120rpx;
+  font-size: 28rpx;
+  color: #333;
+  border: none;
+  outline: none;
+  resize: none;
+}
+
+.confirm-button {
+  width: 100% !important;
+  height: 80rpx;
+  background-color: #1890ff;
+  color: #fff;
+  font-size: 32rpx;
+  border: none;
+  border-radius: 40rpx;
+}

+ 145 - 0
subpackages/order/order.js

@@ -0,0 +1,145 @@
+Page({
+  data: {
+    categoriesindex: 1,
+    categories: [
+      {
+        title: '全部',
+        type: 1,
+      },
+      {
+        title: '待支付',
+        type: 2,
+      },
+      {
+        title: '待收货',
+        type: 3,
+      },
+      {
+        title: '已完成',
+        type: 4,
+      }
+    ],
+    orders: [
+      {
+        status: 1,
+        date: '2023-05-01',
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '幼儿启蒙绘本 10册套装',
+        description: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        actionText: '确认收货'
+      },
+      {
+        status: 2,
+        date: '2023-05-01',
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '幼儿启蒙绘本 10册套装',
+        description: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        actionText: '立即支付'
+      },
+      {
+        status: 3,
+        date: '2023-05-01',
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '幼儿启蒙绘本 10册套装',
+        description: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        actionText: '再来一单'
+      }
+    ],
+    souimg: '',
+  },
+
+  onLoad(options) {
+    const type = Number(options.type) || 1;
+    console.log('收到的 type 参数:', type);
+    // 根据 type 加载数据
+    this.setData({
+      categoriesindex: type
+    });
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/sou.png',
+    ];
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        souimg: tempFilePaths[0]
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  tabcategories(e) {
+    const type = e.currentTarget.dataset.type;
+    this.setData({
+      categoriesindex: type
+    });
+  },
+
+  handleAction1(e) {
+    console.log('查看详情', e);
+  },
+
+  handleAction2(e) {
+    console.log('处理其他操作', e);
+  },
+
+  // 处理第一个按钮的点击事件
+  handleAction1: function (event) {
+      const index = event.currentTarget.dataset.index; // 获取点击的订单索引
+      const status = this.data.orders[index].status; // 获取订单状态
+
+      switch (status) {
+          case 1:
+              console.log("查看详情", index);
+              // 执行查看详情的逻辑
+              break;
+          case 2:
+              console.log("取消订单", index);
+              // 执行取消订单的逻辑
+              break;
+          case 3:
+              console.log("申请售后", index);
+              // 执行申请售后的逻辑
+              break;
+          default:
+              console.log("未知状态");
+      }
+  },
+
+  // 处理第二个按钮的点击事件
+  handleAction2: function (event) {
+      const index = event.currentTarget.dataset.index; // 获取点击的订单索引
+      const status = this.data.orders[index].status; // 获取订单状态
+
+      switch (status) {
+          case 1:
+              console.log("确认收货", index);
+              // 执行确认收货的逻辑
+              break;
+          case 2:
+              console.log("立即支付", index);
+              // 执行立即支付的逻辑
+              break;
+          case 3:
+              console.log("再来一单", index);
+              // 执行再来一单的逻辑
+              break;
+          default:
+              console.log("未知状态");
+      }
+  },
+
+  goToGoodsList () {
+    wx.navigateTo({
+      url: '/subpackages/orderdetails/orderdetails'
+    });
+  }
+});

+ 4 - 0
subpackages/order/order.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "订单查询"
+}

+ 48 - 0
subpackages/order/order.wxml

@@ -0,0 +1,48 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <!-- 搜索框 -->
+    <view class="search-bar">
+      <input class="search-input" placeholder="搜索订单号或商品名称" />
+      <image class="search-icon" src="{{souimg}}" />
+    </view>
+
+    <!-- 分类 -->
+    <view class="category-tabs">
+      <view wx:for="{{categories}}" wx:key="type">
+        <view class="category-tab {{item.type === categoriesindex ? 'active' : ''}}" bindtap="tabcategories" data-type="{{item.type}}">{{item.title}}</view>
+      </view>
+    </view>
+
+    <!-- 列表 -->
+    <view class="order-list">
+      <block wx:for="{{orders}}" wx:key="order_id">
+        <view class="order-item" bindtap="goToGoodsList">
+          <view class="order-status">
+            <view class="{{ item.status === 1 ? 'dsh' : item.status === 2 ? 'dfk' : 'ywc' }}">{{item.status === 1 ? "待收货" : item.status === 2 ? "待付款" : "已完成"}}</view>
+            <view>{{item.date}}</view>
+          </view>
+          <view>订单号: {{item.price}}</view>
+          <view class="order-detail">
+            <image class="order-image" src="{{item.image}}" mode="aspectFill"></image>
+            <view class="order-info">
+              <view class="order-title">{{item.title}}</view>
+              <view style="display: flex; justify-content: space-between;">
+                <view class="order-description">{{item.description}}</view>
+                <view class="order-price">¥{{item.price}}</view>
+              </view>
+              <view class="order-description">数量: 1</view>
+            </view>
+          </view>
+          <view class="order-actions">
+            <button class="order-action-btn1" bindtap="handleAction1" data-index="{{index}}">
+                {{ item.status === 1 ? "查看详情" : item.status === 2 ? "取消订单" : "申请售后" }}
+            </button>
+            <button class="order-action-btn2" bindtap="handleAction2" data-index="{{index}}">
+                {{ item.status === 1 ? "确认收货" : item.status === 2 ? "立即支付" : "再来一单" }}
+            </button>
+          </view>
+        </view>
+      </block>
+    </view>
+  </view>
+</view>

+ 159 - 0
subpackages/order/order.wxss

@@ -0,0 +1,159 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  padding: 0 0;
+}
+
+.search-bar {
+  width: calc(100% - 50rpx);
+  position: relative;
+  display: flex;
+  align-items: center;
+  background-color: #fff;
+  border: 1rpx solid #dcdfe6;
+  border-radius: 12rpx;
+  padding: 16rpx 20rpx;
+}
+
+.search-bar input {
+  flex: 1;
+  height: 100%;
+  padding-right: 60rpx;
+  font-size: 32rpx;
+  border: none;
+  background: transparent;
+}
+
+.search-icon {
+  position: absolute;
+  right: 20rpx;
+  width: 45rpx;
+  height: 45rpx;
+}
+
+.category-tabs {
+  width: 100%;
+  display: flex;
+  justify-content: space-between;
+  margin-top: 20rpx;
+}
+
+.category-tab {
+  margin: 0 16rpx;
+  padding: 13rpx 30rpx;
+  font-size: 26rpx;
+  color: #666;
+  border-radius: 25rpx;
+}
+
+.category-tab.active {
+  color: #409eff;
+  background: #ecf5ff;
+  border: 1rpx solid #d9ecff;
+}
+
+.order-list {
+  width: 100%;
+  margin-top: 20rpx;
+}
+
+.order-item {
+  background: #fff;
+  border-radius: 16rpx;
+  padding: 20rpx;
+  margin-bottom: 20rpx;
+}
+
+.order-status {
+  display: flex;
+  justify-content: space-between;
+  align-content: center;
+  margin-bottom: 10rpx;
+}
+
+.order-detail {
+  display: flex;
+  margin: 20rpx 0;
+}
+
+.order-image {
+  width: 120rpx;
+  height: 120rpx;
+  margin-right: 20rpx;
+}
+
+.order-info {
+  flex: 1;
+}
+
+.order-title {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.order-description {
+  font-size: 28rpx;
+  color: #666;
+  margin-bottom: 10rpx;
+}
+
+.order-price {
+  font-size: 32rpx;
+  color: #f00;
+}
+
+.order-actions {
+  display: flex;
+  justify-content: flex-end !important;
+  border-top: 1rpx solid #cccccc;
+  padding-top: 30rpx;
+  padding-bottom: 20rpx;
+}
+
+.order-action-btn1 {
+  width: 200rpx !important;
+  margin-left: 20rpx;
+  padding: 20rpx 20rpx;
+  font-size: 28rpx;
+  color: #909399;
+  background: #f4f4f5;
+  border: 1rpx solid #c7c9cc;
+  border-radius: 40rpx;
+}
+
+.order-action-btn2 {
+  width: 200rpx !important;
+  margin-left: 20rpx;
+  padding: 20rpx 20rpx;
+  font-size: 28rpx;
+  color: #fff;
+  background: #409eff;
+  border: 1rpx solid #409eff;
+  border-radius: 12rpx;
+  border-radius: 40rpx;
+}
+
+.dsh {
+  color: #67c23a;
+  background: #f0f9eb;
+  border: 1rpx solid #e1f3d8;
+  padding: 7rpx 20rpx;
+  border-radius: 25rpx;
+}
+
+.dfk {
+  color: #e6a23c;
+  background: #fcf6ec;
+  border: 1rpx solid #faecd8;
+  padding: 7rpx 20rpx;
+  border-radius: 25rpx;
+}
+
+.ywc {
+  color: #409eff;
+  background: #ecf5ff;
+  border: 1rpx solid #d9ecff;
+  padding: 7rpx 20rpx;
+  border-radius: 25rpx;
+}

+ 36 - 0
subpackages/orderdetails/orderdetails.js

@@ -0,0 +1,36 @@
+// subpackages/orderdetails/orderdetails.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+    dingwei: '',
+    fuzhi: '',
+    yesbaoguo: '',
+  },
+
+  onLoad() {
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/dingwei.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/fuzhi.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/yesbaoguo.png'
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        dingwei: tempFilePaths[0],
+        fuzhi: tempFilePaths[1],
+        yesbaoguo: tempFilePaths[2],
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+})

+ 4 - 0
subpackages/orderdetails/orderdetails.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "订单详情"
+}

+ 66 - 0
subpackages/orderdetails/orderdetails.wxml

@@ -0,0 +1,66 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <view class="top_boxs">
+      <view class="displayboxs">
+        <view class="left">
+          <image src="{{yesbaoguo}}" alt=""/>
+        </view>
+        <view class="right">您的快件已签收</view>
+      </view>
+      <view class="displayboxs" style="margin-top: 10rpx;">
+        <view class="left">
+          <image src="{{dingwei}}" alt=""/>
+        </view>
+        <view class="right">
+          <view>苏州市姑苏区江平路186号枕河人家小区</view>
+          <view>周白芷  153***0508</view>
+        </view>
+      </view>
+    </view>
+    <view class="list_boxs">
+      <view class="title">商品信息</view>
+      <!-- 商品信息 -->
+      <view class="product_info">
+        <image src="https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500" alt="" class="product_image"/>
+        <view class="product_details">
+          <view class="product_name">幼儿启蒙绘本10册套装</view>
+          <view class="product_description">适合3-6岁儿童,培养创造力</view>
+          <view class="product_quantity">数量: 1套</view>
+        </view>
+        <view class="product_price">¥134.00</view>
+      </view>
+      <view class="order_info">
+        <view class="order_item">
+          <text>订单编号</text>
+          <view>
+            <text>20231115143012345</text>
+            <image style="width: 35rpx; height: 35rpx;margin-left: 16rpx;" src="{{fuzhi}}" alt=""/></view>
+        </view>
+        <view class="order_item">
+          <text>下单时间</text>
+          <text>2023-11-15 14:30:22</text>
+        </view>
+        <view class="order_item">
+          <text>支付金额</text>
+          <text>¥134.00</text>
+        </view>
+        <view class="order_item">
+          <text>邮寄方式</text>
+          <text>自提</text>
+        </view>
+        <view class="order_item">
+          <view>物流单号</view>
+          <view>
+            <text>SF123123123123</text>
+            <image style="width: 35rpx; height: 35rpx;margin-left: 16rpx;" src="{{fuzhi}}" alt=""/>
+          </view>
+        </view>
+      </view>
+    </view>
+    <!-- 底部栏 -->
+    <view class="button_boxs">
+      <button class="buttons">申请售后</button>
+      <button class="buttons2">再次购买</button>
+    </view>
+  </view>
+</view>

+ 122 - 0
subpackages/orderdetails/orderdetails.wxss

@@ -0,0 +1,122 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  padding: 0 0;
+}
+
+.top_boxs {
+  width: calc( 100% - 60rpx );
+  padding: 30rpx;
+  background: #fff;
+  border-radius: 16rpx;
+  margin-bottom: 20rpx;
+}
+
+.list_boxs {
+  width: calc( 100% - 60rpx );
+  padding: 30rpx;
+  background: #fff;
+  border-radius: 16rpx;
+}
+
+.title {
+  font-size: 34rpx;
+}
+
+.button_boxs {
+  padding: 30rpx;
+  width: calc(100% - 60rpx);
+  background: #fff;
+  position: fixed;
+  bottom: 0;
+  left: 0;
+  display: flex;
+  justify-content: space-between;
+  padding-bottom: 40rpx;
+}
+
+.displayboxs {
+  display: flex;
+}
+
+.left {
+  width: 10%;
+}
+
+.left image {
+  width: 40rpx;
+  height: 40rpx;
+}
+
+.right {
+  width: 90%;
+  font-size: 30rpx;
+}
+
+.product_info {
+  display: flex;
+  margin-top: 20rpx;
+}
+
+.product_image {
+  width: 120rpx;
+  height: 120rpx;
+  margin-right: 20rpx;
+}
+
+.product_details {
+  flex: 1;
+}
+
+.product_name {
+  font-size: 32rpx;
+  color: #333;
+}
+
+.product_description {
+  font-size: 28rpx;
+  color: #666;
+  margin-top: 10rpx;
+}
+
+.product_quantity {
+  font-size: 28rpx;
+  color: #999;
+  margin-top: 10rpx;
+}
+
+.product_price {
+  font-size: 32rpx;
+  color: #ff5722;
+  margin-left: 20rpx;
+}
+
+.order_info {
+  margin-top: 30rpx;
+  border-top: 1rpx solid #d8d8d8;
+  padding-top: 30rpx;
+}
+
+.order_item {
+  display: flex;
+  justify-content: space-between;
+  font-size: 28rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.buttons {
+  width: 300rpx !important;
+  border: 1rpx solid #c7c9cc !important;
+  background: #f4f4f5;
+  color: #c7c9cc;
+  border-radius: 40rpx;
+}
+
+.buttons2 {
+  width: 300rpx !important;
+  border: 1rpx solid #409eff;
+  background: #409eff;
+  color: #fff;
+  border-radius: 40rpx;
+}

+ 63 - 0
subpackages/productdetails/productdetails.js

@@ -0,0 +1,63 @@
+Page({
+  data: {
+    item: {},
+    selectedSpec: '基础款(50粒)',
+    quantity: 1,
+    showimg: '',
+    gouwucimg: '',
+  },
+  onLoad(options) {
+    console.log('进了');
+    // const itemData = decodeURIComponent(options.data);
+    // const item = JSON.parse(itemData);
+    // this.setData({
+    //   item: item
+    // });
+
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/show.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/gouwuc_img.png'
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        showimg: tempFilePaths[0],
+        gouwucimg: tempFilePaths[1]
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  handleSpecSelect(e) {
+    const spec = e.currentTarget.dataset.spec;
+    this.setData({ selectedSpec: spec });
+  },
+  
+  handleQuantityChange(e) {
+    const action = e.currentTarget.dataset.action;
+    let quantity = this.data.quantity;
+    if (action === 'plus') {
+      quantity++;
+    } else if (action === 'minus' && quantity > 1) {
+      quantity--;
+    }
+    this.setData({ quantity });
+  },
+  
+  addToCart() {
+    // 加入购物车逻辑
+    console.log('加入购物车');
+  },
+  
+  buyNow() {
+    // 立即购买逻辑
+    console.log('立即购买');
+  }
+});

+ 4 - 0
subpackages/productdetails/productdetails.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "商品详情"
+}

+ 64 - 0
subpackages/productdetails/productdetails.wxml

@@ -0,0 +1,64 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="goodslist_boxs">
+    <!-- 商品图片 -->
+    <image class="goods-image" src="https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500" mode="aspectFill"></image>
+    
+    <!-- 商品价格和浏览量 -->
+    <view class="price-and-views">
+      <view>
+        <text class="price">¥68.00</text>
+        <text class="original-price">¥99.00</text>
+      </view>
+      <view style="display: flex; align-content: center;">
+        <image style="width: 30rpx; height: 30rpx;" src="{{showimg}}" />
+        <text style="margin-left: 16rpx;" class="views">256人浏览</text>
+      </view>
+    </view>
+    
+    <!-- 商品标题 -->
+    <view class="goods-title">儿童益智积木玩具套装 大颗粒安全无毒</view>
+    
+    <!-- 选择规格 -->
+    <view class="specifications">
+      <text style="font-size: 38rpx;">选择规格</text>
+      <view class="specifications_boxs">
+        <button class="spec-btn active">基础款(50粒)</button>
+        <button class="spec-btn">进阶款(100粒)</button>
+        <button class="spec-btn">豪华款(200粒)</button>
+      </view>
+    </view>
+    
+    <!-- 购买数量 -->
+    <view class="quantity">
+      <text style="font-size: 38rpx;">购买数量</text>
+
+      <van-stepper
+        value="1"
+        bind:change="onChange"
+      />
+    </view>
+    
+    <!-- 产品详情 -->
+    <view class="product-details">
+      <text style="font-size: 38rpx;">产品详情</text>
+      <view class="details-list">
+        <text>• 安全材质:采用环保ABS塑料,无毒无味,通过国际安全认证</text>
+        <text>• 大颗粒设计:专为3-6岁儿童设计,防止误吞</text>
+        <text>• 益智启蒙:培养孩子空间想象力、创造力和手眼协调能力</text>
+        <text>• 丰富配件:包含多种形状积木、数字和字母积木</text>
+      </view>
+    </view>
+    
+    <!-- 按钮区域 -->
+    <view class="buttons">
+    <view style="width: 10%; text-align: center;">
+      <image class="search-icon" src="{{gouwucimg}}" />
+      <view style="font-size: 24rpx;">购物车</view>
+    </view>
+      <view style="display: flex; justify-content: space-between; width: 74%;">
+        <button class="cart-btn">加入购物车</button>
+        <button class="buy-btn">立即购买</button>
+      </view>
+    </view>
+  </view>
+</view>

+ 157 - 0
subpackages/productdetails/productdetails.wxss

@@ -0,0 +1,157 @@
+.goodslist_boxs {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+}
+
+.goods-image {
+  width: 100%;
+  height: 400rpx;
+}
+
+.price-and-views {
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  padding: 20rpx;
+}
+
+.price {
+  color: #ff5722;
+  font-size: 32rpx;
+}
+
+.original-price {
+  color: #999;
+  font-size: 24rpx;
+  margin-left: 20rpx;
+  text-decoration: line-through;
+}
+
+.views {
+  color: #999;
+  font-size: 24rpx;
+}
+
+.goods-title {
+  padding: 0 20rpx;
+  font-size: 32rpx;
+  font-weight: bold;
+}
+
+.specifications {
+  margin: 20rpx 0;
+  padding: 20rpx;
+  background: #fff;
+  border-radius: 16rpx;
+}
+
+.specifications_boxs {
+  width: 100%;
+  height: 80%;
+  margin-top: 20rpx;
+  display: flex;
+  flex-wrap: wrap; /* 允许内容自动换行 */
+  justify-content: flex-start; /* 靠右排列 */
+  align-content: flex-start;
+  gap: 20rpx; /* 设置项目之间的间距 */
+}
+
+.spec-btn {
+  width: 48% !important;
+  margin-bottom: 20rpx; /* 设置底部边距,确保换行后有间距 */
+  padding: 10rpx 20rpx;
+  border: 1px solid #ccc;
+  border-radius: 50rpx;
+  font-size: 28rpx;
+  white-space: nowrap; /* 防止文字换行 */
+}
+
+.spec-btn.active {
+  background-color: #fff;
+  color: #fff;
+  border-color: #409eff;
+  color: #409eff;
+}
+
+.quantity {
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  padding: 20rpx;
+  background: #fff;
+  border-radius: 16rpx;
+}
+
+.quantity-controls {
+  display: flex;
+  align-items: center;
+}
+
+.quantity-btn {
+  width: 60rpx;
+  height: 60rpx;
+  background-color: #f5f5f5;
+  border: none;
+  font-size: 40rpx;
+  color: #999;
+}
+
+.quantity-input {
+  width: 80rpx;
+  height: 60rpx;
+  text-align: center;
+  font-size: 32rpx;
+  margin: 0 10rpx;
+}
+
+.product-details {
+  padding: 20rpx;
+  background: #fff;
+  border-radius: 16rpx;
+  margin-top: 20rpx;
+  margin-bottom: 150rpx;
+}
+
+.details-list text {
+  margin-top: 20rpx;
+  display: block;
+  margin-bottom: 10rpx;
+  font-size: 30rpx;
+  color: #666;
+}
+
+.buttons {
+  width: 100%;
+  display: flex;
+  justify-content: space-around;
+  padding: 20rpx;
+  position: fixed;
+  bottom: 0;
+  left: 0;
+  background: #fff;
+  padding-bottom: 40rpx;
+  padding-top: 20rpx;
+}
+
+.cart-btn, .buy-btn {
+  width: 40%;
+  height: 80rpx;
+  border-radius: 50rpx;
+  font-size: 32rpx;
+  color: #fff;
+}
+
+.cart-btn {
+  width: 260rpx !important;
+  background-color: #ea0000;
+}
+
+.buy-btn {
+  width: 260rpx !important;
+  background-color: #409eff;
+}
+
+.search-icon {
+  width: 50rpx;
+  height: 50rpx;
+}

+ 124 - 0
subpackages/purchasehistory/purchasehistory.js

@@ -0,0 +1,124 @@
+Page({
+  data: {
+    role: "teacher",
+    historyList: [
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      {
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        title: '趣味识字卡片',
+        date: '2023-10-15 14:30',
+        checked: false
+      },
+      // 其他列表项...
+    ],
+    isManaging: false
+  },
+
+  onLoad(options) {
+    // 页面加载时的初始化操作
+  },
+
+  onReachBottom() {
+    // 上拉触底事件的处理函数
+    this.loadMore();
+  },
+
+  loadMore() {
+    // 加载更多数据的逻辑
+    console.log('加载更多');
+  },
+
+  toggleManageMode() {
+    const { isManaging, historyList } = this.data;
+    if (isManaging) {
+      if (historyList && historyList.length > 0) {
+        historyList.forEach(item => item.checked = false);
+      }
+      this.setData({ isManaging: false });
+    } else {
+      this.setData({ isManaging: true });
+    }
+  },
+
+  selectAll() {
+    const { historyList } = this.data;
+    if (historyList && historyList.length > 0) {
+      const allChecked = historyList.every(item => item.checked);
+      historyList.forEach(item => item.checked = !allChecked);
+      this.setData({ historyList });
+    }
+  },
+
+  deleteItems() {
+    const { historyList } = this.data;
+    if (historyList && historyList.length > 0) {
+      const newList = historyList.filter(item => !item.checked);
+      this.setData({ historyList: newList });
+    }
+  }
+});

+ 4 - 0
subpackages/purchasehistory/purchasehistory.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "下载历史"
+}

+ 31 - 0
subpackages/purchasehistory/purchasehistory.wxml

@@ -0,0 +1,31 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <view class="title_1" bindtap="toggleManageMode">
+      {{ isManaging ? '退出管理' : '购买历史管理' }}
+    </view>
+    <!-- 列表 -->
+    <view class="lishi_list {{ isManaging ? 'ones' : ''}}">
+      <block wx:for="{{ historyList }}" wx:key="index">
+        <view class="lishi_item">
+          <checkbox wx:if="{{ isManaging }}" class="checkbox" value="{{ index }}" checked="{{ item.checked }}" />
+          <image src="{{ item.image }}" mode="aspectFill" class="item_image"></image>
+          <view class="item_info">
+            <view class="item_title">{{ item.title }}</view>
+            <view class="item_date">{{ item.date }}</view>
+          </view>
+          <!-- <view class="xiazai_img">
+            <image class="search-icon" src="../../image/imgs/xiazai.png" />
+          </view> -->
+        </view>
+      </block>
+    </view>
+    <!-- <button class="load_more_button" wx:if="{{ !isManaging }}">加载更多</button> -->
+    <view class="bottom_bar" wx:if="{{ isManaging }}">
+      <view class="select_all" >
+        <checkbox  bindtap="selectAll" />
+        <view style="padding-left: 16rpx;">全选</view>
+      </view>
+      <button class="delete_button" bindtap="deleteItems">删除</button>
+    </view>
+  </view>
+</view>

+ 111 - 0
subpackages/purchasehistory/purchasehistory.wxss

@@ -0,0 +1,111 @@
+.container {
+  margin: 0 30rpx;
+  width: calc(100% - 60rpx);
+  padding: 0;
+  height: 100%;
+}
+
+.title_1 {
+  width: 100%;
+  font-size: 34rpx;
+  font-weight: bold;
+  padding: 20rpx 0;
+}
+
+.lishi_list {
+  width: 100%;
+  overflow: hidden;
+}
+
+.ones {
+  padding-bottom: 140rpx;
+}
+
+.lishi_item {
+  display: flex;
+  background-color: #fff;
+  border-radius: 16rpx;
+  align-items: center;
+  padding: 20rpx;
+  margin: 20rpx 0;
+}
+
+.checkbox {
+  margin-right: 20rpx;
+}
+
+.item_image {
+  width: 100rpx;
+  height: 100rpx;
+  margin-right: 20rpx;
+  border-radius: 12rpx;
+}
+
+.item_info {
+  flex: 1;
+}
+
+.item_title {
+  font-size: 28rpx;
+  color: #333;
+}
+
+.item_date {
+  font-size: 24rpx;
+  color: #999;
+  margin-top: 10rpx;
+}
+
+.xiazai_img {
+  width: 45rpx;
+  height: 35rpx;
+  float: right;
+}
+
+.search-icon {
+  width: 100%;
+  height: 100%;
+}
+
+.load_more_button {
+  width: 100%;
+  margin-top: 20rpx;
+  background-color: #e6f7ff;
+  color: #1890ff;
+  border: none;
+  border-radius: 50rpx;
+  padding: 10rpx 0;
+  font-size: 28rpx;
+}
+
+.bottom_bar {
+  height: 110rpx;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  padding: 20rpx 50rpx;
+  background-color: #fff;
+  position: fixed;
+  bottom: 0;
+  left: 0;
+  right: 0;
+}
+
+.select_all {
+  align-content: center;
+  align-content: center;
+  display: flex;
+  font-size: 28rpx;
+  color: #333;
+}
+
+.delete_button {
+  width: 66% !important;
+  background-color: #1890ff;
+  color: #fff;
+  border: none;
+  border-radius: 50rpx;
+  padding: 23rpx 0;
+  font-size: 28rpx;
+  margin: 0 !important;
+}

+ 87 - 0
subpackages/submitorder/submitorder.js

@@ -0,0 +1,87 @@
+Page({
+  data: {
+    products: [
+      {
+        id: 1,
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        name: '幼儿启蒙绘本10册套装',
+        desc: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        quantity: 1
+      },
+      {
+        id: 1,
+        image: 'https://img1.baidu.com/it/u=2052658756,3021621759&fm=253&fmt=auto&app=120&f=JPEG?w=500&h=500',
+        name: '幼儿启蒙绘本10册套装',
+        desc: '适合3-6岁儿童,培养创造力',
+        price: 134.00,
+        quantity: 1
+      }
+    ],
+    totalAmount: 134.00,
+    dingweiimg: '',
+    youjiantouimg: '',
+  },
+
+  onLoad(options) {
+    // const title = options.title ? decodeURIComponent(options.title) : '商品列表';
+    // this.setData({ title });
+    // wx.setNavigationBarTitle({ title });
+
+    const fileIDs = [
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/dingwei.png',
+      'cloud://cloud1-6g98iw7i28b01747.636c-cloud1-6g98iw7i28b01747-1367995226/images/icon/youjiantou.png',
+    ];
+    
+    // 并发下载多个 fileID
+    Promise.all(
+      fileIDs.map(fileID => wx.cloud.downloadFile({ fileID }))
+    ).then(results => {
+      // 每个 result 对应一个下载结果
+      const tempFilePaths = results.map(r => r.tempFilePath);
+      console.log('全部下载成功:', tempFilePaths);
+      this.setData({
+        dingweiimg: tempFilePaths[0],
+        youjiantouimg: tempFilePaths[1],
+      });
+    }).catch(err => {
+      console.error('有文件下载失败:', err);
+    });
+  },
+
+  decreaseQuantity(e) {
+    const index = e.currentTarget.dataset.index;
+    let products = this.data.products;
+    if (products[index].quantity > 1) {
+      products[index].quantity--;
+      this.setData({ products });
+      this.calculateTotal();
+    }
+  },
+
+  increaseQuantity(e) {
+    const index = e.currentTarget.dataset.index;
+    let products = this.data.products;
+    products[index].quantity++;
+    this.setData({ products });
+    this.calculateTotal();
+  },
+
+  calculateTotal() {
+    let totalAmount = 0;
+    this.data.products.forEach(item => {
+      totalAmount += item.price * item.quantity;
+    });
+    this.setData({ totalAmount });
+  },
+
+  handlePay() {
+    // 处理支付逻辑
+  },
+
+  setGridView() {
+    wx.navigateTo({
+      url: '/subpackages/addresslist/addresslist'
+    });
+  }
+});

+ 4 - 0
subpackages/submitorder/submitorder.json

@@ -0,0 +1,4 @@
+{
+  "usingComponents": {},
+  "navigationBarTitleText": "提交订单"
+}

+ 51 - 0
subpackages/submitorder/submitorder.wxml

@@ -0,0 +1,51 @@
+<view style="background: #f5f5f5; padding: 20rpx 0;">
+  <view class="container">
+    <!-- 地址选择 -->
+    <view class="dizhi_boxs" bindtap="setGridView">
+      <view class="address_info">
+        <image src="{{dingweiimg}}" class="location_icon"></image>
+      </view>
+      <view class="contact_info">
+        <view class="address_text">上海市浦东新区创新大道88号科技智慧城</view>
+        <view style="margin-top: 10rpx;">
+          <text class="name">陈宇轩</text>
+          <text class="phone">16743435789</text>
+        </view>
+      </view>
+      <image src="{{youjiantouimg}}" class="right_arrow"></image>
+    </view>
+
+    <!-- 购买商品列表 -->
+    <view class="product_list">
+      <block wx:for="{{products}}" wx:key="index">
+        <view class="product_item">
+          <image src="{{item.image}}" class="product_image"></image>
+          <view class="product_details">
+            <view class="product_name">{{item.name}}</view>
+            <view class="product_desc">{{item.desc}}</view>
+            <view class="price_and_quantity">
+              <text class="product_price">¥{{item.price}}</text>
+              <view class="quantity_selector">
+                <van-stepper
+                  value="{{item.quantity}}"
+                  data-id="{{item.id}}"
+                  bind:change="onChange"
+                />
+              </view>
+            </view>
+          </view>
+        </view>
+      </block>
+    </view>
+
+    <!-- 底部结算栏 -->
+    <view class="footer">
+      <view class="total_amount">
+        <text>合计:¥{{totalAmount}}</text>
+      </view>
+      <view>
+        <button class="pay_button" bindtap="handlePay">立即支付</button>
+      </view>
+    </view>
+  </view>
+</view>

+ 155 - 0
subpackages/submitorder/submitorder.wxss

@@ -0,0 +1,155 @@
+.container {
+  margin: 0rpx 30rpx;
+  width: calc(100% - 60rpx);
+  padding: 0;
+}
+
+.dizhi_boxs {
+  width: calc( 100% - 40rpx);
+  background-color: #fff;
+  border-radius: 10rpx;
+  padding: 30rpx 20rpx;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+}
+
+.address_info {
+  display: flex;
+  align-items: center;
+}
+
+.location_icon {
+  width: 35rpx;
+  height: 35rpx;
+  margin-right: 10rpx;
+}
+
+.address_text {
+  font-size: 28rpx;
+  color: #333;
+}
+
+.contact_info {
+  margin-left: 10rpx;
+}
+
+.name {
+  font-size: 28rpx;
+  color: #333;
+  margin-right: 20rpx;
+}
+
+.phone {
+  font-size: 28rpx;
+  color: #333;
+}
+
+.right_arrow {
+  width: 35rpx;
+  height: 35rpx;
+  margin-left: 20rpx;
+}
+
+.product_list {
+  width: 100%;
+  margin-top: 20rpx;
+  margin-bottom: 140rpx;
+}
+
+.product_item {
+  width: calc( 100% - 40rpx);
+  padding: 20rpx;
+  background-color: #fff;
+  border-radius: 10rpx;
+  display: flex;
+  align-items: center;
+  margin-bottom: 20rpx;
+}
+
+.product_image {
+  width: 180rpx;
+  height: 180rpx;
+  margin-right: 20rpx;
+}
+
+.product_details {
+  flex: 1;
+}
+
+.product_name {
+  font-size: 32rpx;
+  color: #333;
+  margin-bottom: 10rpx;
+}
+
+.product_desc {
+  font-size: 28rpx;
+  color: #666;
+  margin-bottom: 10rpx;
+}
+
+.price_and_quantity {
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  margin-top: 30rpx;
+}
+
+.product_price {
+  font-size: 32rpx;
+  color: #ff5722;
+}
+
+.quantity_selector {
+  display: flex;
+  align-items: center;
+}
+
+.decrease, .increase {
+  width: 40rpx;
+  height: 40rpx;
+  background-color: #f5f5f5;
+  border-radius: 50%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  font-size: 28rpx;
+  color: #333;
+  margin: 0 10rpx;
+}
+
+.quantity {
+  font-size: 28rpx;
+  color: #333;
+}
+
+.footer {
+  background: #fff;
+  width: calc( 100% - 40rpx);
+  position: fixed;
+  bottom: 0;
+  left: 0;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  padding-bottom: 40rpx;
+  padding-top: 20rpx;
+  padding-left: 20rpx;
+  padding-right: 20rpx;
+  z-index: 999;
+}
+
+.total_amount {
+  font-size: 32rpx;
+  color: #ff5722;
+}
+
+.pay_button {
+  width: 300rpx !important;
+  height: 80rpx !important;
+  background-color: #3b8cff;
+  color: #fff;
+  font-size: 32rpx;
+  border-radius: 40rpx;
+}

+ 13 - 0
utils/cloudbase.js

@@ -0,0 +1,13 @@
+// utils/cloudbase.js
+import { init } from '@cloudbase/wx-cloud-client-sdk'
+
+wx.cloud.init({
+  env: 'cloud1-6g98iw7i28b01747',
+  traceUser: true
+})
+
+const client = init(wx.cloud)
+const db = client.database()
+const models = client.models
+
+export { db, models }

+ 19 - 0
utils/util.js

@@ -0,0 +1,19 @@
+const formatTime = date => {
+  const year = date.getFullYear()
+  const month = date.getMonth() + 1
+  const day = date.getDate()
+  const hour = date.getHours()
+  const minute = date.getMinutes()
+  const second = date.getSeconds()
+
+  return `${[year, month, day].map(formatNumber).join('/')} ${[hour, minute, second].map(formatNumber).join(':')}`
+}
+
+const formatNumber = n => {
+  n = n.toString()
+  return n[1] ? n : `0${n}`
+}
+
+module.exports = {
+  formatTime
+}