Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
self-support
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李俊赕
self-support
Commits
8b91f718
Commit
8b91f718
authored
Apr 28, 2021
by
李超鹏
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
# Conflicts: # src/common/api/order.js
parents
37caa8cc
4eee97a2
Changes
24
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
2345 additions
and
1522 deletions
+2345
-1522
.env.dev.js
.env.dev.js
+4
-4
learn.js
src/common/api/learn.js
+1
-1
order.js
src/common/api/order.js
+60
-39
settled.js
src/common/api/settled.js
+1
-1
http.interceptor.js
src/common/http.interceptor.js
+2
-1
appoint-time.vue
src/components/appoint/appoint-time.vue
+160
-73
index.vue
src/components/order/index.vue
+18
-14
index.vue
src/components/popView/index.vue
+29
-8
index.vue
src/components/settle/index.vue
+10
-2
main.js
src/main.js
+14
-2
pages.json
src/pages.json
+9
-3
index.vue
src/pages/index/index.vue
+13
-10
answer.vue
src/pages/learn/answer.vue
+247
-156
assessment.vue
src/pages/learn/assessment.vue
+101
-143
curriculum.vue
src/pages/learn/curriculum.vue
+55
-14
index.vue
src/pages/learn/index.vue
+639
-468
result.vue
src/pages/learn/result.vue
+128
-81
section.vue
src/pages/learn/section.vue
+330
-334
detail.vue
src/pages/order/detail.vue
+288
-123
feedback.vue
src/pages/order/feedback.vue
+162
-17
index.vue
src/pages/order/index.vue
+19
-14
refuse.vue
src/pages/order/refuse.vue
+53
-12
prompt.vue
src/pages/settle/prompt.vue
+1
-1
sign-contract.vue
src/pages/settle/sign-contract.vue
+1
-1
No files found.
.env.dev.js
View file @
8b91f718
const
UNI_APP
=
{
const
UNI_APP
=
{
ucenterUrl
:
{
ucenterUrl
:
{
apiUrl
:
'http://
192.168.1.46
'
,
//php端域名请求头
apiUrl
:
'http://
rest-u.yunya.com
'
,
//php端域名请求头
xueUrl
:
'http://
192.168.1.46:8088'
,
//学院
xueUrl
:
'http://
xue.yunya.com'
,
//学院
// banshou: 'https://m.banshou.com', //扳手app
// banshou: 'https://m.banshou.com', //扳手app
},
},
systemUrl
:
{
systemUrl
:
{
apiUrl
:
'http://192.168.1.22'
,
//java端域名请求头
//
apiUrl: 'http://192.168.1.22', //java端域名请求头
//
apiUrl: 'http://apidoc.banshouhui.com:3000/mock/31', // mock端域名请求头
apiUrl
:
'http://apidoc.banshouhui.com:3000/mock/31'
,
// mock端域名请求头
},
},
qn_base_url
:
'https://qn-static.banshouhui.com/self-support/'
qn_base_url
:
'https://qn-static.banshouhui.com/self-support/'
}
}
...
...
src/common/api/learn.js
View file @
8b91f718
...
@@ -7,7 +7,7 @@ let learnApiFun = function(vm){
...
@@ -7,7 +7,7 @@ let learnApiFun = function(vm){
let
getTrainingNoticeList
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
ucenterApiUrl
+
'/v1/notice/list'
,
params
);
let
getTrainingNoticeList
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
ucenterApiUrl
+
'/v1/notice/list'
,
params
);
/* 获取学习视频基本信息 */
/* 获取学习视频基本信息 */
let
CourseList
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
collegeApiUrl
+
'/v1/course-details
?course_id=173
'
,
params
);
let
CourseList
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
collegeApiUrl
+
'/v1/course-details'
,
params
);
/* 获取章节详情 */
/* 获取章节详情 */
let
ChapterDetails
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
collegeApiUrl
+
'/v1/chapter-sections'
,
params
);
let
ChapterDetails
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
collegeApiUrl
+
'/v1/chapter-sections'
,
params
);
/* 获取课程节信息*/
/* 获取课程节信息*/
...
...
src/common/api/order.js
View file @
8b91f718
import
util
from
'@/utils/util.js'
import
util
from
'@/utils/util.js'
// 接口公共前缀
const
prefix
=
'/wxh-worker-rest/rest/'
let
orderApiFun
=
function
(
vm
){
let
orderApiFun
=
function
(
vm
){
let
listByRecommendOrder
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/recommend/order'
,
params
);
let
listByRecommendOrder
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/recommend/order'
,
params
);
/**
/**
* 工单数量查询接口
* 工单数量查询接口
*/
*/
let
listOrderCount
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/wokerOrder/queryOrdersCount/V2'
,
params
);
let
listOrderCount
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/wokerOrder/queryOrdersCount/V2'
,
params
);
/**
/**
* 工单列表接口
wxh-worker-rest/rest/order/revision/{token}/list
* 工单列表接口
*/
*/
let
listOrder
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/'
+
vm
.
vuex_token
+
'/list'
,
params
);
let
listOrder
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/'
+
vm
.
vuex_token
+
'/list'
,
params
);
/**
/**
* 获取师傅的预约日历
* 获取师傅的预约日历
*/
*/
let
workerCalendar
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/wokerOrder/appointment/calendar'
,
params
);
let
workerCalendar
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/wokerOrder/appointment/calendar'
,
params
);
/**
/**
* 师傅预约
* 师傅预约
*/
*/
let
workerAppointment
=
async
(
params
=
{})
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/order/traceAndAppointment/traceOrder/'
+
vm
.
vuex_token
+
'/order/{orderId}'
,
params
,{
'content-type'
:
'application/x-www-form-urlencoded'
});
let
workerAppointment
=
async
(
params
=
{})
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/order/traceAndAppointment/traceOrder/'
+
vm
.
vuex_token
+
'/order/{orderId}'
,
params
,{
'content-type'
:
'application/x-www-form-urlencoded'
});
// 联系顾客时间更新接口,暂时没有
// 联系顾客时间更新接口,暂时没有
/**
/**
* 师傅签到接口
* 师傅签到接口
*/
*/
let
maintainWorkerCheckin
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
prefix
+
'/wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintainWorkerCheckin'
,
params
,{
'content-type'
:
'application/x-www-form-urlencoded'
});
let
maintainWorkerCheckin
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
prefix
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintainWorkerCheckin'
,
params
,{
'content-type'
:
'application/x-www-form-urlencoded'
});
/**
/**
* 订单详情查询
* 订单详情查询
*/
*/
let
orderDetail
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/'
+
vm
.
vuex_token
+
'/'
+
orderId
,
params
);
let
orderDetail
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/'
+
vm
.
vuex_token
+
'/'
+
orderId
,
params
);
/* 过程反馈查询接口 */
/* 过程反馈查询接口 */
let
feedbackConfig
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rst/order/v2/getFeedBack/'
+
vm
.
vuex_token
,
params
)
let
feedbackConfig
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/r
e
st/order/v2/getFeedBack/'
+
vm
.
vuex_token
,
params
)
/* 预约+过程反馈 接口 */
/* 预约+过程反馈 接口 */
let
traceAndAppointment
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/order/traceAndAppointment/trace/V2/'
+
vm
.
vuex_token
+
'/'
+
orderId
,
params
)
let
traceAndAppointment
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/order/traceAndAppointment/trace/V2/'
+
vm
.
vuex_token
+
`/
${
orderId
}
`
,
params
)
/* 师傅拒单 */
/* 师傅拒单 */
let
rejectOrder
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/workerReject/V2'
,
params
)
let
rejectOrder
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
`/order/
${
orderId
}
/workerReject/V2`
,
params
)
/**
/**
* 查询工单操作记录列表接口
* 查询工单操作记录列表接口
*/
*/
let
listOrderRecord
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/record/'
+
vm
.
vuex_token
+
'/listOrderRecord/'
+
params
.
orderId
,
params
);
let
listOrderRecord
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/record/'
+
vm
.
vuex_token
+
'/listOrderRecord/'
+
params
.
orderId
,
params
);
/**
/**
* 接单
* 接单
*/
*/
let
orderAccept
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/accept'
,
params
);
let
orderAccept
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/accept'
,
params
);
/**
/**
* 抢单
* 抢单
*/
*/
let
orderGan
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/order/revision/applets/'
+
vm
.
vuex_token
+
'/order/acceptAppletsOrder'
,
params
,{
'content-type'
:
'application/x-www-form-urlencoded'
});
let
orderGan
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/order/revision/applets/'
+
vm
.
vuex_token
+
'/order/acceptAppletsOrder'
,
params
,{
'content-type'
:
'application/x-www-form-urlencoded'
});
/**
/**
* 获取拍照标准
* 获取拍照标准
*/
*/
let
orderStandard
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/photo/standard'
,
params
);
let
orderStandard
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/photo/standard'
,
params
);
/**
/**
* 保存图片信息
* 保存图片信息
*/
*/
let
saveImage
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'/wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintain/saveImage'
,
params
);
let
saveImage
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
prefix
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintain/saveImage'
,
params
);
/**
/**
* 获取师傅水印 or 默认水印
* 获取师傅水印 or 默认水印
*/
*/
let
getWatermark
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/photo/watermark'
,
params
);
let
getWatermark
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/photo/watermark'
,
params
);
/**
* 获取师傅开放可选时间段
*/
let
openTimerange
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/wokerOrder/appointment/timerange'
,
params
);
/**
* 联系时间接口
*/
let
contactTime
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/record/'
+
vm
.
vuex_token
+
'/contact/'
+
orderId
,
params
);
/**
* 检查是否可以拒单
*/
let
checkRejectable
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/'
+
vm
.
vuex_token
+
'/wokerOrder/checkRejectable'
,
params
);
/**
/**
* 获取订单的完工项目(配置+数据)
* 获取订单的完工项目(配置+数据)
*/
*/
let
getCompleteConfigAndData
=
async
(
orderId
)
=>
await
vm
.
$u
.
get
(
'wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintain/info'
);
let
getCompleteConfigAndData
=
async
(
orderId
)
=>
await
vm
.
$u
.
get
(
'wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintain/info'
);
/**
/**
* 查询措施
* 查询措施
*/
*/
let
getMeasure
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'wxh-worker-rest/rest/service/'
+
vm
.
vuex_token
+
'/measure/queryMeasureItems'
,
params
);
let
getMeasure
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'wxh-worker-rest/rest/service/'
+
vm
.
vuex_token
+
'/measure/queryMeasureItems'
,
params
);
/**
/**
* 保存售后记录
* 保存售后记录
*/
*/
let
saveCompleteData
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintain/saveMaintainInfoV2'
,
params
);
let
saveCompleteData
=
async
(
params
=
{},
orderId
)
=>
await
vm
.
$u
.
post
(
'wxh-worker-rest/rest/'
+
vm
.
vuex_token
+
'/order/'
+
orderId
+
'/maintain/saveMaintainInfoV2'
,
params
);
const
orderApi
=
{
const
orderApi
=
{
listByRecommendOrder
,
listByRecommendOrder
,
listOrderCount
,
listOrderCount
,
...
@@ -105,6 +123,9 @@ let orderApiFun = function(vm){
...
@@ -105,6 +123,9 @@ let orderApiFun = function(vm){
orderStandard
,
orderStandard
,
saveImage
,
saveImage
,
getWatermark
,
getWatermark
,
openTimerange
,
contactTime
,
checkRejectable
,
getCompleteConfigAndData
,
getCompleteConfigAndData
,
getMeasure
,
getMeasure
,
saveCompleteData
saveCompleteData
...
@@ -113,4 +134,4 @@ let orderApiFun = function(vm){
...
@@ -113,4 +134,4 @@ let orderApiFun = function(vm){
}
}
module
.
exports
=
{
module
.
exports
=
{
orderApiFun
orderApiFun
}
}
\ No newline at end of file
src/common/api/settled.js
View file @
8b91f718
...
@@ -39,7 +39,7 @@ let settledApiFun = function(vm){
...
@@ -39,7 +39,7 @@ let settledApiFun = function(vm){
let
saveCourseRate
=
async
(
params
=
{})
=>
await
vm
.
$u
.
post
(
ucenterApiUrl
+
'/v1/settled/save-course-rate'
,
params
);
let
saveCourseRate
=
async
(
params
=
{})
=>
await
vm
.
$u
.
post
(
ucenterApiUrl
+
'/v1/settled/save-course-rate'
,
params
);
/* 获取消息内容列表 */
/* 获取消息内容列表 */
let
listByNotice
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
ucenterApiUrl
+
'/v1/notice/list'
,
params
);
let
listByNotice
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
ucenterApiUrl
+
'/v1/notice/
home-
list'
,
params
);
const
settledApi
=
{
const
settledApi
=
{
getSettleBaseInfo
,
getSettleBaseInfo
,
...
...
src/common/http.interceptor.js
View file @
8b91f718
...
@@ -12,6 +12,7 @@ const globalUrl = process.uniEnv || {}
...
@@ -12,6 +12,7 @@ const globalUrl = process.uniEnv || {}
const
install
=
(
Vue
,
vm
)
=>
{
const
install
=
(
Vue
,
vm
)
=>
{
let
systemApiUrl
=
globalUrl
.
systemUrl
.
apiUrl
let
systemApiUrl
=
globalUrl
.
systemUrl
.
apiUrl
let
ucenterApiUrl
=
globalUrl
.
ucenterUrl
.
apiUrl
let
ucenterApiUrl
=
globalUrl
.
ucenterUrl
.
apiUrl
let
xueApiUrl
=
globalUrl
.
ucenterUrl
.
xueUrl
function
toLoginPage
(){
function
toLoginPage
(){
const
app
=
getApp
()
const
app
=
getApp
()
...
@@ -48,7 +49,7 @@ const install = (Vue, vm) => {
...
@@ -48,7 +49,7 @@ const install = (Vue, vm) => {
config
.
url
+=
'?access-token='
+
token
config
.
url
+=
'?access-token='
+
token
}
}
}
}
if
(
config
.
url
.
indexOf
(
ucenterApiUrl
)
>-
1
){
if
(
config
.
url
.
indexOf
(
ucenterApiUrl
)
>-
1
||
config
.
url
.
indexOf
(
xueApiUrl
)
>-
1
){
// php端增加header Authorization
// php端增加header Authorization
config
.
header
[
'Authorization'
]
=
token
config
.
header
[
'Authorization'
]
=
token
}
}
...
...
src/components/appoint/appoint-time.vue
View file @
8b91f718
<!-- 预约时间 -->
<!-- 预约时间 -->
<
template
>
<
template
>
<view
:class=
"
{'con-box':titleShow}">
<view
:class=
"
{'con-box':titleShow}">
<view
class=
"title"
v-if=
"titleShow"
>
{{
'预约时间'
}}
</view>
<view
class=
"title"
v-if=
"titleShow"
>
{{
title
}}
</view>
<view
class=
"u-m-t-40"
>
<view
class=
"u-m-t-40"
>
<view
class=
"appoint-box"
>
<view
class=
"appoint-box"
>
<view
class=
"select-date"
>
<view
class=
"select-date"
>
<view
class=
"u-flex u-row-between "
>
<view
class=
"u-flex u-row-between "
>
<view
class=
"txt"
>
选择日期
</view>
<view
class=
"txt"
>
选择日期
:
</view>
<view
class=
"txt active"
>
{{
dateList
[
currentDay
].
day
}}
</view>
<view
class=
"txt active"
>
{{
appointTime
|
datefmt
(
'YYYY.MM.DD'
)
}}
</view>
</view>
</view>
<view
class=
"u-m-t-30 u-flex u-row-between date-list"
>
<view
class=
"u-m-t-30 u-flex u-row-between date-list"
>
<view
:class=
"
{'date-item':true,'active':index===currentDay}"
<view
v-show=
"hasLast"
class=
"last"
@
click=
"lastWeek(dateList[0],dateList)"
>
@click="dateChange(item,index,dateList)" v-for="(item,index) in dateList" :key="index">
<u-icon
name=
"arrow-left"
color=
"#2979ff"
size=
"28"
></u-icon>
<text
class=
"day"
>
{{
item
.
weekDay
}}
</text>
<text
class=
"day day1"
>
{{
item
.
day
}}
</text>
</view>
</view>
<view
class=
"next"
@
click=
"weekChange"
>
<view
class=
"u-flex u-row-between date-box"
>
<view
:class=
"
{'date-item':true,'active':item.day===appointTime}"
@click="dateChange(item,index,dateList)" v-for="(item,index) in dateList" :key="index">
<text
class=
"day"
>
{{
item
.
day
|
datefmt
(
'周dd'
)
}}
</text>
<text
class=
"day day1"
>
{{
item
.
day
|
datefmt
(
'DD'
)
}}
</text>
</view>
</view>
<view
class=
"next"
@
click=
"nextWeek(dateList[0],dateList)"
>
<u-icon
name=
"arrow-right"
color=
"#2979ff"
size=
"28"
></u-icon>
<u-icon
name=
"arrow-right"
color=
"#2979ff"
size=
"28"
></u-icon>
</view>
</view>
</view>
</view>
...
@@ -23,14 +28,18 @@
...
@@ -23,14 +28,18 @@
<!-- weekChange -->
<!-- weekChange -->
<view
class=
"select-time u-p-t-50"
>
<view
class=
"select-time u-p-t-50"
>
<view
class=
"u-flex u-row-between"
>
<view
class=
"u-flex u-row-between"
>
<view
class=
"txt"
>
选择时间
</view>
<view
class=
"txt"
>
选择时间
:
</view>
<view
class=
"txt active"
>
{{
currentTimeTxt
}}
</view>
<view
class=
"txt active"
>
{{
currentTimeTxt
}}
</view>
</view>
</view>
<view
class=
"u-p-t-30 u-flex u-flex-wrap time-list"
>
<view
class=
"u-p-t-30 u-flex u-flex-wrap time-list"
>
<view
@
click=
"timeChange(item,index,timeList)"
<view
:class=
"
{'time-item':true,'active': (currentTime
&&
index===currentTime)}" v-for="(item,index) in timeList"
:class=
"
{'time-item':true,'active': index===currentTime}" v-for="(item,index) in timeList"
:key="index">
:key="item.pkey">
<text
class=
"time"
>
{{
item
}}
</text>
<button
class=
"time"
:plain=
"true"
:disabled=
"item.disabled"
:hair-line=
"false"
@
click=
"timeChange(item,index,timeList)"
>
{{
item
.
name
}}
</button>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -41,45 +50,72 @@
...
@@ -41,45 +50,72 @@
</
template
>
</
template
>
<
script
>
<
script
>
let
now
=
Date
.
now
()
export
default
{
export
default
{
props
:
{
props
:
{
titleShow
:
{
titleShow
:
{
type
:
Boolean
,
type
:
Boolean
,
default
:
true
default
:
true
},
},
title
:
{
type
:
String
,
default
(){
return
"预约时间"
}
},
dateList
:
{
type
:
Array
,
default
(){
return
[
{
day
:
now
,
timeRange
:
[]},
{
day
:
now
+
(
1
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
2
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
3
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
4
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
5
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
6
*
86400000
),
timeRange
:
[]},
]
}
},
timeList
:
{
type
:
Array
,
default
(){
return
[
{
"name"
:
"06:00-08:00"
,
"pkey"
:
"appointment_range_8"
,
"disabled"
:
false
},
{
"name"
:
"08:00-10:00"
,
"pkey"
:
"appointment_range_10"
,
"disabled"
:
false
},
{
"name"
:
"10:00-12:00"
,
"pkey"
:
"appointment_range_12"
,
"disabled"
:
false
},
{
"name"
:
"12:00-14:00"
,
"pkey"
:
"appointment_range_14"
,
"disabled"
:
false
},
{
"name"
:
"14:00-16:00"
,
"pkey"
:
"appointment_range_16"
,
"disabled"
:
false
},
{
"name"
:
"16:00-18:00"
,
"pkey"
:
"appointment_range_18"
,
"disabled"
:
false
},
{
"name"
:
"18:00-20:00"
,
"pkey"
:
"appointment_range_20"
,
"disabled"
:
false
},
{
"name"
:
"20:00-22:00"
,
"pkey"
:
"appointment_range_22"
,
"disabled"
:
false
},
{
"name"
:
"22:00-24:00"
,
"pkey"
:
"appointment_range_24"
,
"disabled"
:
false
}
]
}
},
},
},
data
()
{
data
()
{
return
{
return
{
currentDay
:
0
,
currentDay
:
0
,
currentTime
:
null
,
currentTime
:
null
,
dateList
:
[{
appointTime
:
Date
.
now
(),
weekDay
:
'周三'
,
appointRange
:
""
,
day
:
'21'
,
num
:
0
,
},
{
hasLast
:
false
weekDay
:
'周四'
,
}
day
:
'22'
,
},
},
{
watch
:
{
weekDay
:
'周五'
,
title
()
{
day
:
'23'
,
this
.
currentDay
=
0
},
{
this
.
appointTime
=
Date
.
now
()
weekDay
:
'周六'
,
this
.
currentTime
=
null
day
:
'24'
,
this
.
appointRange
=
""
},
{
weekDay
:
'周日'
,
day
:
'25'
,
},
{
weekDay
:
'周一'
,
day
:
'26'
,
},
],
timeList
:
[
'06:00-08:00'
,
'08:00-10:00'
,
'10:00-12:00'
,
'12:00-14:00'
,
'14:00-16:00'
,
'16:00-18:00'
,
'18:00-20:00'
,
'20:00-22:00'
,
'22:00-24:00'
],
}
}
},
},
computed
:
{
computed
:
{
currentTimeTxt
()
{
currentTimeTxt
()
{
if
(
this
.
currentTime
!=
null
)
{
if
(
this
.
currentTime
!=
null
)
{
return
this
.
timeList
[
this
.
currentTime
]
return
this
.
timeList
[
this
.
currentTime
]
.
name
}
}
return
''
return
''
},
},
...
@@ -88,13 +124,16 @@
...
@@ -88,13 +124,16 @@
getDateList
()
{
getDateList
()
{
// 获取日期
// 获取日期
},
},
dateChange
(
item
,
index
,
list
)
{
async
dateChange
(
item
,
index
,
list
)
{
let
data
=
{
let
data
=
{
item
,
item
,
index
,
index
,
list
,
list
,
}
}
this
.
currentDay
=
index
this
.
currentDay
=
index
this
.
appointTime
=
item
.
day
this
.
currentTime
=
null
this
.
appointRange
=
""
this
.
$emit
(
'date-change'
,
data
)
this
.
$emit
(
'date-change'
,
data
)
},
},
timeChange
(
item
,
index
,
list
)
{
timeChange
(
item
,
index
,
list
)
{
...
@@ -104,6 +143,7 @@
...
@@ -104,6 +143,7 @@
list
,
list
,
}
}
this
.
currentTime
=
index
this
.
currentTime
=
index
this
.
appointRange
=
item
.
pkey
this
.
$emit
(
'time-change'
,
data
)
this
.
$emit
(
'time-change'
,
data
)
},
},
weekChange
(
item
,
index
,
list
)
{
weekChange
(
item
,
index
,
list
)
{
...
@@ -114,7 +154,34 @@
...
@@ -114,7 +154,34 @@
}
}
this
.
$emit
(
'week-change'
,
data
)
this
.
$emit
(
'week-change'
,
data
)
},
},
lastWeek
(
item
,
list
)
{
if
(
this
.
num
>
0
)
{
this
.
num
--
let
len
=
list
.
length
if
(
this
.
num
==
0
)
{
this
.
hasLast
=
false
len
++
}
let
time
=
item
.
day
-
len
*
86400000
let
data
=
{
time
:
time
,
num
:
this
.
num
}
this
.
$emit
(
'week-change'
,
data
)
}
},
nextWeek
(
item
,
list
)
{
this
.
hasLast
=
true
this
.
num
++
let
len
=
list
.
length
let
time
=
item
.
day
+
len
*
86400000
let
data
=
{
time
:
time
,
num
:
this
.
num
}
this
.
$emit
(
'week-change'
,
data
)
},
}
}
}
}
</
script
>
</
script
>
...
@@ -146,59 +213,71 @@
...
@@ -146,59 +213,71 @@
.date-list
{
.date-list
{
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
.
nex
t
{
.
las
t
{
width
:
60rpx
;
width
:
60rpx
;
height
:
120rpx
;
height
:
120rpx
;
line-height
:
120rpx
;
line-height
:
120rpx
;
text-align
:
center
;
text-align
:
center
;
border-
lef
t
:
2rpx
solid
#fff
;
border-
righ
t
:
2rpx
solid
#fff
;
}
}
.date-item
{
.date-box
{
padding
:
20rpx
20rpx
16rpx
;
padding
:
20rpx
18rpx
16rpx
20rpx
;
border-radius
:
12rpx
;
width
:
568rpx
;
.date-item
{
.day
{
// padding: 20rpx 20rpx 16rpx;
display
:
block
;
border-radius
:
12rpx
;
font-size
:
24rpx
;
line-height
:
26rpx
;
color
:
#999
;
&
.day1
{
width
:
48rpx
;
height
:
48rpx
;
margin-top
:
10rpx
;
border-radius
:
50%
;
font-size
:
28rpx
;
text-align
:
center
;
line-height
:
48rpx
;
}
}
&
.active
{
// background-color: #2272FF;
.day
{
.day
{
color
:
#2272FF
;
display
:
block
;
font-size
:
24rpx
;
line-height
:
26rpx
;
color
:
#999
;
&
.day1
{
&
.day1
{
background-color
:
#2272FF
;
width
:
48rpx
;
color
:
#fff
!
important
;
height
:
48rpx
;
margin-top
:
10rpx
;
border-radius
:
50%
;
font-size
:
28rpx
;
text-align
:
center
;
line-height
:
48rpx
;
}
}
&
.active
{
// background-color: #2272FF;
.day
{
color
:
#2272FF
;
&
.day1
{
background-color
:
#2272FF
;
color
:
#fff
!
important
;
}
}
}
}
}
}
}
}
}
.next
{
width
:
60rpx
;
height
:
120rpx
;
line-height
:
120rpx
;
text-align
:
center
;
border-left
:
2rpx
solid
#fff
;
}
}
}
.time-list
{
.time-list
{
justify-content
:
space-between
;
margin-bottom
:
-30rpx
;
margin-bottom
:
-30rpx
;
.time-item
{
.time-item
{
min-width
:
196rpx
;
min-width
:
196rpx
;
margin-right
:
21
rpx
;
// margin-right: 24
rpx;
margin-bottom
:
2
4
rpx
;
margin-bottom
:
2
0
rpx
;
border-radius
:
12rpx
;
border-radius
:
12rpx
;
padding
:
26rpx
20rpx
24rpx
;
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
&
:nth-child
(
3n
)
{
&
:nth-child
(
3n
)
{
...
@@ -212,9 +291,17 @@
...
@@ -212,9 +291,17 @@
}
}
.time
{
.time
{
font-size
:
26rpx
;
font-size
:
26rpx
;
line-height
:
2
6rpx
;
line-height
:
7
6rpx
;
color
:
#999
;
color
:
#999
;
}
}
/
deep
/
button
{
padding
:
0
;
height
:
76rpx
;
}
/
deep
/
button
[
plain
]
{
border
:
none
;
}
}
}
}
}
</
style
>
</
style
>
src/components/order/index.vue
View file @
8b91f718
...
@@ -26,8 +26,8 @@
...
@@ -26,8 +26,8 @@
</view>
</view>
<view
class=
"line-view"
></view>
<view
class=
"line-view"
></view>
<view
class=
"reason-view"
v-if=
"showReason"
><text>
未通过原因:
</text>
<view
class=
"reason-view"
v-if=
"showReason"
><text
class=
"reason-text"
>
未通过原因:
</text>
<text
class=
"reason-text"
>
{{
orderData
.
auditResults
.
remark
}}
</text>
<text>
{{
orderData
.
auditResults
.
remark
}}
</text>
</view>
</view>
<view
class=
"bottom-view"
>
<view
class=
"bottom-view"
>
<view>
<view>
...
@@ -78,13 +78,15 @@
...
@@ -78,13 +78,15 @@
}
}
}
}
},
},
// waitAccept:待接单、
/* 订单类型
// waitAppointment:待预约、
waitAccept:待接单、
// waitCheckIn:待签到、
waitAppointment:待预约、
// waitFinish:待完工、
waitCheckIn:待签到、
// review: 审核中、
waitFinish:待完工、
// exception:异常单、
audit: 审核中、
// finish:已完工
exception:异常单、
finish:已完工
*/
type
:
String
,
type
:
String
,
location
:
{
// 当前坐标
location
:
{
// 当前坐标
type
:
Array
,
type
:
Array
,
...
@@ -156,7 +158,7 @@
...
@@ -156,7 +158,7 @@
.
orderBusinessType
!=
'R'
)
.
orderBusinessType
!=
'R'
)
},
},
showTime
()
{
showTime
()
{
return
[
4
,
6
].
indexOf
(
this
.
orderType
)
!=
-
1
return
[
4
,
5
,
6
].
indexOf
(
this
.
orderType
)
!=
-
1
},
},
infoTexts
()
{
infoTexts
()
{
return
{
return
{
...
@@ -222,7 +224,7 @@
...
@@ -222,7 +224,7 @@
'waitAppointment'
:
1
,
// 待预约、
'waitAppointment'
:
1
,
// 待预约、
'waitCheckIn'
:
2
,
// 待签到、
'waitCheckIn'
:
2
,
// 待签到、
'waitFinish'
:
3
,
// 待完工、
'waitFinish'
:
3
,
// 待完工、
'
review
'
:
4
,
// 审核中、
'
audit
'
:
4
,
// 审核中、
'exception'
:
5
,
// 异常单、
'exception'
:
5
,
// 异常单、
'finish'
:
6
,
//已完工
'finish'
:
6
,
//已完工
}
}
...
@@ -367,10 +369,12 @@
...
@@ -367,10 +369,12 @@
text-align
:
left
;
text-align
:
left
;
margin-top
:
30rpx
;
margin-top
:
30rpx
;
font-size
:
26rpx
;
font-size
:
26rpx
;
color
:
#666666
;
color
:
#FA5A49
;
display
:
flex
;
align-items
:
flex-start
;
.reason-text
{
.reason-text
{
color
:
#FA5A49
;
flex-shrink
:
0
;
color
:
#666666
;
}
}
}
}
...
...
src/components/popView/index.vue
View file @
8b91f718
...
@@ -6,7 +6,12 @@
...
@@ -6,7 +6,12 @@
<view
class=
"order-pop-title"
>
<view
class=
"order-pop-title"
>
<text>
{{
title
}}
</text>
<text>
{{
title
}}
</text>
</view>
</view>
<view
class=
"line-view"
/>
<view
class=
"line-view"
/>
<view
class=
"order-content"
>
<view
v-if=
"count"
>
你本月还有
<text
class=
"order-content-count"
>
{{
count
}}
</text>
次拒单机会
</view>
</view>
<view
class=
"order-pop-text"
>
<view
class=
"order-pop-text"
>
<text>
{{
message
}}
</text>
<text>
{{
message
}}
</text>
</view>
</view>
...
@@ -16,7 +21,7 @@
...
@@ -16,7 +21,7 @@
取消
取消
</u-button>
</u-button>
<u-button
:custom-style=
"customStyleSave"
shape=
"circle"
type=
"primary"
@
click=
"handleClickSure"
>
<u-button
:custom-style=
"customStyleSave"
shape=
"circle"
type=
"primary"
@
click=
"handleClickSure"
>
查看
{{
buttonText
}}
</u-button>
</u-button>
</view>
</view>
</view>
</view>
...
@@ -29,7 +34,12 @@
...
@@ -29,7 +34,12 @@
props
:
{
props
:
{
visible
:
Boolean
,
visible
:
Boolean
,
title
:
String
,
title
:
String
,
message
:
String
,
message
:
String
,
count
:
Number
,
// 剩余次数
buttonText
:
{
// 确定按钮
type
:
String
,
default
:
'查看'
},
},
},
data
()
{
data
()
{
return
{}
return
{}
...
@@ -76,21 +86,32 @@
...
@@ -76,21 +86,32 @@
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.order-pop-view
{
.order-pop-view
{
padding
:
30rpx
;
padding
:
30rpx
;
min-height
:
520rpx
;
.order-pop-title
{
.order-pop-title
{
font-size
:
40rpx
;
font-size
:
40rpx
;
margin-top
:
4
0rpx
;
margin-top
:
3
0rpx
;
margin-bottom
:
40
rpx
;
margin-bottom
:
34
rpx
;
text-align
:
center
;
text-align
:
center
;
color
:
#333333
;
color
:
#333333
;
}
.order-content
{
min-height
:
14rpx
;
text-align
:
center
;
color
:
#333333
;
font-size
:
32rpx
;
margin-top
:
26rpx
;
.order-content-count
{
color
:
#FA5A49
;
}
}
}
.order-pop-text
{
.order-pop-text
{
color
:
#999999
;
color
:
#999999
;
text-align
:
center
;
text-align
:
center
;
margin-top
:
4
0rpx
;
margin-top
:
3
0rpx
;
font-size
:
28rpx
;
font-size
:
28rpx
;
margin-bottom
:
26
0rpx
;
// margin-bottom: 18
0rpx;
}
}
.line-view
{
.line-view
{
...
...
src/components/settle/index.vue
View file @
8b91f718
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
<u-navbar
style=
"position: absolute;"
title=
"入驻"
background=
"
{background: transparent}" :border-bottom="false"
<u-navbar
style=
"position: absolute;"
title=
"入驻"
background=
"
{background: transparent}" :border-bottom="false"
back-icon-color="#ffffff" title-color="#ffffff">
</u-navbar>
back-icon-color="#ffffff" title-color="#ffffff">
</u-navbar>
<image
:src=
"url"
style=
"width: 100%;"
mode=
"widthFix"
></image>
<image
:src=
"url"
style=
"width: 100%;"
mode=
"widthFix"
></image>
<view
class=
"introduction
"
>
<view
:class=
"['introduction',
{'active': type}]
">
<slot></slot>
<slot></slot>
</view>
</view>
<view
class=
"settle-bottom"
>
<view
class=
"settle-bottom"
>
...
@@ -18,6 +18,11 @@
...
@@ -18,6 +18,11 @@
index
:
{
index
:
{
type
:
Number
,
type
:
Number
,
default
:
1
default
:
1
},
// 0: introduction距离底部168rpx 1: introduction距离底部0rpx
type
:
{
type
:
Number
,
default
:
0
}
}
},
},
data
()
{
data
()
{
...
@@ -45,7 +50,10 @@
...
@@ -45,7 +50,10 @@
top
:
370rpx
;
top
:
370rpx
;
bottom
:
168rpx
;
bottom
:
168rpx
;
left
:
30rpx
;
left
:
30rpx
;
right
:
30rpx
;
right
:
30rpx
;
&
.active
{
bottom
:
0rpx
;
}
}
}
.settle-bottom
{
.settle-bottom
{
...
...
src/main.js
View file @
8b91f718
import
Vue
from
'vue'
import
Vue
from
'vue'
import
moment
from
'moment'
import
App
from
'./App'
import
App
from
'./App'
import
uView
from
"uview-ui"
;
import
uView
from
"uview-ui"
;
import
vuexStore
from
"@/store/$u.mixin.js"
;
import
vuexStore
from
"@/store/$u.mixin.js"
;
...
@@ -7,13 +8,24 @@ import {router,RouterMount} from '@/router/index.js' //路径换成自己的
...
@@ -7,13 +8,24 @@ import {router,RouterMount} from '@/router/index.js' //路径换成自己的
Vue
.
config
.
productionTip
=
false
Vue
.
config
.
productionTip
=
false
Vue
.
mixin
(
vuexStore
)
Vue
.
mixin
(
vuexStore
)
Vue
.
use
(
uView
);
Vue
.
use
(
uView
);
App
.
mpType
=
'app'
App
.
mpType
=
'app'
const
app
=
new
Vue
({
const
app
=
new
Vue
({
store
,
store
,
...
App
...
App
})
})
// 引入时间组件 moment
moment
.
locale
(
'zh-cn'
);
Vue
.
prototype
.
moment
=
moment
Vue
.
filter
(
'datefmt'
,
function
(
input
,
fmtstring
)
{
//当input为时间戳,需转为Number类型
if
(
input
){
return
moment
(
input
).
format
(
fmtstring
);
}
else
{
return
""
;
}
});
// http拦截器,将此部分放在new Vue()和app.$mount()之间,才能App.vue中正常使用
// http拦截器,将此部分放在new Vue()和app.$mount()之间,才能App.vue中正常使用
import
httpInterceptor
from
'@/common/http.interceptor.js'
import
httpInterceptor
from
'@/common/http.interceptor.js'
...
...
src/pages.json
View file @
8b91f718
...
@@ -324,9 +324,10 @@
...
@@ -324,9 +324,10 @@
"path"
:
"pages/photo/index"
,
//启动页面,必选
"path"
:
"pages/photo/index"
,
//启动页面,必选
"query"
:
""
//启动参数,在页面的onLoad函数里面得到
"query"
:
""
//启动参数,在页面的onLoad函数里面得到
},
},
{
{
"name"
:
"工单搜索"
,
//
gaomingbo
"path"
:
"pages/order/search"
,
"name"
:
"工单-过程反馈"
,
"path"
:
"pages/order/feedback"
,
"query"
:
""
"query"
:
""
},
},
{
{
...
@@ -368,6 +369,11 @@
...
@@ -368,6 +369,11 @@
"name"
:
"订单 - 拒单"
,
//模式名称
"name"
:
"订单 - 拒单"
,
//模式名称
"path"
:
"pages/order/refuse"
,
//启动页面,必选
"path"
:
"pages/order/refuse"
,
//启动页面,必选
"query"
:
""
//启动参数,在页面的onLoad函数里面得到
"query"
:
""
//启动参数,在页面的onLoad函数里面得到
},
{
"name"
:
"订单 - 过程反馈"
,
//模式名称
"path"
:
"pages/order/feedback"
,
//启动页面,必选
"query"
:
""
//启动参数,在页面的onLoad函数里面得到
}
}
]
]
}
}
...
...
src/pages/index/index.vue
View file @
8b91f718
...
@@ -13,12 +13,12 @@
...
@@ -13,12 +13,12 @@
</view>
</view>
<image
class=
"right-icon"
:src=
"shouyeyouImage"
></image>
<image
class=
"right-icon"
:src=
"shouyeyouImage"
></image>
</view>
</view>
<view
class=
"line-view"
v-if=
"index !=
2
"
></view>
<view
class=
"line-view"
v-if=
"index !=
1
"
></view>
</view>
</view>
</view>
</view>
</view>
</view>
<!-- 订单推荐吸顶 -->
<!-- 订单推荐吸顶 -->
<u-sticky>
<u-sticky
offset-top=
"60"
>
<view
class=
"sticky"
>
<view
class=
"sticky"
>
<text>
订单推荐
</text>
<text>
订单推荐
</text>
</view>
</view>
...
@@ -73,7 +73,7 @@
...
@@ -73,7 +73,7 @@
},
},
data
()
{
data
()
{
return
{
return
{
status
:
0
,
// 入驻状态:0=>'待提交',1=>'待审核',2=>'已通过',3=>'备选',4=>'已驳回',
5=>'已签约',6=>'未支付保证金
',7=>'已支付保证金',8=>'已通过考试',9=>'待提交'
status
:
0
,
// 入驻状态:0=>'待提交',1=>'待审核',2=>'已通过',3=>'备选',4=>'已驳回',
6=>'已签约
',7=>'已支付保证金',8=>'已通过考试',9=>'待提交'
location
:
[
116.3896
,
39.91917
],
// 经纬度
location
:
[
116.3896
,
39.91917
],
// 经纬度
title
:
false
,
title
:
false
,
title
:
"Hello"
,
title
:
"Hello"
,
...
@@ -87,7 +87,7 @@
...
@@ -87,7 +87,7 @@
search
:
{
search
:
{
token
:
""
,
token
:
""
,
pageNumber
:
0
,
pageNumber
:
0
,
pageSize
:
10
0
,
pageSize
:
10
,
},
},
bottomLoading
:
false
bottomLoading
:
false
};
};
...
@@ -179,8 +179,8 @@
...
@@ -179,8 +179,8 @@
self
.
$u
.
api
.
listByNotice
().
then
((
res
)
=>
{
self
.
$u
.
api
.
listByNotice
().
then
((
res
)
=>
{
uni
.
stopPullDownRefresh
()
// 结束下拉刷新
uni
.
stopPullDownRefresh
()
// 结束下拉刷新
if
(
res
.
code
==
200
)
{
if
(
res
.
code
==
200
)
{
if
(
res
.
data
&&
res
.
data
.
length
>
3
)
{
if
(
res
.
data
&&
res
.
data
.
length
>
2
)
{
self
.
messageList
=
res
.
data
.
slice
(
0
,
3
);
self
.
messageList
=
res
.
data
.
slice
(
0
,
2
);
}
else
{
}
else
{
self
.
messageList
=
res
.
data
||
[];
self
.
messageList
=
res
.
data
||
[];
}
}
...
@@ -197,8 +197,8 @@
...
@@ -197,8 +197,8 @@
self
.
$u
.
api
.
listByRecommendOrder
(
self
.
search
).
then
((
res
)
=>
{
self
.
$u
.
api
.
listByRecommendOrder
(
self
.
search
).
then
((
res
)
=>
{
uni
.
stopPullDownRefresh
()
// 结束下拉刷新
uni
.
stopPullDownRefresh
()
// 结束下拉刷新
if
(
res
.
code
==
200
)
{
if
(
res
.
code
==
200
)
{
if
(
res
.
data
&&
res
.
data
.
length
>
0
)
{
if
(
res
.
data
&&
res
.
data
.
l
ist
&&
res
.
data
.
list
.
l
ength
>
0
)
{
self
.
orderList
.
push
(...
res
.
data
);
self
.
orderList
.
push
(...
res
.
data
.
list
);
}
}
}
else
{
}
else
{
console
.
log
(
res
.
message
,
"初始化订单列表异常"
);
console
.
log
(
res
.
message
,
"初始化订单列表异常"
);
...
@@ -235,10 +235,12 @@
...
@@ -235,10 +235,12 @@
handleScroll
()
{
handleScroll
()
{
console
.
log
(
"-----scroll-------"
);
console
.
log
(
"-----scroll-------"
);
},
},
/* 立即入驻 */
immediatelyIn
()
{
immediatelyIn
()
{
if
(
this
.
vuex_token
)
{
if
(
this
.
vuex_token
)
{
//
0=>'待提交',1=>'待审核',2=>'已通过',3=>'备选',4=>'已驳回',5=>'已签约',6=>'未支付保证金',7=>'已支付保证金',8=>'已通过考试',9=>'待提交'
//
用户已登录
var
pageIndex
=
1
;
var
pageIndex
=
1
;
// 0=>'待提交',1=>'待审核',2=>'已通过',3=>'备选',4=>'已驳回',5=>'已签约',6=>'未支付保证金',7=>'已支付保证金',8=>'已通过考试',9=>'待提交'
switch
(
this
.
status
)
{
switch
(
this
.
status
)
{
case
1
:
case
1
:
case
2
:
case
2
:
...
@@ -266,6 +268,7 @@
...
@@ -266,6 +268,7 @@
"/pages/settle/prompt?pageIndex="
+
pageIndex
:
"/pages/settle/index"
,
"/pages/settle/prompt?pageIndex="
+
pageIndex
:
"/pages/settle/index"
,
});
});
}
else
{
}
else
{
// 用户未登录
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
"pages/login/index"
,
url
:
"pages/login/index"
,
});
});
...
@@ -294,7 +297,7 @@
...
@@ -294,7 +297,7 @@
border-radius
:
12rpx
;
border-radius
:
12rpx
;
background-color
:
#ffffff
;
background-color
:
#ffffff
;
padding
:
12rpx
30rpx
;
padding
:
12rpx
30rpx
;
height
:
252
rpx
;
height
:
174
rpx
;
}
}
.msg-content
{
.msg-content
{
...
...
src/pages/learn/answer.vue
View file @
8b91f718
<
template
>
<
template
>
<view
class=
"content"
>
<view
class=
"content"
>
<view
class=
""
>
<view
class=
""
>
<view
class=
""
style=
"padding-left: 94rpx;margin:36rpx 0"
>
<view
class=
""
style=
"padding-left: 94rpx; margin: 36rpx 0"
>
<text
class=
"dx"
>
多选
</text><text
class=
"num"
>
第1题
</text><text
class=
"all"
>
/共30题
</text>
<text
class=
"dx"
>
多选
</text
</view>
><text
class=
"all"
>
{{
ExaminationQuestions
.
progress
}}
</text>
<view
class=
""
style=
"text-align: center;"
>
</view>
一下对压缩机故障描述有误的是?
<view
class=
""
style=
"text-align: center"
>
</view>
{{
ExaminationQuestions
.
question
.
content
}}
<view
class=
""
style=
"margin-top: 130rpx;"
>
</view>
<view
class=
"list-box"
>
<view
class=
""
style=
"margin-top: 130rpx"
>
<view
v-for=
"(item,index) in list"
:key=
"index"
@
click=
"choice(index)"
:class=
"[item.selected?'selde':'noselde']"
>
<view
class=
"list-box"
>
{{
item
.
selected
?
item
.
title
:
item
.
title
}}
<view
</view>
v-for=
"(item, index) in list"
</view>
:key=
"index"
</view>
@
click=
"choice(index)"
<button
class=
"btn"
>
下一题
</button>
:class=
"[item.isRight ? 'selde' : 'noselde']"
</view>
>
</view>
{{
item
.
content
}}
</view>
</view>
</view>
<button
class=
"btn"
@
click=
"nextClick()"
>
下一题
</button>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
list
:
[{
list
:
[
selected
:
false
,
{
title
:
'A'
isRight
:
false
,
},
title
:
"A"
,
{
},
selected
:
false
,
{
title
:
'B'
isRight
:
false
,
},
title
:
"B"
,
{
},
selected
:
false
,
{
title
:
'C'
isRight
:
false
,
},
title
:
"C"
,
{
},
selected
:
false
,
{
title
:
'D'
isRight
:
false
,
},
title
:
"D"
,
{
},
selected
:
false
,
{
title
:
'E'
isRight
:
false
,
}
title
:
"E"
,
],
},
selectId
:[],
],
isSelect
:
false
,
};
selectId
:
[],
},
userExamId
:
null
,
onLoad
()
{
ExaminationQuestions
:
null
,
this
.
getUserExamInfo
()
isQuestion
:
true
,
},
};
methods
:
{
},
abc
()
{
onLoad
(
num
)
{
console
.
log
(
"11111"
)
console
.
log
(
"标识符4"
,
this
.
userExamId
);
var
arr
=
document
.
querySelector
(
".btm"
);
console
.
log
(
"标识符3"
+
num
);
for
(
let
i
=
0
;
i
<
arr
.
length
;
i
++
)
{
arr
[
i
].
onclick
=
function
()
{
this
.
userExamId
=
num
;
console
.
log
(
this
.
value
)
}
this
.
getExaminationQuestions
();
}
},
},
onUnload
()
{
//选择按钮
wx
.
reLaunch
({
choice
(
index
)
{
url
:
"./index"
,
if
(
this
.
list
[
index
].
selected
==
true
)
{
});
this
.
list
[
index
].
selected
=
false
;
},
//取消选中时删除数组中的值
for
(
var
i
=
0
;
i
<
this
.
selectId
.
length
;
i
++
)
{
methods
:
{
if
(
this
.
selectId
[
i
]
===
this
.
list
[
index
].
title
)
{
abc
()
{
this
.
selectId
.
splice
(
i
,
1
);
console
.
log
(
"11111"
);
}
var
arr
=
document
.
querySelector
(
".btm"
);
}
for
(
let
i
=
0
;
i
<
arr
.
length
;
i
++
)
{
console
.
log
(
"选中的值"
,
this
.
selectId
)
arr
[
i
].
onclick
=
function
()
{
}
else
{
console
.
log
(
this
.
value
);
this
.
list
[
index
].
selected
=
true
;
};
this
.
selectId
.
push
(
this
.
list
[
index
].
title
)
}
console
.
log
(
"选中的值"
,
this
.
selectId
)
},
}
//选择按钮
},
choice
(
index
)
{
if
(
this
.
list
[
index
].
isRight
==
true
)
{
this
.
list
[
index
].
isRight
=
false
;
this
.
isSelect
=
false
;
},
console
.
log
(
this
.
isSelect
);
mounted
()
{
//取消选中时删除数组中的值
console
.
log
(
"111111"
)
for
(
var
i
=
0
;
i
<
this
.
selectId
.
length
;
i
++
)
{
}
if
(
this
.
selectId
[
i
]
===
this
.
list
[
index
].
id
)
{
}
this
.
selectId
.
splice
(
i
,
1
);
}
}
console
.
log
(
"选中的值"
,
this
.
selectId
);
}
else
{
this
.
list
[
index
].
isRight
=
true
;
this
.
isSelect
=
true
;
console
.
log
(
this
.
isSelect
);
this
.
selectId
.
push
(
this
.
list
[
index
].
id
);
console
.
log
(
"选中的值"
,
this
.
selectId
);
}
},
//申请考试题目
getExaminationQuestions
:
function
()
{
uni
.
request
({
url
:
"http://192.168.1.22"
+
"/wxh-worker-rest/rest/exam"
+
"/serviceRule/next/"
+
this
.
vuex_token
+
"?userExamId="
+
this
.
userExamId
.
userExamId
,
method
:
"POST"
,
header
:
{
"Content-Type"
:
"application/x-www-form-urlencoded"
,
},
success
:
(
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
this
.
ExaminationQuestions
=
res
.
data
.
data
;
this
.
list
=
res
.
data
.
data
.
answerList
;
console
.
log
(
this
.
ExaminationQuestions
);
}
},
});
console
.
log
(
"answer的userExamId是"
,
this
.
userExamId
);
},
//下一题
nextClick
:
function
()
{
//判断
if
(
this
.
isQuestion
==
"第20题/共20题"
)
{
this
.
isQuestion
=
""
;
console
.
log
(
"标识符6666"
,
this
.
userExamId
.
userExamId
);
wx
.
navigateTo
({
url
:
"./result?userExamId="
+
this
.
userExamId
.
userExamId
,
});
}
//判断有没有选
if
(
this
.
selectId
.
length
==
0
)
{
wx
.
showToast
({
title
:
"请选择"
,
icon
:
"none"
,
//当icon:'none'时,没有图标 只有文字
duration
:
2000
,
});
return
;
}
uni
.
request
({
url
:
"http://192.168.1.22"
+
"/wxh-worker-rest/rest/exam"
+
"/serviceRule/next/"
+
this
.
vuex_token
+
"?userExamId="
+
this
.
userExamId
.
userExamId
+
"&questionId="
+
this
.
ExaminationQuestions
.
question
.
id
+
"&userAnswerIds="
+
this
.
selectId
,
method
:
"POST"
,
header
:
{
"Content-Type"
:
"application/x-www-form-urlencoded"
,
},
success
:
(
res
)
=>
{
console
.
log
(
"sssss"
,
res
);
if
(
res
.
data
.
code
==
200
)
{
this
.
ExaminationQuestions
=
res
.
data
.
data
;
this
.
list
=
res
.
data
.
data
.
answerList
;
this
.
isQuestion
=
res
.
data
.
data
.
progress
;
console
.
log
(
"uuuuuuuu"
,
this
.
ExaminationQuestions
);
}
this
.
selectId
=
[];
console
.
log
(
"zzy"
,
this
.
selectId
);
},
});
},
},
};
</
script
>
</
script
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
.content
{
.content
{
width
:
600rpx
;
width
:
600rpx
;
height
:
800rpx
;
height
:
800rpx
;
/* background: #8F8F94; */
/* background: #8F8F94; */
margin
:
0
auto
;
margin
:
0
auto
;
}
}
.dx
{
.dx
{
padding
:
0rpx
;
padding
:
0rpx
;
background
:
#2979FF
;
background
:
#2979ff
;
color
:
#FFFFFF
;
color
:
#ffffff
;
border-radius
:
0px
;
border-radius
:
0px
;
}
}
.num
{
.num
{
color
:
#2B85E4
;
color
:
#2b85e4
;
}
}
.all
{
.all
{
color
:
#8F8F94
;
color
:
#8f8f94
;
}
}
.btn
{
.btn
{
margin-top
:
98rpx
;
margin-top
:
98rpx
;
width
:
476rpx
;
width
:
476rpx
;
height
:
60rpx
;
height
:
60rpx
;
line-height
:
30px
;
line-height
:
30px
;
background
:
#007AFF
;
background
:
#007aff
;
color
:
#FFFFFF
;
color
:
#ffffff
;
}
}
.btm
{
.btm
{
width
:
476rpx
;
width
:
476rpx
;
height
:
60rpx
;
height
:
60rpx
;
line-height
:
30px
;
line-height
:
30px
;
margin
:
34rpx
auto
;
margin
:
34rpx
auto
;
}
}
.list-box
{
.list-box
{
// display: flex;
// display: flex;
// flex-wrap: wrap;
// flex-wrap: wrap;
padding
:
16upx
;
padding
:
16upx
;
border-radius
:
10upx
;
border-radius
:
10upx
;
view
{
view
{
width
:
476rpx
;
width
:
476rpx
;
height
:
60upx
;
height
:
60upx
;
line-height
:
60upx
;
line-height
:
60upx
;
text-align
:
center
;
text-align
:
center
;
margin
:
26rpx
auto
0
;
margin
:
26rpx
auto
0
;
}
}
}
}
/*已选择*/
.selde
{
/*已选择*/
background
:
#007aff
;
.selde
{
color
:
#ffffff
;
background
:
#007AFF
;
border-radius
:
20upx
;
color
:
#FFFFFF
;
font-size
:
26rpx
;
border-radius
:
20upx
;
padding
:
0
10upx
;
font-size
:
26rpx
;
}
padding
:
0
10upx
;
}
/*未选择*/
.noselde
{
/*未选择*/
background
:
#e4e7ed
;
.noselde
{
color
:
#959595
;
background
:
#E4E7ED
;
border-radius
:
20upx
;
color
:
#959595
;
font-size
:
20upx
;
border-radius
:
20upx
;
padding
:
0
10upx
;
font-size
:
20upx
;
}
padding
:
0
10upx
;
}
</
style
>
</
style
>
src/pages/learn/assessment.vue
View file @
8b91f718
<
template
>
<
template
>
<view
class=
"content"
>
<view
class=
"content"
>
<view
class=
"title"
>
考试规则说明
</view>
<view
class=
"title"
>
考试规则说明
</view>
<view
class=
"test"
>
<view
class=
"test"
>
<view
class=
"text"
>
<view
class=
"text"
>
<text
class=
"left"
>
考试科目:
</text><text
style=
"color: #007AFF;"
>
{{
exam
.
examName
}}
</text>
<text
class=
"left"
>
考试科目:
</text
</view>
><text
style=
"color: #007aff"
>
{{
exam
.
examName
}}
</text>
<view
class=
"text"
>
</view>
<text
class=
"left"
>
合格条件:
</text><text>
{{
exam
.
ruleDisc
}}
</text>
<view
class=
"text"
>
</view>
<text
class=
"left"
>
合格条件:
</text
<view
class=
"text"
>
><text>
{{
exam
.
ruleDisc
}}
</text>
<text
class=
"left"
>
考试时间:
</text><text>
30分钟
</text>
</view>
</view>
<view
class=
"text"
>
<view
class=
"text"
>
<text
class=
"left"
>
考试时间:
</text><text>
30分钟
</text>
<text
class=
"left"
>
题目规则:
</text><text>
题库100题,随机抽20题
</text>
</view>
</view>
<view
class=
"text"
>
<view
class=
"text"
>
<text
class=
"left"
>
题目规则:
</text
<text
class=
"left"
>
备注说明:
</text><text>
无
</text>
><text>
题库100题,随机抽20题
</text>
</view>
</view>
</view>
<view
class=
"text"
>
<button
@
click=
"aaa"
>
开始考试
</button>
<text
class=
"left"
>
备注说明:
</text><text>
无
</text>
</view>
</view>
</view>
<button
@
click=
"getUserExamId()"
>
开始考试
</button>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
examId
:
1
,
examId
:
2
,
exam
:
null
exam
:
null
,
}
userExamId
:
null
,
},
};
onLoad
()
{
},
this
.
getUserExamInfo
()
onLoad
()
{
},
// this.getUserExamInfo();
methods
:
{
},
aaa
(){
methods
:
{
//申请考试获取userExamId
wx
.
navigateTo
({
getUserExamId
:
function
()
{
var
that
=
this
;
url
:
'./answer'
console
.
log
(
"这是一条消息"
);
})
uni
.
request
({
},
url
:
//获取考试信息
"http://192.168.1.22"
+
getUserExamInfo
:
function
()
{
"/wxh-worker-rest/rest/exam/serviceRule/"
+
that
.
vuex_token
+
uni
.
showLoading
({
"?examId="
+
title
:
'请稍候'
this
.
examId
,
})
method
:
"POST"
,
header
:
{
let
that
=
this
"Content-Type"
:
"application/x-www-from-urlencoded"
,
uni
.
request
({
},
url
:
'https://system.banshouhui.com'
+
'/wxh-worker-rest/rest/exam'
+
success
:
(
res
)
=>
{
'/serviceRule/userExamInfo/'
+
console
.
log
(
"标识符1"
,
res
.
data
);
'RTOKENf86a7c0606ef5ebf36f211ace3466b7f9de56e37'
+
uni
.
hideLoading
();
'?examId='
+
this
.
examId
,
if
(
res
.
data
.
code
==
200
)
{
method
:
'POST'
,
if
(
res
.
data
.
data
.
userExamId
)
{
data
:
{
that
.
userExamId
=
res
.
data
.
data
.
userExamId
;
//examId:this.examId,
console
.
log
(
"这个是个标识符"
,
that
.
userExamId
);
},
}
header
:
{
}
'Content-Type'
:
'application/x-www-form-urlencoded'
},
},
});
success
:
(
res
)
=>
{
setTimeout
(()
=>
{
console
.
log
(
res
.
data
)
wx
.
navigateTo
({
uni
.
hideLoading
()
url
:
"./answer?userExamId="
+
that
.
userExamId
,
if
(
!
res
.
data
)
{
});
return
},
1000
);
}
},
if
(
res
.
data
.
code
==
401
||
res
.
data
.
code
==
403
)
{
},
// uni.navigateTo({
};
// url: '/pages/login/wxlogin'
// })
// return
console
.
log
(
'洪塘张学友'
)
}
if
(
res
.
data
.
code
==
200
)
{
//examStatus 用户考试状态 0考试中 1考试完成 2未参与
that
.
exam
=
res
.
data
.
data
console
.
log
(
that
.
exam
)
if
(
res
.
data
.
data
.
examStatus
==
2
)
{
that
.
applyExam
()
return
}
if
(
res
.
data
.
data
.
examStatus
==
1
){
console
.
log
(
'111111111111111111111111111'
)
that
.
isComplete
=
true
that
.
examScore
=
res
.
data
.
data
.
examScore
that
.
postResult
()
return
}
if
(
res
.
data
.
data
.
examStatus
==
0
)
{
that
.
userExamId
=
res
.
data
.
data
.
id
that
.
getNext
()
}
}
else
{
uni
.
showToast
({
icon
:
'none'
,
title
:
res
.
data
.
message
})
}
},
fail
:
(
e
)
=>
{
uni
.
hideLoading
()
uni
.
showToast
({
icon
:
'none'
,
title
:
'获取考试信息失败'
})
}
})
},
}
}
</
script
>
</
script
>
<
style
>
<
style
>
.content
{
.content
{
margin
:
187
rpx
80
rpx
;
margin
:
187
rpx
80
rpx
;
}
}
.title
{
font-size
:
17px
;
.title
{
text-align
:
center
;
font-size
:
17px
;
}
text-align
:
center
;
.test
{
}
margin
:
0
0
;
}
.test
{
.left
{
margin
:
0
0
;
margin-right
:
8
rpx
;
}
margin-left
:
68
rpx
;
.left
{
}
margin-right
:
8
rpx
;
.text
{
margin-left
:
68
rpx
;
margin
:
50
rpx
0
;
}
}
button
{
.text
{
width
:
364
rpx
;
margin
:
50
rpx
0
;
height
:
56
rpx
;
}
background
:
#007AFF
;
font-size
:
24
rpx
;
button
{
color
:
#FFFFFF
;
width
:
364
rpx
;
}
height
:
56
rpx
;
background
:
#007aff
;
font-size
:
24
rpx
;
color
:
#ffffff
;
}
</
style
>
</
style
>
src/pages/learn/curriculum.vue
View file @
8b91f718
...
@@ -3,30 +3,34 @@
...
@@ -3,30 +3,34 @@
<view
class=
"title"
>
<view
class=
"title"
>
课程简介
课程简介
</view>
</view>
<view
class=
"u-content"
>
<u-parse
:html=
"courseInfo.intro"
></u-parse>
</view>
<view
class=
"lecturer"
>
<view
class=
"lecturer"
>
<view
class=
""
style=
"font-size: 40rpx;font-weight: bold;margin: 30rpx 0;"
>
<view
class=
""
v-if=
"courseInfo.isTeachers"
>
讲师
<view
class=
""
style=
"font-size: 40rpx;font-weight: bold;margin: 30rpx 0;"
>
</view>
讲师
<view
class=
""
style=
"display: flex;"
>
</view>
<image
src=
"../../static/logo.png"
mode=
""
></image>
<view
class=
""
style=
"display: flex;"
>
<view
style=
"font-size: 30rpx;font-weight:1000;margin: 19px 24px;"
>
扳手卢老师
</view>
<image
src=
"../../static/logo.png"
mode=
""
></image>
<view
style=
"font-size: 30rpx;font-weight:1000;margin: 19px 24px;"
>
{{
courseInfo
.
teacher
.
name
}}
</view>
</view>
</view>
</view>
<view
class=
""
style=
"margin: 36rpx 0;"
>
<view
class=
""
style=
"margin: 36rpx 0;"
>
<view
class=
""
style=
"font-size: 40rpx;font-weight:1000"
>
<view
class=
""
style=
"font-size: 40rpx;font-weight:1000"
>
目录
目录
</view>
</view>
<view
v-for=
"
item
in list"
>
<view
v-for=
"
(item,index)
in list"
>
<view
class=
"chapter"
>
<view
class=
"chapter"
>
{{
item
.
name
}}
{{
item
.
name
}}
</view>
</view>
<view
class=
"video"
v-for=
"
key in item.section"
@
click=
details(key
.id)
>
<view
class=
"video"
v-for=
"
(section,key) in item.section"
@
click=
details(section
.id)
>
<view
class=
"video_1"
>
<view
class=
"video_1"
>
<view
class=
"text"
v-text=
"wareType(key.ware)"
>
<view
class=
"text"
v-text=
"wareType(section.ware)"
>
</view>
</view>
<text
>
1-
{{
key
.
order
}}
</text>
<text
class=
"texts"
>
{{
index
+
1
}}
-
{{
key
+
1
}}
</text>
<text
class=
"text2"
>
{{
key
.
name
}}
</text>
<text
class=
"text2"
>
{{
section
.
name
}}
</text>
<text
class=
"text3"
v-text=
"
key
.isLearned==false?'未开始':'完成'"
></text>
<text
class=
"text3"
v-text=
"
section
.isLearned==false?'未开始':'完成'"
></text>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -45,6 +49,11 @@
...
@@ -45,6 +49,11 @@
},
},
list
:[],
list
:[],
examId
:
1
,
examId
:
1
,
courseInfo
:
{
intro
:
''
,
isTeachers
:
false
,
teacher
:
{}
}
}
}
},
},
onLoad
(
a
){
onLoad
(
a
){
...
@@ -52,8 +61,31 @@
...
@@ -52,8 +61,31 @@
this
.
params
.
course_id
=
a
.
course_id
this
.
params
.
course_id
=
a
.
course_id
console
.
log
(
this
.
params
.
course_id
)
console
.
log
(
this
.
params
.
course_id
)
this
.
getCapterDetails
()
this
.
getCapterDetails
()
this
.
getCourseInfo
()
},
},
methods
:
{
methods
:
{
getCourseInfo
()
{
let
param
=
{
course_id
:
this
.
params
.
course_id
};
this
.
$u
.
api
.
CourseList
(
param
)
.
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
if
(
res
.
data
)
{
this
.
courseInfo
.
intro
=
res
.
data
.
course
.
intro
;
this
.
courseInfo
.
isTeachers
=
res
.
data
.
course
.
teachers
.
length
>
0
;
this
.
courseInfo
.
teacher
=
this
.
courseInfo
.
isTeachers
?
res
.
data
.
course
.
teachers
[
0
]
:
{};
}
}
})
.
catch
((
err
)
=>
{
uni
.
showToast
({
title
:
err
,
icon
:
"none"
,
});
});
},
//获取章节详情
//获取章节详情
getCapterDetails
()
{
getCapterDetails
()
{
console
.
log
(
'获取章节详情'
)
console
.
log
(
'获取章节详情'
)
...
@@ -133,7 +165,7 @@
...
@@ -133,7 +165,7 @@
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
.title
{
.title
{
height
:
1
64rpx
;
height
:
64rpx
;
font-size
:
40rpx
;
font-size
:
40rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
margin
:
24rpx
34rpx
;
margin
:
24rpx
34rpx
;
...
@@ -158,6 +190,12 @@
...
@@ -158,6 +190,12 @@
margin
:
20rpx
0
;
margin
:
20rpx
0
;
position
:
relative
;
position
:
relative
;
width
:
100%
;
width
:
100%
;
.texts
{
border
:
1px
solid
#8F8F94
;
text-align
:
center
;
line-height
:
38rpx
;
margin-right
:
5rpx
;
}
.text
{
.text
{
width
:
100rpx
;
width
:
100rpx
;
height
:
38rpx
;
height
:
38rpx
;
...
@@ -179,4 +217,7 @@
...
@@ -179,4 +217,7 @@
right
:
0
;
right
:
0
;
}
}
}
}
.u-content
{
padding
:
0rpx
34rpx
;
}
</
style
>
</
style
>
src/pages/learn/index.vue
View file @
8b91f718
<
template
>
<
template
>
<view
class=
"study"
>
<view
class=
"study"
>
<u-navbar
<u-navbar
:is-back=
"false"
:is-back=
"false"
background=
"
{background: transparent}"
background=
"
{background: transparent}"
:border-bottom="false"
:border-bottom="false"
:is-fixed="false"
:is-fixed="false"
>
>
<text
class=
"title-view"
>
学习
</text>
<text
class=
"title-view"
>
学习
</text>
</u-navbar>
</u-navbar>
<image
:src=
"bannerImage"
mode=
""
class=
"banner"
></image>
<image
:src=
"bannerImage"
mode=
""
class=
"banner"
></image>
<!--
<u-tabs
:list=
"tabs"
:is-scroll=
"false"
:current=
"current"
@
change=
"change"
></u-tabs>
-->
<view>
<view>
<u-tabs-swiper
<u-tabs-swiper
bg-color=
"#F4F5F7"
inactive-color=
"#999999"
font-size=
"28"
ref=
"uTabs"
:list=
"tabs"
:current=
"current"
@
change=
"tabsChange"
:is-scroll=
"false"
swiperWidth=
"750"
></u-tabs-swiper>
bg-color=
"#F4F5F7"
</view>
inactive-color=
"#999999"
<swiper
:current=
"swiperCurrent"
@
transition=
"transition"
@
animationfinish=
"animationfinish"
style=
"height: 755rpx;"
>
font-size=
"28"
<swiper-item
class=
"swiper-item"
>
ref=
"uTabs"
<scroll-view
scroll-y
style=
"height:796rpx;width:100%;"
@
scrolltolower=
"onreachBottom"
>
:list=
"tabs"
<view
class=
"standard"
@
click=
"goToPrint"
>
:current=
"current"
<text>
充电桩交付规范
</text>
@
change=
"tabsChange"
<text>
>
</text>
:is-scroll=
"false"
</view>
swiperWidth=
"750"
</scroll-view>
></u-tabs-swiper>
</swiper-item>
</view>
<swiper-item
class=
"swiper-item"
>
<swiper
<scroll-view
scroll-y
style=
"height:100%;width:100%;"
@
scrolltolower=
"onreachBottom"
>
:current=
"swiperCurrent"
<view
v-for=
"item in list"
:key=
"item.id"
class=
"notice"
@
click=
"bbb(item)"
>
@
transition=
"transition"
<view
class=
"n-head"
>
@
animationfinish=
"animationfinish"
《
{{
item
.
title
}}
》
style=
"height: 755rpx"
</view>
>
<view
class=
"news"
v-html=
"item.body"
>
<swiper-item
class=
"swiper-item"
>
{{
item
.
body
}}
<scroll-view
</view>
scroll-y
</view>
style=
"height: 796rpx; width: 100%"
<view
v-shou=
"isLoadMore"
>
@
scrolltolower=
"onreachBottom"
<u-loadmore
:status=
"loadStatus"
/>
>
</view>
<view
class=
"standard"
@
click=
"goToPrint"
>
</scroll-view>
<text>
充电桩交付规范
</text>
</swiper-item>
<text>
>
</text>
<swiper-item
class=
"swiper-item"
>
</view>
<scroll-view
scroll-y
style=
"height:100%;width:100%;"
>
</scroll-view>
<view
class=
"lean"
>
</swiper-item>
<view
class=
"top"
>
<swiper-item
class=
"swiper-item"
>
<view
class=
"currency-class"
>
<scroll-view
<view
class=
"title"
>
通用课程
</view>
scroll-y
<view
class=
"class1"
@
click=
ccc(173)
>
style=
"height: 100%; width: 100%"
<image
class=
"img"
:src=
courselist.course.preview_pic
mode=
""
></image>
@
scrolltolower=
"onreachBottom"
<view
class=
"right"
>
>
<view
class=
""
>
<view
v-for=
"item in list"
{{
courselist
.
course
.
name
}}
:key=
"item.id"
</view>
class=
"notice"
<view
class=
"intro"
v-html=
"courselist.course.intro"
>
@
click=
"bbb(item)"
{{
courselist
.
course
.
intro
}}
>
</view>
<view
class=
"n-head"
>
《
{{
item
.
title
}}
》
</view>
<view
class=
""
style=
"display:flex;justify-content: space-between;"
>
<view
class=
"news"
v-html=
"item.body"
>
<u-line-progress
active-color=
"#2979ff"
:percent=
courselist.learnedInfo.learnPercent
style=
"width:54%;"
></u-line-progress>
{{
item
.
body
}}
<text
v-text=
"(courselist.learnedInfo.isLearned) ?(courselist.learnedInfo.learnPercent==1)?'已完成':'继续':'未观看' "
></text>
</view>
</view>
</view>
</view>
<view
v-shou=
"isLoadMore"
>
</view>
<u-loadmore
:status=
"loadStatus"
/>
<view
class=
"class1"
>
</view>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
</scroll-view>
<view
class=
"right"
>
</swiper-item>
<view
class=
""
>
<swiper-item
class=
"swiper-item"
>
接单操作
<scroll-view
scroll-y
style=
"height: 100%; width: 100%"
>
</view>
<view
class=
"lean"
>
<view
class=
""
>
<view
class=
"top"
>
快速学习,使用APP接单、抢单
<view
class=
"currency-class"
>
</view>
<view
class=
"title"
>
通用课程
</view>
<view
class=
""
style=
"display:flex;justify-content: space-between;"
>
<view
<u-line-progress
active-color=
"#2979ff"
:percent=
"30"
style=
"width:54%;"
></u-line-progress>
class=
"class1"
<text>
继续
</text>
@
click=
"ccc(courselist[0].id)"
</view>
>
</view>
<image
</view>
class=
"img"
</view>
:src=
"courselist[0].pic"
<view
class=
"currency-class"
>
mode=
""
<view
class=
"title"
>
技能课程
</view>
></image>
<view
class=
"class1"
>
<view
class=
"right"
>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
<view
class=
""
>
<view
class=
"right"
>
{{
courselist
[
0
].
title
}}
<view
class=
""
>
</view>
从0-1学习充电桩安装服务
<view
class=
"intro"
>
</view>
{{
courselist
[
0
].
desc
}}
<view
class=
""
>
</view>
让你全面了解充电桩市场及服务规范
<view
</view>
class=
""
<view
class=
""
style=
"display:flex;justify-content: space-between;"
>
style=
"
<u-line-progress
active-color=
"#2979ff"
:percent=
"100"
style=
"width:54%;"
></u-line-progress>
display: flex;
<text>
完成
</text>
justify-content: space-between;
</view>
"
</view>
>
</view>
<u-line-progress
</view>
active-color=
"#2979ff"
</view>
:percent=
"courselist[0].percent"
</view>
style=
"width: 54%"
</scroll-view>
>
</swiper-item>
</u-line-progress>
<swiper-item>
<text
<scroll-view
scroll-y
style=
"height:100%;width:100%;"
@
scrolltolower=
"onreachBottom"
>
v-text=
"courselist[0].status"
<view
class=
"lean"
>
></text>
<view
class=
"top"
>
</view>
<view
class=
"currency-class"
>
</view>
<text
class=
"title"
>
通用认证
</text>
</view>
<view
class=
"class1"
@
click=
"aaa"
>
<view
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
class=
"class1"
<view
class=
"right"
>
@
click=
"ccc(courselist[1].id)"
<view
class=
""
>
>
服务规范
<image
</view>
class=
"img"
<view
class=
""
>
:src=
"courselist[1].pic"
通过本认证,是接单的前提条件
mode=
""
</view>
></image>
<view
class=
""
style=
"display:flex;justify-content: space-between;"
>
<view
class=
"right"
>
<text
style=
"color: #a69999;"
>
随机20题,及格20题
</text>
<view
class=
""
>
<text>
通过
</text>
{{
courselist
[
1
].
title
}}
</view>
</view>
</view>
<view
class=
""
>
</view>
{{
courselist
[
1
].
desc
}}
<view
class=
"class1"
@
click=
"aaa"
>
</view>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
<view
<view
class=
"right"
>
class=
""
<view
class=
""
>
style=
"
接单操作
display: flex;
</view>
justify-content: space-between;
<view
class=
""
>
"
快速认证,是否具备接单操作能力
>
</view>
<u-line-progress
<view
class=
""
style=
"display:flex;justify-content: space-between;"
>
active-color=
"#2979ff"
<text
style=
"color: #a69999"
>
随机20题,及格16题
</text>
:percent=
"courselist[1].percent"
<text>
未通过
</text>
style=
"width: 54%"
</view>
>
</view>
</u-line-progress>
</view>
<text
</view>
v-text=
"courselist[1].status"
<view
class=
"currency-class"
>
></text>
<text
class=
"title"
>
技能认证
</text>
</view>
<view
class=
"class1"
@
click=
"aaa"
>
</view>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
</view>
<view
class=
"right"
>
</view>
<view
class=
""
>
<view
class=
"currency-class"
>
从0-1学习充电桩安装服务
<view
class=
"title"
>
技能课程
</view>
</view>
<view
<view
class=
""
>
class=
"class1"
通过本认证后,可接充电桩业务单
@
click=
"ccc(courselist[2].id)"
</view>
>
<view
class=
""
style=
"display:flex;justify-content: space-between;"
>
<image
<text
style=
"color: #a69999;"
>
随机30题,及格25题
</text>
class=
"img"
<text>
未通过
</text>
:src=
"courselist[2].pic"
</view>
mode=
""
</view>
></image>
</view>
<view
class=
"right"
>
</view>
<view
class=
""
>
</view>
{{
courselist
[
2
].
title
}}
</view>
</view>
</scroll-view>
<view
class=
""
>
</swiper-item>
{{
courselist
[
2
].
desc
}}
</swiper>
</view>
</view>
<view
</view>
class=
""
style=
"
display: flex;
justify-content: space-between;
"
>
<u-line-progress
active-color=
"#2979ff"
:percent=
"courselist[2].percent"
style=
"width: 54%"
>
</u-line-progress>
<text
v-text=
"courselist[2].status"
></text>
</view>
</view>
</view>
</view>
</view>
</view>
</scroll-view>
</swiper-item>
<swiper-item>
<scroll-view
scroll-y
style=
"height: 100%; width: 100%"
@
scrolltolower=
"onreachBottom"
>
<view
class=
"lean"
>
<view
class=
"top"
>
<view
class=
"currency-class"
>
<text
class=
"title"
>
通用认证
</text>
<view
class=
"class1"
@
click=
"aaa"
>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
<view
class=
"right"
>
<view
class=
""
>
服务规范
</view>
<view
class=
""
>
通过本认证,是接单的前提条件
</view>
<view
class=
""
style=
"
display: flex;
justify-content: space-between;
"
>
<text
style=
"color: #a69999"
>
随机20题,及格20题
</text
>
<text>
通过
</text>
</view>
</view>
</view>
<view
class=
"class1"
@
click=
"aaa"
>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
<view
class=
"right"
>
<view
class=
""
>
接单操作
</view>
<view
class=
""
>
快速认证,是否具备接单操作能力
</view>
<view
class=
""
style=
"
display: flex;
justify-content: space-between;
"
>
<text
style=
"color: #a69999"
>
随机20题,及格16题
</text
>
<text>
未通过
</text>
</view>
</view>
</view>
</view>
<view
class=
"currency-class"
>
<text
class=
"title"
>
技能认证
</text>
<view
class=
"class1"
@
click=
"aaa"
>
<image
class=
"img"
src=
"../../static/logo.png"
mode=
""
></image>
<view
class=
"right"
>
<view
class=
""
>
从0-1学习充电桩安装服务
</view>
<view
class=
""
>
通过本认证后,可接充电桩业务单
</view>
<view
class=
""
style=
"
display: flex;
justify-content: space-between;
"
>
<text
style=
"color: #a69999"
>
随机30题,及格25题
</text
>
<text>
未通过
</text>
</view>
</view>
</view>
</view>
</view>
</view>
</scroll-view>
</swiper-item>
</swiper>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
msg
:
"赣南吴彦祖"
,
msg
:
"赣南吴彦祖"
,
tabs
:
[
tabs
:
[
{
{
name
:
"交付规范"
,
name
:
"交付规范"
,
},
},
{
{
name
:
"培训通知"
,
name
:
"培训通知"
,
},
},
{
{
name
:
"在线学习"
,
name
:
"在线学习"
,
},
},
{
{
name
:
"考核认证"
,
name
:
"考核认证"
,
},
],
current
:
0
,
swiperCurrent
:
0
,
params
:
{
start
:
0
,
},
list
:
[],
courselist
:
[
{
title
:
"服务规范"
,
desc
:
"为用户提供更好服务,自己赚更多钱"
,
percent
:
0
,
status
:
""
,
pic
:
process
.
uniEnv
.
qn_base_url
+
"guifan1@3x.png"
,
id
:
173
,
},
{
title
:
"接单操作"
,
desc
:
"快速学习,使用APP 接单、抢单"
,
percent
:
0
,
status
:
""
,
pic
:
process
.
uniEnv
.
qn_base_url
+
"guifan2@3x.png"
,
id
:
173
,
},
{
title
:
"从0-1学习充电桩安装服务"
,
desc
:
"让你全面了解充电桩市场及服务规范"
,
percent
:
0
,
status
:
""
,
pic
:
process
.
uniEnv
.
qn_base_url
+
"kecehng1@3x.png"
,
id
:
173
,
},
],
loadStatus
:
"loading"
,
//加载样式:loadMore-加载前样式,loading-加载加载中样式,nomore-没有数据样式
isLoadMore
:
false
,
//是否加载中
course_id
:
"course_id_=173"
,
exam
:
null
,
};
},
onLoad
()
{
// this.getList();
// this.getCourseList();
// this.getUserExamInfo();
},
computed
:
{
bannerImage
()
{
return
process
.
uniEnv
.
qn_base_url
+
"banner-xx@3x.png"
;
},
},
],
current
:
0
,
swiperCurrent
:
0
,
params
:
{
start
:
0
,
},
list
:
[],
courselist
:
null
,
loadStatus
:
"loading"
,
//加载样式:loadMore-加载前样式,loading-加载加载中样式,nomore-没有数据样式
isLoadMore
:
false
,
//是否加载中
course_id
:
"course_id_=173"
,
exam
:
null
,
};
},
onLoad
()
{
this
.
getList
();
this
.
getCourseList
();
this
.
getUserExamInfo
();
},
computed
:
{
bannerImage
()
{
return
process
.
uniEnv
.
qn_base_url
+
"banner-xx.png"
;
},
},
},
methods
:
{
methods
:
{
getList
()
{
getList
()
{
this
.
$u
.
api
this
.
$u
.
api
.
getTrainingNoticeList
(
this
.
params
)
.
getTrainingNoticeList
(
this
.
params
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
if
(
res
.
code
==
200
)
{
if
(
res
.
data
)
{
if
(
res
.
data
)
{
this
.
list
=
this
.
list
.
concat
(
res
.
data
);
this
.
list
=
this
.
list
.
concat
(
res
.
data
);
if
(
res
.
data
.
length
<
5
)
{
if
(
res
.
data
.
length
<
5
)
{
//判断接口返回数据量小于请求数据量,则表示此为最后一页
//判断接口返回数据量小于请求数据量,则表示此为最后一页
this
.
isLoadMore
=
true
;
this
.
isLoadMore
=
true
;
this
.
loadStatus
=
"nomore"
;
this
.
loadStatus
=
"nomore"
;
}
else
{
}
else
{
this
.
isLoadMore
=
false
;
this
.
isLoadMore
=
false
;
}
}
}
else
{
this
.
isLoadMore
=
true
;
this
.
loadStatus
=
"nomore"
;
}
}
else
{
//接口请求失败的处理
uni
.
showToast
({
title
:
res
.
message
,
icon
:
"none"
,
});
this
.
isLoadMore
=
false
;
if
(
this
.
params
.
start
>
0
)
{
this
.
page
-=
5
;
}
}
})
.
catch
((
err
)
=>
{
uni
.
showToast
({
title
:
err
,
icon
:
"none"
,
});
this
.
isLoadMore
=
false
;
if
(
this
.
params
.
start
>
0
)
{
this
.
page
-=
5
;
}
});
},
getTypeName
(
percent
)
{
if
(
percent
==
0
)
{
return
"未开始"
;
}
else
if
(
percent
==
"100"
)
{
return
"已完成"
;
}
else
{
}
else
{
this
.
isLoadMore
=
true
;
return
"继续"
;
this
.
loadStatus
=
"nomore"
;
}
}
else
{
//接口请求失败的处理
uni
.
showToast
({
title
:
res
.
message
,
icon
:
"none"
,
});
this
.
isLoadMore
=
false
;
if
(
this
.
params
.
start
>
0
)
{
this
.
page
-=
5
;
}
}
}
},
})
//在线学习通用课程信息
.
catch
((
err
)
=>
{
getCourseList
()
{
uni
.
showToast
({
let
courseLength
=
this
.
courselist
.
length
;
title
:
err
,
for
(
let
i
=
0
;
i
<
courseLength
;
i
++
)
{
icon
:
"none"
,
let
param
=
{
});
course_id
:
this
.
courselist
[
i
].
id
,
this
.
isLoadMore
=
false
;
};
if
(
this
.
params
.
start
>
0
)
{
this
.
$u
.
api
this
.
page
-=
5
;
.
CourseList
(
param
)
}
.
then
((
res
)
=>
{
});
if
(
res
.
code
==
200
)
{
},
if
(
res
.
data
)
{
//在线学习通用课程信息
this
.
courselist
[
i
].
status
=
this
.
getTypeName
(
getCourseList
()
{
res
.
data
.
learnedInfo
.
learnPercent
this
.
$u
.
api
);
.
CourseList
()
this
.
courselist
[
i
].
percent
=
.
then
((
res
)
=>
{
res
.
data
.
learnedInfo
.
learnPercent
;
if
(
res
.
code
==
200
)
{
}
if
(
res
.
data
)
{
}
this
.
courselist
=
res
.
data
;
})
console
.
log
(
"--------"
);
.
catch
((
err
)
=>
{
console
.
log
(
this
.
courselist
);
uni
.
showToast
({
if
(
res
.
data
.
length
<
5
)
{
title
:
err
,
//判断接口返回数据量小于请求数据量,则表示此为最后一页
icon
:
"none"
,
this
.
isLoadMore
=
true
;
});
this
.
loadStatus
=
"nomore"
;
});
}
else
{
this
.
isLoadMore
=
false
;
}
}
else
{
this
.
isLoadMore
=
true
;
this
.
loadStatus
=
"nomore"
;
}
}
}
else
{
},
//接口请求失败的处理
//tabs通知swiper切换
uni
.
showToast
({
tabsChange
(
index
)
{
title
:
res
.
message
,
this
.
swiperCurrent
=
index
;
icon
:
"none"
,
switch
(
index
)
{
});
case
1
:
this
.
isLoadMore
=
false
;
this
.
params
.
start
=
0
;
if
(
this
.
params
.
start
>
0
)
{
this
.
list
=
[];
this
.
page
-=
5
;
this
.
getList
();
break
;
case
2
:
this
.
getCourseList
();
console
.
log
(
"重新加载学习进度"
);
break
;
case
3
:
this
.
getUserExamInfo
();
break
;
}
}
}
})
.
catch
((
err
)
=>
{
uni
.
showToast
({
title
:
err
,
icon
:
"none"
,
});
this
.
isLoadMore
=
false
;
if
(
this
.
params
.
start
>
0
)
{
this
.
page
-=
5
;
}
});
},
//tabs通知swiper切换
tabsChange
(
index
)
{
this
.
swiperCurrent
=
index
;
},
//swiper-item左右移动,通知tabs的滑块跟随移动
transition
(
e
)
{
let
dx
=
e
.
detail
.
dx
;
this
.
$refs
.
uTabs
.
setDx
(
dx
);
},
animationfinish
(
e
)
{
let
current
=
e
.
detail
.
current
;
this
.
$refs
.
uTabs
.
setFinishCurrent
(
current
);
this
.
swiperCurrent
=
current
;
this
.
current
=
current
;
},
//跳转到assessment页面
aaa
()
{
wx
.
navigateTo
({
url
:
"./assessment"
,
});
},
//跳转到课程介绍
ccc
(
id
)
{
uni
.
navigateTo
({
url
:
"./curriculum?course_id="
+
id
,
});
},
//跳转到
bbb
(
e
)
{
var
news
=
{
body
:
e
.
body
,
id
:
e
.
id
,
level
:
e
.
level
,
title
:
e
.
title
,
};
// console.log(news)
uni
.
navigateTo
({
url
:
"./news-details"
,
});
setTimeout
(()
=>
{
uni
.
$emit
(
"news"
,
news
),
console
.
log
(
"发送数据"
);
},
500
);
console
.
log
(
"跳转结束11111111"
);
},
//scroll-view到底部加载更多
onreachBottom
()
{
console
.
log
(
"上拉触底函数"
);
//上拉触底函数
if
(
!
this
.
isLoadMore
)
{
this
.
isLoadMore
=
true
;
this
.
params
.
start
+=
5
;
if
(
this
.
loadStatus
!==
"nomore"
)
{
this
.
getList
();
}
}
},
//跳转到拍照小程序首页
goToPrint
()
{
console
.
log
(
"111111"
);
uni
.
navigateToMiniProgram
({
appId
:
"wxd1d6eede324b0465"
,
success
(
res
)
{
//打开成功
console
.
log
(
"success"
,
res
);
},
},
fail
(
err
)
{
//swiper-item左右移动,通知tabs的滑块跟随移动
console
.
log
(
"err"
,
err
);
transition
(
e
)
{
let
dx
=
e
.
detail
.
dx
;
this
.
$refs
.
uTabs
.
setDx
(
dx
);
},
},
});
animationfinish
(
e
)
{
},
let
current
=
e
.
detail
.
current
;
//考核认证,通用认证,考试通过or未通过查询接口请求
this
.
$refs
.
uTabs
.
setFinishCurrent
(
current
);
getUserExamInfo
()
{
this
.
swiperCurrent
=
current
;
uni
.
showLoading
({
this
.
current
=
current
;
title
:
"请稍候"
,
},
});
//跳转到assessment页面
aaa
()
{
var
id
=
this
.
exam
.
id
;
if
(
this
.
exam
.
examStatus
==
0
)
{
console
.
log
(
"这是个标识符"
,
this
.
exam
.
id
);
let
that
=
this
;
wx
.
navigateTo
({
uni
.
request
({
url
:
"./answer?userExamId="
+
id
,
url
:
});
"http://192.168.1.22"
+
}
else
if
(
this
.
exam
.
examStatus
==
1
)
{
"/wxh-worker-rest/rest/exam"
+
wx
.
navigateTo
({
"/serviceRule/userExamInfo/"
+
url
:
"./result?userExamId="
+
id
,
getApp
().
globalData
.
token
+
});
"?examId="
+
}
else
if
(
this
.
exam
.
examStatus
==
2
)
{
2
,
wx
.
navigateTo
({
method
:
"POST
"
,
url
:
"./assessment
"
,
data
:
{
});
//examId:this.examId,
}
},
},
header
:
{
//跳转到课程介绍
"Content-Type"
:
"application/x-www-form-urlencoded"
,
ccc
(
id
)
{
uni
.
navigateTo
({
url
:
"./curriculum?course_id="
+
id
,
});
},
},
success
:
(
res
)
=>
{
//跳转到
console
.
log
(
res
.
data
);
bbb
(
e
)
{
uni
.
hideLoading
();
var
news
=
{
if
(
!
res
.
data
)
{
body
:
e
.
body
,
return
;
id
:
e
.
id
,
}
level
:
e
.
level
,
if
(
res
.
data
.
code
==
401
||
res
.
data
.
code
==
403
)
{
title
:
e
.
title
,
// uni.navigateTo({
};
// url: '/pages/login/wxlogin'
// console.log(news)
// })
// return
uni
.
navigateTo
({
console
.
log
(
"洪塘张学友"
);
url
:
"./news-details"
,
}
});
if
(
res
.
data
.
code
==
200
)
{
setTimeout
(()
=>
{
//examStatus 用户考试状态 0考试中 1考试完成 2未参与
uni
.
$emit
(
"news"
,
news
),
console
.
log
(
"发送数据"
);
that
.
exam
=
res
.
data
.
data
;
},
500
);
console
.
log
(
that
.
exam
);
if
(
res
.
data
.
data
.
examStatus
==
2
)
{
console
.
log
(
"跳转结束11111111"
);
that
.
applyExam
();
},
return
;
//scroll-view到底部加载更多
}
onreachBottom
()
{
if
(
res
.
data
.
data
.
examStatus
==
1
)
{
console
.
log
(
"上拉触底函数"
);
console
.
log
(
"111111111111111111111111111"
);
//上拉触底函数
that
.
isComplete
=
true
;
if
(
!
this
.
isLoadMore
)
{
that
.
examScore
=
res
.
data
.
data
.
examScore
;
this
.
isLoadMore
=
true
;
that
.
postResult
();
this
.
params
.
start
+=
5
;
return
;
if
(
this
.
loadStatus
!==
"nomore"
)
{
}
this
.
getList
();
if
(
res
.
data
.
data
.
examStatus
==
0
)
{
}
that
.
userExamId
=
res
.
data
.
data
.
id
;
that
.
getNext
();
}
}
}
else
{
},
uni
.
showToast
({
//跳转到拍照小程序首页
icon
:
"none"
,
goToPrint
()
{
title
:
res
.
data
.
message
,
console
.
log
(
"111111"
);
uni
.
navigateToMiniProgram
({
appId
:
"wxd1d6eede324b0465"
,
success
(
res
)
{
//打开成功
console
.
log
(
"success"
,
res
);
},
fail
(
err
)
{
console
.
log
(
"err"
,
err
);
},
});
});
}
},
},
fail
:
(
e
)
=>
{
//考核认证,通用认证,考试通过or未通过查询接口请求
uni
.
hideLoading
();
getUserExamInfo
()
{
uni
.
showToast
({
uni
.
showLoading
({
icon
:
"none"
,
title
:
"请稍候"
,
title
:
"获取考试信息失败"
,
});
});
let
that
=
this
;
uni
.
request
({
url
:
"http://192.168.1.22"
+
"/wxh-worker-rest/rest/exam"
+
"/serviceRule/userExamInfo/"
+
that
.
vuex_token
+
"?examId="
+
2
,
method
:
"POST"
,
data
:
{
//examId:this.examId,
},
header
:
{
"Content-Type"
:
"application/x-www-form-urlencoded"
,
},
success
:
(
res
)
=>
{
console
.
log
(
res
.
data
);
uni
.
hideLoading
();
if
(
!
res
.
data
)
{
return
;
}
if
(
res
.
data
.
code
==
401
||
res
.
data
.
code
==
403
)
{
// uni.navigateTo({
// url: '/pages/login/wxlogin'
// })
// return
console
.
log
(
"洪塘张学友"
);
}
if
(
res
.
data
.
code
==
200
)
{
//examStatus 用户考试状态 0考试中 1考试完成 2未参与
that
.
exam
=
res
.
data
.
data
;
console
.
log
(
that
.
exam
);
if
(
res
.
data
.
data
.
examStatus
==
2
)
{
that
.
applyExam
();
return
;
}
if
(
res
.
data
.
data
.
examStatus
==
1
)
{
console
.
log
(
"111111111111111111111111111"
);
that
.
isComplete
=
true
;
that
.
examScore
=
res
.
data
.
data
.
examScore
;
that
.
postResult
();
return
;
}
if
(
res
.
data
.
data
.
examStatus
==
0
)
{
that
.
userExamId
=
res
.
data
.
data
.
id
;
that
.
getNext
();
}
}
else
{
uni
.
showToast
({
icon
:
"none"
,
title
:
res
.
data
.
message
,
});
}
},
fail
:
(
e
)
=>
{
uni
.
hideLoading
();
uni
.
showToast
({
icon
:
"none"
,
title
:
"获取考试信息失败"
,
});
},
});
},
},
});
},
},
},
};
};
</
script
>
</
script
>
<
style
>
<
style
>
.study
{
.study
{
height
:
100vh
;
height
:
100vh
;
background-color
:
#f4f5f7
;
background-color
:
#f4f5f7
;
padding
:
0
rpx
30
rpx
0
30
rpx
;
padding
:
0
rpx
30
rpx
0
30
rpx
;
}
}
.title-view
{
.title-view
{
color
:
#333333
;
color
:
#333333
;
font-weight
:
bold
;
font-weight
:
bold
;
font-size
:
40
rpx
;
font-size
:
40
rpx
;
}
}
.banner
{
.banner
{
width
:
690
rpx
;
width
:
690
rpx
;
height
:
240
rpx
;
height
:
240
rpx
;
/* margin-left: -15rpx; */
margin-top
:
10
rpx
;
}
}
/* //交付规范 */
/* //交付规范 */
.standard
{
.standard
{
width
:
656
rpx
;
width
:
656
rpx
;
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
border-bottom
:
1
rpx
solid
#82848a
;
border-bottom
:
1
rpx
solid
#82848a
;
padding
:
0
34
rpx
;
padding
:
0
34
rpx
;
margin
:
72
rpx
auto
;
margin
:
72
rpx
auto
;
}
}
/* //培训通知 */
/* //培训通知 */
.notice
{
.notice
{
border
:
#808080
solid
2
rpx
;
border
:
#808080
solid
2
rpx
;
width
:
100%
;
width
:
100%
;
height
:
400
rpx
;
height
:
400
rpx
;
margin-top
:
36
rpx
;
margin-top
:
36
rpx
;
overflow
:
hidden
;
overflow
:
hidden
;
}
}
.n-head
{
.n-head
{
text-align
:
center
;
text-align
:
center
;
margin
:
32
rpx
0
;
margin
:
32
rpx
0
;
}
}
.news
{
.news
{
}
}
/* //在线学习 */
/* //在线学习 */
.currency-class
{
.currency-class
{
width
:
100%
;
width
:
100%
;
background
:
#ffffff
;
background
:
#ffffff
;
padding
:
18
rpx
;
padding
:
18
rpx
;
margin-bottom
:
11px
;
margin-bottom
:
11px
;
border-radius
:
12
rpx
;
border-radius
:
12
rpx
;
}
}
.title
{
.title
{
font-size
:
32
rpx
;
font-size
:
32
rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
font-family
:
PingFang-SC-Bold
,
PingFang-SC
;
font-family
:
PingFang-SC-Bold
,
PingFang-SC
;
}
}
.class1
{
.class1
{
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
padding-top
:
22
rpx
;
padding-top
:
22
rpx
;
margin-top
:
28
rpx
;
margin-top
:
28
rpx
;
border-top
:
1
rpx
solid
#808080
;
border-top
:
1
rpx
solid
#808080
;
}
}
.img
{
.img
{
width
:
201
rpx
;
width
:
201
rpx
;
height
:
201
rpx
;
height
:
201
rpx
;
display
:
block
;
display
:
block
;
margin-right
:
0
rpx
;
margin-right
:
0
rpx
;
}
}
.right
{
.right
{
width
:
428
rpx
;
width
:
428
rpx
;
display
:
flex
;
display
:
flex
;
flex-direction
:
column
;
flex-direction
:
column
;
justify-content
:
space-between
;
justify-content
:
space-between
;
}
}
.intro
{
.intro
{
color
:
#9999a6
;
color
:
#9999a6
;
}
}
.tab
{
.tab
{
background
:
#fff
;
background
:
#fff
;
height
:
82
rpx
;
height
:
82
rpx
;
margin
:
0
0
;
margin
:
0
0
;
}
}
.text
{
.text
{
margin
:
0
40
rpx
;
margin
:
0
40
rpx
;
line-height
:
82
rpx
;
line-height
:
82
rpx
;
color
:
#667eb5
;
color
:
#667eb5
;
}
}
.content
{
.content
{
margin
:
5px
0
;
margin
:
5px
0
;
height
:
485
rpx
;
height
:
485
rpx
;
background
:
#fff
;
background
:
#fff
;
}
}
swiper
{
swiper
{
height
:
691
rpx
;
height
:
691
rpx
;
}
}
</
style
>
</
style
>
\ No newline at end of file
src/pages/learn/result.vue
View file @
8b91f718
<
template
>
<
template
>
<view
class=
"test-result"
>
<view
class=
"test-result"
>
<text
class=
"title"
>
考试结果
</text>
<text
class=
"title"
>
考试结果
</text>
<view
class=
"result"
>
<view
class=
"result"
>
{{
text
}}
</view>
未通过
<view
class=
"test-explain"
>
</view>
<view
class=
"hang"
>
<view
class=
"test-explain"
>
<text
class=
"text1"
>
合格条件:
</text
<view
class=
"hang"
>
><text
class=
"text2"
>
答对20题
</text>
<text
class=
"text1"
>
合格条件:
</text><text
class=
"text2"
>
答对20题
</text>
</view>
</view>
<view
class=
"hang"
>
<view
class=
"hang"
>
<text
class=
"text1"
>
考试结果:
</text
<text
class=
"text1"
>
考试结果:
</text><text
class=
"text2"
>
答对10题
</text>
><text
class=
"text2"
>
答对10题
</text>
</view>
</view>
<view
class=
"hang"
>
<view
class=
"hang"
>
<text
class=
"text1"
>
考试用时:
</text><text
class=
"text2"
>
16分29秒
</text>
<text
class=
"text1"
>
考试用时:
</text
</view>
><text
class=
"text2"
>
16分29秒
</text>
</view>
</view>
<view
class=
"btn"
>
</view>
<button
class=
"btn1"
>
再答一次
</button>
<view
class=
"btn"
>
<button
class=
"btn2"
>
退出重考
</button>
<button
class=
"btn1"
@
click=
"getAgain()"
>
再答一次
</button>
</view>
<button
class=
"btn2"
@
click=
"toIndex"
>
下次再考
</button>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
text
:
""
,
}
examId
:
2
,
},
result
:
null
,
methods
:
{
userExamId
:
null
,
};
}
},
}
onLoad
(
a
)
{
this
.
userExamId
=
a
.
userExamId
;
console
.
log
(
"userExamId是"
,
this
.
userExamId
);
this
.
nextClick
();
},
onUnload
()
{
wx
.
reLaunch
({
url
:
"./index"
,
});
},
methods
:
{
//考试结果
nextClick
:
function
()
{
console
.
log
(
"wwwwwwwwww"
);
uni
.
request
({
url
:
"http://192.168.1.22"
+
"/wxh-worker-rest/rest/exam"
+
"/serviceRule/next/"
+
this
.
vuex_token
+
"?userExamId="
+
this
.
userExamId
,
method
:
"POST"
,
header
:
{
"Content-Type"
:
"application/x-www-form-urlencoded"
,
},
success
:
(
res
)
=>
{
this
.
result
=
res
.
data
.
data
;
this
.
text
=
res
.
data
.
data
.
examLevelResult
;
console
.
log
(
"标识符55"
,
this
.
result
);
},
});
},
//再次考试
getAgain
:
function
()
{
wx
.
navigateTo
({
url
:
"./assessment"
,
});
},
//下次再考跳转到学习主界面页面
toIndex
:
function
()
{
wx
.
reLaunch
({
url
:
"./index"
,
});
},
},
};
</
script
>
</
script
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
.test-result
{
.test-result
{
width
:
610rpx
;
width
:
610rpx
;
height
:
965rpx
;
height
:
965rpx
;
margin
:
70rpx
auto
0
;
margin
:
70rpx
auto
0
;
.title
{
.title
{
margin
:
0
44rpx
0
;
margin
:
0
44rpx
0
;
}
}
.result
{
.result
{
color
:
red
;
color
:
red
;
font-size
:
66rpx
;
font-size
:
66rpx
;
text-align
:
center
;
text-align
:
center
;
border-bottom
:
1px
dashed
#000000
;
border-bottom
:
1px
dashed
#000000
;
margin
:
74rpx
0
;
margin
:
74rpx
0
;
padding
:
66rpx
;
padding
:
66rpx
;
}
}
.test-explain
{
.test-explain
{
.hang
{
.hang
{
margin
:
26rpx
26rpx
;
margin
:
26rpx
26rpx
;
.text1
{
.text1
{
color
:
#a69999
;
color
:
#a69999
;
margin-right
:
22rpx
;
margin-right
:
22rpx
;
}
}
.text2
{
.text2
{
color
:
#333333
;
color
:
#333333
;
}
}
}
}
}
}
.btn
{
.btn
{
margin-top
:
236rpx
;
margin-top
:
236rpx
;
.btn1
{
.btn1
{
width
:
478rpx
;
width
:
478rpx
;
height
:
60rpx
;
height
:
60rpx
;
background
:
#0079fe
;
background
:
#0079fe
;
color
:
#fff
;
color
:
#fff
;
font-size
:
26rpx
;
font-size
:
26rpx
;
line-height
:
60rpx
;
line-height
:
60rpx
;
margin
:
20rpx
auto
;
margin
:
20rpx
auto
;
}
}
.btn2
{
.btn2
{
width
:
478rpx
;
width
:
478rpx
;
height
:
60rpx
;
height
:
60rpx
;
background
:
#f2f2f2
;
background
:
#f2f2f2
;
color
:
#333333
;
color
:
#333333
;
font-size
:
26rpx
;
font-size
:
26rpx
;
line-height
:
60rpx
;
line-height
:
60rpx
;
margin
:
0
auto
;
margin
:
0
auto
;
}
}
}
}
}
}
</
style
>
</
style
>
src/pages/learn/section.vue
View file @
8b91f718
<
template
>
<
template
>
<view
class=
"learn-vedio"
v-if=
"isShowVideo"
>
<view
class=
"learn-vedio"
v-if=
"isShowVideo"
>
<view
class=
"uni-padding-wrap uni-common-mt"
>
<view
class=
"uni-padding-wrap uni-common-mt"
>
<view><video
<view><video
object-fit=
"cover"
class=
"course-video"
id=
"courseVideo"
:src=
"courseSrc"
object-fit=
"cover"
:options=
"playerOptions"
:playsinline=
"true"
@
play=
"playCourse"
@
error=
"videoErrorCallback"
class=
"course-video"
@
ready=
"playerReadied"
@
timeupdate=
"onPlayerTimeupdate($event)"
controls
></video></view>
id=
"courseVideo"
<view
class=
"title-content"
>
:src=
"courseSrc"
<view
class=
"item-content"
>
:options=
"playerOptions"
<view
class=
"item-st"
>
:playsinline=
"true"
<image
style=
"width: 80rpx; height: 36rpx"
:src=
"kcImage"
></image>
@
play=
"playCourse"
<text
class=
"item-st-text"
>
{{
courseTitle
.
split
(
" "
)
?
courseTitle
.
split
(
" "
)[
0
]
:
""
}}
</text>
@
error=
"videoErrorCallback"
</view>
@
ready=
"playerReadied"
<view
class=
"item-title"
>
{{
courseTitle
.
split
(
" "
)
?
courseTitle
.
split
(
" "
)[
1
]
:
""
}}
</view>
@
timeupdate =
"onPlayerTimeupdate($event)"
</view>
controls
<view>
接单操作须知有助你快速了解充电桩安装业务,提高接单效率,请认真查看及学习。
</view>
></video
</view>
></view>
<view
class=
"learn-view"
v-if=
"courseId >= 0"
>
<view
class=
"title-content"
>
<view
class=
"learn-view-title"
>
视频内容介绍
</view>
<view
class=
"item-content"
>
<!--
<view
<view
class=
"item-st"
>
<image
style=
"width: 80rpx; height: 36rpx"
:src=
"kcImage"
></image>
<text
class=
"item-st-text"
>
{{
courseTitle
.
split
(
" "
)
?
courseTitle
.
split
(
" "
)[
0
]
:
""
}}
</text>
</view>
<view
class=
"item-title"
>
{{
courseTitle
.
split
(
" "
)
?
courseTitle
.
split
(
" "
)[
1
]
:
""
}}
</view>
</view>
<view
>
接单操作须知有助你快速了解充电桩安装业务,提高接单效率,请认真查看及学习。
</view
>
</view>
<view
class=
"learn-view"
v-if=
"courseId >= 0"
>
<view
class=
"learn-view-title"
>
视频内容介绍
</view>
<!--
<view
class=
"learn-list"
class=
"learn-list"
v-for=
"(item, key) in courseOutlines[courseId]"
v-for=
"(item, key) in courseOutlines[courseId]"
:key=
"key"
:key=
"key"
>
-->
>
-->
<view
class=
"learn-list-item"
>
{{
item
}}
</view>
<!--
<view
class=
"learn-list-item"
>
{{
item
}}
</view>
-->
</view>
<view
class=
"u-content"
>
</view>
<u-parse
:html=
"CourseSectionlist.content"
></u-parse>
</view>
</view>
</view>
</view>
</view>
<view
v-else
>
<view
v-else
>
<view
class=
"title"
>
<view
class=
"title"
>
{{
CourseSectionlist
.
name
}}
{{
CourseSectionlist
.
name
}}
</view>
</view>
<view
class=
"content"
v-html=
"CourseSectionlist.content"
>
<view
class=
"u-content"
>
{{
CourseSectionlist
.
content
}}
<u-parse
:html=
"CourseSectionlist.content"
></u-parse>
</view>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
let
app
=
getApp
();
let
app
=
getApp
();
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
courseId
:
""
,
courseId
:
""
,
courseStatus
:
0
,
courseStatus
:
0
,
courseSrc
:
""
,
courseSrc
:
""
,
courseTitle
:
""
,
courseTitle
:
""
,
courseDesc
:
""
,
courseDesc
:
""
,
currentIndex
:
-
1
,
// 第几个视频
currentIndex
:
-
1
,
// 第几个视频
section_id
:
0
,
section_id
:
0
,
isShowVideo
:
false
,
isShowVideo
:
false
,
CourseSectionlist
:
{},
//节信息
CourseSectionlist
:
{
name
:
''
,
content
:
''
},
//节信息
playerOptions
:
{
playerOptions
:
{
playbackRates
:
[
0.7
,
1.0
,
1.5
,
2.0
],
//播放速度
playbackRates
:
[
0.7
,
1.0
,
1.5
,
2.0
],
//播放速度
autoplay
:
false
,
//如果true,浏览器准备好时开始回放。
autoplay
:
true
,
//如果true,浏览器准备好时开始回放。
muted
:
false
,
// 默认情况下将会消除任何音频。
muted
:
false
,
// 默认情况下将会消除任何音频。
loop
:
false
,
// 导致视频一结束就重新开始。
loop
:
false
,
// 导致视频一结束就重新开始。
preload
:
'auto'
,
preload
:
'auto'
,
language
:
'zh-CN'
,
language
:
'zh-CN'
,
aspectRatio
:
'16:9'
,
aspectRatio
:
'16:9'
,
fluid
:
true
,
fluid
:
true
,
// sources: [{
notSupportedMessage
:
'此视频暂无法播放,请稍后再试'
,
// type: "",
controlBar
:
{
// src: "" //url地址
timeDivider
:
true
,
// }],
durationDisplay
:
true
,
// poster: "../../static/images/test.jpg", //你的封面地址
remainingTimeDisplay
:
false
,
// width: document.documentElement.clientWidth,
fullscreenToggle
:
true
//全屏按钮
notSupportedMessage
:
'此视频暂无法播放,请稍后再试'
,
controlBar
:
{
timeDivider
:
true
,
durationDisplay
:
true
,
remainingTimeDisplay
:
false
,
fullscreenToggle
:
true
//全屏按钮
}
},
gklog
:
''
,
videoTotalTime
:
0
,
howTimeToUpdateLearnedStatus
:
5
,
//设置几秒提交一次状态
status
:
1
,
//是否已学习默认1已学习
howLongIsLearned
:
this
.
videoTotalTime
/
2
,
//默认设置观看1/2就是已学
};
},
computed
:
{
courseOutlines
()
{
// 视频内容介绍
return
{
1
:
[
"1、考核规则:接单及时率"
,
"2、考核规则:上门及时率"
,
"3、考核规则:安装完工率"
,
"4、考核规则:资料提交及时率"
,
"5、考核规则:安装完工率"
,
"6、考核规则:客户满意度"
,
],
2
:
[
"1、必备材料4大类"
,
"2、施工工具准备"
],
3
:
[
"1、接线安装工艺标准"
,
"2、PVC、镀锌管电缆管明敷"
,
"3、电缆敷设的防火要求"
,
"4、电源点标识"
,
"5、配电箱接线及安装"
,
"6、管线敷设接头处理"
,
"7、充电桩内部接线"
,
"8、配电箱安装"
,
],
4
:
[
"1、勘测环节录单要求"
,
"2、安装环节录单要求"
],
};
},
kcImage
()
{
return
process
.
uniEnv
.
qn_base_url
+
"kc.png"
;
},
},
onLoad
(
e
)
{
this
.
getCourseSection
({
section_id
:
e
.
section_id
})
},
onReady
:
function
(
res
)
{
// #ifndef MP-ALIPAY
this
.
videoContext
=
uni
.
createVideoContext
(
"courseVideo"
);
// #endif
},
methods
:
{
onPlayerTimeupdate
(
player
)
{
console
.
log
(
'-----onplay----'
);
console
.
log
(
player
);
let
intCurrentTime
=
parseInt
(
player
.
detail
.
currentTime
);
this
.
updateLearnedStatus
(
intCurrentTime
);
this
.
gklog
=
intCurrentTime
;
console
.
log
(
' onPlayerTimeupdate!'
,
this
.
gklog
)
},
videoErrorCallback
:
function
(
e
)
{
uni
.
showModal
({
content
:
e
.
target
.
errMsg
,
showCancel
:
false
,
});
},
getRandomColor
:
function
()
{
const
rgb
=
[];
for
(
let
i
=
0
;
i
<
3
;
++
i
)
{
let
color
=
Math
.
floor
(
Math
.
random
()
*
256
).
toString
(
16
);
color
=
color
.
length
==
1
?
"0"
+
color
:
color
;
rgb
.
push
(
color
);
}
return
"#"
+
rgb
.
join
(
""
);
},
playCourse
:
function
(
e
)
{
if
(
this
.
courseStatus
&&
(
this
.
courseStatus
==
"1"
||
this
.
courseStatus
==
1
))
{
return
}
this
.
changeCourseStatus
();
},
playerReadied
(
player
)
{
console
.
log
(
'i go to playerReadied gklog:'
+
this
.
gklog
)
player
.
currentTime
(
this
.
gklog
)
},
changeCourseStatus
()
{
let
that
=
this
;
if
(
that
.
courseId
)
{
that
.
$u
.
api
.
saveCourseRate
({
courseId
:
that
.
courseId
,
})
.
then
((
res
)
=>
{
if
(
res
.
code
!==
200
)
{
uni
.
showToast
({
icon
:
"none"
,
title
:
"更新课程状态失败"
,
});
}
});
}
else
{
uni
.
showToast
({
title
:
"课程ID为空,请重新选择课程"
,
});
}
},
getCourseSection
(
param
)
{
this
.
$u
.
api
.
CourseSection
(
param
)
.
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
if
(
res
.
data
)
{
this
.
CourseSectionlist
=
res
.
data
;
console
.
log
(
"--------"
)
console
.
log
(
this
.
CourseSectionlist
)
let
wareVal
=
this
.
CourseSectionlist
.
ware
;
this
.
isShowVideo
=
wareVal
==
"0"
;
if
(
this
.
isShowVideo
){
let
coureWareList
=
res
.
data
.
courseware
;
this
.
courseSrc
=
coureWareList
[
0
].
src
;
this
.
videoTotalTime
=
parseInt
(
JSON
.
parse
(
coureWareList
[
0
].
info
).
time
);
console
.
log
(
'视频时长信息:'
+
this
.
videoTotalTime
);
this
.
courseTitle
=
res
.
data
.
name
;
this
.
courseDesc
=
res
.
data
.
content
;
this
.
section_id
=
res
.
data
.
id
;
}
}
}
}
},
gklog
:
''
,
videoTotalTime
:
0
,
howTimeToUpdateLearnedStatus
:
5
,
//设置几秒提交一次状态
status
:
1
,
//是否已学习默认1已学习
howLongIsLearned
:
this
.
videoTotalTime
/
2
,
//默认设置观看1/2就是已学
};
},
computed
:
{
courseOutlines
()
{
// 视频内容介绍
return
{
1
:
[
"1、考核规则:接单及时率"
,
"2、考核规则:上门及时率"
,
"3、考核规则:安装完工率"
,
"4、考核规则:资料提交及时率"
,
"5、考核规则:安装完工率"
,
"6、考核规则:客户满意度"
,
],
2
:
[
"1、必备材料4大类"
,
"2、施工工具准备"
],
3
:
[
"1、接线安装工艺标准"
,
"2、PVC、镀锌管电缆管明敷"
,
"3、电缆敷设的防火要求"
,
"4、电源点标识"
,
"5、配电箱接线及安装"
,
"6、管线敷设接头处理"
,
"7、充电桩内部接线"
,
"8、配电箱安装"
,
],
4
:
[
"1、勘测环节录单要求"
,
"2、安装环节录单要求"
],
};
},
kcImage
()
{
return
process
.
uniEnv
.
qn_base_url
+
"kc.png"
;
},
},
onLoad
(
e
)
{
this
.
getCourseSection
({
section_id
:
e
.
section_id
})
})
.
catch
((
err
)
=>
{
},
console
.
log
(
'--------settttt---------'
);
onReady
:
function
(
res
)
{
console
.
log
(
err
);
// #ifndef MP-ALIPAY
uni
.
showToast
({
this
.
videoContext
=
uni
.
createVideoContext
(
"courseVideo"
);
title
:
err
,
// #endif
icon
:
"none"
,
},
methods
:
{
onPlayerTimeupdate
(
player
)
{
console
.
log
(
'-----onplay----'
);
console
.
log
(
player
);
let
intCurrentTime
=
parseInt
(
player
.
detail
.
currentTime
);
this
.
updateLearnedStatus
(
intCurrentTime
);
this
.
gklog
=
intCurrentTime
;
console
.
log
(
' onPlayerTimeupdate!'
,
this
.
gklog
)
},
videoErrorCallback
:
function
(
e
)
{
uni
.
showModal
({
content
:
e
.
target
.
errMsg
,
showCancel
:
false
,
});
});
});
},
},
getRandomColor
:
function
()
{
updateLearnedStatus
(
nowLength
)
{
const
rgb
=
[];
if
(
this
.
gklog
!=
nowLength
&&
nowLength
%
this
.
howTimeToUpdateLearnedStatus
==
0
){
for
(
let
i
=
0
;
i
<
3
;
++
i
)
{
if
(
nowLength
<
this
.
howLongIsLearned
){
let
color
=
Math
.
floor
(
Math
.
random
()
*
256
).
toString
(
16
);
this
.
status
=
0
;
color
=
color
.
length
==
1
?
"0"
+
color
:
color
;
}
else
{
rgb
.
push
(
color
);
this
.
status
=
1
;
}
console
.
log
(
'--已学习--'
);
return
"#"
+
rgb
.
join
(
""
);
}
},
//大于
playCourse
:
function
(
e
)
{
let
param
=
{
if
(
this
.
courseStatus
&&
(
this
.
courseStatus
==
"1"
||
this
.
courseStatus
==
1
))
{
section_id
:
this
.
section_id
,
return
video_time
:
nowLength
,
}
status
:
this
.
status
,
},
};
playerReadied
(
player
)
{
this
.
$u
.
api
.
updateLearnCourses
(
param
).
then
((
res
)
=>
{
console
.
log
(
'i go to playerReadied gklog:'
+
this
.
gklog
)
console
.
log
(
'--'
+
this
.
howTimeToUpdateLearnedStatus
+
'更新一次观看状态--time:'
+
nowLength
);
player
.
currentTime
(
this
.
gklog
)
});
},
}
getCourseSection
(
param
)
{
}
this
.
$u
.
api
},
.
CourseSection
(
param
)
};
.
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
if
(
res
.
data
)
{
this
.
CourseSectionlist
=
res
.
data
;
console
.
log
(
"--------"
)
console
.
log
(
this
.
CourseSectionlist
)
let
wareVal
=
this
.
CourseSectionlist
.
ware
;
this
.
isShowVideo
=
wareVal
==
"0"
;
this
.
courseTitle
=
res
.
data
.
name
;
this
.
courseDesc
=
res
.
data
.
content
;
this
.
section_id
=
res
.
data
.
id
;
this
.
section_content
=
res
.
data
.
content
;
if
(
this
.
isShowVideo
)
{
let
coureWareList
=
res
.
data
.
courseware
;
this
.
courseSrc
=
coureWareList
[
0
].
src
;
this
.
videoTotalTime
=
parseInt
(
JSON
.
parse
(
coureWareList
[
0
].
info
).
time
);
console
.
log
(
'视频时长信息:'
+
this
.
videoTotalTime
);
}
else
{
this
.
updateLearnedStatusForText
();
}
}
}
})
.
catch
((
err
)
=>
{
console
.
log
(
'--------settttt---------'
);
console
.
log
(
err
);
uni
.
showToast
({
title
:
err
,
icon
:
"none"
,
});
});
},
updateLearnedStatusForText
()
{
if
(
this
.
isShowVideo
)
{
return
false
;
}
let
param
=
{
section_id
:
this
.
section_id
,
video_time
:
0
,
status
:
1
,
};
this
.
$u
.
api
.
updateLearnCourses
(
param
).
then
((
res
)
=>
{
console
.
log
(
'--'
+
this
.
howTimeToUpdateLearnedStatus
+
'更新一次观看状态--time:'
+
nowTime
);
}).
catch
((
err
)
=>
{
console
.
log
(
'--------updateLearnedStatusForText---------'
);
console
.
log
(
err
);
uni
.
showToast
({
title
:
err
,
icon
:
"none"
,
});
});
},
updateLearnedStatus
(
nowTime
)
{
if
(
this
.
gklog
!=
nowTime
&&
nowTime
%
this
.
howTimeToUpdateLearnedStatus
==
0
)
{
if
(
nowTime
<
this
.
howLongIsLearned
)
{
this
.
status
=
0
;
}
else
{
this
.
status
=
1
;
console
.
log
(
'--大于规定时间标记为已学习--'
);
}
let
param
=
{
section_id
:
this
.
section_id
,
video_time
:
nowTime
,
status
:
this
.
status
,
};
this
.
$u
.
api
.
updateLearnCourses
(
param
).
then
((
res
)
=>
{
console
.
log
(
'--'
+
this
.
howTimeToUpdateLearnedStatus
+
'更新一次观看状态--time:'
+
nowTime
);
}).
catch
((
err
)
=>
{
console
.
log
(
'--------updateLearnedStatus---------'
);
console
.
log
(
err
);
uni
.
showToast
({
title
:
err
,
icon
:
"none"
,
});
});
}
}
},
};
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.learn-vedio
{
.learn-vedio
{
background-color
:
#f4f5f7
;
background-color
:
#f4f5f7
;
position
:
absolute
;
position
:
absolute
;
top
:
0
;
top
:
0
;
left
:
0
;
left
:
0
;
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
display
:
flex
;
display
:
flex
;
flex-direction
:
column
;
flex-direction
:
column
;
overflow-y
:auto
;
overflow-y
:
auto
;
}
}
.course-video
{
width
:
100%
;
}
.course-title
{
font-size
:
36rpx
;
font-weight
:
700
;
padding
:
40rpx
40rpx
10rpx
40rpx
;
}
.title
{
font-weight
:
700
;
font-family
:
Medium
,
Helvetica
Neue
,
Helvetica
,
Arial
,
sans-serif
;
font-size
:
77rpx
;
color
:
#333
;
padding
:
80rpx
60rpx
40rpx
60rpx
;
}
.course-video
{
.content
{
width
:
100%
;
padding
:
40rpx
30rpx
;
}
margin-bottom
:
20rpx
;
}
.course-title
{
.course-desc
{
font-size
:
36rpx
;
margin-left
:
60rpx
;
font-weight
:
700
;
}
padding
:
80rpx
60rpx
40rpx
60rpx
;
}
.title
{
.title-content
{
font-weight
:
700
;
padding
:
40rpx
30rpx
;
font-family
:
Medium
,
Helvetica
Neue
,
Helvetica
,
Arial
,
sans-serif
;
margin-bottom
:
20rpx
;
font-size
:
77rpx
;
background-color
:
#ffffff
;
color
:
#333
;
color
:
#999999
;
padding
:
80rpx
60rpx
40rpx
60rpx
;
font-size
:
24rpx
;
}
.
content
{
.item-
content
{
padding
:
40rpx
30rp
x
;
display
:
fle
x
;
margin-bottom
:
20rpx
;
align-items
:
center
;
}
}
.course-desc
{
.item-st
{
margin-left
:
60rpx
;
width
:
80rpx
;
}
height
:
36rpx
;
padding-right
:
2rpx
;
text-align
:
center
;
margin-right
:
20rpx
;
line-height
:
24rpx
;
position
:
relative
;
.title-content
{
.item-st-text
{
padding
:
40rpx
30rpx
;
color
:
#ffffff
;
margin-bottom
:
20rpx
;
position
:
absolute
;
background-color
:
#ffffff
;
font-size
:
16rpx
;
color
:
#999999
;
left
:
20rpx
;
font-size
:
24rpx
;
top
:
8rpx
;
line-height
:
28rpx
;
}
}
.item-content
{
.item-title
{
display
:
flex
;
color
:
#333333
;
align-items
:
center
;
font-size
:
44rpx
;
}
font-weight
:
bold
;
}
}
.item-st
{
.item-content
{
width
:
80rpx
;
display
:
flex
;
height
:
36rpx
;
padding-bottom
:
30rpx
;
padding-right
:
2rpx
;
}
text-align
:
center
;
margin-right
:
20rpx
;
line-height
:
24rpx
;
position
:
relative
;
.item-st-text
{
color
:
#ffffff
;
position
:
absolute
;
font-size
:
16rpx
;
left
:
20rpx
;
top
:
8rpx
;
line-height
:
28rpx
;
}
}
.item-title
{
.item-title
{
color
:
#333333
;
color
:
#333333
;
font-size
:
44rpx
;
font-size
:
28rpx
;
font-weight
:
bold
;
}
}
}
.item-content
{
.learn-view
{
display
:
flex
;
background-color
:
#ffffff
;
padding-bottom
:
30rpx
;
border-radius
:
12rpx
;
}
padding
:
38rpx
30rpx
30rpx
30rpx
;
margin-bottom
:
20rpx
;
font-size
:
32rpx
;
color
:
#333333
;
.item-title
{
.learn-view-title
{
color
:
#333333
;
font-size
:
32rpx
;
font-size
:
28rpx
;
font-weight
:
bold
;
}
margin-bottom
:
10rpx
;
}
.learn-view
{
.learn-list
{
background-color
:
#ffffff
;
.learn-list-item
{
border-radius
:
12
rpx
;
font-size
:
28
rpx
;
padding
:
38rpx
30rpx
30rpx
30rpx
;
margin-top
:
30rpx
;
margin-bottom
:
2
0rpx
;
margin-bottom
:
3
0rpx
;
font-size
:
32rpx
;
color
:
#333333
;
color
:
#333333
;
}
.learn-view-title
{
.line-view
{
font-size
:
32rpx
;
background-color
:
#f4f5f7
;
font-weight
:
bold
;
height
:
2rpx
;
margin-bottom
:
10rpx
;
width
:
100%
;
}
}
.learn-list
{
}
.learn-list-item
{
}
font-size
:
28rpx
;
margin-top
:
30rpx
;
margin-bottom
:
30rpx
;
color
:
#333333
;
}
.line-view
{
.u-content
{
background-color
:
#f4f5f7
;
// margin-top: 10rpx;
height
:
2rpx
;
padding
:
40rpx
30rpx
;
width
:
100%
;
margin-bottom
:
20rpx
;
}
}
}
}
</
style
>
</
style
>
src/pages/order/detail.vue
View file @
8b91f718
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
<view
class=
"card base-item"
>
<view
class=
"card base-item"
>
<view
class=
"top-item"
>
<view
class=
"top-item"
>
<view
class=
"left"
>
<view
class=
"left"
>
<view
class=
"tag
"
>
{{
order
.
orderServiceType
}}
</view>
<view
:class=
"['tag',
{'active': order.orderServiceType == '安装'}]
">
{{
order
.
orderServiceType
}}
</view>
<text
class=
"title"
>
{{
order
.
categoryName
}}
</text>
<text
class=
"title"
>
{{
order
.
categoryName
}}
</text>
</view>
</view>
<view
class=
"right"
>
{{
order
.
orderBusinessTypeText
}}
</view>
<view
class=
"right"
>
{{
order
.
orderBusinessTypeText
}}
</view>
...
@@ -23,7 +23,7 @@
...
@@ -23,7 +23,7 @@
<text>
客户信息:
</text>
<text>
客户信息:
</text>
<text>
{{
order
.
contactName
}}
</text>
<text>
{{
order
.
contactName
}}
</text>
</view>
</view>
<u-image
width=
"
60rpx"
height=
"60rpx"
:src=
"phoneIcon"
></u-image>
<u-image
width=
"
48rpx"
height=
"48rpx"
:src=
"phoneIcon"
@
click=
"phoneToCustomer(order.contactPhone)"
></u-image>
</view>
</view>
<view
class=
"order-cell"
>
<view
class=
"order-cell"
>
<text>
联系方式:
</text>
<text>
联系方式:
</text>
...
@@ -34,52 +34,74 @@
...
@@ -34,52 +34,74 @@
<u-icon
name=
"map"
size=
"28"
></u-icon>
<u-icon
name=
"map"
size=
"28"
></u-icon>
<text
class=
"address-txt"
>
{{
order
.
contactAddress
}}
</text>
<text
class=
"address-txt"
>
{{
order
.
contactAddress
}}
</text>
</view>
</view>
<u-image
width=
"
60rpx"
height=
"60rpx"
:src=
"navigationIc
on"
></u-image>
<u-image
width=
"
48rpx"
height=
"48rpx"
:src=
"navigationIcon"
@
click=
"openLocati
on"
></u-image>
</view>
</view>
<!--
<u-read-more
ref=
"uReadMore"
:show-height=
"40"
:shadowStyle=
"
{paddingTop: '0rpx',marginTop: '0rpx'}" close-text="查看更多" open-text="点击收起" toggle color="#2272FF" font-size="26"> -->
<view
v-if=
"readMore"
@
click=
"readMore = false"
class=
"read-more-toggle"
>
<u-icon
name=
"arrow-down"
></u-icon>
<text
class=
"read-more-text"
>
查看更多
</text>
</view>
<view
v-else
class=
"order-item-more"
>
<view
class=
"line-view"
></view>
<view
class=
"order-cell between-cell"
>
<text>
品牌:
</text>
<text>
{{
order
.
brandName
}}
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
数量:
</text>
<text>
x
{{
order
.
orderProductCount
}}
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
信息:
</text>
<text>
{{
order
.
serviceContent
}}
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
备注:
</text>
<text>
{{
order
.
serviceContent
}}
</text>
</view>
<view
class=
"read-more-toggle"
>
<u-icon
name=
"arrow-up"
></u-icon>
<text
class=
"read-more-text"
@
click=
"readMore = true"
>
点击收起
</text>
</view>
</view>
<!--
</u-read-more>
-->
</view>
</view>
<view
class=
"card order-item"
>
<view
class=
"card appoint-item"
v-show=
"showTimeSelect"
>
<view
class=
"top-item"
>
<appoint-time
@
dateChange=
"dateChange"
@
timeChange=
"timeChange"
@
weekChange=
"weekChange"
></appoint-time>
<text
class=
"title"
>
订单内容
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
品牌:
</text>
<text>
{{
order
.
brandName
}}
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
数量:
</text>
<text>
x
{{
order
.
orderProductCount
}}
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
信息:
</text>
<text>
{{
order
.
serviceContent
}}
</text>
</view>
<view
class=
"order-cell between-cell"
>
<text>
备注:
</text>
<text>
{{
order
.
serviceContent
}}
</text>
</view>
</view>
</view>
<view
class=
"card order-item record-item"
>
<view
class=
"card order-item record-item"
>
<view
class=
"top-item"
>
<view
class=
"top-item"
>
<text
class=
"title"
>
履约记录
</text>
<text
class=
"title"
>
履约记录
</text>
</view>
</view>
<view
class=
"order"
v-for=
"(record,index) in orderRecords"
:key=
"record.operationContent"
>
<view
v-if=
"orderRecords.length == 0"
class=
"no-record-view"
>
当前暂无履约记录
</view>
<view
class=
"order-cell between-cell"
>
<view
v-else
>
<text>
{{
record
.
operationType
}}
</text>
<view
class=
"order"
v-for=
"(record,index) in shwoOrderRecords"
:key=
"record.operationContent"
>
<text>
{{
$u
.
timeFormat
(
record
.
operationDatetime
,
'yyyy-mm-dd hh:MM:ss'
)
}}
</text>
<view
class=
"order-cell between-cell"
>
<text
style=
"color: red;"
>
{{
record
.
overTime
?
''
:
'超时 '
}}{{
record
.
exception
?
''
:
' 异常'
}}
</text>
<text>
{{
record
.
operationType
}}
</text>
<text>
{{
$u
.
timeFormat
(
record
.
operationDatetime
,
'yyyy-mm-dd hh:MM:ss'
)
}}
</text>
<text
style=
"color: red;"
>
{{
record
.
overTime
?
''
:
'超时 '
}}{{
record
.
exception
?
''
:
' 异常'
}}
</text>
</view>
</view>
</view>
<view
v-if=
"orderRecords.length > showLenght"
>
<view
v-if=
"readMoreRecord"
@
click=
"readMoreRecord = false"
class=
"read-more-toggle"
>
<u-icon
name=
"arrow-down"
></u-icon>
<text
class=
"read-more-text"
>
查看更多
</text>
</view>
<view
v-else
class=
"read-more-toggle"
>
<u-icon
name=
"arrow-up"
></u-icon>
<text
class=
"read-more-text"
@
click=
"readMoreRecord = true"
>
点击收起
</text>
</view>
</view>
<view
v-else
style=
"height: 10rpx;"
></view>
</view>
</view>
</view>
</view>
<view
class=
"card appoint-item"
v-show=
"showTimeSelect"
>
<appoint-time
@
dateChange=
"dateChange"
@
timeChange=
"timeChange"
@
weekChange=
"weekChange"
></appoint-time>
</view>
</view>
</view>
<view
class=
"toolbar"
>
<view
class=
"toolbar"
>
<!-- 背景,内容,请求接口 根据状态不同改变
{{
operationDoing
[
order
.
orderStatus
].
background
}}
-->
<!-- 背景,内容,请求接口 根据状态不同改变
{{
operationDoing
[
order
.
orderStatus
].
background
}}
-->
<!-- 过程反馈 -->
<!-- 过程反馈 -->
<view
class=
"left"
>
<view
class=
"left"
>
<view
v-show=
"allowFeedback"
@
click=
"clickFeedback"
class=
"button"
>
<view
v-show=
"allowFeedback"
@
click=
"clickFeedback"
class=
"button"
>
过程反馈
<text>
过程反馈
</text>
</view>
</view>
</view>
</view>
<!--接单,抢单,已被抢, 预约 ,签到 ,去完工 timestampDiff(order.currentOverTime)>0 -->
<!--接单,抢单,已被抢, 预约 ,签到 ,去完工 timestampDiff(order.currentOverTime)>0 -->
...
@@ -87,27 +109,29 @@
...
@@ -87,27 +109,29 @@
<view>
<view>
<u-toast
ref=
"uToast"
/>
<u-toast
ref=
"uToast"
/>
</view>
</view>
<view
v-if=
"showCenterBtn"
@
click=
"handleBtn"
class=
"button"
:class=
"btnClass"
>
<view
v-if=
"showCenterBtn"
@
click=
"handleBtn"
class=
"button"
:class=
"['center-button-view', btnClass]"
>
{{
centerButtonText
}}
<text>
{{
centerButtonText
}}
抢单
</text>
<view
v-if=
"order.currentOverTime > 0"
class=
"time-view"
>
<text>
{{
order
.
currentOverTime
*
1000
>
new
Date
().
getTime
()?
'剩'
:
'超'
}}
</text>
<u-count-down
:timestamp=
"timestampDiff(order.currentOverTime)"
font-size=
"20"
color=
"#FFFFFF"
bg-color=
"transparent"
separator-color=
"#FFFFFF"
separator-size=
"20"
:ref=
"'uCountDown'"
@
change=
"timeOutChange(order.currentOverTime)"
>
</u-count-down>
</view>
</view>
</view>
<view
v-show=
"order.currentOverTime > 0"
>
<view
class=
"tag"
>
{{
order
.
currentOverTime
*
1000
>
new
Date
().
getTime
()?
'剩'
:
'超'
}}
</view>
<u-count-down
:timestamp=
"timestampDiff(order.currentOverTime)"
font-size=
"30"
:ref=
"'uCountDown'"
@
change=
"timeOutChange(order.currentOverTime)"
>
</u-count-down>
</view>
</view>
</view>
<!-- 异常预约 ,现场拍照 这里是调用拍照的两个组件-->
<!-- 异常预约 ,现场拍照 这里是调用拍照的两个组件-->
<view
class=
"right"
>
<view
class=
"right"
>
<view
v-if=
"errorSignIn"
@
click=
"take"
class=
"button"
>
<view
v-if=
"errorSignIn || scenePhoto"
@
click=
"$u.debounce(handleClickRight, 500)"
:class=
"['button',
{'active': scenePhoto}]">
<text>
异常签到
</text>
<text>
{{
errorSignIn
?
'异常签到'
:
'现场拍照'
}}
</text>
</view>
<view
v-if=
"scenePhoto"
@
click=
"scenePhotoClick"
class=
"button"
>
<text>
现场拍照
</text>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -128,6 +152,9 @@
...
@@ -128,6 +152,9 @@
},
},
data
()
{
data
()
{
return
{
return
{
readMore
:
true
,
readMoreRecord
:
true
,
showLenght
:
5
,
background
:
{
background
:
{
backgroundColor
:
'none'
,
backgroundColor
:
'none'
,
// 导航栏背景图
// 导航栏背景图
...
@@ -146,14 +173,17 @@
...
@@ -146,14 +173,17 @@
centerButtonText
:
''
,
centerButtonText
:
''
,
orderRecords
:
[],
orderRecords
:
[],
method
:
null
,
method
:
null
,
showCenterBtn
:
fals
e
,
showCenterBtn
:
tru
e
,
showTimeSelect
:
false
,
showTimeSelect
:
false
,
submitType
:
''
,
submitType
:
''
,
nextUrl
:
''
,
nextUrl
:
''
,
btnClass
:
'appoint-btn'
,
btnClass
:
'appoint-btn'
,
takeStatus
:
false
,
takeStatus
:
false
,
errorSignIn
:
false
,
errorSignIn
:
false
,
scenePhoto
:
true
scenePhoto
:
true
,
isErrorSign
:
false
,
errorSignUrl
:
''
,
isAllowDianhuaAndDaohang
:
false
}
}
},
},
onLoad
(
option
)
{
onLoad
(
option
)
{
...
@@ -164,23 +194,85 @@
...
@@ -164,23 +194,85 @@
}
else
{
}
else
{
// 异常处理
// 异常处理
}
}
this
.
orderId
=
'8371315'
this
.
loadOrderDetail
()
this
.
loadOrderDetail
()
this
.
loadOrderRecord
()
this
.
loadOrderRecord
()
this
.
getLocation
()
this
.
getLocation
()
},
},
computed
:
{
computed
:
{
phoneIcon
()
{
phoneIcon
()
{
return
process
.
uniEnv
.
qn_base_url
+
'icon/dianhua-1@2x.png'
//self-support/icon/dianhua-0@2x.png
if
(
this
.
isAllowDianhuaAndDaohang
){
return
process
.
uniEnv
.
qn_base_url
+
'dianhua-1.png'
}
else
{
return
process
.
uniEnv
.
qn_base_url
+
'dianhua-0.png'
}
},
},
navigationIcon
()
{
navigationIcon
()
{
return
process
.
uniEnv
.
qn_base_url
+
'icon/daohang-1@2x.png'
//self-support/icon/daohang-0@2x.png
if
(
this
.
isAllowDianhuaAndDaohang
){
return
process
.
uniEnv
.
qn_base_url
+
'daohang-1.png'
}
else
{
return
process
.
uniEnv
.
qn_base_url
+
'daohang-0.png'
}
},
},
centerButtonClass
()
{
centerButtonClass
()
{
let
btnClass
=
"appoint-btn"
let
btnClass
=
"appoint-btn"
return
btnClass
return
btnClass
},
shwoOrderRecords
()
{
if
(
this
.
readMoreRecord
)
{
return
this
.
orderRecords
.
slice
(
0
,
5
)
}
else
{
return
this
.
orderRecords
}
}
}
},
},
methods
:
{
methods
:
{
openLocation
(){
if
(
this
.
isAllowDianhuaAndDaohang
){
uni
.
getLocation
({
type
:
'gcj02'
,
//返回可以用于uni.openLocation的经纬度
success
:
function
(
res
)
{
const
latitude
=
res
.
latitude
;
const
longitude
=
res
.
longitude
;
uni
.
openLocation
({
latitude
:
latitude
,
longitude
:
longitude
,
success
:
function
()
{
console
.
log
(
'success'
);
}
});
}
});
}
},
phoneToCustomer
(
phone
){
// 联系客户
if
(
this
.
isAllowDianhuaAndDaohang
){
uni
.
makePhoneCall
({
phoneNumber
:
phone
,
//仅为示例
complete
()
{
}
});
this
.
contactTime
()
}
},
contactTime
()
{
let
self
=
this
var
data
=
{}
self
.
$u
.
api
.
contactTime
(
data
,
this
.
order
.
orderId
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
console
.
log
(
"==="
,
res
.
data
)
}
else
{
console
.
log
(
res
.
message
);
}
})
},
handleClickRight
(
active
)
{
this
.
scenePhoto
?
this
.
scenePhotoClick
()
:
this
.
take
()
},
scenePhotoClick
()
{
// 跳转拍照小程序
scenePhotoClick
()
{
// 跳转拍照小程序
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
'pages/photo/list?orderId='
+
this
.
order
.
orderId
+
'&brandId='
+
this
.
order
.
lianbaoBrandId
+
'&brand='
+
this
.
order
.
brandName
url
:
'pages/photo/list?orderId='
+
this
.
order
.
orderId
+
'&brandId='
+
this
.
order
.
lianbaoBrandId
+
'&brand='
+
this
.
order
.
brandName
...
@@ -192,22 +284,16 @@
...
@@ -192,22 +284,16 @@
this
.
takeStatus
=
true
this
.
takeStatus
=
true
},
},
closeTake
(
img
)
{
closeTake
(
img
)
{
console
.
log
(
img
)
this
.
takeStatus
=
false
this
.
takeStatus
=
false
// 获取返回的图片 ,如果返回的图片存在则直接异常签约,成功后跳转到去完工页面,
// 获取返回的图片 ,如果返回的图片存在则直接异常签约,成功后跳转到去完工页面,
if
(
img
){
// 拍照完成
if
(
img
){
// 拍照完成
this
.
$refs
.
uToast
.
show
({
this
.
isErrorSign
=
true
title
:
'签到成功'
,
this
.
errorSignUrl
=
img
type
:
'success'
,
this
.
handleBtn
()
url
:
'pages/order/detail'
,
params
:
{
id
:
1
}
})
}
else
{
}
else
{
this
.
$refs
.
uToast
.
show
({
this
.
$refs
.
uToast
.
show
({
title
:
'异常签到失败,请先按要求拍照'
,
title
:
'异常签到失败,请先按要求拍照'
,
type
:
'waning'
type
:
'wa
r
ning'
})
})
}
}
},
},
...
@@ -222,14 +308,8 @@
...
@@ -222,14 +308,8 @@
console
.
log
(
"==="
,
res
.
data
)
console
.
log
(
"==="
,
res
.
data
)
self
.
order
=
res
.
data
self
.
order
=
res
.
data
this
.
getCurrentBtn
()
this
.
getCurrentBtn
()
this
.
visibale
=
true
if
(
self
.
order
.
isFirstOrder
){
// self.order.operationType = "accept"
}
// }else{
// self.order.operationType = "appointment"
// }
// self.method =self.operationDoing[self.order.operationType].action;
// // 根据工单的状态确定是否需要过程反馈
// self.allowFeedback = self.allowFeedbackStatus.indexOf(self.order.orderStatus)>0
}
else
{
}
else
{
console
.
log
(
res
.
message
,
"获取订单详情失败!"
);
console
.
log
(
res
.
message
,
"获取订单详情失败!"
);
}
}
...
@@ -238,7 +318,7 @@
...
@@ -238,7 +318,7 @@
loadOrderRecord
()
{
loadOrderRecord
()
{
let
self
=
this
let
self
=
this
var
param
=
{
var
param
=
{
'orderId'
:
self
.
orderId
orderId
:
self
.
orderId
};
};
self
.
$u
.
api
.
listOrderRecord
(
param
).
then
((
res
)
=>
{
self
.
$u
.
api
.
listOrderRecord
(
param
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
if
(
res
.
code
==
200
)
{
...
@@ -248,9 +328,6 @@
...
@@ -248,9 +328,6 @@
}
}
})
})
},
},
rejectOrder
()
{
// 拒单
console
.
log
(
"点击拒单"
)
},
/**
/**
* 点击下一周
* 点击下一周
* @param {Object} data
* @param {Object} data
...
@@ -297,6 +374,7 @@
...
@@ -297,6 +374,7 @@
this
.
allowFeedback
=
true
this
.
allowFeedback
=
true
this
.
showCenterBtn
=
true
this
.
showCenterBtn
=
true
this
.
showTimeSelect
=
true
this
.
showTimeSelect
=
true
this
.
isAllowDianhuaAndDaohang
=
true
this
.
submitType
=
"workerAppointment"
this
.
submitType
=
"workerAppointment"
}
else
if
(
orderStatus
===
31
&&
this
.
order
.
appointmentDatetime
)
{
}
else
if
(
orderStatus
===
31
&&
this
.
order
.
appointmentDatetime
)
{
// 签到
// 签到
...
@@ -310,36 +388,44 @@
...
@@ -310,36 +388,44 @@
// 完工
// 完工
this
.
centerButton
=
"filish"
this
.
centerButton
=
"filish"
this
.
centerButtonText
=
"去完工"
this
.
centerButtonText
=
"去完工"
this
.
submitType
=
"toFilish"
this
.
allowFeedback
=
true
this
.
allowFeedback
=
true
this
.
showCenterBtn
=
true
this
.
showCenterBtn
=
true
this
.
scenePhoto
=
true
this
.
scenePhoto
=
true
}
else
{}
}
else
{}
},
},
handleBtn
()
{
handleBtn
()
{
if
(
this
.
centerButton
===
"filish"
){
this
.
filish
()
return
}
if
(
!
this
.
submitType
){
if
(
!
this
.
submitType
){
return
;
return
;
}
}
const
data
=
{}
const
data
=
{}
// 不同请求类型传递不同数据
// 不同请求类型传递不同数据
if
(
this
.
submitType
===
'maintainWorkerCheckin'
)
{
// 签到
if
(
this
.
submitType
===
'orderAccept'
){
// 接单
// 检查见到距离是否符合
if
(
this
.
getDistance
(
this
.
order
.
contactAddressLatitud
,
this
.
order
.
contactAddressLongitud
)
>
3
){
this
.
$refs
.
uToast
.
show
({
title
:
'签到失败,请点击异常签到处理或联系客服'
,
type
:
'error'
})
return
}
data
.
remark
=
"123"
data
.
revert
=
true
}
else
if
(
this
.
submitType
===
'orderAccept'
){
// 接单
data
.
orderId
=
this
.
order
.
orderId
data
.
orderId
=
this
.
order
.
orderId
}
else
if
(
this
.
submitType
===
'orderGan'
){
// 抢单
}
else
if
(
this
.
submitType
===
'orderGan'
){
// 抢单
data
.
orderId
=
this
.
order
.
orderId
data
.
orderId
=
this
.
order
.
orderId
}
else
if
(
this
.
submitType
===
'workerAppointment'
){
// 预约
data
.
appointmentDatetime
=
''
data
.
appointmentDatetimeRange
=
''
if
(
!
data
.
appointmentDatetime
||
!
data
.
appointmentDatetimeRange
){
this
.
commonToast
(
'请选择预约时间和时间段'
,
'waring'
)
return
}
}
else
if
(
this
.
submitType
===
'maintainWorkerCheckin'
)
{
// 签到
// 检查见到距离是否符合
if
(
!
this
.
isErrorSign
){
if
(
this
.
getDistance
(
this
.
order
.
contactAddressLatitud
,
this
.
order
.
contactAddressLongitud
)
>
3
){
this
.
commonToast
(
'签到失败,请点击异常签到处理或联系客服'
,
'error'
)
return
}
}
data
.
exception
=
this
.
isErrorSign
data
.
coordinate
=
this
.
dataValue
?
this
.
dataValue
[
0
]
+
','
+
this
.
dataValue
[
1
]:
''
data
.
url
=
this
.
errorSignUrl
?
this
.
errorSignUrl
:
''
}
else
if
(
this
.
submitType
===
'toFilish'
){
// 去完工
this
.
filish
()
return
}
}
this
.
$u
.
api
[
this
.
submitType
](
data
,
this
.
order
.
orderId
).
then
(
res
=>
{
this
.
$u
.
api
[
this
.
submitType
](
data
,
this
.
order
.
orderId
).
then
(
res
=>
{
if
((
res
.
data
.
code
!==
undefined
&&
res
.
data
.
code
===
200
)
if
((
res
.
data
.
code
!==
undefined
&&
res
.
data
.
code
===
200
)
...
@@ -349,8 +435,7 @@
...
@@ -349,8 +435,7 @@
type
:
'success'
,
type
:
'success'
,
url
:
'pages/order/detail'
,
url
:
'pages/order/detail'
,
params
:
{
params
:
{
id
:
1
,
id
:
this
.
order
.
orderId
menu
:
2
}
}
})
})
}
else
{
}
else
{
...
@@ -363,6 +448,14 @@
...
@@ -363,6 +448,14 @@
}
}
})
})
},
},
commonToast
(
message
,
type
,
url
,
params
){
// 统一得toast
this
.
$refs
.
uToast
.
show
({
title
:
message
,
type
:
type
,
url
:
url
,
params
:
params
})
},
isGan
(){
isGan
(){
this
.
centerButtonText
=
"已被抢"
this
.
centerButtonText
=
"已被抢"
this
.
submitType
=
""
this
.
submitType
=
""
...
@@ -382,6 +475,17 @@
...
@@ -382,6 +475,17 @@
+
"&orderServiceType="
+
this
.
order
.
orderServiceType
+
"&orderServiceType="
+
this
.
order
.
orderServiceType
})
})
},
},
rejectOrder
()
{
// 拒单
// 检查是否可以拒单
var
data
=
{}
this
.
$u
.
api
.
checkRejectable
(
data
).
then
(
res
=>
{
if
(
res
.
data
.
code
===
200
&&
res
.
data
.
data
===
true
)
{
uni
.
navigateTo
({
url
:
'pages/order/refuse?orderId='
+
this
.
order
.
orderId
})
}
})
},
/**
/**
* 获取当前位置的经纬度
* 获取当前位置的经纬度
*/
*/
...
@@ -443,13 +547,14 @@
...
@@ -443,13 +547,14 @@
this
.
btnClass
=
'timeOut-btn'
this
.
btnClass
=
'timeOut-btn'
self
.
$refs
[
'uCountDown'
].
seconds
+=
2
self
.
$refs
[
'uCountDown'
].
seconds
+=
2
}
}
},
handleClick
(){
},
handleClick
(){
this
.
visibale
=
false
this
.
visibale
=
false
// 去完工
// 去完工
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
'pages/photo/list'
url
:
'pages/photo/list'
})
})
}
}
}
}
};
};
</
script
>
</
script
>
...
@@ -460,52 +565,57 @@
...
@@ -460,52 +565,57 @@
height
:
100vh
;
height
:
100vh
;
overflow
:
auto
;
overflow
:
auto
;
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
background-image
:
linear-gradient
(
to
top
,
#F4F5F7
,
#2272FF
);
background-image
:
linear-gradient
(
to
top
,
#F4F5F7
0%
,
#2272FF
50%
);
background-size
:
750rpx
600rpx
;
background-size
:
750rpx
600rpx
;
background-repeat
:
no-repeat
;
background-repeat
:
no-repeat
;
display
:
flex
;
flex-direction
:
column
;
.header
{
.header
{
padding
:
12rpx
30rpx
40
rpx
30rpx
;
padding
:
30rpx
30rpx
46
rpx
30rpx
;
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
align-items
:
center
;
align-items
:
center
;
.title
{
.title
{
font-size
:
40rpx
;
line-height
:
40rpx
;
font-
weight
:
bold
;
font-
size
:
40rpx
;
color
:
#FFFFFF
;
color
:
#fff
;
}
}
.button
{
.button
{
text-align
:
center
;
text-align
:
center
;
width
:
106rpx
;
width
:
106rpx
;
height
:
52rpx
;
height
:
52rpx
;
background
:
#FFFFFF
;
border-radius
:
40rpx
;
border-radius
:
40rpx
;
font-size
:
24rpx
;
font-size
:
24rpx
;
font-weight
:
400
;
font-weight
:
400
;
color
:
#2272FF
;
line-height
:
52rpx
;
line-height
:
52rpx
;
color
:
#DEDEDE
;
}
}
}
}
.content
{
.content
{
height
:
2000rpx
;
height
:
100%
;
border-radius
:
12rpx
;
overflow
:
auto
;
margin-right
:
30rpx
;
margin-left
:
30rpx
;
.card
{
.card
{
background-color
:
#FFFFFF
;
background-color
:
#FFFFFF
;
margin
:
0
30rpx
20rpx
3
0rpx
;
margin
-bottom
:
2
0rpx
;
padding
:
30rpx
30rpx
0
30rpx
;
padding
:
30rpx
30rpx
0
30rpx
;
border-radius
:
6px
;
border-radius
:
6px
;
}
}
.base-item
{
.base-item
{
padding-bottom
:
3
6rpx
;
padding-bottom
:
6rpx
;
.top-item
{
.top-item
{
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
margin-bottom
:
2
0rpx
;
margin-bottom
:
3
0rpx
;
.left
{
.left
{
display
:
flex
;
display
:
flex
;
...
@@ -515,16 +625,20 @@
...
@@ -515,16 +625,20 @@
text-align
:
center
;
text-align
:
center
;
width
:
84rpx
;
width
:
84rpx
;
height
:
40rpx
;
height
:
40rpx
;
background-image
:
linear-gradient
(
270deg
,
#47ABFF
0%
,
#2272FF
100%
);
border-radius
:
8rpx
;
border-radius
:
8rpx
;
font-size
:
22rpx
;
font-size
:
22rpx
;
font-weight
:
500
;
font-weight
:
500
;
color
:
#FFFFFF
;
color
:
#FFFFFF
;
line-height
:
40rpx
;
line-height
:
40rpx
;
background-image
:
linear-gradient
(
to
right
,
#FF930D
,
#FFC174
);
&
.active
{
background-image
:
linear-gradient
(
to
right
,
#2272FF
,
#47ABFF
);
}
}
}
.title
{
.title
{
margin-left
:
3
0rpx
;
margin-left
:
2
0rpx
;
height
:
36rpx
;
height
:
36rpx
;
font-size
:
36rpx
;
font-size
:
36rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
...
@@ -552,7 +666,8 @@
...
@@ -552,7 +666,8 @@
font-weight
:
400
;
font-weight
:
400
;
color
:
#333333
;
color
:
#333333
;
line-height
:
24rpx
;
line-height
:
24rpx
;
margin-top
:
20rpx
;
margin-bottom
:
40rpx
;
.left
{
.left
{
.address-txt
{
.address-txt
{
margin-left
:
8rpx
;
margin-left
:
8rpx
;
...
@@ -560,9 +675,33 @@
...
@@ -560,9 +675,33 @@
}
}
}
}
}
}
.read-more-toggle
{
text-align
:
center
;
color
:
#2272FF
;
font-size
:
26rpx
;
margin-top
:
30rpx
;
padding-bottom
:
30rpx
;
}
.read-more-text
{
padding-left
:
8rpx
;
}
.order-item-more
{
font-size
:
26rpx
;
color
:
#333333
;
.line-view
{
background-color
:
#F4F5F7
;
height
:
2rpx
;
margin-bottom
:
20rpx
;
}
}
.order-item
{
.order-item
{
padding-bottom
:
34
rpx
;
padding-bottom
:
6
rpx
;
.top-item
{
.top-item
{
display
:
flex
;
display
:
flex
;
...
@@ -570,12 +709,19 @@
...
@@ -570,12 +709,19 @@
margin-bottom
:
20rpx
;
margin-bottom
:
20rpx
;
.title
{
.title
{
height
:
3
6
rpx
;
height
:
3
2
rpx
;
font-size
:
3
6
rpx
;
font-size
:
3
2
rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
color
:
#333333
;
color
:
#333333
;
line-height
:
36rpx
;
line-height
:
36rpx
;
}
}
}
.no-record-view
{
font-size
:
26rpx
;
color
:
#333333
;
margin-top
:
30rpx
;
}
}
.address-cell
{
.address-cell
{
...
@@ -593,7 +739,9 @@
...
@@ -593,7 +739,9 @@
}
}
}
}
.record-item
{}
.record-item
{
margin-bottom
:
0rpx
;
}
.appoint-item
{
.appoint-item
{
padding
:
0
;
padding
:
0
;
...
@@ -601,7 +749,8 @@
...
@@ -601,7 +749,8 @@
}
}
.toolbar
{
.toolbar
{
margin-bottom
:
104rpx
;
margin-top
:
30rpx
;
margin-bottom
:
44rpx
;
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
align-items
:
center
;
align-items
:
center
;
...
@@ -615,10 +764,13 @@
...
@@ -615,10 +764,13 @@
height
:
100rpx
;
height
:
100rpx
;
background
:
#929CB8
;
background
:
#929CB8
;
border-radius
:
100rpx
;
border-radius
:
100rpx
;
font-size
:
25rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
align-items
:
center
;
display
:
flex
;
display
:
flex
;
text-align
:
center
;
align-items
:
center
;
justify-content
:
center
;
font-size
:
20rpx
;
color
:
#FFFFFF
;
}
}
}
}
...
@@ -628,16 +780,23 @@
...
@@ -628,16 +780,23 @@
margin-left
:
74rpx
;
margin-left
:
74rpx
;
margin-right
:
74rpx
;
margin-right
:
74rpx
;
.
button
{
.
center-button-view
{
width
:
140rpx
;
width
:
140rpx
;
height
:
140rpx
;
height
:
140rpx
;
border-radius
:
100rpx
;
border-radius
:
100rpx
;
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
align-items
:
center
;
align-items
:
center
;
flex-direction
:
column
;
color
:
#FFFFFF
;
color
:
#FFFFFF
;
font-size
:
32rpx
;
font-size
:
32rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
.time-view
{
display
:
flex
;
font-size
:
20rpx
;
color
:
#FFFFFF
;
}
}
}
.appoint-btn
{
.appoint-btn
{
...
@@ -646,13 +805,13 @@
...
@@ -646,13 +805,13 @@
}
}
.isGan-btn
{
.isGan-btn
{
background
:
#
93a7a6
;
background
:
#
D1D4D4
;
box-shadow
:
2px
2px
20px
0px
rgba
(
34
,
114
,
255
,
0
.3
);
box-shadow
:
2px
2px
20px
0px
rgba
(
181
,
181
,
181
,
0
.3
);
}
}
.timeOut-btn
{
.timeOut-btn
{
background
:
#
ff0000
;
background
:
#
e86552
;
box-shadow
:
2px
2px
20px
0px
rgba
(
34
,
114
,
255
,
0
.3
);
box-shadow
:
2px
2px
20px
0px
rgba
(
232
,
101
,
82
,
0
.3
);
}
}
}
}
...
@@ -663,12 +822,17 @@
...
@@ -663,12 +822,17 @@
.button
{
.button
{
width
:
100rpx
;
width
:
100rpx
;
height
:
100rpx
;
height
:
100rpx
;
background
:
#
d99100
;
background
:
#
FF930D
;
border-radius
:
100rpx
;
border-radius
:
100rpx
;
font-size
:
2
5
rpx
;
font-size
:
2
0
rpx
;
font-weight
:
bold
;
font-weight
:
bold
;
align-items
:
center
;
align-items
:
center
;
display
:
flex
;
display
:
flex
;
color
:
#FFFFFF
;
justify-content
:
center
;
&
.active
{
background-color
:
#D1D4D4
;
}
}
}
}
}
}
}
...
@@ -681,7 +845,8 @@
...
@@ -681,7 +845,8 @@
font-weight
:
400
;
font-weight
:
400
;
color
:
#333333
;
color
:
#333333
;
line-height
:
48rpx
;
line-height
:
48rpx
;
margin-bottom
:
30rpx
;
margin-bottom
:
10rpx
;
text-align
:
left
;
}
}
.between-cell
{
.between-cell
{
...
...
src/pages/order/feedback.vue
View file @
8b91f718
...
@@ -20,14 +20,15 @@
...
@@ -20,14 +20,15 @@
<u-tabs
<u-tabs
:list=
"tabList"
:list=
"tabList"
:current=
"curTab"
:current=
"curTab"
height=
"
8
0"
height=
"
6
0"
gutter=
"89"
gutter=
"89"
bar-height=
"4"
bar-height=
"4"
bar-width=
"44"
bar-width=
"44"
bg-color=
"none"
bg-color=
"none"
active-color=
"#FFFFFF"
active-color=
"#FFFFFF"
inactive-color=
"#
FFFFFF
"
inactive-color=
"#
DEDEDE
"
font-size=
"32"
font-size=
"32"
bold
@
change=
"changeTab"
@
change=
"changeTab"
></u-tabs>
></u-tabs>
</view>
</view>
...
@@ -35,6 +36,7 @@
...
@@ -35,6 +36,7 @@
<!--
<view
class=
"con-box"
>
<!--
<view
class=
"con-box"
>
</view>
-->
</view>
-->
<view
class=
"content-view"
>
<view
class=
"con-box"
>
<view
class=
"con-box"
>
<view
class=
"title"
>
{{
feedback
.
own
.
title
}}
</view>
<view
class=
"title"
>
{{
feedback
.
own
.
title
}}
</view>
<view
class=
"u-flex u-flex-wrap"
>
<view
class=
"u-flex u-flex-wrap"
>
...
@@ -43,7 +45,7 @@
...
@@ -43,7 +45,7 @@
:key=
"index"
:key=
"index"
@
click=
"changeOwn(index)"
@
click=
"changeOwn(index)"
:class=
"
{'txt-item':true,'active': (trace.reasonRelegation == index)}">
:class=
"
{'txt-item':true,'active': (trace.reasonRelegation == index)}">
<text
class=
"txt"
>
{{
i
ndex
}}
</text>
<text
class=
"txt"
>
{{
i
tem
}}
</text>
</view>
</view>
</view>
</view>
<u-gap
height=
"30"
></u-gap>
<u-gap
height=
"30"
></u-gap>
...
@@ -53,21 +55,27 @@
...
@@ -53,21 +55,27 @@
v-for=
"(txt, index) in options[curTab][trace.reasonRelegation]"
v-for=
"(txt, index) in options[curTab][trace.reasonRelegation]"
:key=
"index"
:key=
"index"
@
click=
"changeType(txt)"
@
click=
"changeType(txt)"
:class=
"
{'txt-item':true,'active': (trace.reason == txt)}">
:class=
"
{'txt-item':true,'active': (trace.reason == txt)}"
style="width: 306rpx;margin-right: 18rpx"
>
<text
class=
"txt"
>
{{
txt
}}
</text>
<text
class=
"txt"
>
{{
txt
}}
</text>
</view>
</view>
</view>
</view>
<u-input
v-show=
"showRemark"
v-model=
"trace.remark"
class=
"textarea"
height=
"156"
type=
"textarea"
placeholder=
"请补充详细说明,以便于记录您的接单信用分"
></u-input>
<view
class=
"input-view"
v-show=
"showRemark"
>
<u-input
v-model=
"trace.remark"
class=
"textarea"
height=
"156"
type=
"textarea"
placeholder=
"请补充详细说明,以便于记录您的接单信用分"
></u-input>
</view>
</view>
<view
class=
"time-view"
>
<appoint-time
:dateList=
"dateList"
:title=
"appointTitle"
:timeList=
"timeList"
@
dateChange=
"dateChange"
@
timeChange=
"timeChange"
@
weekChange=
"weekChange"
></appoint-time>
</view>
</view>
</view>
<appoint-time
@
dateChange=
"dateChange"
@
timeChange=
"timeChange"
@
weekChange=
"weekChange"
></appoint-time>
</view>
</view>
<view
class=
"
u-m-60
"
>
<view
class=
"
bottom-view
"
>
<button
class=
"btn
"
@
click=
"submitForm"
:loading=
"submiting"
:disabled=
"disabledSubmit"
>
确定
</button>
<button
class=
"btn
, bottom-btn"
@
click=
"submitForm"
:loading=
"submiting"
:disabled=
"disabledSubmit"
><text
class=
"button-text"
>
确定
</text>
</button>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
let
now
=
Date
.
now
()
import
appointTime
from
'@/components/appoint/appoint-time.vue'
import
appointTime
from
'@/components/appoint/appoint-time.vue'
export
default
{
export
default
{
data
()
{
data
()
{
...
@@ -76,6 +84,26 @@
...
@@ -76,6 +84,26 @@
categoryId
:
null
,
categoryId
:
null
,
showRemark
:
false
,
showRemark
:
false
,
submiting
:
false
,
submiting
:
false
,
dateList
:
[
{
day
:
now
,
timeRange
:
[]},
{
day
:
now
+
(
1
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
2
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
3
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
4
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
5
*
86400000
),
timeRange
:
[]},
{
day
:
now
+
(
6
*
86400000
),
timeRange
:
[]},
],
timeList
:
[
{
"name"
:
"06:00-08:00"
,
"pkey"
:
"appointment_range_8"
,
"disabled"
:
false
},
{
"name"
:
"08:00-10:00"
,
"pkey"
:
"appointment_range_10"
,
"disabled"
:
false
},
{
"name"
:
"10:00-12:00"
,
"pkey"
:
"appointment_range_12"
,
"disabled"
:
false
},
{
"name"
:
"12:00-14:00"
,
"pkey"
:
"appointment_range_14"
,
"disabled"
:
false
},
{
"name"
:
"14:00-16:00"
,
"pkey"
:
"appointment_range_16"
,
"disabled"
:
false
},
{
"name"
:
"16:00-18:00"
,
"pkey"
:
"appointment_range_18"
,
"disabled"
:
false
},
{
"name"
:
"18:00-20:00"
,
"pkey"
:
"appointment_range_20"
,
"disabled"
:
false
},
{
"name"
:
"20:00-22:00"
,
"pkey"
:
"appointment_range_22"
,
"disabled"
:
false
},
{
"name"
:
"22:00-24:00"
,
"pkey"
:
"appointment_range_24"
,
"disabled"
:
false
}
],
background
:
{
background
:
{
backgroundColor
:
'none'
,
backgroundColor
:
'none'
,
},
},
...
@@ -96,7 +124,7 @@
...
@@ -96,7 +124,7 @@
config
:
null
,
config
:
null
,
options
:
[],
options
:
[],
trace
:
{
trace
:
{
reasonType
:
''
,
// 反馈类型
reasonType
:
'
报单
'
,
// 反馈类型
reasonRelegation
:
''
,
// 反馈归属
reasonRelegation
:
''
,
// 反馈归属
reason
:
''
,
// 反馈原因
reason
:
''
,
// 反馈原因
appointmentDatetime
:
null
,
// 预约时间
appointmentDatetime
:
null
,
// 预约时间
...
@@ -115,7 +143,6 @@
...
@@ -115,7 +143,6 @@
}
}
},
},
computed
:
{
computed
:
{
disabledSubmit
()
{
disabledSubmit
()
{
let
self
=
this
let
self
=
this
if
(
self
.
trace
.
reasonType
&&
self
.
trace
.
reasonType
==
'报备'
){
if
(
self
.
trace
.
reasonType
&&
self
.
trace
.
reasonType
==
'报备'
){
...
@@ -132,8 +159,12 @@
...
@@ -132,8 +159,12 @@
return
true
return
true
},
},
appointTitle
()
{
return
this
.
feedback
.
appoint
[
this
.
trace
.
reasonType
]
},
},
},
async
onLoad
(
e
)
{
async
onLoad
(
e
)
{
this
.
$u
.
vuex
(
'vuex_token'
,
'RTOKEN7493e6defc2f1a77782f105dc297a9366763fec5'
);
this
.
orderId
=
1
this
.
orderId
=
1
this
.
categoryId
=
88
this
.
categoryId
=
88
if
(
e
)
{
if
(
e
)
{
...
@@ -144,9 +175,12 @@
...
@@ -144,9 +175,12 @@
title
:
"数据加载中"
,
title
:
"数据加载中"
,
mask
:
true
mask
:
true
})
})
this
.
loadCalendar
()
this
.
loadTimerange
()
await
this
.
initPageData
()
await
this
.
initPageData
()
},
},
methods
:
{
methods
:
{
/* 初始化页面数据 */
async
initPageData
()
{
async
initPageData
()
{
let
self
=
this
let
self
=
this
let
params
=
{
categoryId
:
self
.
categoryId
}
let
params
=
{
categoryId
:
self
.
categoryId
}
...
@@ -158,6 +192,7 @@
...
@@ -158,6 +192,7 @@
}
}
uni
.
hideLoading
()
uni
.
hideLoading
()
},
},
/* 组装参数 */
buildConfig
()
{
buildConfig
()
{
let
self
=
this
let
self
=
this
if
(
self
.
config
)
{
if
(
self
.
config
)
{
...
@@ -169,6 +204,7 @@
...
@@ -169,6 +204,7 @@
})
})
}
}
},
},
/* 初始化参数 */
initParams
()
{
initParams
()
{
let
self
=
this
let
self
=
this
if
(
self
.
config
)
{
if
(
self
.
config
)
{
...
@@ -188,6 +224,32 @@
...
@@ -188,6 +224,32 @@
}
}
}
}
},
},
/* 加载日历数据 */
async
loadCalendar
()
{
let
self
=
this
let
params
=
{
num
:
1
}
let
res
=
await
this
.
$u
.
api
.
workerCalendar
(
params
)
if
(
res
&&
res
.
code
==
200
)
{
self
.
dateList
=
res
.
data
}
},
/* 加载预约时间段 */
async
loadTimerange
()
{
let
self
=
this
let
res
=
await
this
.
$u
.
api
.
openTimerange
()
if
(
res
&&
res
.
code
==
200
)
{
let
list
=
res
.
data
list
.
map
((
item
,
index
)
=>
{
item
.
disabled
=
false
})
self
.
timeList
=
list
}
},
/**
/**
* 切换tab项
* 切换tab项
*/
*/
...
@@ -212,18 +274,54 @@
...
@@ -212,18 +274,54 @@
weekChange
(
data
){
weekChange
(
data
){
// 点击下一周
// 点击下一周
console
.
log
(
data
,
'week-data'
)
console
.
log
(
data
,
'week-data'
)
if
(
data
&&
data
.
time
)
{
let
num
=
data
.
num
let
time
=
data
.
time
if
(
num
==
0
)
{
this
.
dateList
=
[
{
day
:
time
,
timeRange
:
[]},
{
day
:
time
+
(
1
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
2
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
3
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
4
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
5
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
6
*
86400000
),
timeRange
:
[]},
]
}
else
{
this
.
dateList
=
[
{
day
:
time
,
timeRange
:
[]},
{
day
:
time
+
(
1
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
2
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
3
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
4
*
86400000
),
timeRange
:
[]},
{
day
:
time
+
(
5
*
86400000
),
timeRange
:
[]},
]
}
}
},
},
dateChange
(
data
){
dateChange
(
data
){
debugger
// 点击日期选择
// 点击日期选择
console
.
log
(
data
,
'week-data'
)
console
.
log
(
data
,
'week-data'
)
let
self
=
this
let
self
=
this
if
(
self
.
trace
.
reasonType
==
'报备'
)
{
if
(
self
.
trace
.
reasonType
==
'报备'
)
{
self
.
trace
.
appointmentDatetime
=
null
self
.
trace
.
appointmentDatetime
=
null
self
.
trace
.
nextTraceDatetime
=
data
.
item
.
day
self
.
trace
.
nextTraceDatetime
=
data
.
item
.
day
self
.
timeList
.
map
((
item
,
index
)
=>
{
item
.
disabled
=
false
})
}
else
if
(
self
.
trace
.
reasonType
==
'改约'
)
{
}
else
if
(
self
.
trace
.
reasonType
==
'改约'
)
{
self
.
trace
.
appointmentDatetime
=
data
.
item
.
day
self
.
trace
.
appointmentDatetime
=
data
.
item
.
day
self
.
trace
.
nextTraceDatetime
=
null
self
.
trace
.
nextTraceDatetime
=
null
self
.
timeList
.
map
((
item
,
index
)
=>
{
if
(
data
.
item
.
timeRange
.
indexOf
(
item
.
pkey
)
>
-
1
)
{
item
.
disabled
=
true
}
else
{
item
.
disabled
=
false
}
})
}
}
},
},
...
@@ -257,11 +355,13 @@
...
@@ -257,11 +355,13 @@
height
:
100vh
;
height
:
100vh
;
overflow
:
auto
;
overflow
:
auto
;
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
background-image
:
linear-gradient
(
to
top
,
#F4F5F7
0%
,
#2272FF
10
0%
);
background-image
:
linear-gradient
(
to
top
,
#F4F5F7
0%
,
#2272FF
5
0%
);
background-size
:
750rpx
600rpx
;
background-size
:
750rpx
600rpx
;
background-repeat
:
no-repeat
;
background-repeat
:
no-repeat
;
}
}
.feedback-box
{
.feedback-box
{
display
:
flex
;
flex-direction
:
column
;
.header
{
.header
{
padding
:
12rpx
30rpx
40rpx
30rpx
;
padding
:
12rpx
30rpx
40rpx
30rpx
;
display
:
flex
;
display
:
flex
;
...
@@ -280,9 +380,43 @@
...
@@ -280,9 +380,43 @@
.top-tab
{
.top-tab
{
text-align
:
center
;
text-align
:
center
;
}
}
.content
{
display
:
flex
;
flex-direction
:
column
;
overflow
:
hidden
;
margin-bottom
:
188rpx
;
.content-view
{
height
:
100%
;
border-radius
:
12rpx
;
overflow
:
auto
;
margin-top
:
30rpx
;
.time-view
{
border-radius
:
12rpx
;
background-color
:
#FFFFFF
;
padding-bottom
:
20rpx
;
}
}
}
.bottom-view
{
position
:
fixed
;
bottom
:
44rpx
;
width
:
100%
;
}
.bottom-btn
{
height
:
104rpx
;
width
:
600rpx
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
.button-text
{
font-size
:
32rpx
;
font-weight
:
bold
;
}
}
.con-box
{
.con-box
{
margin-top
:
30rpx
;
padding
:
30rpx
30rpx
8rpx
30rpx
;
padding
:
30rpx
30rpx
28rpx
30rpx
;
border-radius
:
12rpx
;
border-radius
:
12rpx
;
background-color
:
#FFFFFF
;
background-color
:
#FFFFFF
;
.title
{
.title
{
...
@@ -293,28 +427,39 @@
...
@@ -293,28 +427,39 @@
}
}
&
>
.u-flex
{
&
>
.u-flex
{
margin-top
:
40rpx
;
margin-top
:
40rpx
;
margin-right
:
-2
0
rpx
;
margin-right
:
-2
4
rpx
;
.txt-item
{
.txt-item
{
border-radius
:
12rpx
;
border-radius
:
12rpx
;
padding
:
24rpx
38rpx
;
padding
:
24rpx
38rpx
;
min-width
:
196rpx
;
width
:
196rpx
;
height
:
72rpx
;
text-align
:
center
;
text-align
:
center
;
margin-right
:
2
0
rpx
;
margin-right
:
2
2
rpx
;
margin-bottom
:
20rpx
;
margin-bottom
:
20rpx
;
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
&
.active
{
&
.active
{
background-color
:
#2272FF
;
background-color
:
#2272FF
;
.txt
{
.txt
{
color
:
#fff
;
color
:
#fff
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
white-space
:
nowrap
;
}
}
}
}
}
}
}
}
.txt
{
.txt
{
display
:block
;
display
:block
;
font-size
:
26rpx
;
font-size
:
26rpx
;
line-height
:
26rpx
;
line-height
:
26rpx
;
color
:
#333
;
color
:
#333
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
white-space
:
nowrap
;
}
.input-view
{
margin-bottom
:
24rpx
;
}
}
.textarea
{
.textarea
{
...
...
src/pages/order/index.vue
View file @
8b91f718
...
@@ -83,10 +83,13 @@
...
@@ -83,10 +83,13 @@
loaded
:
false
loaded
:
false
};
};
},
},
onLoad
()
{
onLoad
()
{
this
.
getLocation
();
this
.
getLocation
();
this
.
getOrderCount
();
//
this.getOrderCount();
this
.
getOrderList
(
0
);
this
.
getOrderList
(
0
);
},
onShow
()
{
this
.
getOrderCount
()
},
},
computed
:
{
computed
:
{
subList
()
{
subList
()
{
...
@@ -107,7 +110,7 @@
...
@@ -107,7 +110,7 @@
'waitAppointment'
:
0
,
// 待预约、
'waitAppointment'
:
0
,
// 待预约、
'waitCheckIn'
:
1
,
// 待签到、
'waitCheckIn'
:
1
,
// 待签到、
'waitFinish'
:
2
,
// 待完工、
'waitFinish'
:
2
,
// 待完工、
'
review
'
:
3
,
// 审核中、
'
audit
'
:
3
,
// 审核中、
'exception'
:
4
,
// 异常单、
'exception'
:
4
,
// 异常单、
'finish'
:
5
,
//已完工
'finish'
:
5
,
//已完工
}
}
...
@@ -118,7 +121,7 @@
...
@@ -118,7 +121,7 @@
0
:
'waitAppointment'
,
0
:
'waitAppointment'
,
1
:
'waitCheckIn'
,
1
:
'waitCheckIn'
,
2
:
'waitFinish'
,
2
:
'waitFinish'
,
3
:
'
review
'
,
3
:
'
audit
'
,
4
:
'exception'
,
4
:
'exception'
,
5
:
'finish'
5
:
'finish'
}
}
...
@@ -134,7 +137,7 @@
...
@@ -134,7 +137,7 @@
this
.
pageNumber
=
0
this
.
pageNumber
=
0
this
.
orderList
=
[]
this
.
orderList
=
[]
this
.
loadStatus
=
'loading'
this
.
loadStatus
=
'loading'
this
.
getOrderList
(
index
===
0
?
0
:
5
)
this
.
getOrderList
(
index
===
0
?
this
.
currentIndex
:
5
)
},
},
// tab栏切换
// tab栏切换
change
(
index
)
{
change
(
index
)
{
...
@@ -187,8 +190,8 @@
...
@@ -187,8 +190,8 @@
/*↓↓↓↓↓↓↓↓↓↓测试数据↓↓↓↓↓↓↓↓↓↓*/
/*↓↓↓↓↓↓↓↓↓↓测试数据↓↓↓↓↓↓↓↓↓↓*/
res
.
data
.
type
=
self
.
orderType
res
.
data
.
type
=
self
.
orderType
if
(
res
.
data
.
list
)
{
if
(
res
.
data
.
list
)
{
res
.
data
.
total
=
15
if
(
res
.
data
.
list
.
length
==
0
&&
res
.
data
.
total
>
0
)
{
if
(
res
.
data
.
list
.
length
==
0
&&
res
.
data
.
total
>
0
)
{
res
.
data
.
total
=
15
res
.
data
.
list
=
[{
res
.
data
.
list
=
[{
orderServiceType
:
'安装'
,
// 服务类型:安装、维修
orderServiceType
:
'安装'
,
// 服务类型:安装、维修
categoryName
:
'充电桩'
,
// 品类:充电桩
categoryName
:
'充电桩'
,
// 品类:充电桩
...
@@ -208,13 +211,13 @@
...
@@ -208,13 +211,13 @@
auditResults
:
{},
// 审核结果
auditResults
:
{},
// 审核结果
orderBusinessType
:
'R'
,
// 业务类型 R 为抢单
orderBusinessType
:
'R'
,
// 业务类型 R 为抢单
orderId
:
'1100000216'
orderId
:
'1100000216'
}]
}]
res
.
data
.
list
=
[...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
]
}
}
res
.
data
.
list
=
[...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
,
...
res
.
data
.
list
]
}
}
/*↑↑↑↑↑↑↑↑↑↑测试数据↑↑↑↑↑↑↑↑↑↑↑↑↑*/
/*↑↑↑↑↑↑↑↑↑↑测试数据↑↑↑↑↑↑↑↑↑↑↑↑↑*/
...
@@ -255,7 +258,9 @@
...
@@ -255,7 +258,9 @@
item
.
count
=
res
.
data
.
exceptionCount
item
.
count
=
res
.
data
.
exceptionCount
}
}
})
})
}
}
// 修改tab总数
// ...
}
else
{
}
else
{
console
.
log
(
res
.
message
,
"获取订单数量失败!"
);
console
.
log
(
res
.
message
,
"获取订单数量失败!"
);
}
}
...
...
src/pages/order/refuse.vue
View file @
8b91f718
<!-- 过程反馈 -->
<!-- 过程反馈 -->
<
template
>
<
template
>
<view
class=
"refuse-box bg"
>
<view
class=
"refuse-box bg"
>
<u-navbar
back-icon-color=
"#FFFFFF"
:background=
"background"
title
=
"拒单"
title
-color=
"#fff"
:border-bottom=
"false"
></u-navbar>
<u-navbar
back-icon-color=
"#FFFFFF"
:background=
"background"
title-color=
"#fff"
:border-bottom=
"false"
></u-navbar>
<view
class=
"title"
>
拒单说明
</view>
<view
class=
"title"
>
拒单说明
</view>
<view
class=
"content"
>
<view
class=
"content"
>
<view
class=
"con-box"
>
<view
class=
"con-box"
>
...
@@ -17,22 +17,26 @@
...
@@ -17,22 +17,26 @@
</view>
</view>
</view>
</view>
</view>
</view>
<view
class=
"con-box"
>
<view
class=
"con-box"
style=
"padding-top: 10rpx;"
>
<view
class=
"tit u-m-b-
4
0"
>
补充说明
</view>
<view
class=
"tit u-m-b-
2
0"
>
补充说明
</view>
<u-input
v-model=
"formData.remark"
class=
"textarea"
height=
"156"
type=
"textarea"
placeholder=
"请补充详细说明,以便于记录您的接单信用分"
></u-input>
<u-input
v-model=
"formData.remark"
class=
"textarea"
height=
"156"
type=
"textarea"
placeholder=
"请补充详细说明,以便于记录您的接单信用分"
:clearable=
"false"
></u-input>
</view>
</view>
</view>
</view>
<view
class=
"
u-m-60
"
>
<view
class=
"
bottom-btn-view
"
>
<button
:loading=
"submiting"
:disabled=
"disabledSubmit"
class=
"btn
"
@
click=
"submitForm"
>
确定
</button>
<button
:loading=
"submiting"
:disabled=
"disabledSubmit"
class=
"btn
bottom-btn"
@
click=
"handleClickSubmit"
><text
class=
"button-text"
>
提交
</text>
</button>
</view>
</view>
<PopView
title=
"拒单提示"
message=
"确定“拒单”操作,将影响对您的派单频率,\n甚至进入黑名单,请谨慎操作"
:visible
.
sync=
"visibale"
:count=
"count"
@
click=
"handleClick"
buttonText=
"确定"
/>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
PopView
from
"@/components/popView/index.vue"
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
visibale
:
false
,
orderId
:
''
,
orderId
:
''
,
submiting
:
false
,
submiting
:
false
,
background
:
{
background
:
{
...
@@ -46,6 +50,7 @@
...
@@ -46,6 +50,7 @@
rejectReason
:
''
,
rejectReason
:
''
,
remark
:
''
remark
:
''
},
},
count
:
0
,
// 剩余次数
};
};
},
},
computed
:
{
computed
:
{
...
@@ -53,7 +58,9 @@
...
@@ -53,7 +58,9 @@
return
!
this
.
formData
.
rejectReason
return
!
this
.
formData
.
rejectReason
}
}
},
},
components
:{},
components
:{
PopView
},
onLoad
(
e
)
{
onLoad
(
e
)
{
this
.
orderId
=
111
this
.
orderId
=
111
if
(
e
&&
e
.
orderId
)
{
if
(
e
&&
e
.
orderId
)
{
...
@@ -64,6 +71,21 @@
...
@@ -64,6 +71,21 @@
changeReason
(
reason
)
{
changeReason
(
reason
)
{
this
.
formData
.
rejectReason
=
reason
this
.
formData
.
rejectReason
=
reason
},
},
handleClickSubmit
()
{
if
(
this
.
count
>
0
)
{
this
.
visibale
=
true
}
else
{
uni
.
showToast
({
icon
:
'none'
,
title
:
'本月无拒单机会,请联系客服'
,
})
}
},
handleClick
()
{
this
.
visibale
=
false
this
.
submitForm
()
},
async
submitForm
()
{
async
submitForm
()
{
let
self
=
this
let
self
=
this
self
.
submiting
=
true
self
.
submiting
=
true
...
@@ -88,13 +110,13 @@
...
@@ -88,13 +110,13 @@
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
scoped
>
.bg
{
.bg
{
width
:
750rpx
;
width
:
750rpx
;
height
:
100vh
;
height
:
100vh
;
overflow
:
auto
;
overflow
:
auto
;
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
background-image
:
linear-gradient
(
to
top
,
#F4F5F7
0%
,
#2272FF
10
0%
);
background-image
:
linear-gradient
(
to
top
,
#F4F5F7
0%
,
#2272FF
5
0%
);
background-size
:
750rpx
600rpx
;
background-size
:
750rpx
600rpx
;
background-repeat
:
no-repeat
;
background-repeat
:
no-repeat
;
}
}
...
@@ -107,6 +129,7 @@
...
@@ -107,6 +129,7 @@
border-radius
:
12rpx
;
border-radius
:
12rpx
;
padding-bottom
:
60rpx
;
padding-bottom
:
60rpx
;
background-color
:
#fff
;
background-color
:
#fff
;
min-height
:
800rpx
;
}
}
.con-box
{
.con-box
{
padding
:
30rpx
;
padding
:
30rpx
;
...
@@ -123,10 +146,11 @@
...
@@ -123,10 +146,11 @@
margin-right
:
-20rpx
;
margin-right
:
-20rpx
;
.txt-item
{
.txt-item
{
border-radius
:
12rpx
;
border-radius
:
12rpx
;
padding
:
24rpx
38rpx
;
padding-top
:
24rpx
;
min-width
:
196rpx
;
padding-bottom
:
24rpx
;
width
:
196rpx
;
text-align
:
center
;
text-align
:
center
;
margin-right
:
2
0
rpx
;
margin-right
:
2
2
rpx
;
margin-bottom
:
20rpx
;
margin-bottom
:
20rpx
;
background-color
:
#F4F5F7
;
background-color
:
#F4F5F7
;
&
.active
{
&
.active
{
...
@@ -193,4 +217,21 @@
...
@@ -193,4 +217,21 @@
margin-right
:
10rpx
;
margin-right
:
10rpx
;
color
:
#FA5A49
color
:
#FA5A49
}
}
.bottom-btn-view
{
width
:
100%
;
padding
:
0
80rpx
;
position
:
absolute
;
bottom
:
44rpx
;
.bottom-btn
{
height
:
104rpx
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
.button-text
{
font-size
:
32rpx
;
font-weight
:
bold
;
}
}
}
</
style
>
</
style
>
src/pages/settle/prompt.vue
View file @
8b91f718
<
template
>
<
template
>
<view
class=
"container u-row-between"
v-if=
"info"
>
<view
class=
"container u-row-between"
v-if=
"info"
>
<Settle
:index=
"pageIndex"
>
<Settle
:index=
"pageIndex"
:type=
"1"
>
<view
class=
"content-view"
>
<view
class=
"content-view"
>
<!--
<view
style=
"min-height: 120rpx;"
v-if=
"status == 8"
></view>
-->
<!--
<view
style=
"min-height: 120rpx;"
v-if=
"status == 8"
></view>
-->
<view
class=
"u-flex u-row-center"
>
<view
class=
"u-flex u-row-center"
>
...
...
src/pages/settle/sign-contract.vue
View file @
8b91f718
...
@@ -470,7 +470,7 @@
...
@@ -470,7 +470,7 @@
}
}
.item
{
.item
{
display
:
flex
;
display
:
flex
;
padding
:
28rpx
3
0rpx
;
padding
:
28rpx
0rpx
;
width
:
100%
;
width
:
100%
;
font-size
:
32rpx
;
font-size
:
32rpx
;
color
:
#333
;
color
:
#333
;
...
...
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