diff --git a/App.vue b/App.vue index 53bdbee..fa54101 100644 --- a/App.vue +++ b/App.vue @@ -7,11 +7,11 @@ // url: 'https://pay.bxb.cn/crest', // imgUrl: 'https://xuan-pay-private.obs.cn-southwest-2.myhuaweicloud.com', //测试 - url: 'https://paycs.dctpay.com/crest', + url: 'https://gratia-pay.dctpay.com/crest', imgUrl: 'https://xuan-pay-private.obs.cn-southwest-2.myhuaweicloud.com', userInfo: "", openId: '', - code: '', + h5code: '', token: '', //行业id businessid:'', @@ -20,7 +20,9 @@ //mccid mccid:'', //mcc名称 - mccname:'' + mccname:'', + //数据字典类型数据 + Dictionaries:'' }, onLaunch: function() { let that = this; diff --git a/Utils/Api.js b/Utils/Api.js index 2be773f..94d6da3 100644 --- a/Utils/Api.js +++ b/Utils/Api.js @@ -6,6 +6,10 @@ let base = app.globalData.url; // 登录接口 export const userLogin = params => { return POST('POST', `${base}/login/userLogin`, params).then(res => res.data); +} +//获取openid +export const getAccessToken = params => { + return POST('GET', `${base}/wechat/getAccessToken`, params).then(res => res.data); } //退出登录 export const logout = params => { @@ -15,6 +19,12 @@ export const logout = params => { export const recognizeBankCard = params => { return POST('GET', `${base}/ocr/recognizeBankCard`, params).then(res => res.data); } + +//访问临时路径 +export const getImgSignedUrl = params => { + return POST('POST', `${base}/fileUpload/getImgSignedUrl`, params).then(res => res.data); +} + //营业执照识别 export const recognizeBusinessLicense = params => { return POST('GET', `${base}/ocr/recognizeBusinessLicense`, params).then(res => res.data); @@ -39,83 +49,128 @@ export const configMerAccount = params => { //查询商户详情 export const getMerDetail = params => { return POST('GET', `${base}/mer/getMerDetail`, params).then(res => res.data); -} - -//第二步商户基本信息 +} + +//第二步商户基本信息 export const configMerBasis = params => { return POST('POST', `${base}/mer/configMerBasis`, params).then(res => res.data); -} -//第三步商户结算信息 +} +//第三步商户结算信息 export const configMerSettlement = params => { return POST('POST', `${base}/mer/configMerSettlement`, params).then(res => res.data); -} -//第四步商户门店信心 +} +//第四步商户门店信心 export const configMerStore = params => { return POST('POST', `${base}/mer/configMerStore`, params).then(res => res.data); -} -//业务员查询商户 +} +//业务员查询商户 export const getMerListBySalesman = params => { return POST('GET', `${base}/mer/getMerListBySalesman`, params).then(res => res.data); -} -//业务员查询mcc +} +//业务员查询mcc export const getLklMcc = params => { return POST('GET', `${base}/common/getLklMcc`, params).then(res => res.data); } -//业务员查询费率类型 +//查询所有数据字典 +export const getDictionaries = params => { + return POST('GET', `${base}/common/getDictionaries`, params).then(res => res.data); +} +//查询数据字典 export const getDictionaryByCodeType = params => { return POST('GET', `${base}/common/getDictionaryByCodeType`, params).then(res => res.data); -} - -//查询商户门店 +} +//查询商户门店 export const getStoreListByMer = params => { return POST('GET', `${base}/store/getStoreListByMer`, params).then(res => res.data); -} -//查询商户门店详情 +} +//查询商户门店详情 export const getStoreDetailById = params => { return POST('GET', `${base}/store/getStoreDetailById`, params).then(res => res.data); -} -//商户添加门店 +} +//商户添加门店 export const configStore = params => { return POST('POST', `${base}/store/configStore`, params).then(res => res.data); +} + +// ---------- 设备 ---------- +//查询设备列表 +export const getDeviceList = params => { + return POST('GET', `${base}/device/getDeviceList`, params).then(res => res.data); +} +//订单分配设备 +export const assignOrder = params => { + return POST('POST', `${base}/deviceOrder/assignOrder`, params).then(res => res.data); +} +//查询设备订单列表 +export const getOrderList = params => { + return POST('GET', `${base}/deviceOrder/getOrderList`, params).then(res => res.data); +} +//查询订单详情 +export const getOrderDetail = params => { + return POST('GET', `${base}/deviceOrder/getOrderDetail`, params).then(res => res.data); +} +//支付订单 +export const payOrder = params => { + return POST('POST', `${base}/deviceOrderPay/payOrder`, params).then(res => res.data); +} +//创建设备订单 +export const createDeviceOrder = params => { + return POST('POST', `${base}/deviceOrder/createDeviceOrder`, params).then(res => res.data); +} +//查询设备价格 +export const getDevicePrice = params => { + return POST('GET', `${base}/device/getDevicePrice`, params).then(res => res.data); } -//门店添加设备 -export const bindStoreDevice = params => { - return POST('POST', `${base}/device/bindStoreDevice`, params).then(res => res.data); -} -//业务员查询设备列表 -export const getSalesmanDeviceList = params => { - return POST('GET', `${base}/device/getSalesmanDeviceList`, params).then(res => res.data); +//更换设备 +export const replace = params => { + return POST('POST', `${base}/deviceOrder/replace`, params).then(res => res.data); } -//门店查询设备列表 -export const getStoreDeviceList = params => { - return POST('GET', `${base}/device/getStoreDeviceList`, params).then(res => res.data); +// 订单退款 +export const orderRefund = params => { + return POST('POST', `${base}/deviceOrder/orderRefund`, params).then(res => res.data); } +// ---------------- -//业务员查询统计 + + +// //门店添加设备 +// export const bindStoreDevice = params => { +// return POST('POST', `${base}/device/bindStoreDevice`, params).then(res => res.data); +// } +// //业务员查询设备列表 +// export const getSalesmanDeviceList = params => { +// return POST('GET', `${base}/device/getSalesmanDeviceList`, params).then(res => res.data); +// } +// //门店查询设备列表 +// export const getStoreDeviceList = params => { +// return POST('GET', `${base}/device/getStoreDeviceList`, params).then(res => res.data); +// } + +//业务员查询统计 export const moveHomeCount = params => { return POST('POST', `${base}/salesman/moveHomeCount`, params).then(res => res.data); -} -//商户查询统计 +} +//商户查询统计 export const mermoveHomeCount = params => { return POST('POST', `${base}/mer/moveHomeCount`, params).then(res => res.data); -} -//门店查询统计 +} +//门店查询统计 export const storemoveHomeCount = params => { return POST('POST', `${base}/store/moveHomeCount`, params).then(res => res.data); -} -// 查询交易订单列表 +} +// 查询交易订单列表 export const getTradeOrderList = params => { return POST('GET', `${base}/tradeOrder/getTradeOrderList`, params).then(res => res.data); -} -//业务员绑定门店二维码 +} +//业务员绑定门店二维码 export const bindStore = params => { return POST('POST', `${base}/payQrCode/bindStore`, params).then(res => res.data); -} -//业务员查询二维码列表 +} +//业务员查询二维码列表 export const getSalesmanQrCodeList = params => { return POST('GET', `${base}/payQrCode/getSalesmanQrCodeList`, params).then(res => res.data); -} -//门店查询二维码列表 +} +//门店查询二维码列表 export const getStoreQrCodeList = params => { return POST('GET', `${base}/payQrCode/getStoreQrCodeList`, params).then(res => res.data); } diff --git a/Utils/js/date.js b/Utils/js/date.js index ba60f83..5739aa8 100644 --- a/Utils/js/date.js +++ b/Utils/js/date.js @@ -23,6 +23,9 @@ const timeFormat = (value, format) => { if (format == "yyyy-mm-dd") { result = `${y}-${m < 10 ? "0" + m : m}-${d < 10 ? "0" + d : d} `; } + if (format == "yyyy-mm-dd hh:mm:ss") { + result = `${y}-${m < 10 ? "0" + m : m}-${d < 10 ? "0" + d : d} ${h < 10 ? "0" + h : h}:${min < 10 ? "0" + min : min}:${s < 10 ? "0" + s : s}`; + } if (format == "yyyy-mm") { result = `${y}-${m < 10 ? "0" + m : m}`; } diff --git a/manifest.json b/manifest.json index a9ade7e..c31f4ae 100644 --- a/manifest.json +++ b/manifest.json @@ -1,5 +1,5 @@ { - "name" : "帮寻宝", + "name" : "惠支付", "appid" : "__UNI__190622D", "description" : "", "versionName" : "1.0.0", @@ -74,6 +74,9 @@ "base" : "/cweb", "mode" : "hash" }, - "title" : "炫支付" + "title" : "惠支付", + "devServer" : { + "https" : false + } } } diff --git a/node_modules/.package-lock.json b/node_modules/.package-lock.json new file mode 100644 index 0000000..fb8616a --- /dev/null +++ b/node_modules/.package-lock.json @@ -0,0 +1,13 @@ +{ + "name": "基于uview职位分类选择,具备模糊搜索功能,使用更方便", + "version": "1.1.1", + "lockfileVersion": 2, + "requires": true, + "packages": { + "node_modules/jweixin-module": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/jweixin-module/-/jweixin-module-1.6.0.tgz", + "integrity": "sha512-dGk9cf+ipipHmtzYmKZs5B2toX+p4hLyllGLF6xuC8t+B05oYxd8fYoaRz0T30U2n3RUv8a4iwvjhA+OcYz52w==" + } + } +} diff --git a/node_modules/jweixin-module/README.md b/node_modules/jweixin-module/README.md new file mode 100644 index 0000000..7c91d7b --- /dev/null +++ b/node_modules/jweixin-module/README.md @@ -0,0 +1,30 @@ +# jweixin-module + +微信JS-SDK + +## 安装 + +### NPM + +```shell +npm install jweixin-module --save +``` + +### UMD + +```http +https://unpkg.com/jweixin-module/out/index.js +``` + +## 使用 + +```js +var jweixin = require('jweixin-module') +jweixin.ready(function(){ + // TODO +}); +``` + +## 完整API + +>[微信JS-SDK说明文档](https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421141115) diff --git a/node_modules/jweixin-module/lib/index.js b/node_modules/jweixin-module/lib/index.js new file mode 100644 index 0000000..1b5014b --- /dev/null +++ b/node_modules/jweixin-module/lib/index.js @@ -0,0 +1 @@ +!function(e,n){"function"==typeof define&&(define.amd||define.cmd)?define(function(){return n(e)}):n(e,!0)}(window,function(o,e){if(!o.jWeixin){var n,c={config:"preVerifyJSAPI",onMenuShareTimeline:"menu:share:timeline",onMenuShareAppMessage:"menu:share:appmessage",onMenuShareQQ:"menu:share:qq",onMenuShareWeibo:"menu:share:weiboApp",onMenuShareQZone:"menu:share:QZone",previewImage:"imagePreview",getLocation:"geoLocation",openProductSpecificView:"openProductViewWithPid",addCard:"batchAddCard",openCard:"batchViewCard",chooseWXPay:"getBrandWCPayRequest",openEnterpriseRedPacket:"getRecevieBizHongBaoRequest",startSearchBeacons:"startMonitoringBeacons",stopSearchBeacons:"stopMonitoringBeacons",onSearchBeacons:"onBeaconsInRange",consumeAndShareCard:"consumedShareCard",openAddress:"editAddress"},a=function(){var e={};for(var n in c)e[c[n]]=n;return e}(),i=o.document,t=i.title,r=navigator.userAgent.toLowerCase(),s=navigator.platform.toLowerCase(),d=!(!s.match("mac")&&!s.match("win")),u=-1!=r.indexOf("wxdebugger"),l=-1!=r.indexOf("micromessenger"),p=-1!=r.indexOf("android"),f=-1!=r.indexOf("iphone")||-1!=r.indexOf("ipad"),m=(n=r.match(/micromessenger\/(\d+\.\d+\.\d+)/)||r.match(/micromessenger\/(\d+\.\d+)/))?n[1]:"",g={initStartTime:L(),initEndTime:0,preVerifyStartTime:0,preVerifyEndTime:0},h={version:1,appId:"",initTime:0,preVerifyTime:0,networkType:"",isPreVerifyOk:1,systemType:f?1:p?2:-1,clientVersion:m,url:encodeURIComponent(location.href)},v={},S={_completes:[]},y={state:0,data:{}};O(function(){g.initEndTime=L()});var I=!1,_=[],w={config:function(e){B("config",v=e);var t=!1!==v.check;O(function(){if(t)M(c.config,{verifyJsApiList:C(v.jsApiList),verifyOpenTagList:C(v.openTagList)},function(){S._complete=function(e){g.preVerifyEndTime=L(),y.state=1,y.data=e},S.success=function(e){h.isPreVerifyOk=0},S.fail=function(e){S._fail?S._fail(e):y.state=-1};var t=S._completes;return t.push(function(){!function(){if(!(d||u||v.debug||m<"6.0.2"||h.systemType<0)){var i=new Image;h.appId=v.appId,h.initTime=g.initEndTime-g.initStartTime,h.preVerifyTime=g.preVerifyEndTime-g.preVerifyStartTime,w.getNetworkType({isInnerInvoke:!0,success:function(e){h.networkType=e.networkType;var n="https://open.weixin.qq.com/sdk/report?v="+h.version+"&o="+h.isPreVerifyOk+"&s="+h.systemType+"&c="+h.clientVersion+"&a="+h.appId+"&n="+h.networkType+"&i="+h.initTime+"&p="+h.preVerifyTime+"&u="+h.url;i.src=n}})}}()}),S.complete=function(e){for(var n=0,i=t.length;n - - - - + + + + 设备类型 + + + {{serviceName}} + + + 请选择设备类型 + + + + + + + 购买方式 + + + {{payName}} + + + 请选择购买方式 + + + + + + + + 设备单价 + + + + + 设备数量 + + + + 支付金额: ¥{{payPrice}} + + + diff --git a/pages/index/doorManage/doorManage.vue b/pages/index/doorManage/doorManage.vue index 5644f77..a2ab1dc 100644 --- a/pages/index/doorManage/doorManage.vue +++ b/pages/index/doorManage/doorManage.vue @@ -1,7 +1,7 @@