diff --git a/common/api/api.js b/common/api/api.js index de5b900..fd9d4d3 100644 --- a/common/api/api.js +++ b/common/api/api.js @@ -1,8 +1,10 @@ import {request} from './request.js' export default{ + // 商品 + productApi:require("./module/productApi.js").default, // 订单,模块 - orderApi:require("./orderApi.js").default, + orderApi:require("./module/orderApi.js").default, /* * 登录相关 */ @@ -67,4 +69,14 @@ export default{ }) }) }, + getSmsCode(data) {// 获取短信验证码 + return new Promise((resolve, reject) => { + request.get('/resource/sms/code',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, } \ No newline at end of file diff --git a/common/api/alarm.js b/common/api/module/alarm.js similarity index 100% rename from common/api/alarm.js rename to common/api/module/alarm.js diff --git a/common/api/orderApi.js b/common/api/module/orderApi.js similarity index 98% rename from common/api/orderApi.js rename to common/api/module/orderApi.js index 3132f0a..142dd9f 100644 --- a/common/api/orderApi.js +++ b/common/api/module/orderApi.js @@ -1,4 +1,4 @@ -import {request} from './request' +import {request} from '../request' export default { // 获取订单列表 getOrderList(data){ diff --git a/common/api/module/productApi.js b/common/api/module/productApi.js new file mode 100644 index 0000000..fe7b0be --- /dev/null +++ b/common/api/module/productApi.js @@ -0,0 +1,147 @@ +import {request} from '../request' +export default { + // 获取商品列表 + getProductList(data){ + return new Promise((resolve, reject) => { + request.get('/mall/product/list',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 获取商品详情 + getProductDetail(id){ + return new Promise((resolve, reject) => { + request.get('/mall/product/' + id) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 获取订单商品列表 + getMallclientOrderProductList(data){ + return new Promise((resolve, reject) => { + request.get('/mallclient/clientorderItem/list',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 查询订单商品素材模板列表 + getProductMaterialDictList(data){ + return new Promise((resolve, reject) => { + request.get('/mall/materialDict/listWithProduct',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 查询订单商品素材列表(已有) + getMallOrderProductMaterialList(data){ + return new Promise((resolve, reject) => { + request.get('/mall/material/list',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 查询订单商品素材模板素材项列表 + getProductMaterialDictItemList(data){ + return new Promise((resolve, reject) => { + request.get('/mall/materialTemplate/listById',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 删除文件 + delOssFile(id){ + console.log("id",id) + return new Promise((resolve, reject) => { + request.delete('/resource/oss/' + id) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 订单素材列表(流程) + getOrderMaterialList(data){ + return new Promise((resolve, reject) => { + request.get('/mall/orderMaterial/list',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 新增订单素材(流程) + AddOrderMaterial(data){ + return new Promise((resolve, reject) => { + request.post('/mall/orderMaterial',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 修改素材(批量) + mallMaterialUpdateBatch(data){ + return new Promise((resolve, reject) => { + request.put('/mall/material/updateBatch',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 提交商品素材列表(完成) + mallMaterialCommit(orderId,productId){ + return new Promise((resolve, reject) => { + request.put('/mall/material/commit/' + orderId + '/' + productId) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 启动任务(流程) + startWorkFlow(data){ + return new Promise((resolve, reject) => { + request.post('/workflow/task/startWorkFlow',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, + // 办理流程(流程) + completeTask(data){ + return new Promise((resolve, reject) => { + request.post('/workflow/task/completeTask',data) + .then((res) =>{ + resolve(res); + }).catch(err =>{ + reject(err); + }) + }) + }, +} \ No newline at end of file diff --git a/pages.json b/pages.json index 3c35908..18ca7c4 100644 --- a/pages.json +++ b/pages.json @@ -10,6 +10,13 @@ "navigationBarBackgroundColor": "#1890ff" } }, + { + "path": "pages/auth/codeLogin", + "style": { + "navigationBarTitleText": "手机号注册/登录", + "navigationBarBackgroundColor": "#1890ff" + } + }, { "path": "pages/auth/login", "style": { @@ -24,6 +31,13 @@ // "navigationStyle": "custom" } }, + { + "path": "pages/tabBar/product", + "style": { + "navigationBarTitleText": "商品" + // "navigationStyle": "custom" + } + }, { "path": "pages/tabBar/order", "style": { @@ -636,6 +650,22 @@ "navigationBarTitleText": "素材上传", "navigationBarBackgroundColor": "#fff" } + },{ + "path": "videoView", + "style": { + "navigationBarTitleText": "视频预览", + "navigationBarBackgroundColor": "#fff" + } + }] + }, + { + "root": "pages/product/", + "pages": [{ + "path": "detail", + "style": { + "navigationBarTitleText": "商品详情", + "navigationBarBackgroundColor": "#fff" + } }] } ], @@ -648,6 +678,11 @@ "text": "消息", "iconPath": "static/images/toolbar/new.png", "selectedIconPath": "static/images/toolbar/new-active.png" + }, { + "pagePath": "pages/tabBar/product", + "text": "商品", + "iconPath": "static/images/toolbar/product.png", + "selectedIconPath": "static/images/toolbar/product-active.png" }, { "pagePath": "pages/tabBar/order", "text": "订单", @@ -673,6 +708,23 @@ "path": "pages/auth/passwordLogin", "name": "默认页面" //模式名称 }, + { + "path": "pages/auth/codeLogin", + "name": "验证码登录" //模式名称 + }, + { + "path": "pages/fun/videoView", + "name": "预览" //模式名称 + }, + { + "path": "pages/tabBar/product", + "name": "商品" //模式名称 + }, + { + "path": "pages/product/detail", + "name": "商品详情" ,//模式名称 + "query": "id=1888110308906405890" + }, { "path": "pages/tabBar/order", "name": "订单" //模式名称 diff --git a/pages/auth/codeLogin.vue b/pages/auth/codeLogin.vue new file mode 100644 index 0000000..ad8aca6 --- /dev/null +++ b/pages/auth/codeLogin.vue @@ -0,0 +1,607 @@ + + + + + \ No newline at end of file diff --git a/pages/auth/passwordLogin.vue b/pages/auth/passwordLogin.vue index f9aff98..1191a5d 100644 --- a/pages/auth/passwordLogin.vue +++ b/pages/auth/passwordLogin.vue @@ -1,3 +1,469 @@ + + + + - - - - \ No newline at end of file + \ No newline at end of file diff --git a/pages/product/detail.vue b/pages/product/detail.vue new file mode 100644 index 0000000..f339f34 --- /dev/null +++ b/pages/product/detail.vue @@ -0,0 +1,204 @@ + + + + + \ No newline at end of file diff --git a/pages/tabBar/product.vue b/pages/tabBar/product.vue new file mode 100644 index 0000000..52ca7dc --- /dev/null +++ b/pages/tabBar/product.vue @@ -0,0 +1,243 @@ + + + + + \ No newline at end of file diff --git a/static/fonts/iconfont.css b/static/fonts/iconfont.css index d0ff450..a482f7b 100644 --- a/static/fonts/iconfont.css +++ b/static/fonts/iconfont.css @@ -1,192 +1,415 @@ -/* @font-face { - font-family: "diconfont"; - src: url('//at.alicdn.com/t/c/font_4601750_didlrvj3tlw.woff2?t=1733898191649') format('woff2'), - url('//at.alicdn.com/t/c/font_4601750_didlrvj3tlw.woff?t=1733898191649') format('woff'), - url('//at.alicdn.com/t/c/font_4601750_didlrvj3tlw.ttf?t=1733898191649') format('truetype'); -} */ @font-face { - font-family: "diconfont"; - src: url('//static.drgyen.com/app/hc-app-power/font/iconfont.woff2?t=1733898191649') format('woff2'), - url('//static.drgyen.com/app/hc-app-power/font/iconfont.woff?t=1733898191649') format('woff'), - url('//static.drgyen.com/app/hc-app-power/font/iconfont.ttf?t=1733898191649') format('truetype'); + font-family: "iconfont"; /* Project id 4669262 */ + src: url('//at.alicdn.com/t/c/font_4669262_u9rbl9p25qn.woff2?t=1740103284583') format('woff2'), + url('//at.alicdn.com/t/c/font_4669262_u9rbl9p25qn.woff?t=1740103284583') format('woff'), + url('//at.alicdn.com/t/c/font_4669262_u9rbl9p25qn.ttf?t=1740103284583') format('truetype'), + url('//at.alicdn.com/t/c/font_4669262_u9rbl9p25qn.svg?t=1740103284583#iconfont') format('svg'); } -.diconfont { - font-family: "diconfont" !important; +.iconfont { + font-family: "iconfont" !important; font-size: 16px; font-style: normal; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } -.dicon-saoyisao2:before { +.icon-shouji:before { + content: "\e653"; +} + +.icon-weixin1:before { + content: "\e661"; +} + +.icon-suo:before { + content: "\e662"; +} + +.icon-my-task:before { + content: "\e718"; +} + +.icon-finish:before { content: "\e618"; } -.dicon-mti-qiehuan:before { - content: "\e73e"; +.icon-model:before { + content: "\e74a"; } -.dicon-shebei_shebeizu:before { - content: "\e616"; +.icon-category:before { + content: "\e65d"; } -.dicon-icon_dianliang:before { - content: "\e776"; +.icon-waiting:before { + content: "\e65e"; } -.dicon-icon_dianya:before { - content: "\e777"; +.icon-workflow:before { + content: "\e600"; } -.dicon-icon_zongliang:before { - content: "\e778"; +.icon-my-copy:before { + content: "\e65f"; } -.dicon-icon_fenzha:before { - content: "\e779"; +.icon-topiam:before { + content: "\e660"; } -.dicon-icon_jinribaojing:before { - content: "\e77a"; +.icon-caret-back:before { + content: "\e64a"; } -.dicon-icon_hezha:before { - content: "\e77b"; +.icon-caret-forward:before { + content: "\e61e"; } -.dicon-icon_wendu:before { - content: "\e77c"; +.icon-example:before { + content: "\e64f"; } -.dicon-icon_dianliu:before { - content: "\e77d"; +.icon-email:before { + content: "\e650"; } -.dicon-icon_xiugai:before { - content: "\e77e"; +.icon-drag:before { + content: "\e651"; } -.dicon-icon_saoma:before { - content: "\e77f"; +.icon-edit:before { + content: "\e652"; } -.dicon-icon_weibaojilu:before { - content: "\e780"; +.icon-checkbox:before { + content: "\e654"; } -.dicon-icon_gengduo:before { - content: "\e781"; +.icon-documentation:before { + content: "\e655"; } -.dicon-duanxin:before { +.icon-color:before { + content: "\e656"; +} + +.icon-clipboard:before { + content: "\e657"; +} + +.icon-druid:before { + content: "\e658"; +} + +.icon-cascader:before { + content: "\e659"; +} + +.icon-company:before { + content: "\e65a"; +} + +.icon-code:before { + content: "\e65b"; +} + +.icon-chart:before { + content: "\e65c"; +} + +.icon-component:before { + content: "\e64d"; +} + +.icon-date-range:before { + content: "\e64e"; +} + +.icon-list:before { + content: "\e63a"; +} + +.icon-logininfor:before { + content: "\e63b"; +} + +.icon-github:before { + content: "\e63c"; +} + +.icon-guide:before { + content: "\e63d"; +} + +.icon-message:before { content: "\e63e"; } -.dicon-zuoji:before { +.icon-lock:before { + content: "\e63f"; +} + +.icon-link:before { + content: "\e640"; +} + +.icon-eye-open:before { + content: "\e641"; +} + +.icon-international:before { + content: "\e642"; +} + +.icon-exit-fullscreen:before { content: "\e643"; } -.dicon-fenhezhajingshi:before { - content: "\e6cd"; +.icon-gitee:before { + content: "\e644"; } -.dicon-dingwei:before { +.icon-excel:before { + content: "\e645"; +} + +.icon-date:before { + content: "\e646"; +} + +.icon-dashboard:before { + content: "\e647"; +} + +.icon-dict:before { + content: "\e648"; +} + +.icon-fullscreen:before { + content: "\e649"; +} + +.icon-eye:before { + content: "\e64b"; +} + +.icon-education:before { + content: "\e64c"; +} + +.icon-search:before { + content: "\e624"; +} + +.icon-slider:before { + content: "\e625"; +} + +.icon-rate:before { + content: "\e626"; +} + +.icon-input:before { + content: "\e627"; +} + +.icon-shopping:before { + content: "\e628"; +} + +.icon-post:before { + content: "\e629"; +} + +.icon-redis-list:before { + content: "\e62a"; +} + +.icon-select:before { + content: "\e62b"; +} + +.icon-nested:before { + content: "\e62c"; +} + +.icon-people:before { + content: "\e62d"; +} + +.icon-question:before { + content: "\e62e"; +} + +.icon-number:before { + content: "\e62f"; +} + +.icon-radio:before { + content: "\e630"; +} + +.icon-pdf:before { + content: "\e631"; +} + +.icon-download:before { + content: "\e632"; +} + +.icon-phone:before { + content: "\e633"; +} + +.icon-password:before { + content: "\e634"; +} + +.icon-language:before { + content: "\e635"; +} + +.icon-money:before { + content: "\e636"; +} + +.icon-monitor:before { + content: "\e637"; +} + +.icon-job:before { + content: "\e638"; +} + +.icon-log:before { + content: "\e639"; +} + +.icon-user:before { + content: "\e60b"; +} + +.icon-build:before { + content: "\e60c"; +} + +.icon-tool:before { + content: "\e60d"; +} + +.icon-system:before { + content: "\e60e"; +} + +.icon-star:before { + content: "\e60f"; +} + +.icon-peoples:before { + content: "\e611"; +} + +.icon-icon:before { + content: "\e612"; +} + +.icon-upload:before { + content: "\e613"; +} + +.icon-validCode:before { + content: "\e614"; +} + +.icon-tree-table:before { + content: "\e615"; +} + +.icon-table:before { + content: "\e616"; +} + +.icon-theme:before { content: "\e617"; } -.dicon-bangzhu:before { - content: "\e70f"; +.icon-time-range:before { + content: "\e619"; } -.dicon-mima1:before { - content: "\e668"; +.icon-swagger:before { + content: "\e61a"; } -.dicon-xiaoxi:before { +.icon-row:before { + content: "\e61b"; +} + +.icon-server:before { + content: "\e61c"; +} + +.icon-qq:before { + content: "\e61d"; +} + +.icon-skill:before { + content: "\e61f"; +} + +.icon-textarea:before { + content: "\e620"; +} + +.icon-form:before { + content: "\e621"; +} + +.icon-tab:before { + content: "\e622"; +} + +.icon-online:before { + content: "\e623"; +} + +.icon-a-404:before { + content: "\e602"; +} + +.icon-size:before { + content: "\e603"; +} + +.icon-bug:before { content: "\e604"; } -.dicon-you:before { - content: "\e68b"; +.icon-switch:before { + content: "\e605"; } -.dicon-icon_weizhi:before { - content: "\e770"; +.icon-button:before { + content: "\e606"; } -.dicon-icon_banbenhao:before { - content: "\e763"; +.icon-redis:before { + content: "\e607"; } -.dicon-icon_yongnengfenxi:before { - content: "\e764"; +.icon-zip:before { + content: "\e608"; } -.dicon-icon_bianji:before { - content: "\e765"; +.icon-wechat:before { + content: "\e609"; } -.dicon-icon_dingshiqi:before { - content: "\e766"; +.icon-tree:before { + content: "\e60a"; } -.dicon-icon_dingwei:before { - content: "\e767"; -} - -.dicon-icon_guanyu:before { - content: "\e768"; -} - -.dicon-icon_gongcheng:before { - content: "\e769"; -} - -.dicon-icon_mulu:before { - content: "\e76a"; -} - -.dicon-icon_gaojingjilu:before { - content: "\e76b"; -} - -.dicon-icon_shishi:before { - content: "\e76c"; -} - -.dicon-icon_liandongpeizhi:before { - content: "\e76d"; -} - -.dicon-icon_shijian:before { - content: "\e76e"; -} - -.dicon-icon_weibao:before { - content: "\e76f"; -} - -.dicon-icon_jiance:before { - content: "\e75d"; -} - -.dicon-icon_xiaofang:before { - content: "\e75e"; -} - -.dicon-icon_yongqi:before { - content: "\e75f"; -} - -.dicon-icon_yongdian:before { - content: "\e760"; -} - -.dicon-icon_shipin:before { - content: "\e761"; -} - -.dicon-icon_yongshui:before { - content: "\e762"; +.icon-time:before { + content: "\e601"; } diff --git a/static/images/toolbar/product-active.png b/static/images/toolbar/product-active.png new file mode 100644 index 0000000..792f87c Binary files /dev/null and b/static/images/toolbar/product-active.png differ diff --git a/static/images/toolbar/product.png b/static/images/toolbar/product.png new file mode 100644 index 0000000..304189c Binary files /dev/null and b/static/images/toolbar/product.png differ diff --git a/store/modules/auth.js b/store/modules/auth.js index 6cee3fe..f554b5e 100644 --- a/store/modules/auth.js +++ b/store/modules/auth.js @@ -17,7 +17,14 @@ const auth = { state.hasLogin = false; state.userInfo = {}; state.userToken = {}; - uni.clearStorageSync(); + // uni.clearStorageSync(); + const resStorage = uni.getStorageInfoSync(); + console.log("获取到缓存信息",resStorage) + resStorage.keys.forEach((item)=>{ + if(item!="username" && item!="password" && item!="phonenumber"){ + uni.removeStorageSync(item); + } + }) }, }, actions:{