Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xinrenli-app
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
郑云飞
xinrenli-app
Commits
7956d42d
Commit
7956d42d
authored
Apr 07, 2023
by
honghong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
支付,退款
parent
b536ed2d
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
198 additions
and
118 deletions
+198
-118
api/my/index.js
+3
-2
api/system/index.js
+25
-5
components/comment/comment.vue
+2
-2
components/evaluate.vue
+8
-2
demand/confirm/index.vue
+8
-5
demand/payment/index.vue
+0
-0
demand/updateForm/updateForm.vue
+3
-0
my/coupon/index.vue
+12
-13
my/invite/index.vue
+40
-18
order/detail/detail.vue
+30
-46
pages/demand/components/index.vue
+10
-8
pages/demand/index.vue
+27
-3
pages/my/index.vue
+3
-2
pages/order/index.vue
+9
-12
utils/request.js
+18
-0
No files found.
api/my/index.js
View file @
7956d42d
...
@@ -25,14 +25,14 @@ const queryInviteListGet = (params) =>{
...
@@ -25,14 +25,14 @@ const queryInviteListGet = (params) =>{
return
ApiHttp
(
'/xinrenli/Inviter/list'
,
params
,
'GET'
)
return
ApiHttp
(
'/xinrenli/Inviter/list'
,
params
,
'GET'
)
}
}
// 查询邀请列表
// 查询邀请列表
const
addInviter
Get
=
(
params
)
=>
{
const
addInviter
POST
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/Inviter'
,
params
,
'POST'
)
return
ApiHttp
(
'/xinrenli/Inviter'
,
params
,
'POST'
)
}
}
export
{
export
{
addUserFeedback
,
addUserFeedback
,
couponListGet
,
couponListGet
,
queryInviteListGet
,
queryInviteListGet
,
addInviter
Get
,
addInviter
POST
,
userCouponList
,
userCouponList
,
userCouponListLose
userCouponListLose
}
}
\ No newline at end of file
api/system/index.js
View file @
7956d42d
...
@@ -28,10 +28,6 @@ const orderDetailMsgNew = (params) => {
...
@@ -28,10 +28,6 @@ const orderDetailMsgNew = (params) => {
const
myNeedList
=
(
params
)
=>
{
const
myNeedList
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/order/MyNeeds'
,
params
,
'GET'
)
return
ApiHttp
(
'/xinrenli/order/MyNeeds'
,
params
,
'GET'
)
}
}
// 上传图片视频
// const = () => {
// return ApiHttp('/system/oss/upload')
// }
// 新增订单(发布)
// 新增订单(发布)
const
addOrderFunction
=
(
params
)
=>
{
const
addOrderFunction
=
(
params
)
=>
{
...
@@ -42,12 +38,31 @@ const addOrderFunction = (params) =>{
...
@@ -42,12 +38,31 @@ const addOrderFunction = (params) =>{
const
updateOrderFunction
=
(
params
)
=>
{
const
updateOrderFunction
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/order/edit'
,
params
,
'POST'
)
return
ApiHttp
(
'/xinrenli/order/edit'
,
params
,
'POST'
)
}
}
// 重新发布接口
const
againSubmitOrder
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/order/edit'
,
params
,
'POST'
)
}
//取消订单
//取消订单
const
removeOrderFunction
=
(
params
)
=>
{
const
removeOrderFunction
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/order/remove'
,
params
,
'GET'
)
return
ApiHttp
(
'/xinrenli/order/remove'
,
params
,
'GET'
)
}
}
//生成支付订单
const
createPayOrder
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/order/orderPay'
,
params
,
'GET'
)
}
//退款
const
refundFunction
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/order/refund'
,
params
,
'POST'
)
}
//查询用户折扣列表
const
userDiscountList
=
(
params
)
=>
{
return
ApiHttp
(
'/xinrenli/userDiscount/list'
,
params
,
'GET'
)
}
export
{
export
{
updateUserMsg
,
updateUserMsg
,
userNeedSquare
,
userNeedSquare
,
...
@@ -56,6 +71,10 @@ export {
...
@@ -56,6 +71,10 @@ export {
orderDetailMsgNew
,
orderDetailMsgNew
,
myNeedList
,
myNeedList
,
addOrderFunction
,
addOrderFunction
,
againSubmitOrder
,
updateOrderFunction
,
updateOrderFunction
,
removeOrderFunction
removeOrderFunction
,
createPayOrder
,
refundFunction
,
userDiscountList
}
}
\ No newline at end of file
components/comment/comment.vue
View file @
7956d42d
...
@@ -4,8 +4,8 @@
...
@@ -4,8 +4,8 @@
<img
class=
"avatar-img"
:src=
"item.userHead"
alt=
""
>
<img
class=
"avatar-img"
:src=
"item.userHead"
alt=
""
>
<view
class=
"flex-1 margin-left-one"
>
<view
class=
"flex-1 margin-left-one"
>
<view
class=
"d-flex a-center j-sb"
>
<view
class=
"d-flex a-center j-sb"
>
<view
class=
"nickname"
>
{{
item
.
createUser
?
item
.
createUser
:
''
}}
</view>
<view
class=
"nickname"
>
{{
item
.
userName
?
item
.
userName
:
''
}}
</view>
<view
class=
"font"
>
{{
item
.
create
Time
|
formatDate
}}
</view>
<view
class=
"font"
>
{{
item
.
modify
Time
|
formatDate
}}
</view>
</view>
</view>
<view
class=
"evaluateText"
>
{{
item
.
content
}}
</view>
<view
class=
"evaluateText"
>
{{
item
.
content
}}
</view>
</view>
</view>
...
...
components/evaluate.vue
View file @
7956d42d
...
@@ -7,12 +7,12 @@
...
@@ -7,12 +7,12 @@
<view
class=
"evaluateTip d-flex j-sb a-center"
>
<view
class=
"evaluateTip d-flex j-sb a-center"
>
<view
class=
"d-flex a-center"
>
<view
class=
"d-flex a-center"
>
<image
class=
"img"
src=
"../static/logoLogin.png"
mode=
"widthFix"
></image>
<image
class=
"img"
src=
"../static/logoLogin.png"
mode=
"widthFix"
></image>
<view
class=
"evaluate-name"
>
{{
item
.
createUser
}}
</view>
<view
class=
"evaluate-name"
>
{{
item
.
createUser
?
item
.
createUser
:
'官方发布'
}}
</view>
</view>
</view>
<view
class=
"font"
>
{{
item
.
createTime
|
formatDate
}}
</view>
<view
class=
"font"
>
{{
item
.
createTime
|
formatDate
}}
</view>
</view>
</view>
<view
class=
"evaluate-title"
>
{{
item
.
title
}}
</view>
<view
class=
"evaluate-title"
>
{{
item
.
title
}}
</view>
<view
class=
"evaluateText"
:class=
"
{lineclamp2:item.contentAll}"
>
{{
item
.
content
}}
</view>
<view
class=
"evaluateText"
:class=
"
{lineclamp2:item.contentAll}"
v-html="item.content">
</view>
<!--
<view
class=
""
v-if=
"item.isMore"
>
<!--
<view
class=
""
v-if=
"item.isMore"
>
<view
class=
"rightText"
v-if=
"item.contentAll"
@
click=
"changeAllFun(item, index)"
>
全部
</view>
<view
class=
"rightText"
v-if=
"item.contentAll"
@
click=
"changeAllFun(item, index)"
>
全部
</view>
<view
class=
"rightText"
v-else
@
click=
"changeAllFun(item, index)"
>
收起
</view>
<view
class=
"rightText"
v-else
@
click=
"changeAllFun(item, index)"
>
收起
</view>
...
@@ -100,6 +100,12 @@
...
@@ -100,6 +100,12 @@
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.evaluate
.evaluateCenter
.evaluateItem
{
.evaluate
.evaluateCenter
.evaluateItem
{
//
display
:
inline-block
;
//
display
:
inline-block
;
background
:
#ffa
;
background-color
:
#FFFFFF
;
padding
:
30
rpx
20
rpx
;
border-radius
:
10
rpx
;
margin
:
10px
20
rpx
0
20
rpx
;
box-shadow
:
0px
0px
8px
0px
rgba
(
0
,
0
,
0
,
0.1
);
}
}
//
展开收起
//
展开收起
...
...
demand/confirm/index.vue
View file @
7956d42d
...
@@ -15,7 +15,8 @@
...
@@ -15,7 +15,8 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
apiBaseConfig
from
'@/config/index.js'
;
import
apiBaseConfig
from
'@/config/index.js'
;
import
{
createPayOrder
}
from
'@/api/system/index.js'
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -26,10 +27,12 @@
...
@@ -26,10 +27,12 @@
},
},
onLoad
()
{},
onLoad
()
{},
methods
:
{
methods
:
{
jump
(){
async
jump
(){
this
.
$uniGo
.
navigateTo
({
const
data_back
=
await
createPayOrder
()
url
:
`/demand/prosperity/index`
console
.
log
(
data_back
,
'支付'
)
});
// this.$uniGo.navigateTo({
// url: `/demand/prosperity/index`
// });
}
}
}
}
}
}
...
...
demand/payment/index.vue
View file @
7956d42d
This diff is collapsed.
Click to expand it.
demand/updateForm/updateForm.vue
View file @
7956d42d
...
@@ -43,6 +43,9 @@
...
@@ -43,6 +43,9 @@
//重新发布和修改按钮事件
//重新发布和修改按钮事件
async
handleSubmit
(
data
){
async
handleSubmit
(
data
){
let
that
=
this
let
that
=
this
if
(
that
.
detailInfo
.
status
==
1
){
that
.
$set
(
data
,
'status'
,
0
)
}
const
back_data
=
await
updateOrderFunction
(
data
)
const
back_data
=
await
updateOrderFunction
(
data
)
const
{
code
}
=
back_data
const
{
code
}
=
back_data
if
(
code
==
200
){
if
(
code
==
200
){
...
...
my/coupon/index.vue
View file @
7956d42d
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
<text></text>
<text></text>
<view>
可用优惠券
{{
cantotal
}}
</view>
<view>
可用优惠券
{{
cantotal
}}
</view>
</view>
</view>
<view
class=
"index-content-item-qu"
@
click=
"optionData.type === 'pay'?jump():null"
>
<view
class=
"index-content-item-qu"
@
click=
"optionData.type === 'pay'?jump(
item
):null"
>
<image
class=
"index-content-item-qu-bg"
src=
"@/static/icon/xy01.png"
mode=
""
></image>
<image
class=
"index-content-item-qu-bg"
src=
"@/static/icon/xy01.png"
mode=
""
></image>
<view
class=
"index-content-item-qu-bl"
>
<view
class=
"index-content-item-qu-bl"
>
<text
class=
"index-content-item-qu-bl-tl"
>
满减优惠券
</text>
<text
class=
"index-content-item-qu-bl-tl"
>
满减优惠券
</text>
...
@@ -78,16 +78,16 @@
...
@@ -78,16 +78,16 @@
optionData
:
{},
optionData
:
{},
title
:
''
,
title
:
''
,
queryParams
:{
queryParams
:{
pageNum
:
1
,
//
pageNum:1,
pageSize
:
10
,
//
pageSize:10,
deleteStatus
:
0
,
deleteStatus
:
0
,
useStatus
:
0
useStatus
:
0
},
//优惠券有效参数
},
//优惠券有效参数
useCouponList
:[],
//可使用的优惠券列表
useCouponList
:[],
//可使用的优惠券列表
cantotal
:
0
,
cantotal
:
0
,
loseParams
:{
loseParams
:{
pageNum
:
1
,
//
pageNum:1,
pageSize
:
10
,
//
pageSize:10,
deleteStatus
:
1
,
deleteStatus
:
1
,
useStatus
:
1
useStatus
:
1
},
},
...
@@ -140,22 +140,21 @@
...
@@ -140,22 +140,21 @@
break
;
break
;
}
}
},
},
jump
()
{
jump
(
data
)
{
console
.
log
(
'22222'
)
uni
.
$emit
(
'payInfo'
,
data
)
// 获取所有页面栈实例列表
// 获取所有页面栈实例列表
let
pages
=
getCurrentPages
();
//
let pages = getCurrentPages();
// 上一页页面实例
//
//
上一页页面实例
let
prevPage
=
pages
[
pages
.
length
-
2
];
//
let prevPage = pages[pages.length - 2];
// 修改上一页data里面的times参数值为100
//
//
修改上一页data里面的times参数值为100
prevPage
.
$vm
.
times
=
100
;
//
prevPage.$vm.times = 100;
//uni.navigateTo跳转的返回,默认1为返回上一级
//uni.navigateTo跳转的返回,默认1为返回上一级
uni
.
navigateBack
({
uni
.
navigateBack
({
delta
:
1
delta
:
1
});
});
console
.
log
(
'1111111'
)
}
}
}
}
};
};
...
...
my/invite/index.vue
View file @
7956d42d
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
<text></text>
<text></text>
<view>
<view>
我已邀请:
我已邀请:
<text>
3
位用户
</text>
<text>
{{
total
}}
位用户
</text>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -34,42 +34,64 @@
...
@@ -34,42 +34,64 @@
-->
-->
</view>
</view>
<view>
<view>
<button
class=
"invite-btn"
data-name=
"shareB
tn"
open-type=
"share"
>
继续邀请新用户
</button>
<button
class=
"invite-b
tn"
open-type=
"share"
>
继续邀请新用户
</button>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
apiBaseConfig
from
'@/config/index.js'
;
import
apiBaseConfig
from
'@/config/index.js'
;
import
{
queryInviteListGet
,
addInviterGet
}
from
'@/api/my/index.js'
import
{
queryInviteListGet
,
addInviterGet
}
from
'@/api/my/index.js'
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
imgBgUrl
:
apiBaseConfig
.
imgBgUrl
,
imgBgUrl
:
apiBaseConfig
.
imgBgUrl
,
globalData
:
getApp
().
globalData
,
globalData
:
getApp
().
globalData
,
scrollTopHeader
:
0
scrollTopHeader
:
0
,
inviteList
:
[],
total
:
0
};
};
},
},
//分享
onShareAppMessage
(
options
)
{
onShareAppMessage
()
{
var
that
=
this
;
return
{
// 设置菜单中的转发按钮触发转发事件时的转发内容
title
:
'分享的标题'
,
var
shareObj
=
{
success
()
{
title
:
"新人力小程序"
,
// 默认是小程序的名称(可以写slogan等)
addInviterGet
().
then
(
res
=>
{
path
:
'/my/login/login'
,
// 默认是当前页面,必须是以‘/'开头的完整路径
};
})
// 来自页面内的按钮的转发
}
if
(
options
.
from
==
'button'
)
{
var
eData
=
options
.
target
.
dataset
;
console
.
log
(
eData
.
name
);
// shareBtn
// 此处可以修改 shareObj 中的内容
shareObj
.
path
=
'/my/login/login'
;
}
}
console
.
log
(
"shareObj"
,
shareObj
)
// 返回shareObj
return
shareObj
;
},
},
onLoad
()
{
onLoad
()
{
wx
.
hideShareMenu
()
this
.
getList
()
this
.
getList
()
},
},
methods
:
{
methods
:
{
// 获取邀请列表
// 获取邀请列表
getList
(){
async
getList
()
{
queryInviteListGet
().
then
(
res
=>
{
const
data_back
=
await
queryInviteListGet
()
console
.
log
(
data_back
,
'第三节'
)
})
const
{
code
,
rows
,
total
}
=
data_back
if
(
code
==
200
&&
total
>
0
)
{
this
.
inviteList
=
rows
this
.
total
=
total
}
}
}
}
}
};
};
...
...
order/detail/detail.vue
View file @
7956d42d
...
@@ -16,14 +16,12 @@
...
@@ -16,14 +16,12 @@
<image
class=
"img"
<image
class=
"img"
src=
"https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500"
src=
"https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500"
mode=
"widthFix"
></image>
mode=
"widthFix"
></image>
<view
class=
"evaluate-name"
>
张三
</view>
<view
class=
"evaluate-name"
>
{{
articleData
.
createUser
?
articleData
.
createUser
:
'官方'
}}
</view>
</view>
</view>
<view
class=
"eval-time"
>
发布于
{{
articleData
.
createTime
|
formatDate
}}
</view>
<view
class=
"eval-time"
>
发布于
{{
articleData
.
createTime
|
formatDate
}}
</view>
</view>
</view>
<view
class=
"evaluateText text-indent"
>
<view
class=
"evaluateText text-indent"
v-html=
"articleData.content"
></view>
{{
articleData
.
content
}}
</view>
</view>
</view>
</view>
</view>
<view
class=
"bgWhite"
>
<view
class=
"bgWhite"
>
...
@@ -34,7 +32,7 @@
...
@@ -34,7 +32,7 @@
</view>
</view>
<view
class=
"comment-box"
>
<view
class=
"comment-box"
>
<view
class=
"paddding-x-two comment-box-height d-flex a-center j-sb"
>
<view
class=
"paddding-x-two comment-box-height d-flex a-center j-sb"
>
<input
v-model=
"content"
class=
"send-input"
type=
"text"
placeholder=
"评论一下吧"
>
<input
v-model=
"
evalQuery.
content"
class=
"send-input"
type=
"text"
placeholder=
"评论一下吧"
>
<view
class=
"send-btn-box"
@
click=
"handleSend"
>
发送
</view>
<view
class=
"send-btn-box"
@
click=
"handleSend"
>
发送
</view>
</view>
</view>
</view>
</view>
...
@@ -47,37 +45,6 @@
...
@@ -47,37 +45,6 @@
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
personEvalList
:
[{
avatar
:
'https://img2.baidu.com/it/u=955956276,3392954639&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500'
,
nickname
:
'李哈哈'
,
date
:
'2022-01-31'
,
content
:
'评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容'
},
{
avatar
:
'https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500'
,
nickname
:
'李小乖'
,
date
:
'2022-05-11'
,
content
:
'评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容'
},
{
avatar
:
'https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500'
,
nickname
:
'李晓扎'
,
date
:
'2022-05-11'
,
content
:
'评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容'
},
{
avatar
:
'https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500'
,
nickname
:
'李小乖'
,
date
:
'2022-05-11'
,
content
:
'评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容'
},
{
avatar
:
'https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500'
,
nickname
:
'李晓扎'
,
date
:
'2022-05-11'
,
content
:
'评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容评论内容'
},
],
articleData
:{},
articleData
:{},
userQuery
:{
userQuery
:{
pageNum
:
1
,
pageNum
:
1
,
...
@@ -85,11 +52,14 @@
...
@@ -85,11 +52,14 @@
articleId
:
null
articleId
:
null
},
},
userEvalList
:[],
userEvalList
:[],
content
:
''
,
//评论的内容
evalQuery
:{
content
:
''
,
//评论的内容
articleId
:
''
,
//文章id
deleteStatus
:
0
}
}
}
},
},
onLoad
(
option
)
{
onLoad
(
option
)
{
console
.
log
(
option
.
id
,
'接受的'
)
this
.
getDetail
(
option
.
id
)
this
.
getDetail
(
option
.
id
)
this
.
getUserEvalList
(
option
.
id
)
this
.
getUserEvalList
(
option
.
id
)
},
},
...
@@ -97,7 +67,6 @@
...
@@ -97,7 +67,6 @@
getDetail
(
id
){
getDetail
(
id
){
let
that
=
this
let
that
=
this
articleDetail
(
id
).
then
(
res
=>
{
articleDetail
(
id
).
then
(
res
=>
{
console
.
log
(
res
,
'文章详情'
)
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
that
.
articleData
=
res
.
data
that
.
articleData
=
res
.
data
}
}
...
@@ -107,7 +76,6 @@
...
@@ -107,7 +76,6 @@
let
that
=
this
let
that
=
this
that
.
userQuery
.
articleId
=
id
that
.
userQuery
.
articleId
=
id
userEvaluateGet
(
that
.
userQuery
).
then
(
res
=>
{
userEvaluateGet
(
that
.
userQuery
).
then
(
res
=>
{
console
.
log
(
res
,
'用户评论列表'
)
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
if
(
res
.
total
>
0
){
if
(
res
.
total
>
0
){
this
.
userEvalList
=
res
.
rows
this
.
userEvalList
=
res
.
rows
...
@@ -115,13 +83,29 @@
...
@@ -115,13 +83,29 @@
}
}
})
})
},
},
handleSend
(){
async
handleSend
(){
let
that
=
this
let
that
=
this
that
.
content
=
that
.
content
.
trim
()
if
(
that
.
evalQuery
.
content
){
if
(
that
.
content
){
that
.
$set
(
that
.
evalQuery
,
'content'
,
that
.
evalQuery
.
content
.
trim
())
addUserEvaluate
({
content
:
this
.
content
.
trim
()}).
then
(
res
=>
{
that
.
$set
(
that
.
evalQuery
,
'articleId'
,
that
.
articleData
.
id
)
console
.
log
(
'发送'
,
res
)
const
data_back
=
await
addUserEvaluate
(
that
.
evalQuery
)
})
const
{
code
}
=
data_back
if
(
code
===
200
){
that
.
evalQuery
.
content
=
''
uni
.
showToast
({
title
:
'评论成功!'
,
icon
:
'none'
,
duration
:
2000
,
success
()
{
let
clearTime
=
setTimeout
(()
=>
{
clearTimeout
(
clearTime
)
that
.
$uniGo
.
navigateBack
({
delta
:
1
})
},
1000
)
}
})
}
}
else
{
}
else
{
return
uni
.
showToast
({
return
uni
.
showToast
({
title
:
'不可发布空白内容'
,
title
:
'不可发布空白内容'
,
...
...
pages/demand/components/index.vue
View file @
7956d42d
...
@@ -40,15 +40,15 @@
...
@@ -40,15 +40,15 @@
截止1小时内支付完成
<text>
{{
isEndTime
}}
</text>
截止1小时内支付完成
<text>
{{
isEndTime
}}
</text>
</view>
</view>
</view>
</view>
<view
class=
""
@
click
.
stop=
"payment"
>
<view
class=
""
@
click
.
stop=
"payment
(item)
"
>
<button
class=
"buttoncl"
>
支付
</button>
<button
class=
"buttoncl"
>
支付
</button>
</view>
</view>
</view>
</view>
<!-- // 已接单 -->
<!-- // 已接单 -->
<view
class=
"buttoncolor"
v-if=
"subscript == '3'"
>
<view
class=
"buttoncolor"
v-if=
"subscript == '3'"
>
<button
class=
"buttoncl"
@
click
.
stop=
"abolish(2)"
>
退款
</button>
<button
class=
"buttoncl"
@
click
.
stop=
"abolish(2
,item
)"
>
退款
</button>
<button
class=
"buttonclde"
@
click
.
stop=
"abolish(3)"
>
详情
</button>
<button
class=
"buttonclde"
@
click
.
stop=
"abolish(3
,item
)"
>
详情
</button>
<button
class=
"buttonclde"
@
click
.
stop=
"abolish(4)"
>
已退款
</button>
<button
class=
"buttonclde"
@
click
.
stop=
"abolish(4
,item
)"
>
已退款
</button>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -83,6 +83,7 @@
...
@@ -83,6 +83,7 @@
title
:
'确认取消订单吗'
,
title
:
'确认取消订单吗'
,
titbut
:
'取消订单'
,
titbut
:
'取消订单'
,
currentId
:
''
,
//当前的id
currentId
:
''
,
//当前的id
actualAmount
:
0
,
//实付金饿
}
}
},
},
...
@@ -114,15 +115,16 @@
...
@@ -114,15 +115,16 @@
});
});
},
},
// 跳转支付界面
// 跳转支付界面
payment
()
{
payment
(
data
)
{
this
.
$uniGo
.
navigateTo
({
this
.
$uniGo
.
navigateTo
({
url
:
`/demand/payment/index`
url
:
`/demand/payment/index
?detailInfo=
${
encodeURIComponent
(
JSON
.
stringify
(
data
))}
`
});
});
},
},
// 取消订单1 立即退款2
// 取消订单1 立即退款2
abolish
(
val
,
data
)
{
abolish
(
val
,
data
)
{
console
.
log
(
data
.
id
,
'数控'
)
console
.
log
(
data
.
id
,
data
.
actualAmount
,
'数控'
)
this
.
currentId
=
data
.
id
this
.
currentId
=
data
.
id
this
.
actualAmount
=
data
.
actualAmount
if
(
val
==
1
)
{
if
(
val
==
1
)
{
this
.
title
=
'确认取消订单吗'
this
.
title
=
'确认取消订单吗'
this
.
titbut
=
'1'
this
.
titbut
=
'1'
...
@@ -154,7 +156,7 @@
...
@@ -154,7 +156,7 @@
},
},
// 取消订单2 立即退款3
// 取消订单2 立即退款3
aindexst
(
val
)
{
aindexst
(
val
)
{
this
.
$emit
(
'getVal'
,
val
,
this
.
currentId
)
this
.
$emit
(
'getVal'
,
val
,
this
.
currentId
,
this
.
actualAmount
)
this
.
show
=
false
this
.
show
=
false
}
}
}
}
...
...
pages/demand/index.vue
View file @
7956d42d
...
@@ -58,7 +58,8 @@
...
@@ -58,7 +58,8 @@
import
{
import
{
myNeedList
,
myNeedList
,
orderDetailList
,
orderDetailList
,
removeOrderFunction
removeOrderFunction
,
refundFunction
}
from
'../../api/system/index.js'
}
from
'../../api/system/index.js'
import
apiBaseConfig
from
'@/config/index.js'
;
import
apiBaseConfig
from
'@/config/index.js'
;
import
uniGo
from
'@/utils/unIGO.js'
;
import
uniGo
from
'@/utils/unIGO.js'
;
...
@@ -150,12 +151,35 @@
...
@@ -150,12 +151,35 @@
})
})
}
}
},
},
// 立即退款接口
async
handleRefund
(
id
,
price
){
const
data_back
=
await
refundFunction
({
refundeAmount
:
price
,
orderId
:
id
})
console
.
log
(
data_back
,
'退款'
)
const
{
code
}
=
back_data
if
(
code
==
200
)
{
uni
.
showToast
({
title
:
'退款成功!'
,
icon
:
'none'
,
duration
:
2000
,
success
()
{
setTimeout
(()
=>
{
that
.
getMyNeedList
()
},
1000
)
}
})
}
},
// 取消订单2 立即退款3
// 取消订单2 立即退款3
handleStatus
(
val
,
id
)
{
handleStatus
(
val
,
id
,
price
)
{
console
.
log
(
val
,
id
,
'装订好'
)
console
.
log
(
val
,
id
,
price
,
'装订好'
)
let
that
=
this
let
that
=
this
if
(
val
==
2
)
{
if
(
val
==
2
)
{
that
.
handleCancle
(
id
)
that
.
handleCancle
(
id
)
}
else
if
(
val
==
3
){
that
.
handleRefund
(
id
,
price
)
}
}
}
}
}
}
...
...
pages/my/index.vue
View file @
7956d42d
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<view
class=
"content-in-info-r"
>
<view
class=
"content-in-info-r"
>
<view
class=
"content-in-info-r-t baiyin-flex"
>
<view
class=
"content-in-info-r-t baiyin-flex"
>
<text
v-if=
"nameDisabled"
>
{{
nickname
}}
</text>
<text
v-if=
"nameDisabled"
>
{{
nickname
}}
</text>
<input
v-else
confirm-type=
"确定"
@
confirm=
"inputNameConfirm"
maxlength=
"15"
type=
"text"
value=
"用户名称1
"
/>
<input
v-else
confirm-type=
"确定"
@
confirm=
"inputNameConfirm"
maxlength=
"15"
type=
"text"
:value=
"nickname
"
/>
<image
src=
"@/static/icon/my02.png"
mode=
""
@
click=
"nameDisabled = !nameDisabled"
></image>
<image
src=
"@/static/icon/my02.png"
mode=
""
@
click=
"nameDisabled = !nameDisabled"
></image>
</view>
</view>
<view
class=
"content-in-info-r-b"
v-if=
"mobile"
>
手机号:
{{
mobile
}}
</view>
<view
class=
"content-in-info-r-b"
v-if=
"mobile"
>
手机号:
{{
mobile
}}
</view>
...
@@ -93,7 +93,7 @@ export default {
...
@@ -93,7 +93,7 @@ export default {
globalData
:
getApp
().
globalData
,
globalData
:
getApp
().
globalData
,
scrollTopHeader
:
0
,
scrollTopHeader
:
0
,
nameDisabled
:
true
,
nameDisabled
:
true
,
nickname
:
this
.
$store
.
state
.
login
.
userInfo
.
user
.
nickname
,
nickname
:
'用户名称'
,
mobile
:
''
,
//手机号
mobile
:
''
,
//手机号
list
:
[
list
:
[
{
{
...
@@ -124,6 +124,7 @@ export default {
...
@@ -124,6 +124,7 @@ export default {
};
};
},
},
onLoad
()
{
onLoad
()
{
this
.
nickname
=
this
.
$store
.
state
.
login
.
userInfo
.
user
.
nickname
console
.
log
(
this
.
$store
.
state
.
login
.
userInfo
.
user
.
nickname
,
'D撒'
)
console
.
log
(
this
.
$store
.
state
.
login
.
userInfo
.
user
.
nickname
,
'D撒'
)
let
mobile
=
uni
.
getStorageSync
(
'mobile'
)
let
mobile
=
uni
.
getStorageSync
(
'mobile'
)
this
.
mobile
=
mobile
this
.
mobile
=
mobile
...
...
pages/order/index.vue
View file @
7956d42d
...
@@ -105,21 +105,18 @@
...
@@ -105,21 +105,18 @@
]
]
}
}
},
},
onLoad
()
{
onReachBottom
()
{
let
that
=
this
if
(
that
.
total
<=
that
.
queryParams
.
pageNum
*
that
.
queryParams
.
pageSize
)
return
that
.
queryParams
.
pageNum
++
that
.
getArticleList
()
},
onShow
()
{
this
.
getArticleList
()
this
.
getArticleList
()
},
},
methods
:
{
methods
:
{
async
getArticleList
(){
async
getArticleList
(){
let
that
=
this
let
that
=
this
// userArticleGet(that.queryParams).then(res=>{
// console.log('文章列表',res.rows)
// if(res.code == 200){
// if(res.total > 0){
// that.articleList = res.rows
// that.total = res.total
// }
// }
// })
const
data_back
=
await
userArticleGet
(
that
.
queryParams
);
const
data_back
=
await
userArticleGet
(
that
.
queryParams
);
const
{
code
,
total
,
rows
}
=
data_back
;
const
{
code
,
total
,
rows
}
=
data_back
;
if
(
code
===
200
&&
total
>
0
)
{
if
(
code
===
200
&&
total
>
0
)
{
...
@@ -142,10 +139,10 @@
...
@@ -142,10 +139,10 @@
<
style
>
<
style
>
.friends-list-box
{
.friends-list-box
{
background-color
:
#FFFFFF
;
/*
background-color: #FFFFFF;
padding: 30rpx 20rpx;
padding: 30rpx 20rpx;
border-radius: 10rpx;
border-radius: 10rpx;
margin: 10px 20rpx 0 20rpx;
margin: 10px 20rpx 0 20rpx;
box-shadow
:
0px
0px
8px
0px
rgba
(
0
,
0
,
0
,
0.1
);
box-shadow: 0px 0px 8px 0px rgba(0, 0, 0, 0.1);
*/
}
}
</
style
>
</
style
>
utils/request.js
View file @
7956d42d
...
@@ -63,6 +63,23 @@ const ApiHttp = (url, params, method, isToken = true) => {
...
@@ -63,6 +63,23 @@ const ApiHttp = (url, params, method, isToken = true) => {
if
(
code
===
200
)
{
if
(
code
===
200
)
{
resolve
(
data
);
resolve
(
data
);
}
else
if
(
code
===
401
)
{
}
else
if
(
code
===
401
)
{
uni
.
clearStorageSync
();
uni
.
showModal
({
title
:
'请登录'
,
content
:
'您需要登录才能使用该功能'
,
success
:
(
res
)
=>
{
if
(
res
.
confirm
)
{
uni
.
reLaunch
({
url
:
'/my/login/login'
})
}
else
if
(
res
.
cancel
)
{
uni
.
navigateBack
()
}
}
})
resolve
(
data
);
resolve
(
data
);
}
else
{
}
else
{
if
(
url
==
'/group-buy/by-consumer-order/leader/refunde'
||
if
(
url
==
'/group-buy/by-consumer-order/leader/refunde'
||
...
@@ -75,6 +92,7 @@ const ApiHttp = (url, params, method, isToken = true) => {
...
@@ -75,6 +92,7 @@ const ApiHttp = (url, params, method, isToken = true) => {
title
:
msg
||
'系统内部错误'
,
title
:
msg
||
'系统内部错误'
,
icon
:
"none"
icon
:
"none"
})
})
if
(
url
==
'/system/xcxLogin'
||
url
==
'system/getPhone'
)
{
if
(
url
==
'/system/xcxLogin'
||
url
==
'system/getPhone'
)
{
uni
.
clearStorageSync
();
uni
.
clearStorageSync
();
store
.
dispatch
(
'loginOut'
)
store
.
dispatch
(
'loginOut'
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment