diff --git a/api/goods.js b/api/goods.js index f1fadbf..b1754c3 100644 --- a/api/goods.js +++ b/api/goods.js @@ -15,6 +15,11 @@ const api = { paymentListUrl: "Paymentlist/certiaudit/listIndet", certificationPay: "PayCallBack/order/certificationPay", rankingList: "AgencyAddress/ranking/queryList", + orderPaymentList: "AgencyAddress/order/queryRrder", + userOrderpay: "slb/pay/order/userOrderpay", + marketleader: "AgencyAddress/ranking/insertCount", + addClient: "AgencyAddress/signInfo/insertEntrustingPartyInfo", + addClickmarket: "AgencyAddress/signInfo/insertEntrustingPartyInfo", } // 商品列表 @@ -93,3 +98,26 @@ export const getRankingList = (param) => { return request.get(api.rankingList + paramStr,{}) } +// 缴费订单列表 +export const orderPaymentList = (data) => { + return request.post(api.orderPaymentList,data) +} + +// 订单确认支付 +export const userOrderpay = (data) => { + return request.post(api.userOrderpay,data) +} +// 排行榜销售量 +export const marketleader = (data) => { + return request.post(api.marketleader,data) +} +// 添加委托方统计数据 +export const addClient = (data) => { + return request.post(api.addClient,data) +} +// 交易信息数据统计销售量 +export const addClickmarket = (data) => { + return request.post(api.addClickmarket,data) +} + + diff --git a/api/user.js b/api/user.js index ecaab10..4cc6510 100644 --- a/api/user.js +++ b/api/user.js @@ -10,6 +10,14 @@ const api = { oplogs: "slb/userself/v1/account/operation", //重置密码 resetpwd:'slb/userself/v1/account/reset-pwd', + // 购物车 + shop_cart: "tes/api/goods/getShoppingCar", + // 购物车 + del_shop_cart: "AgencyAddress/order/delShoppingCa", + // 去结算 + create_order: "AgencyAddress/order/createOrder", + // 发票管理 + bill_manage: "AgencyAddress/order/getTicket", } // 当前登录的用户信息 @@ -45,4 +53,37 @@ export const oplogs = (param, option) => { // 重置用户密码 export const resetpass = (data,option) =>{ return request.post(api.resetpwd,data,option) +} + +// 获取购物车列表 +export function getShopCart(data){ + return request.post(api.shop_cart,data) +} + +// 删除购物车 +export function delShopCart(param){ + let paramArr = []; + for (let key in param) { + paramArr.push(key + '=' + param[key]) + } + let paramStr = '?' + paramArr.join('&') + return request.post(api.del_shop_cart + paramStr) +} + +// 删除购物车 +export function createOrder(param){ + let paramArr = []; + for (let key in param) { + paramArr.push(key + '=' + param[key]) + } + let paramStr = '?' + paramArr.join('&') + return request.post(api.create_order + paramStr) +} + +// 发票管理 +export function getBillManage(data){ + let option={header:{ + "Content-Type":"application/x-www-form-urlencoded;charset=UTF-8" + }} + return request.post(api.bill_manage,data,option) } \ No newline at end of file diff --git a/components/empty-cart/index.vue b/components/empty-cart/index.vue new file mode 100644 index 0000000..c44fe14 --- /dev/null +++ b/components/empty-cart/index.vue @@ -0,0 +1,79 @@ + + + + + diff --git a/pages.json b/pages.json index 18d9235..ef59b57 100644 --- a/pages.json +++ b/pages.json @@ -55,12 +55,6 @@ "enablePullDownRefresh" : false } }, - { - "path": "pages/cart/index", - "style": { - "navigationBarTitleText": "购物车" - } - }, { "path": "pages/user/index", "style": { @@ -350,7 +344,7 @@ "navigationBarTitleText" : "公共数据专区", "navigationBarTextStyle": "white", "navigationBarBackgroundColor": "#1c223b", - "enablePullDownRefresh" : false + "enablePullDownRefresh" : true } }, { @@ -360,7 +354,7 @@ "navigationBarTitleText" : "数据超市", "navigationBarTextStyle": "white", "navigationBarBackgroundColor": "#1c223b", - "enablePullDownRefresh" : false + "enablePullDownRefresh" : true } }, { @@ -370,7 +364,7 @@ "navigationBarTitleText" : "文化资源数据", "navigationBarTextStyle": "white", "navigationBarBackgroundColor": "#1c223b", - "enablePullDownRefresh" : false + "enablePullDownRefresh" : true } }, { @@ -380,7 +374,7 @@ "navigationBarTitleText" : "文化数字内容", "navigationBarTextStyle": "white", "navigationBarBackgroundColor": "#1c223b", - "enablePullDownRefresh" : false + "enablePullDownRefresh" : true } }, { @@ -388,7 +382,17 @@ "style" : { "navigationBarTitleText" : "购物车", - "enablePullDownRefresh" : false + "enablePullDownRefresh" : true, + "navigationBarTextStyle": "white", + "navigationBarBackgroundColor": "#1c223b" + } + }, + { + "path" : "pages/goods/payment/verifyPayment", + "style" : + { + "navigationBarTitleText" : "认证订单结算", + "enablePullDownRefresh" : true } }, { @@ -396,7 +400,7 @@ "style" : { "navigationBarTitleText" : "订单结算", - "enablePullDownRefresh" : false + "enablePullDownRefresh" : true } }, { diff --git a/pages/goods/detail.vue b/pages/goods/detail.vue index 57210df..8b764b2 100644 --- a/pages/goods/detail.vue +++ b/pages/goods/detail.vue @@ -250,7 +250,6 @@ shopyear_show: false, // 输入购买年限显示 talprice_show: false, // 合计显示 purchase_show: false, // 立即购买显示 - shopyear_num: '', // 立即购买显示 shopcart_str: '加入购物车', new_total: 0, // 标的数量 addprice: 0, // 合计金额 @@ -378,7 +377,7 @@ } else { if (app.ears_of === 2) { - let shopyear_num = app.shopyear_num + let shopyear_num = app.use_years if (shopyear_num === 0 || shopyear_num === '') { app.$error('购买年限只能输入整数') } else { @@ -409,7 +408,7 @@ let param = { goods_isli : app.goods.goods_islicode, user_isli : uni.getStorageSync("isliCode"), - use_years : 0, + use_years : app.use_years, } if (app.ears_of === 3) { param.use_years = 1 @@ -482,8 +481,7 @@ if (res.resultCode === "00000000") { // 跳转至付款界面 - - this.$navTo('pages/goods/payment', { batchcode:res.data.batchcode, img: app.goods.img, time: new Date().getTime() }) + this.$navTo('pages/goods/payment/orderPayment', { batchcode:res.data.batchcode, img: app.goods.img, time: new Date().getTime() }) } else { app.$error(res.errMsg); } diff --git a/pages/goods/payment/orderPayment.vue b/pages/goods/payment/orderPayment.vue index 2d518e2..a1b080d 100644 --- a/pages/goods/payment/orderPayment.vue +++ b/pages/goods/payment/orderPayment.vue @@ -8,256 +8,582 @@ - 认证缴费订单 + 标的清单 - 订单号 - 姓名 - 订单金额 + 缩略图 + 标的名称 + 委托关联编码 + 付费类型 + 交易方式 + 委托方 + 单价 + 购买年限 + 小计 + 交易佣金 + 合计 - {{ item.pay_no }} - - 认证缴费订单 + + - {{ item.address }} + {{ item.buy_username }} + {{ item.buy_islicode }} + {{ item.price_type}} + {{ item.goods_entrust }} + {{ item.order_detail[0].entrust_name }} + {{ item.price }} + {{ item.transaction_count }} + {{ item.small_count }} + ¥{{ item.order_detail[0].service_charge }} + {{ item.money }} + + + + + 我已阅读并同意 《文化数据交易协议》 + + + + + + + - 请扫码支付! - + + 温馨提示 请使用 网银、支付宝 App扫码支付 + + 支付成功! + 支付失败! + + \ No newline at end of file diff --git a/pages/goods/payment/verifyPayment.vue b/pages/goods/payment/verifyPayment.vue new file mode 100644 index 0000000..2d518e2 --- /dev/null +++ b/pages/goods/payment/verifyPayment.vue @@ -0,0 +1,263 @@ + + + + + \ No newline at end of file diff --git a/pages/help/purchase.vue b/pages/help/purchase.vue new file mode 100644 index 0000000..baaacab --- /dev/null +++ b/pages/help/purchase.vue @@ -0,0 +1,167 @@ + + + + + \ No newline at end of file diff --git a/pages/login/components/WhPopup.vue b/pages/login/components/WhPopup.vue index daa4680..ed5048d 100644 --- a/pages/login/components/WhPopup.vue +++ b/pages/login/components/WhPopup.vue @@ -17,6 +17,8 @@ + + @@ -36,6 +38,7 @@ import commission from '@/pages/help/commission' import business from '@/pages/help/business' import escapeclause from '@/pages/help/escapeclause' + import purchase from '@/pages/help/purchase' export default { components: { @@ -45,6 +48,7 @@ commission, business, escapeclause, + purchase, }, props: { diff --git a/pages/user/index.vue b/pages/user/index.vue index c511112..01c9dfe 100644 --- a/pages/user/index.vue +++ b/pages/user/index.vue @@ -10,12 +10,12 @@ - {{ userInfo.username }} + {{ userInfo.cellPhone }} ({{ userInfo.username }}) - - {{userInfo.userType}} + + {{userInfo.userType}} @@ -68,10 +68,17 @@ - + 发票管理 + + + + + + 购物车 + @@ -109,11 +116,13 @@ import * as UserApi from '@/api/user' import * as OrderApi from '@/api/order' import { checkLogin } from '@/core/app' + import uniIcons from '../../uni_modules/uni-icons/components/uni-icons/uni-icons' export default { components: { - AvatarImage + AvatarImage, + uniIcons, }, data() { return { @@ -254,6 +263,22 @@ } return true }, + // 买入订单 + shopCart(){ + if (this.validateVerify()) { + this.$navTo('pages/user/shopcart/index') + } else { + this.$error('未完成机构认证,请前往认证后查看') + } + }, + // 发票管理 + billManage(){ + if (this.validateVerify()) { + this.$navTo('pages/user/billManage/index') + } else { + this.$error('未完成机构认证,请前往认证后查看') + } + }, // 跳转到登录页 handleLogin() { diff --git a/pages/user/mycertinfo/mycertinfo.vue b/pages/user/mycertinfo/mycertinfo.vue index 63bc7cb..2c24a1d 100644 --- a/pages/user/mycertinfo/mycertinfo.vue +++ b/pages/user/mycertinfo/mycertinfo.vue @@ -64,7 +64,7 @@ //机构认证 orgverify(){ if (this.institutionsStr === '待缴费') { - this.$navTo("/pages/goods/payment/orderPayment") + this.$navTo("/pages/goods/payment/verifyPayment") } else { this.$navTo("pages/user/mycertinfo/orgverify") } @@ -72,7 +72,7 @@ //个人认证 personverify(){ if (this.peopleStr === '待缴费') { - this.$navTo("/pages/goods/payment/orderPayment") + this.$navTo("/pages/goods/payment/verifyPayment") } else { this.$navTo("pages/user/mycertinfo/personverify") } diff --git a/pages/user/mycertinfo/orgverify.vue b/pages/user/mycertinfo/orgverify.vue index fcab039..591b043 100644 --- a/pages/user/mycertinfo/orgverify.vue +++ b/pages/user/mycertinfo/orgverify.vue @@ -1161,7 +1161,7 @@ export default { }, jumpUrl() { if (this.fee > 0) { - uni.reLaunch({url: "/pages/goods/payment/orderPayment"}) + uni.reLaunch({url: "/pages/goods/payment/verifyPayment"}) } else { uni.reLaunch({url: "/pages/user/index"}) } diff --git a/pages/user/shopcart/index.vue b/pages/user/shopcart/index.vue new file mode 100644 index 0000000..be758d9 --- /dev/null +++ b/pages/user/shopcart/index.vue @@ -0,0 +1,543 @@ + + + + + + diff --git a/static/tabbar/cart_empty.jpg b/static/tabbar/cart_empty.jpg new file mode 100644 index 0000000..7c46d38 Binary files /dev/null and b/static/tabbar/cart_empty.jpg differ