uni-app-pro.html 13 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <!DOCTYPE html>
  2. <html lang="en-US">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width,initial-scale=1">
  6. <title>范肆商城小程序 | 偶游前端</title>
  7. <meta name="generator" content="VuePress 1.9.7">
  8. <meta name="description" content="">
  9. <link rel="preload" href="/docs/assets/css/0.styles.e901f3ad.css" as="style"><link rel="preload" href="/docs/assets/js/app.9d841bbb.js" as="script"><link rel="preload" href="/docs/assets/js/2.a7c99d38.js" as="script"><link rel="preload" href="/docs/assets/js/17.255d9f5b.js" as="script"><link rel="prefetch" href="/docs/assets/js/10.dffec12e.js"><link rel="prefetch" href="/docs/assets/js/11.29345ef4.js"><link rel="prefetch" href="/docs/assets/js/12.d71ff1f2.js"><link rel="prefetch" href="/docs/assets/js/13.eadceca7.js"><link rel="prefetch" href="/docs/assets/js/14.86faea9b.js"><link rel="prefetch" href="/docs/assets/js/15.8cc4ecb6.js"><link rel="prefetch" href="/docs/assets/js/16.e10f6d69.js"><link rel="prefetch" href="/docs/assets/js/18.9f1823b8.js"><link rel="prefetch" href="/docs/assets/js/19.03db59c9.js"><link rel="prefetch" href="/docs/assets/js/20.f003980f.js"><link rel="prefetch" href="/docs/assets/js/21.5ec8f90e.js"><link rel="prefetch" href="/docs/assets/js/22.77e586e0.js"><link rel="prefetch" href="/docs/assets/js/23.793cee7f.js"><link rel="prefetch" href="/docs/assets/js/24.b9b4a05b.js"><link rel="prefetch" href="/docs/assets/js/25.12ca9a6b.js"><link rel="prefetch" href="/docs/assets/js/3.de84d37d.js"><link rel="prefetch" href="/docs/assets/js/4.47824499.js"><link rel="prefetch" href="/docs/assets/js/5.bd819ce0.js"><link rel="prefetch" href="/docs/assets/js/6.dfb8683d.js"><link rel="prefetch" href="/docs/assets/js/7.0e5538c2.js"><link rel="prefetch" href="/docs/assets/js/8.d3104372.js"><link rel="prefetch" href="/docs/assets/js/9.f4b68565.js">
  10. <link rel="stylesheet" href="/docs/assets/css/0.styles.e901f3ad.css">
  11. </head>
  12. <body>
  13. <div id="app" data-server-rendered="true"><div class="theme-container"><header class="navbar"><div class="sidebar-button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" role="img" viewBox="0 0 448 512" class="icon"><path fill="currentColor" d="M436 124H12c-6.627 0-12-5.373-12-12V80c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12z"></path></svg></div> <a href="/docs/" class="home-link router-link-active"><!----> <span class="site-name">偶游前端</span></a> <div class="links"><div class="search-box"><input aria-label="Search" autocomplete="off" spellcheck="false" value=""> <!----></div> <!----></div></header> <div class="sidebar-mask"></div> <aside class="sidebar"><!----> <ul class="sidebar-links"><li><a href="/docs/" aria-current="page" class="sidebar-link">偶游前端(冯垣玮)</a></li><li><section class="sidebar-group depth-0"><p class="sidebar-heading open"><span>项目</span> <!----></p> <ul class="sidebar-links sidebar-group-items"><li><a href="/docs/currentProgram/funfet.html" class="sidebar-link">智能鞋官网</a></li><li><a href="/docs/currentProgram/guide.html" class="sidebar-link">智能鞋落地页</a></li><li><a href="/docs/currentProgram/uni-app-pro.html" aria-current="page" class="active sidebar-link">智能鞋小程序商城</a><ul class="sidebar-sub-headers"><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#说明" class="sidebar-link">说明</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#项目地址" class="sidebar-link">项目地址</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#技术选型" class="sidebar-link">技术选型</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#最终的技术栈" class="sidebar-link">最终的技术栈</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#node版本" class="sidebar-link">node版本</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#开发工具" class="sidebar-link">开发工具</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#项目架构" class="sidebar-link">项目架构</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#备注" class="sidebar-link">备注</a><ul class="sidebar-sub-headers"><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#商品数据缓存" class="sidebar-link">商品数据缓存</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#商品只能购买一件问题" class="sidebar-link">商品只能购买一件问题</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#订单商品过多展示问题" class="sidebar-link">订单商品过多展示问题</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#频繁点击跳转生成多个跳转页面问题" class="sidebar-link">频繁点击跳转生成多个跳转页面问题</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#兼容ipad" class="sidebar-link">兼容ipad</a></li><li class="sidebar-sub-header"><a href="/docs/currentProgram/uni-app-pro.html#关于商品详情tab描点问题" class="sidebar-link">关于商品详情tab描点问题</a></li></ul></li></ul></li><li><a href="/docs/currentProgram/customerService.html" class="sidebar-link">智能鞋客服系统</a></li><li><a href="/docs/currentProgram/tank.html" class="sidebar-link">坦克专题</a></li><li><a href="/docs/currentProgram/hiydMini.html" class="sidebar-link">hi运动教练小程序</a></li><li><a href="/docs/currentProgram/hiydShop.html" class="sidebar-link">hi运动商城</a></li><li><a href="/docs/currentProgram/webGame.html" class="sidebar-link">多玩游戏大厅</a></li></ul></section></li></ul> </aside> <main class="page"> <div class="theme-default-content content__default"><h1 id="智能运动鞋落地页"><a href="#智能运动鞋落地页" class="header-anchor">#</a> 智能运动鞋落地页</h1> <blockquote><p>请编辑过的人员留下你的姓名</p></blockquote> <ul><li>文档编辑人员 冯垣玮(2022/10/28)</li></ul> <h2 id="说明"><a href="#说明" class="header-anchor">#</a> 说明</h2> <p>范肆智能鞋购买平台</p> <h2 id="项目地址"><a href="#项目地址" class="header-anchor">#</a> 项目地址</h2> <ul><li>svn://dev.webdev.ouj.com/biz/mini_mall/template/uni-app-pro</li></ul> <h2 id="技术选型"><a href="#技术选型" class="header-anchor">#</a> 技术选型</h2> <blockquote><p>目标:微信小程序</p></blockquote> <p>可选择的方案,(1)原生 (2)uni-app (3)taro</p> <p>考虑以后有h5端的需求,使用跨端框架可节约开发成本,最终选择技术人员更熟悉的跨端框架uni-app。</p> <h2 id="最终的技术栈"><a href="#最终的技术栈" class="header-anchor">#</a> 最终的技术栈</h2> <blockquote><p>uniapp + scss + uviewui(2.0.31) + 原生小程序内置 Api</p></blockquote> <h2 id="node版本"><a href="#node版本" class="header-anchor">#</a> node版本</h2> <blockquote><p>&quot;node&quot;: &quot;16.13.0&quot;</p></blockquote> <h2 id="开发工具"><a href="#开发工具" class="header-anchor">#</a> 开发工具</h2> <blockquote><p>XBuilder X (3.6.3.20220917)</p></blockquote> <h2 id="项目架构"><a href="#项目架构" class="header-anchor">#</a> 项目架构</h2> <div class="language-Bash extra-class"><pre class="language-bash"><code>- api <span class="token comment"># http请求</span>
  14. - components <span class="token comment"># 公共组件(自定义)</span>
  15. - config <span class="token comment"># 项目变量配置文件</span>
  16. - mixins <span class="token comment"># 全局mixin</span>
  17. - node_modules
  18. - pages
  19. <span class="token operator">|</span>- Activity <span class="token comment"># 商城活动相关,如抽奖码活动(搁置中)</span>
  20. <span class="token operator">|</span>- Index <span class="token comment"># 商城首页</span>
  21. <span class="token operator">|</span>- Login <span class="token comment"># 登录</span>
  22. <span class="token operator">|</span>- Product <span class="token comment"># 商品相关</span>
  23. <span class="token operator">|</span>-Detail <span class="token comment"># 商品详情</span>
  24. <span class="token operator">|</span>-Eval <span class="token comment"># 商品评价</span>
  25. <span class="token operator">|</span>-Index <span class="token comment"># 商品页</span>
  26. <span class="token operator">|</span>-Video <span class="token comment"># 商品视频查看</span>
  27. <span class="token operator">|</span>- User <span class="token comment"># 用户相关</span>
  28. <span class="token operator">|</span>-AccSet <span class="token comment"># 账户设置</span>
  29. <span class="token operator">|</span>-Address <span class="token comment"># 收货地址</span>
  30. <span class="token operator">|</span>-Cart <span class="token comment"># 购物车</span>
  31. <span class="token operator">|</span>-Coupon <span class="token comment"># 优惠券</span>
  32. <span class="token operator">|</span>-Index <span class="token comment"># 个人中心</span>
  33. <span class="token operator">|</span>-Order <span class="token comment"># 订单相关(订单列表,订单详情,售后服务,用户评价)</span>
  34. <span class="token operator">|</span>-Suggest <span class="token comment"># 投诉反馈</span>
  35. - static <span class="token comment"># 存放应用引用的本地静态资源</span>
  36. - store <span class="token comment"># 全局存储</span>
  37. - styles <span class="token comment"># 定义的全局scss</span>
  38. - utils <span class="token comment"># 工具类</span>
  39. - App.vue <span class="token comment"># 应用配置,用来配置App全局样式以及监听</span>
  40. - main.js <span class="token comment"># Vue初始化入口文件</span>
  41. - manifest.json <span class="token comment"># 配置应用名称、appid、logo、版本等打包信息</span>
  42. - pages.json <span class="token comment"># 配置页面路由、导航条、选项卡等页面类信息</span>
  43. - uni.scss <span class="token comment"># uni-app内置的全局常用样式变量 </span>
  44. </code></pre></div><h2 id="备注"><a href="#备注" class="header-anchor">#</a> 备注</h2> <h3 id="商品数据缓存"><a href="#商品数据缓存" class="header-anchor">#</a> 商品数据缓存</h3> <ul><li>把第一次加载商品信息的数据进行缓存,下次进入该商品页便可不用重新加载数据,可避免白屏加载,提升用户体验。</li></ul> <h3 id="商品只能购买一件问题"><a href="#商品只能购买一件问题" class="header-anchor">#</a> 商品只能购买一件问题</h3> <ul><li>因为需要对接erp的商品,订单,售后等信息,确保订单结构一致。(可优化购买多件)</li></ul> <h3 id="订单商品过多展示问题"><a href="#订单商品过多展示问题" class="header-anchor">#</a> 订单商品过多展示问题</h3> <ul><li>若是一个订单存在多个商品,商品会根据顺序排列出来,样式不够美观。</li></ul> <h3 id="频繁点击跳转生成多个跳转页面问题"><a href="#频繁点击跳转生成多个跳转页面问题" class="header-anchor">#</a> 频繁点击跳转生成多个跳转页面问题</h3> <ul><li>使用节流函数进行处理</li></ul> <h3 id="兼容ipad"><a href="#兼容ipad" class="header-anchor">#</a> 兼容ipad</h3> <ul><li>使用@media进行兼容</li></ul> <h3 id="关于商品详情tab描点问题"><a href="#关于商品详情tab描点问题" class="header-anchor">#</a> 关于商品详情tab描点问题</h3> <blockquote><p>因为是内嵌H5页面,无法获取H5里面的图片加载是否完成,描点无法准确定位</p></blockquote> <p>处理思考:</p> <ul><li><p>更改现在的切换模式</p></li> <li><p>弃用H5内嵌</p></li> <li><p>减少图片大小,增加响应速度,再用定时处理(用户第一次进入小程序由于图片未缓存,用定时处理,然后通过vuex记录用户已经进来过一次,即图片已缓存。第二次进入则无需定时但 是缺点明显,用户第一次进入无法判断图片加载完成时间)</p></li></ul></div> <footer class="page-edit"><!----> <!----></footer> <div class="page-nav"><p class="inner"><span class="prev">
  45. <a href="/docs/currentProgram/guide.html" class="prev">
  46. 智能鞋落地页
  47. </a></span> <span class="next"><a href="/docs/currentProgram/customerService.html">
  48. 智能鞋客服系统
  49. </a>
  50. </span></p></div> </main></div><div class="global-ui"></div></div>
  51. <script src="/docs/assets/js/app.9d841bbb.js" defer></script><script src="/docs/assets/js/2.a7c99d38.js" defer></script><script src="/docs/assets/js/17.255d9f5b.js" defer></script>
  52. </body>
  53. </html>