Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
repair_workers_h5
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
石盼盼
repair_workers_h5
Commits
48cf7b31
Commit
48cf7b31
authored
Oct 27, 2021
by
郭欢
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'gh_test' into 'master'
Gh test See merge request
!42
parents
ca7a15af
0d033b16
Changes
24
Show whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
2127 additions
and
1796 deletions
+2127
-1796
index.html
public/index.html
+21
-0
App.vue
src/App.vue
+3
-3
apiList.js
src/api/apiList.js
+2
-2
axios.js
src/api/axios.js
+1
-1
wxShare.js
src/api/wxShare.js
+6
-6
self.js
src/assets/js/self.js
+1
-1
common.scss
src/assets/styles/common.scss
+7
-0
tabbar.scss
src/assets/styles/common/tabbar.scss
+3
-3
global.scss
src/assets/styles/global.scss
+4
-0
menulist.scss
src/assets/styles/index/menulist.scss
+1
-1
admin_index.scss
src/assets/styles/tabbar/admin_index.scss
+25
-16
index.scss
src/assets/styles/tabbar/index.scss
+21
-12
modifyPhone.scss
src/assets/styles/tabbar/modifyPhone.scss
+1
-1
main.js
src/main.js
+2
-2
index.js
src/router/index.js
+5
-3
login.vue
src/views/login/login.vue
+18
-8
admin_detail.vue
src/views/my/admin_detail.vue
+311
-284
charge.vue
src/views/my/charge.vue
+229
-176
lookEvaluate.vue
src/views/my/lookEvaluate.vue
+56
-32
order_detail.vue
src/views/my/order_detail.vue
+371
-323
Home.vue
src/views/tabbar/Home.vue
+459
-397
admin_home.vue
src/views/tabbar/admin_home.vue
+465
-434
mine.vue
src/views/tabbar/mine.vue
+76
-68
modifyPhone.vue
src/views/tabbar/modifyPhone.vue
+39
-23
No files found.
public/index.html
View file @
48cf7b31
...
@@ -29,5 +29,26 @@
...
@@ -29,5 +29,26 @@
}
}
window
.
onresize
=
resizeRoot
;
window
.
onresize
=
resizeRoot
;
})(
window
);
})(
window
);
// 强制禁止用户修改微信客户端的字体大小
(
function
()
{
function
handleFontSize
()
{
// 设置网页字体为默认大小
WeixinJSBridge
.
invoke
(
'
setFontSizeCallback
'
,
{
'
fontSize
'
:
0
});
// 重写设置网页字体大小的事件
WeixinJSBridge
.
on
(
'
menu:setfont
'
,
function
()
{
WeixinJSBridge
.
invoke
(
'
setFontSizeCallback
'
,
{
'
fontSize
'
:
0
});
});
}
if
(
typeof
WeixinJSBridge
==
"
object
"
&&
typeof
WeixinJSBridge
.
invoke
==
"
function
"
)
{
handleFontSize
();
}
else
{
if
(
document
.
addEventListener
)
{
document
.
addEventListener
(
"
WeixinJSBridgeReady
"
,
handleFontSize
,
false
);
}
else
if
(
document
.
attachEvent
)
{
document
.
attachEvent
(
"
WeixinJSBridgeReady
"
,
handleFontSize
);
document
.
attachEvent
(
"
onWeixinJSBridgeReady
"
,
handleFontSize
);
}
}
})();
</script>
</script>
</html>
</html>
\ No newline at end of file
src/App.vue
View file @
48cf7b31
<
template
>
<
template
>
<div
id=
"app"
>
<div
id=
"app"
>
<keep-alive
v-if=
"$route.meta.keepAlive"
>
<keep-alive
>
<router-view
/>
<router-view
v-if=
"$route.meta.keepAlive"
/>
</keep-alive>
</keep-alive>
<router-view
v-
else
/>
<router-view
v-
if=
"!$route.meta.keepAlive"
/>
<div
class=
"goBack-btn flex-h flex-hc flex-align-center"
v-if=
"!$route.meta.hideBack"
>
<div
class=
"goBack-btn flex-h flex-hc flex-align-center"
v-if=
"!$route.meta.hideBack"
>
<i
class=
"iconfont icon-icon_fanhuishouye"
@
click=
"gohome"
></i>
<i
class=
"iconfont icon-icon_fanhuishouye"
@
click=
"gohome"
></i>
</div>
</div>
...
...
src/api/apiList.js
View file @
48cf7b31
...
@@ -10,8 +10,8 @@ const baseUrl = '/api'
...
@@ -10,8 +10,8 @@ const baseUrl = '/api'
// todo: url
// todo: url
// const httpUrl = 'https://repairtest.zeruiedu.com' // 测试接口
// const httpUrl = 'https://repairtest.zeruiedu.com' // 测试接口
const
httpUrl
=
'
https://repair.zeruiedu.com
'
// 正式接口
const
httpUrl
=
'
https://repair.zeruiedu.com
'
// 正式接口
const
h5Url
=
'
http://localhost:8080
'
// 测试h5线上地址
//
const h5Url = 'http://localhost:8080' // 测试h5线上地址
//
const h5Url = 'http://repair.h5.zeruiedu.com' // 测试h5线上地址
const
h5Url
=
'
http://repair.h5.zeruiedu.com
'
// 测试h5线上地址
window
.
localStorage
.
setItem
(
'
httpUrl
'
,
httpUrl
)
window
.
localStorage
.
setItem
(
'
httpUrl
'
,
httpUrl
)
window
.
localStorage
.
setItem
(
'
h5Url
'
,
h5Url
)
window
.
localStorage
.
setItem
(
'
h5Url
'
,
h5Url
)
// const httpUrl = 'https://fenghexm.xueyoubangedu.com' // 正式接口
// const httpUrl = 'https://fenghexm.xueyoubangedu.com' // 正式接口
...
...
src/api/axios.js
View file @
48cf7b31
...
@@ -53,7 +53,7 @@ service.interceptors.response.use(
...
@@ -53,7 +53,7 @@ service.interceptors.response.use(
},
(
err
)
=>
{
},
(
err
)
=>
{
resolve
(
err
)
resolve
(
err
)
window
.
localStorage
.
clear
()
window
.
localStorage
.
clear
()
Toast
(
'
身份失效,请重新登录
'
)
Toast
(
'
身份失效,请重新登录
11111
'
)
window
.
document
.
location
=
selfApi
.
WINDOWHREF_LOGIN
// url-
window
.
document
.
location
=
selfApi
.
WINDOWHREF_LOGIN
// url-
console
.
log
(
'
错误--------
'
,
err
)
console
.
log
(
'
错误--------
'
,
err
)
})
})
...
...
src/api/wxShare.js
View file @
48cf7b31
var
wx
=
require
(
'
weixin-js-sdk
'
)
import
axios
from
'
axios
'
import
axios
from
'
axios
'
import
apiList
from
'
./apiList
'
import
apiList
from
'
./apiList
'
import
myAxios
from
'
./index
'
import
myAxios
from
'
./index
'
import
{
import
{
Toast
Toast
}
from
'
vant
'
}
from
'
vant
'
var
wx
=
require
(
'
weixin-js-sdk
'
)
// 微信分享方法
// 微信分享方法
const
share
=
(
param
)
=>
{
const
share
=
(
param
)
=>
{
Toast
.
loading
({
Toast
.
loading
({
message
:
"
加载中...
"
,
message
:
'
加载中...
'
,
duration
:
1000
,
//
持续展示 toast
duration
:
1000
//
持续展示 toast
})
})
const
successCall
=
(
res
)
=>
{
const
successCall
=
(
res
)
=>
{
console
.
log
(
'
res
'
,
res
)
console
.
log
(
'
res
'
,
res
)
Toast
.
clear
()
Toast
.
clear
()
le
t
result
=
res
.
conf
cons
t
result
=
res
.
conf
// let result = res.data
// let result = res.data
// let {
// let {
// wxConfig,
// wxConfig,
...
@@ -68,7 +68,7 @@ const share = (param) => {
...
@@ -68,7 +68,7 @@ const share = (param) => {
menuList
:
hideMenuItems
menuList
:
hideMenuItems
})
})
wx
.
showMenuItems
({
wx
.
showMenuItems
({
menuList
:
[
"
menuItem:share:appMessage
"
,
"
menuItem:share:timeline
"
]
// 要显示的菜单项,所有menu项见附录3
menuList
:
[
'
menuItem:share:appMessage
'
,
'
menuItem:share:timeline
'
]
// 要显示的菜单项,所有menu项见附录3
})
})
})
})
}
}
...
@@ -81,7 +81,7 @@ const share = (param) => {
...
@@ -81,7 +81,7 @@ const share = (param) => {
successCall
(
res
)
successCall
(
res
)
Toast
.
clear
()
Toast
.
clear
()
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
}
}
export
{
export
{
...
...
src/assets/js/self.js
View file @
48cf7b31
// export const SELFSHOP = 'self_shop
'
export
const
REFRESH_LIST
=
'
REFRESH_LIST
'
/**
/**
* 设置缓存 getLocalStorage
* 设置缓存 getLocalStorage
...
...
src/assets/styles/common.scss
View file @
48cf7b31
@charset
"UTF-8"
;
@charset
"UTF-8"
;
/* iOS禁止微信调整字体大小 */
body
{
-webkit-text-size-adjust
:
100%
!
important
;
text-size-adjust
:
100%
!
important
;
-moz-text-size-adjust
:
100%
!
important
;
}
html
,
body
,
div
,
span
,
applet
,
object
,
iframe
,
h1
,
h2
,
h3
,
html
,
body
,
div
,
span
,
applet
,
object
,
iframe
,
h1
,
h2
,
h3
,
h4
,
h5
,
h6
,
p
,
blockquote
,
pre
,
a
,
abbr
,
acronym
,
address
,
h4
,
h5
,
h6
,
p
,
blockquote
,
pre
,
a
,
abbr
,
acronym
,
address
,
big
,
cite
,
code
,
del
,
dfn
,
em
,
font
,
img
,
ins
,
kbd
,
q
,
s
,
samp
,
big
,
cite
,
code
,
del
,
dfn
,
em
,
font
,
img
,
ins
,
kbd
,
q
,
s
,
samp
,
...
...
src/assets/styles/common/tabbar.scss
View file @
48cf7b31
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
width
:
1
.5rem
;
width
:
1
.5rem
;
height
:
100%
;
height
:
100%
;
text-align
:
center
;
text-align
:
center
;
font-size
:
0
.
26
rem
;
font-size
:
0
.
3
rem
;
color
:
#333333
;
color
:
#333333
;
}
}
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
}
}
.tabbar-item
img
{
.tabbar-item
img
{
width
:
0
.
44
rem
;
width
:
0
.
56
rem
;
height
:
0
.
44
rem
;
height
:
0
.
56
rem
;
margin
:
0
auto
;
margin
:
0
auto
;
}
}
\ No newline at end of file
src/assets/styles/global.scss
View file @
48cf7b31
...
@@ -197,3 +197,7 @@ $text-gray: #989794;
...
@@ -197,3 +197,7 @@ $text-gray: #989794;
.self-cont-sticky
.van-sticky.van-sticky--fixed
{
.self-cont-sticky
.van-sticky.van-sticky--fixed
{
width
:
1rem
!
important
;
width
:
1rem
!
important
;
}
}
.specile-text
{
color
:
#ff0000
!
important
;
}
\ No newline at end of file
src/assets/styles/index/menulist.scss
View file @
48cf7b31
...
@@ -16,7 +16,7 @@
...
@@ -16,7 +16,7 @@
}
}
.title-cont
{
.title-cont
{
font-size
:
.32
rem
;
font-size
:
0
.4
rem
;
}
}
}
}
...
...
src/assets/styles/tabbar/admin_index.scss
View file @
48cf7b31
...
@@ -22,13 +22,13 @@
...
@@ -22,13 +22,13 @@
.top
.status
{
.top
.status
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.3
6
rem
;
font-size
:
0
.3
8
rem
;
font-weight
:
bold
;
font-weight
:
bold
;
}
}
.menu
.hc_total
{
.menu
.hc_total
{
color
:
#727272
;
color
:
#727272
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
}
}
.menu
.options
{
.menu
.options
{
...
@@ -38,7 +38,7 @@
...
@@ -38,7 +38,7 @@
border
:
1px
solid
#0054ff
;
border
:
1px
solid
#0054ff
;
border-radius
:
0
.12rem
;
border-radius
:
0
.12rem
;
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
34
rem
;
line-height
:
0
.58rem
;
line-height
:
0
.58rem
;
text-align
:
center
;
text-align
:
center
;
position
:
relative
;
position
:
relative
;
...
@@ -74,7 +74,7 @@
...
@@ -74,7 +74,7 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.58rem
;
line-height
:
0
.58rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
}
}
.date
.end
{
.date
.end
{
width
:
3
.08rem
;
width
:
3
.08rem
;
...
@@ -85,7 +85,7 @@
...
@@ -85,7 +85,7 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.58rem
;
line-height
:
0
.58rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
}
}
.date
.blue
{
.date
.blue
{
width
:
0
.31rem
;
width
:
0
.31rem
;
...
@@ -111,7 +111,7 @@
...
@@ -111,7 +111,7 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.7rem
;
line-height
:
0
.7rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
24
rem
;
font-size
:
0
.
32
rem
;
// margin-right: 0.2rem;
// margin-right: 0.2rem;
}
}
.allBtn
.sureBtn
{
.allBtn
.sureBtn
{
...
@@ -122,7 +122,7 @@
...
@@ -122,7 +122,7 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.7rem
;
line-height
:
0
.7rem
;
color
:
#fff
;
color
:
#fff
;
font-size
:
0
.
24
rem
;
font-size
:
0
.
32
rem
;
margin-left
:
0
.2rem
;
margin-left
:
0
.2rem
;
}
}
.cancel_cont
{
.cancel_cont
{
...
@@ -141,12 +141,12 @@
...
@@ -141,12 +141,12 @@
border-radius
:
0
.12rem
;
border-radius
:
0
.12rem
;
margin
:
0
.4rem
auto
0
.2rem
;
margin
:
0
.4rem
auto
0
.2rem
;
padding
:
0
.4rem
0
.3rem
;
padding
:
0
.4rem
0
.3rem
;
font-size
:
0
.
3
rem
;
font-size
:
0
.
4
rem
;
}
}
.title
{
.title
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.32
rem
;
// font-size: 0.4
rem;
font-weight
:
bold
;
font-weight
:
bold
;
margin-bottom
:
0
.5rem
;
margin-bottom
:
0
.5rem
;
}
}
...
@@ -225,7 +225,7 @@
...
@@ -225,7 +225,7 @@
}
}
.btn
{
.btn
{
margin-top
:
0
.
2
rem
;
margin-top
:
0
.
5
rem
;
}
}
.btn-item
{
.btn-item
{
...
@@ -236,8 +236,9 @@
...
@@ -236,8 +236,9 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.7rem
;
line-height
:
0
.7rem
;
color
:
#fff
;
color
:
#fff
;
font-size
:
0
.
27
rem
;
font-size
:
0
.
34
rem
;
margin-left
:
0
.2rem
;
margin-left
:
0
.2rem
;
margin-bottom
:
.1rem
;
}
}
.sf-btn
{
.sf-btn
{
...
@@ -263,7 +264,7 @@
...
@@ -263,7 +264,7 @@
.pop_title
{
.pop_title
{
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
36
rem
;
font-size
:
0
.
4
rem
;
font-weight
:
bold
;
font-weight
:
bold
;
margin-bottom
:
0
.4rem
;
margin-bottom
:
0
.4rem
;
}
}
...
@@ -362,7 +363,7 @@
...
@@ -362,7 +363,7 @@
}
}
.tc-box
.tc-title
{
.tc-box
.tc-title
{
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
margin-bottom
:
0
.3rem
;
margin-bottom
:
0
.3rem
;
font-weight
:
bold
;
font-weight
:
bold
;
text-align
:
center
;
text-align
:
center
;
...
@@ -376,7 +377,7 @@
...
@@ -376,7 +377,7 @@
background
:
#f2f2f2
;
background
:
#f2f2f2
;
line-height
:
0
.56rem
;
line-height
:
0
.56rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
padding-left
:
0
.3rem
;
padding-left
:
0
.3rem
;
margin-bottom
:
0
.3rem
;
margin-bottom
:
0
.3rem
;
}
}
...
@@ -392,7 +393,7 @@
...
@@ -392,7 +393,7 @@
}
}
.tc-box
.workers
.gr-item
.gr-name
{
.tc-box
.workers
.gr-item
.gr-name
{
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
}
}
.tc-box
.workers
.k-img
{
.tc-box
.workers
.k-img
{
width
:
0
.42rem
;
width
:
0
.42rem
;
...
@@ -437,5 +438,13 @@
...
@@ -437,5 +438,13 @@
.none
{
.none
{
margin-left
:
0
.3rem
;
margin-left
:
0
.3rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.28rem
;
font-size
:
0
.32rem
;
}
/
deep
/
.van-ellipsis
{
font-size
:
0
.4rem
!
important
;
}
/
deep
/
.van-picker__confirm
,
/
deep
/
.van-picker__cancel
{
font-size
:
0
.4rem
!
important
;
}
}
\ No newline at end of file
src/assets/styles/tabbar/index.scss
View file @
48cf7b31
...
@@ -18,12 +18,12 @@
...
@@ -18,12 +18,12 @@
}
}
.top
.status
{
.top
.status
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.3
6
rem
;
font-size
:
0
.3
8
rem
;
font-weight
:
bold
;
font-weight
:
bold
;
}
}
.menu
.hc_total
{
.menu
.hc_total
{
color
:
#727272
;
color
:
#727272
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
4
rem
;
}
}
.menu
.options
{
.menu
.options
{
width
:
1
.76rem
;
width
:
1
.76rem
;
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
border
:
1px
solid
#0054ff
;
border
:
1px
solid
#0054ff
;
border-radius
:
0
.12rem
;
border-radius
:
0
.12rem
;
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
34
rem
;
line-height
:
0
.58rem
;
line-height
:
0
.58rem
;
text-align
:
center
;
text-align
:
center
;
position
:
relative
;
position
:
relative
;
...
@@ -57,11 +57,11 @@
...
@@ -57,11 +57,11 @@
border-radius
:
0
.12rem
;
border-radius
:
0
.12rem
;
margin
:
0
.4rem
auto
0
.2rem
;
margin
:
0
.4rem
auto
0
.2rem
;
padding
:
0
.4rem
0
.3rem
;
padding
:
0
.4rem
0
.3rem
;
font-size
:
0
.
3
rem
;
font-size
:
0
.
4
rem
;
}
}
.title
{
.title
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.32
rem
;
// font-size: 0.4
rem;
font-weight
:
bold
;
font-weight
:
bold
;
margin-bottom
:
0
.5rem
;
margin-bottom
:
0
.5rem
;
}
}
...
@@ -158,7 +158,7 @@
...
@@ -158,7 +158,7 @@
margin-right
:
0
.3rem
;
margin-right
:
0
.3rem
;
}
}
.btn
{
.btn
{
margin-top
:
0
.
2
rem
;
margin-top
:
0
.
5
rem
;
}
}
.btn-item
{
.btn-item
{
width
:
1
.8rem
;
width
:
1
.8rem
;
...
@@ -168,8 +168,9 @@
...
@@ -168,8 +168,9 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.7rem
;
line-height
:
0
.7rem
;
color
:
#fff
;
color
:
#fff
;
font-size
:
0
.
27
rem
;
font-size
:
0
.
34
rem
;
margin-left
:
0
.2rem
;
margin-left
:
0
.2rem
;
margin-bottom
:
.1rem
;
}
}
.sf-btn
{
.sf-btn
{
background
:
#ffffff
;
background
:
#ffffff
;
...
@@ -200,7 +201,7 @@
...
@@ -200,7 +201,7 @@
// }
// }
.pop_title
{
.pop_title
{
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
36
rem
;
font-size
:
0
.
4
rem
;
font-weight
:
bold
;
font-weight
:
bold
;
margin-bottom
:
0
.4rem
;
margin-bottom
:
0
.4rem
;
}
}
...
@@ -213,7 +214,7 @@
...
@@ -213,7 +214,7 @@
}
}
.
van-popup
textarea
:
:-
webkit-input-placeholder
{
.
van-popup
textarea
:
:-
webkit-input-placeholder
{
color
:
#c8c8c8
;
color
:
#c8c8c8
;
font-size
:
0
.
26
rem
;
font-size
:
0
.
34
rem
;
}
}
.btnItem
{
.btnItem
{
margin-top
:
0
.4rem
;
margin-top
:
0
.4rem
;
...
@@ -279,7 +280,7 @@
...
@@ -279,7 +280,7 @@
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.26rem
;
font-size
:
0
.26rem
;
margin-left
:
0
.3rem
;
margin-left
:
0
.3rem
;
margin-top
:
0
.4rem
;
//
margin-top: 0.4rem;
}
}
.sure-btn
{
.sure-btn
{
width
:
3
.12rem
;
width
:
3
.12rem
;
...
@@ -308,7 +309,7 @@
...
@@ -308,7 +309,7 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.58rem
;
line-height
:
0
.58rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
34
rem
;
}
}
.date
.end
{
.date
.end
{
...
@@ -320,7 +321,7 @@
...
@@ -320,7 +321,7 @@
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.58rem
;
line-height
:
0
.58rem
;
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
34
rem
;
}
}
.date
.blue
{
.date
.blue
{
...
@@ -328,3 +329,11 @@
...
@@ -328,3 +329,11 @@
height
:
0
.03rem
;
height
:
0
.03rem
;
background
:
#0054FF
;
background
:
#0054FF
;
}
}
/
deep
/
.van-ellipsis
{
font-size
:
0
.4rem
!
important
;
}
/
deep
/
.van-picker__confirm
,
/
deep
/
.van-picker__cancel
{
font-size
:
0
.4rem
!
important
;
}
\ No newline at end of file
src/assets/styles/tabbar/modifyPhone.scss
View file @
48cf7b31
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
}
}
input
:
:-
webkit-input-placeholder
{
input
:
:-
webkit-input-placeholder
{
color
:
#C8C8C8
;
color
:
#C8C8C8
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
32
rem
;
}
}
.code
{
.code
{
position
:
relative
;
position
:
relative
;
...
...
src/main.js
View file @
48cf7b31
...
@@ -7,11 +7,11 @@ import myApi from './api/apiList'
...
@@ -7,11 +7,11 @@ import myApi from './api/apiList'
import
myAxios
from
'
./api/index
'
import
myAxios
from
'
./api/index
'
import
Vant
from
'
vant
'
import
Vant
from
'
vant
'
import
'
vant/lib/index.css
'
import
'
vant/lib/index.css
'
import
vConsole
from
'
@/plugins/vconsole.js
'
//
import vConsole from '@/plugins/vconsole.js'
import
listTips
from
'
@/components/common/listtips.vue
'
import
listTips
from
'
@/components/common/listtips.vue
'
Vue
.
component
(
'
listTips
'
,
listTips
)
Vue
.
component
(
'
listTips
'
,
listTips
)
Vue
.
use
(
vConsole
)
//
Vue.use(vConsole)
Vue
.
config
.
productionTip
=
false
Vue
.
config
.
productionTip
=
false
...
...
src/router/index.js
View file @
48cf7b31
...
@@ -29,7 +29,8 @@ const routes = [{
...
@@ -29,7 +29,8 @@ const routes = [{
name
:
'
mine
'
,
name
:
'
mine
'
,
meta
:
{
meta
:
{
title
:
'
我的
'
,
title
:
'
我的
'
,
hideBack
:
true
hideBack
:
true
,
keepAlive
:
true
},
},
component
:
()
=>
import
(
'
../views/tabbar/mine.vue
'
)
component
:
()
=>
import
(
'
../views/tabbar/mine.vue
'
)
},
},
...
@@ -66,7 +67,8 @@ const routes = [{
...
@@ -66,7 +67,8 @@ const routes = [{
name
:
'
order_detail
'
,
name
:
'
order_detail
'
,
meta
:
{
meta
:
{
title
:
'
工单详情
'
,
title
:
'
工单详情
'
,
hideBack
:
true
hideBack
:
true
,
keepAlive
:
true
},
},
component
:
()
=>
import
(
'
@/views/my/order_detail.vue
'
)
component
:
()
=>
import
(
'
@/views/my/order_detail.vue
'
)
},
},
...
@@ -94,7 +96,7 @@ const router = new VueRouter({
...
@@ -94,7 +96,7 @@ const router = new VueRouter({
mode
:
'
history
'
,
mode
:
'
history
'
,
base
:
process
.
env
.
BASE_URL
,
base
:
process
.
env
.
BASE_URL
,
routes
,
routes
,
scrollBehavior
(
to
,
from
,
savePosition
)
{
scrollBehavior
(
to
,
from
,
savePosition
)
{
if
(
savePosition
)
{
if
(
savePosition
)
{
return
savePosition
return
savePosition
}
else
{
}
else
{
...
...
src/views/login/login.vue
View file @
48cf7b31
...
@@ -7,12 +7,22 @@
...
@@ -7,12 +7,22 @@
<div>
<div>
<div
class=
"filed-list"
>
<div
class=
"filed-list"
>
<img
class=
"icon-img"
src=
"@assets/images/login/shouji.png"
/>
<img
class=
"icon-img"
src=
"@assets/images/login/shouji.png"
/>
<van-field
v-model.trim=
"tel"
type=
"tel"
placeholder=
"请输入手机号"
maxlength=
"11"
/>
<van-field
v-model.trim=
"tel"
type=
"tel"
placeholder=
"请输入手机号"
maxlength=
"11"
/>
</div>
</div>
<div
class=
"filed-list code-cont"
>
<div
class=
"filed-list code-cont"
>
<img
class=
"icon-img"
src=
"@assets/images/login/yzm.png"
/>
<img
class=
"icon-img"
src=
"@assets/images/login/yzm.png"
/>
<van-field
v-model.trim=
"code"
type=
"text"
placeholder=
"请输入验证码"
maxlength=
"6"
/>
<van-field
<div
class=
"code-btn"
@
click=
"getCode"
>
{{
buttonText
}}
</div>
v-model.trim=
"code"
type=
"text"
placeholder=
"请输入验证码"
maxlength=
"6"
/>
<div
class=
"code-btn"
@
click=
"getCode"
>
{{
buttonText
}}
</div>
</div>
</div>
</div>
</div>
<div
class=
"login-btn"
@
click=
"goLogin"
>
立即登录
</div>
<div
class=
"login-btn"
@
click=
"goLogin"
>
立即登录
</div>
...
@@ -64,7 +74,7 @@ export default {
...
@@ -64,7 +74,7 @@ export default {
this
.
isSending
=
true
this
.
isSending
=
true
this
.
countDown
()
this
.
countDown
()
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
countDown
()
{
countDown
()
{
let
seconds
=
60
let
seconds
=
60
...
@@ -93,7 +103,7 @@ export default {
...
@@ -93,7 +103,7 @@ export default {
let
url
=
`
${
httpUrl
}${
wxLogin
}
?callBack=
${
t
}
&scopes=snsapi_userinfo&type=1`
let
url
=
`
${
httpUrl
}${
wxLogin
}
?callBack=
${
t
}
&scopes=snsapi_userinfo&type=1`
window
.
document
.
location
=
url
// url-
window
.
document
.
location
=
url
// url-
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
fetchData
(
to
,
from
)
{
fetchData
(
to
,
from
)
{
this
.
tel
=
''
// 手机号
this
.
tel
=
''
// 手机号
...
@@ -118,5 +128,5 @@ export default {
...
@@ -118,5 +128,5 @@ export default {
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/login/login.scss"
;
@import
'@assets/styles/login/login.scss'
;
</
style
>
</
style
>
src/views/my/admin_detail.vue
View file @
48cf7b31
...
@@ -5,28 +5,30 @@
...
@@ -5,28 +5,30 @@
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"title"
>
{{
order
.
order_status_display
}}
</div>
<div
class=
"title"
>
{{
order
.
order_status_display
}}
</div>
</div>
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-desc que-desc"
>
{{
order
.
repair_type
.
type_name
}}
-
{{
order
.
description
}}
</div>
<div
<div
class=
"item flex-h flex-vc"
>
class=
"item-desc que-desc"
<div
class=
"item-title"
>
服务地址:
</div>
>
{{
order
.
repair_type
.
type_name
}}
-
{{
order
.
description
}}
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
服务地址:
</div>
<div
<div
class=
"item-desc"
class=
"item-desc"
>
{{
order
.
region
.
region_name
}}
-
{{
order
.
room
.
room_name
}}
-
{{
order
.
address
}}
</div>
>
{{
order
.
region
.
region_name
}}
-
{{
order
.
room
.
room_name
}}
-
{{
order
.
address
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-desc"
>
{{
order
.
realname
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
realname
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(order)"
>
{{
order
.
telephone
}}
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(order)"
>
{{
order
.
telephone
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-desc"
>
2021-06-17 09:28:43
</div>
<div
class=
"item-desc"
>
{{
order
.
created_at
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc
"
>
<div
class=
"item flex-h flex-start
"
>
<div
class=
"item-title"
>
图片详情:
</div>
<div
class=
"item-title"
>
图片详情:
</div>
<div
<div
class=
"img"
class=
"img"
v-for=
"(child, index) in order.image"
v-for=
"(child, index) in order.image"
...
@@ -44,7 +46,7 @@
...
@@ -44,7 +46,7 @@
</div>
</div>
</div>
</div>
<div
class=
"material"
v-if=
"order.no_pay_order"
>
<div
class=
"material"
v-if=
"order.no_pay_order"
>
<div
class=
"item-title bz-title"
>
待支付耗材
</div>
<div
class=
"item-title bz-title specile-text"
>
待支付耗材:
</div>
<div
<div
class=
"no-pay ma-item flex-h flex-hb"
class=
"no-pay ma-item flex-h flex-hb"
v-for=
"(child, index) in order.no_pay_order.goods"
v-for=
"(child, index) in order.no_pay_order.goods"
...
@@ -60,9 +62,13 @@
...
@@ -60,9 +62,13 @@
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<div
class=
"material"
v-if=
"order.pay_order != ''"
>
<div
class=
"material"
v-if=
"order.pay_order != ''"
>
<div
class=
"item-title"
>
已支付耗材
</div>
<div
class=
"item-title"
>
已支付耗材:
</div>
<div
v-for=
"(parent, index) in order.pay_order"
:key=
"index"
>
<div
v-for=
"(parent, index) in order.pay_order"
:key=
"index"
>
<div
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in parent.goods"
:key=
"index"
>
<div
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in parent.goods"
:key=
"index"
>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
...
@@ -74,7 +80,7 @@
...
@@ -74,7 +80,7 @@
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<div
class=
"material"
v-if=
"order.free_material_order"
>
<div
class=
"material"
v-if=
"order.free_material_order"
>
<div
class=
"item-title bz-title"
>
备注耗材
</div>
<div
class=
"item-title bz-title"
>
备注耗材:
</div>
<div
<div
class=
"ma-item flex-h flex-hb"
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in order.free_material_order.goods"
v-for=
"(child, index) in order.free_material_order.goods"
...
@@ -82,7 +88,10 @@
...
@@ -82,7 +88,10 @@
>
>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
@
click=
"showAll(item,$event)"
>
{{
child
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
@
click=
"showAll(item,$event)"
>
{{
child
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3 text-line-one"
>
¥0
</div>
<div
class=
"one one3 text-line-one"
>
¥0
</div>
...
@@ -90,11 +99,11 @@
...
@@ -90,11 +99,11 @@
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_transfer"
>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_transfer"
>
<div
class=
"item-title"
>
转单备注:
</div>
<div
class=
"item-title"
>
转单备注:
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_transfer
.
remark
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_transfer
.
remark
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_cancel"
>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_cancel"
>
<div
class=
"item-title"
>
退回备注:
</div>
<div
class=
"item-title"
>
退回备注:
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_cancel
.
remark
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_cancel
.
remark
}}
</div>
</div>
</div>
<div
v-if=
"order.is_can_assign_worker==1"
>
<div
v-if=
"order.is_can_assign_worker==1"
>
...
@@ -107,7 +116,9 @@
...
@@ -107,7 +116,9 @@
<div
class=
"wo flex-h flex-vc"
>
<div
class=
"wo flex-h flex-vc"
>
<div
class=
"item-title"
v-if=
"order.order_status_display == '已派工'"
>
重新派工:
</div>
<div
class=
"item-title"
v-if=
"order.order_status_display == '已派工'"
>
重新派工:
</div>
<div
class=
"item-title"
v-else
>
派工对象:
</div>
<div
class=
"item-title"
v-else
>
派工对象:
</div>
<div
class=
"item-desc worker-name"
>
{{
workerName
.
length
?
workerName
.
join
(
'
,
'
)
:
''
}}
</div>
<div
class=
"item-desc worker-name"
>
{{
workerName
.
length
?
workerName
.
join
(
'
,
'
)
:
''
}}
</div>
</div>
</div>
<div
class=
"flex-h flex-vc"
>
<div
class=
"flex-h flex-vc"
>
<div
class=
"select flex-h flex-vc"
>
<div
class=
"select flex-h flex-vc"
>
...
@@ -119,7 +130,11 @@
...
@@ -119,7 +130,11 @@
</div>
</div>
<div
class=
"line"
></div>
<div
class=
"line"
></div>
<div
class=
"allBtn flex-h flex-hr"
>
<div
class=
"allBtn flex-h flex-hr"
>
<div
v-if=
"order.is_can_assign_worker==1"
class=
"button sureBtn"
@
click=
"sureOrder"
>
确定
</div>
<div
v-if=
"order.is_can_assign_worker==1"
class=
"button sureBtn"
@
click=
"sureOrder"
>
确定
</div>
<div
v-if=
"order.is_can_cancel==1"
class=
"button"
@
click=
"cancelOrder"
>
取消
</div>
<div
v-if=
"order.is_can_cancel==1"
class=
"button"
@
click=
"cancelOrder"
>
取消
</div>
</div>
</div>
...
@@ -128,7 +143,11 @@
...
@@ -128,7 +143,11 @@
<div
class=
"tc-box"
>
<div
class=
"tc-box"
>
<div
class=
"tc-title"
>
选择工人
</div>
<div
class=
"tc-title"
>
选择工人
</div>
<div
class=
"workers"
>
<div
class=
"workers"
>
<div
class=
"gr-item"
v-for=
"(child_item,child_index) in columns"
:key=
"child_index"
>
<div
class=
"gr-item"
v-for=
"(child_item,child_index) in columns"
:key=
"child_index"
>
<div
class=
"bm-item"
>
{{
child_item
.
name
}}
</div>
<div
class=
"bm-item"
>
{{
child_item
.
name
}}
</div>
<div
v-if=
"child_item.user.length"
>
<div
v-if=
"child_item.user.length"
>
<div
<div
...
@@ -138,7 +157,7 @@
...
@@ -138,7 +157,7 @@
@
click=
"chooseWorker(lchild_item,lchild_index)"
@
click=
"chooseWorker(lchild_item,lchild_index)"
>
>
<div
class=
"flex-h flex-vc"
>
<div
class=
"flex-h flex-vc"
>
<img
class=
"gr-img"
:src=
"gr_i
mg"
/>
<img
class=
"gr-img"
:src=
"grI
mg"
/>
<div
<div
class=
"gr-name"
class=
"gr-name"
v-if=
"lchild_item.repired_count !== 0 || lchild_item.repiring_count !== 0"
v-if=
"lchild_item.repired_count !== 0 || lchild_item.repiring_count !== 0"
...
@@ -147,7 +166,7 @@
...
@@ -147,7 +166,7 @@
</div>
</div>
<img
<img
class=
"k-img"
class=
"k-img"
:src=
"temporaryId && temporaryId.includes(lchild_item.id) ? select_img : unselect_i
mg"
:src=
"temporaryId && temporaryId.includes(lchild_item.id) ? selectImg : unselectI
mg"
/>
/>
</div>
</div>
</div>
</div>
...
@@ -180,24 +199,23 @@
...
@@ -180,24 +199,23 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
trimStrSpace
}
from
'
@assets/js/format.js
'
//
import { trimStrSpace } from '@assets/js/format.js'
import
{
ImagePreview
,
CellGroup
}
from
'
vant
'
;
import
{
ImagePreview
}
from
'
vant
'
import
select
_i
mg
from
'
@assets/images/select.png
'
import
select
I
mg
from
'
@assets/images/select.png
'
import
unselect
_i
mg
from
'
@assets/images/un_select.png
'
import
unselect
I
mg
from
'
@assets/images/un_select.png
'
import
gr
_i
mg
from
'
@assets/images/gr.png
'
import
gr
I
mg
from
'
@assets/images/gr.png
'
export
default
{
export
default
{
name
:
'
admin_detail
'
,
name
:
'
admin_detail
'
,
data
()
{
data
()
{
return
{
return
{
showWorker
:
false
,
showWorker
:
false
,
select
_i
mg
,
select
I
mg
,
unselect
_i
mg
,
unselect
I
mg
,
gr
_i
mg
,
gr
I
mg
,
reson
:
''
,
//
取消原因
reson
:
''
,
//
取消原因
qxShow
:
false
,
// 发起转单弹窗
qxShow
:
false
,
// 发起转单弹窗
workerName
:
''
,
workerName
:
''
,
worker_id
:
''
,
worker_id
:
''
,
showWorker
:
false
,
columns
:
[],
columns
:
[],
locked
:
false
,
locked
:
false
,
// 上拉加载
// 上拉加载
...
@@ -210,20 +228,14 @@ export default {
...
@@ -210,20 +228,14 @@ export default {
order
:
null
,
order
:
null
,
order_id
:
''
,
order_id
:
''
,
temporaryName
:
''
,
temporaryName
:
''
,
temporaryId
:
''
,
temporaryId
:
''
}
}
},
},
created
()
{
this
.
order_id
=
this
.
$route
.
query
.
id
// this.order_id = 211
this
.
getDetail
()
this
.
getWorkers
()
},
methods
:
{
methods
:
{
goBack
()
{
goBack
()
{
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'
/
'
path
:
'
/
'
}).
catch
(()
=>
{
})
}).
catch
(()
=>
{
})
},
},
getDetail
()
{
getDetail
()
{
this
.
isloading
=
true
this
.
isloading
=
true
...
@@ -234,8 +246,8 @@ export default {
...
@@ -234,8 +246,8 @@ export default {
.
then
(
res
=>
{
.
then
(
res
=>
{
this
.
order
=
res
.
order
this
.
order
=
res
.
order
this
.
workerName
=
[]
this
.
workerName
=
[]
this
.
temporaryName
=
[]
this
.
temporaryName
=
[]
this
.
temporaryId
=
[]
this
.
temporaryId
=
[]
this
.
worker_id
=
[]
this
.
worker_id
=
[]
this
.
locked
=
false
this
.
locked
=
false
this
.
isloading
=
false
this
.
isloading
=
false
...
@@ -246,10 +258,10 @@ export default {
...
@@ -246,10 +258,10 @@ export default {
})
})
},
},
// 选择完工人点击确定按钮
// 选择完工人点击确定按钮
keyConfirm
()
{
keyConfirm
()
{
console
.
log
(
'
this.temporaryId
'
,
this
.
temporaryId
);
console
.
log
(
'
this.temporaryId
'
,
this
.
temporaryId
)
console
.
log
(
'
this.temporaryName
'
,
this
.
temporaryName
);
console
.
log
(
'
this.temporaryName
'
,
this
.
temporaryName
)
if
(
!
this
.
temporaryId
.
length
)
{
if
(
!
this
.
temporaryId
.
length
)
{
this
.
$toast
(
'
请选择工人!
'
)
this
.
$toast
(
'
请选择工人!
'
)
return
return
}
}
...
@@ -257,34 +269,34 @@ export default {
...
@@ -257,34 +269,34 @@ export default {
this
.
worker_id
=
[...
this
.
temporaryId
]
this
.
worker_id
=
[...
this
.
temporaryId
]
this
.
showWorker
=
false
this
.
showWorker
=
false
},
},
chooseWorker
(
item
,
lchild_index
)
{
chooseWorker
(
item
,
lchild_index
)
{
console
.
log
(
'
11111111111
'
,
item
,
item
.
id
,
item
.
name
,
lchild_index
);
console
.
log
(
'
11111111111
'
,
item
,
item
.
id
,
item
.
name
,
lchild_index
)
if
(
this
.
temporaryId
.
includes
(
item
.
id
))
{
// 删除
if
(
this
.
temporaryId
.
includes
(
item
.
id
))
{
// 删除
le
t
name_i
=
this
.
temporaryId
.
indexOf
(
item
.
id
)
cons
t
name_i
=
this
.
temporaryId
.
indexOf
(
item
.
id
)
this
.
temporaryId
.
splice
(
name_i
,
1
)
this
.
temporaryId
.
splice
(
name_i
,
1
)
this
.
temporaryName
.
splice
(
name_i
,
1
)
this
.
temporaryName
.
splice
(
name_i
,
1
)
}
else
{
// 加入
}
else
{
// 加入
this
.
temporaryId
.
push
(
item
.
id
)
this
.
temporaryId
.
push
(
item
.
id
)
this
.
temporaryName
.
push
(
item
.
name
)
this
.
temporaryName
.
push
(
item
.
name
)
}
}
},
},
preview
(
img
,
index
)
{
preview
(
img
,
index
)
{
let
temp
=
img
.
map
(
item
=>
{
const
temp
=
img
.
map
(
item
=>
{
return
item
.
url
return
item
.
url
})
})
ImagePreview
({
ImagePreview
({
images
:
temp
,
images
:
temp
,
startPosition
:
index
,
startPosition
:
index
});
})
},
},
callPhone
(
item
)
{
callPhone
(
item
)
{
le
t
phoneNumber
=
item
.
telephone
cons
t
phoneNumber
=
item
.
telephone
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
},
},
//指派工人
//
指派工人
sureOrder
()
{
sureOrder
()
{
const
vm
=
this
const
vm
=
this
if
(
!
this
.
worker_id
.
length
)
{
if
(
!
this
.
worker_id
.
length
)
{
this
.
$toast
(
'
请选择工人
'
)
this
.
$toast
(
'
请选择工人
'
)
return
return
}
}
...
@@ -295,31 +307,31 @@ export default {
...
@@ -295,31 +307,31 @@ export default {
this
.
$http
this
.
$http
.
post
(
this
.
$myApi
.
REPAIR_ASSIGN
,
curParams
)
.
post
(
this
.
$myApi
.
REPAIR_ASSIGN
,
curParams
)
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
console
.
log
(
'
指派工人
'
,
data
);
console
.
log
(
'
指派工人
'
,
data
)
this
.
$toast
(
'
操作成功
'
)
this
.
$toast
(
'
操作成功
'
)
this
.
workerName
=
[]
this
.
workerName
=
[]
this
.
temporaryName
=
[]
this
.
temporaryName
=
[]
this
.
temporaryId
=
[]
this
.
temporaryId
=
[]
this
.
worker_id
=
[]
this
.
worker_id
=
[]
this
.
reason
=
''
this
.
reason
=
''
this
.
order
=
data
this
.
order
=
data
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
// 取消工单
// 取消工单
cancelOrder
()
{
cancelOrder
()
{
this
.
qxShow
=
true
;
this
.
qxShow
=
true
this
.
reason
=
''
this
.
reason
=
''
},
},
workers
()
{
workers
()
{
this
.
showWorker
=
true
this
.
showWorker
=
true
},
},
Cancel
()
{
Cancel
()
{
this
.
showWorker
=
false
this
.
showWorker
=
false
},
},
//获取工人列表
//
获取工人列表
getWorkers
()
{
getWorkers
()
{
const
curParams
=
{}
const
curParams
=
{}
this
.
$http
this
.
$http
.
get
(
this
.
$myApi
.
GET_WORKER
,
curParams
)
.
get
(
this
.
$myApi
.
GET_WORKER
,
curParams
)
...
@@ -371,11 +383,26 @@ export default {
...
@@ -371,11 +383,26 @@ export default {
cancel
()
{
cancel
()
{
this
.
qxShow
=
false
this
.
qxShow
=
false
},
},
fetchData
(
to
,
from
)
{
this
.
order_id
=
to
.
query
?
to
.
query
.
id
:
''
if
(
this
.
order_id
)
{
this
.
getDetail
()
this
.
getWorkers
()
}
}
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
vm
.
fetchData
(
to
,
from
,
next
)
})
},
beforeRouteLeave
(
to
,
from
,
next
)
{
next
()
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/tabbar/admin_index.scss"
;
@import
'@assets/styles/tabbar/admin_index.scss'
;
</
style
>
</
style
>
src/views/my/charge.vue
View file @
48cf7b31
...
@@ -2,51 +2,68 @@
...
@@ -2,51 +2,68 @@
<div
class=
"cont"
v-if=
"order"
>
<div
class=
"cont"
v-if=
"order"
>
<div
class=
"top"
>
<div
class=
"top"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"title"
>
维修类目
:
</div>
<div
class=
"title"
>
维修类目
:
</div>
<div
class=
"title"
>
{{
order
.
repair_type
.
type_name
}}
</div>
<div
class=
"title"
>
{{
order
.
repair_type
.
type_name
}}
</div>
</div>
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-desc que-desc"
>
{{
order
.
repair_type
.
type_name
}}
-
{{
order
.
description
}}
</div>
<div
class=
"item-desc que-desc"
>
<div
class=
"item flex-h flex-vc"
>
{{
order
.
repair_type
.
type_name
}}
-
{{
order
.
description
}}
<div
class=
"item-title"
>
服务地址:
</div>
</div>
<div
class=
"item-desc"
>
{{
order
.
region
.
region_name
}}
-
{{
order
.
room
.
room_name
}}
-
{{
order
.
address
}}
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
服务地址:
</div>
<div
class=
"item-desc"
>
{{
order
.
region
.
region_name
}}
-
{{
order
.
room
.
room_name
}}
-
{{
order
.
address
}}
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-desc"
>
{{
order
.
realname
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-desc
phone"
@
click=
"callPhone(order)"
>
{{
order
.
telephone
}}
</div>
<div
class=
"item-desc
"
>
{{
order
.
realname
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-desc"
>
2021-06-17 09:28:43
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(order)"
>
{{
order
.
telephone
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
图片详情:
</div>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"img flex-h"
v-for=
"(child, index) in order.image"
:key=
"index"
@
click=
"preview(order.image,index)"
>
<div
class=
"item-desc"
>
{{
order
.
created_at
}}
</div>
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
图片详情:
</div>
<div
class=
"img flex-h"
v-for=
"(child, index) in order.image"
:key=
"index"
@
click=
"preview(order.image, index)"
>
<img
:src=
"child.url"
alt
/>
<img
:src=
"child.url"
alt
/>
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"things"
>
<div
class=
"things"
>
<div
class=
"things_title"
>
所需耗材
</div>
<div
class=
"things_title"
>
所需耗材
</div>
<div
class=
"list-item"
v-for=
"(item,index) in addList"
:key=
"index"
>
<div
<div
class=
"item flex-h flex-hb"
@
click=
"showZl(index)"
>
class=
"list-item"
v-for=
"(item, index) in addList"
:key=
"index"
>
<div
class=
"item flex-h flex-hb"
@
click=
"showZl(index)"
>
<div
class=
"item_title flex-h flex-vc"
>
<div
class=
"item_title flex-h flex-vc"
>
<div
class=
"title_left"
>
耗材种类
</div>
<div
class=
"title_left"
>
耗材种类
</div>
<div
class=
"title_r"
>
{{
item
.
zl
}}
</div>
<div
class=
"title_r"
>
{{
item
.
zl
}}
</div>
</div>
</div>
<div
class=
"select flex-h flex-vc"
>
<div
class=
"select flex-h flex-vc"
>
<div
class=
"select_txt"
>
选择
</div>
<div
class=
"select_txt"
>
选择
</div>
<img
src=
"@assets/images/my/select.png"
alt
/>
<img
src=
"@assets/images/my/select.png"
alt
/>
</div>
</div>
</div>
</div>
<div
class=
"item flex-h flex-hb"
@
click=
"showHc(index)"
>
<div
class=
"item flex-h flex-hb"
@
click=
"showHc(index)"
>
<div
class=
"item_title flex-h flex-vc"
>
<div
class=
"item_title flex-h flex-vc"
>
<div
class=
"title_left"
>
耗材名称
</div>
<div
class=
"title_left"
>
耗材名称
</div>
<div
class=
"title_r"
>
{{
item
.
mc
}}
</div>
<div
class=
"title_r"
>
{{
item
.
mc
}}
</div>
</div>
</div>
<div
class=
"select flex-h flex-vc"
>
<div
class=
"select flex-h flex-vc"
>
<div
class=
"select_txt"
>
选择
</div>
<div
class=
"select_txt"
>
选择
</div>
...
@@ -55,33 +72,52 @@
...
@@ -55,33 +72,52 @@
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"title_left"
>
耗材个数
</div>
<div
class=
"title_left"
>
耗材个数
</div>
<input
type=
"tel"
:min=
"1"
maxlength=
"3"
placeholder=
"请输入"
v-model=
"item.number"
@
input=
"changeInput($event,index)"
/>
<input
type=
"tel"
:min=
"1"
maxlength=
"3"
placeholder=
"请输入"
v-model=
"item.number"
@
input=
"changeInput($event, index)"
/>
<!--
<van-field
class=
"hc_field"
v-model=
"item.number"
type=
"number"
placeholder=
"请输入"
maxlength=
"3"
@
input=
"changeInput(item,index)"
/>
-->
<!--
<van-field
class=
"hc_field"
v-model=
"item.number"
type=
"number"
placeholder=
"请输入"
maxlength=
"3"
@
input=
"changeInput(item,index)"
/>
-->
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"title_left"
>
耗材单价
</div>
<div
class=
"title_left"
>
耗材单价
</div>
<div
class=
"title_r"
>
{{
item
.
single_price
}}
</div>
<div
class=
"title_r"
>
{{
item
.
single_price
}}
</div>
</div>
</div>
<div
v-if=
"addList.length>1"
class=
"delete-btn"
@
click=
"delMeth(index)"
>
<div
<img
src=
"@assets/images/lajitong.png"
alt=
""
>
v-if=
"addList.length > 1"
class=
"delete-btn"
@
click=
"delMeth(index)"
>
<img
src=
"@assets/images/lajitong.png"
alt=
""
/>
</div>
</div>
<!-- 种类弹窗 -->
<!-- 种类弹窗 -->
<van-popup
v-model=
"item.zlSelect"
round
position=
"bottom"
>
<van-popup
v-model=
"item.zlSelect"
round
position=
"bottom"
>
<van-picker
<van-picker
show-toolbar
show-toolbar
:columns=
"types"
:columns=
"types"
value-key=
"goods_name"
value-key=
"goods_name"
@
confirm=
"(value)=>
{typeConfirm(value,index)}"
@
confirm=
"
(value) =>
{
typeConfirm(value, index)
}
"
@cancel="typeCancel(index)"
@cancel="typeCancel(index)"
/>
/>
</van-popup>
</van-popup>
<van-popup
v-model=
"item.mcSelect"
round
position=
"bottom"
>
<van-popup
v-model=
"item.mcSelect"
round
position=
"bottom"
>
<van-picker
<van-picker
show-toolbar
show-toolbar
:columns=
"hcName"
:columns=
"hcName"
value-key=
"goods_name"
value-key=
"goods_name"
@
confirm=
"(value)=>
{hcConfirm(value,index)}"
@
confirm=
"
(value) =>
{
hcConfirm(value, index)
}
"
@cancel="hcCancel(index)"
@cancel="hcCancel(index)"
/>
/>
</van-popup>
</van-popup>
...
@@ -89,43 +125,43 @@
...
@@ -89,43 +125,43 @@
<div
class=
"line"
></div>
<div
class=
"line"
></div>
<div
class=
"add-btn flex-h flex-vc flex-hb"
>
<div
class=
"add-btn flex-h flex-vc flex-hb"
>
<!--
<div
v-if=
"addList.length>1"
class=
"del-btn"
@
click=
"delMeth"
>
-删除耗材
</div>
-->
<!--
<div
v-if=
"addList.length>1"
class=
"del-btn"
@
click=
"delMeth"
>
-删除耗材
</div>
-->
<div
class=
"add-btn"
@
click=
"addMeth"
>
+新增耗材
</div>
<div
class=
"add-btn"
@
click=
"addMeth"
>
+新增耗材
</div>
</div>
</div>
</div>
</div>
<div
class=
"blank"
></div>
<div
class=
"blank"
></div>
<!-- 底部 -->
<!-- 底部 -->
<div
class=
"bottom flex-h flex-hb flex-vc"
>
<div
class=
"bottom flex-h flex-hb flex-vc"
>
<div
class=
"left"
>
<div
class=
"left"
>
共
共
<span>
{{
goods_number
}}
</span>
件,总金额:
<span>
{{
goods_number
}}
</span>
件,总金额:
<!--
<span
v-if=
"isNaN(total_price)"
>
¥暂无
</span>
-->
<!--
<span
v-if=
"isNaN(total_price)"
>
¥暂无
</span>
-->
<span>
¥
{{
total_price
}}
</span>
<span>
¥
{{
total_price
}}
</span>
</div>
</div>
<div
class=
"skBtn"
@
click=
"launch(repair_order_id)"
>
发起收款
</div>
<div
class=
"skBtn"
@
click=
"launch(repair_order_id)"
>
发起收款
</div>
</div>
</div>
<!-- 底部返回按钮 -->
<!-- 底部返回按钮 -->
<div
class=
"backBtn"
@
click=
"goBack"
>
<div
class=
"backBtn"
@
click=
"goBack"
>
<img
src=
"@assets/images/back3.png"
alt=
""
>
<img
src=
"@assets/images/back3.png"
alt=
""
/
>
</div>
</div>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
ImagePreview
}
from
'
vant
'
;
import
{
ImagePreview
}
from
'
vant
'
import
{
REFRESH_LIST
,
setLocalStorage
}
from
'
@assets/js/self.js
'
export
default
{
export
default
{
name
:
'
charge
'
,
name
:
'
charge
'
,
data
()
{
data
()
{
return
{
return
{
addList
:[
addList
:
[
{
{
zl
:
''
,
zl
:
''
,
mc
:
''
,
mc
:
''
,
number
:
''
,
number
:
''
,
single_price
:
'
暂无
'
,
single_price
:
'
暂无
'
,
zlSelect
:
false
,
zlSelect
:
false
,
mcSelect
:
false
,
mcSelect
:
false
,
parent_id
:
''
,
parent_id
:
''
,
goods_id
:
''
,
goods_id
:
''
}
}
],
],
showPicker
:
false
,
showPicker
:
false
,
...
@@ -140,44 +176,40 @@ export default {
...
@@ -140,44 +176,40 @@ export default {
hcList
:
[],
hcList
:
[],
total_price
:
0
,
total_price
:
0
,
hc_price
:
''
,
hc_price
:
''
,
goods_number
:
0
,
goods_number
:
0
}
}
},
},
created
()
{
watch
:
{
this
.
repair_order_id
=
this
.
$route
.
query
.
id
addList
:
{
this
.
getDetail
()
handler
(
newValue
,
oldValue
)
{
},
const
filterValue
=
newValue
.
filter
(
item
=>
{
watch
:{
addList
:{
handler
(
newValue
,
oldValue
){
let
filterValue
=
newValue
.
filter
(
item
=>
{
return
(
item
.
zl
&&
item
.
mc
&&
item
.
number
)
return
(
item
.
zl
&&
item
.
mc
&&
item
.
number
)
})
})
if
(
filterValue
.
length
)
{
if
(
filterValue
.
length
)
{
this
.
getMonery
(
filterValue
)
this
.
getMonery
(
filterValue
)
}
else
{
}
else
{
this
.
total_price
=
0
this
.
total_price
=
0
}
}
},
},
deep
:
true
deep
:
true
}
,
}
},
},
methods
:
{
methods
:
{
goBack
()
{
goBack
()
{
this
.
$router
.
go
(
-
1
);
this
.
$router
.
go
(
-
1
)
},
},
callPhone
(
order
)
{
callPhone
(
order
)
{
le
t
phoneNumber
=
order
.
telephone
cons
t
phoneNumber
=
order
.
telephone
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
},
},
preview
(
img
,
index
)
{
preview
(
img
,
index
)
{
let
temp
=
img
.
map
(
item
=>
{
const
temp
=
img
.
map
(
item
=>
{
return
item
.
url
return
item
.
url
})
})
ImagePreview
({
ImagePreview
({
images
:
temp
,
images
:
temp
,
startPosition
:
index
,
startPosition
:
index
})
;
})
},
},
getDetail
()
{
getDetail
()
{
const
curParams
=
{
const
curParams
=
{
...
@@ -187,7 +219,7 @@ export default {
...
@@ -187,7 +219,7 @@ export default {
.
then
(
res
=>
{
.
then
(
res
=>
{
this
.
order
=
res
.
order
this
.
order
=
res
.
order
var
arr
=
[]
var
arr
=
[]
for
(
let
i
in
res
.
material
)
{
for
(
const
i
in
res
.
material
)
{
arr
.
push
({
arr
.
push
({
id
:
res
.
material
[
i
].
id
,
id
:
res
.
material
[
i
].
id
,
goods_name
:
res
.
material
[
i
].
goods_name
,
goods_name
:
res
.
material
[
i
].
goods_name
,
...
@@ -196,13 +228,13 @@ export default {
...
@@ -196,13 +228,13 @@ export default {
}
}
this
.
types
=
arr
this
.
types
=
arr
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
showZl
(
index
)
{
showZl
(
index
)
{
this
.
addList
[
index
].
zlSelect
=
true
this
.
addList
[
index
].
zlSelect
=
true
},
},
typeConfirm
(
value
,
index
)
{
typeConfirm
(
value
,
index
)
{
if
(
value
.
id
==
this
.
addList
[
index
].
parent_id
)
{
if
(
value
.
id
==
this
.
addList
[
index
].
parent_id
)
{
this
.
addList
[
index
].
zlSelect
=
false
this
.
addList
[
index
].
zlSelect
=
false
return
return
}
}
...
@@ -216,7 +248,7 @@ export default {
...
@@ -216,7 +248,7 @@ export default {
this
.
addList
[
index
].
single_price
=
''
this
.
addList
[
index
].
single_price
=
''
var
childArr
=
[]
var
childArr
=
[]
for
(
let
i
in
value
.
son
)
{
for
(
const
i
in
value
.
son
)
{
childArr
.
push
({
childArr
.
push
({
id
:
value
.
son
[
i
].
id
,
id
:
value
.
son
[
i
].
id
,
goods_name
:
value
.
son
[
i
].
goods_name
,
goods_name
:
value
.
son
[
i
].
goods_name
,
...
@@ -226,45 +258,44 @@ export default {
...
@@ -226,45 +258,44 @@ export default {
this
.
hcName
=
childArr
this
.
hcName
=
childArr
// this.getMonery()
// this.getMonery()
},
},
typeCancel
(
index
)
{
typeCancel
(
index
)
{
this
.
addList
[
index
].
zlSelect
=
false
this
.
addList
[
index
].
zlSelect
=
false
},
},
showHc
(
index
)
{
showHc
(
index
)
{
this
.
addList
[
index
].
mcSelect
=
true
this
.
addList
[
index
].
mcSelect
=
true
},
},
hcConfirm
(
value
,
index
)
{
hcConfirm
(
value
,
index
)
{
this
.
addList
[
index
].
mc
=
value
.
goods_name
this
.
addList
[
index
].
mc
=
value
.
goods_name
this
.
addList
[
index
].
single_price
=
value
.
single_price
this
.
addList
[
index
].
single_price
=
value
.
single_price
this
.
addList
[
index
].
mcSelect
=
false
this
.
addList
[
index
].
mcSelect
=
false
this
.
addList
[
index
].
goods_id
=
value
.
id
this
.
addList
[
index
].
goods_id
=
value
.
id
this
.
hc_price
=
this
.
addList
[
index
].
single_price
this
.
hc_price
=
this
.
addList
[
index
].
single_price
let
bool
=
this
.
addList
.
every
(
item
=>
{
const
bool
=
this
.
addList
.
every
(
item
=>
{
return
item
.
number
&&
item
.
mc
&&
item
.
zl
return
item
.
number
&&
item
.
mc
&&
item
.
zl
})
})
// this.getMonery()
// this.getMonery()
},
},
changeInput
(
e
,
index
)
{
changeInput
(
e
,
index
)
{
this
.
hc_number
=
e
.
target
.
value
this
.
hc_number
=
e
.
target
.
value
this
.
totalCount
()
this
.
totalCount
()
},
},
getMonery
(
filterList
)
{
getMonery
(
filterList
)
{
let
total_price
=
0
let
total_price
=
0
filterList
.
map
(
item
=>
{
filterList
.
map
(
item
=>
{
total_price
+=
Number
(
item
.
number
)
*
Number
(
item
.
single_price
)
total_price
+=
Number
(
item
.
number
)
*
Number
(
item
.
single_price
)
})
})
this
.
total_price
=
Number
(
total_price
)
this
.
total_price
=
Number
(
total_price
)
// console.log('总价钱',total_price);
// console.log('总价钱',total_price);
},
},
totalCount
()
{
totalCount
()
{
let
count
=
0
let
count
=
0
for
(
let
i
=
0
;
i
<
this
.
addList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
this
.
addList
.
length
;
i
++
)
{
count
+=
Number
(
this
.
addList
[
i
].
number
)
count
+=
Number
(
this
.
addList
[
i
].
number
)
}
}
this
.
goods_number
=
count
this
.
goods_number
=
count
},
},
hcCancel
(
index
)
{
hcCancel
(
index
)
{
this
.
addList
[
index
].
mcSelect
=
false
this
.
addList
[
index
].
mcSelect
=
false
},
},
addMeth
()
{
addMeth
()
{
...
@@ -277,29 +308,28 @@ export default {
...
@@ -277,29 +308,28 @@ export default {
mcSelect
:
false
mcSelect
:
false
})
})
},
},
delMeth
(
index
)
{
delMeth
(
index
)
{
this
.
$dialog
.
confirm
({
this
.
$dialog
.
confirm
({
title
:
'
提示
'
,
title
:
'
提示
'
,
message
:
'
确认删除吗?
'
message
:
'
确认删除吗?
'
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
addList
.
splice
(
index
,
1
)
this
.
addList
.
splice
(
index
,
1
)
// this.getMonery()
// this.getMonery()
this
.
totalCount
()
this
.
totalCount
()
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
launch
(
id
)
{
launch
(
id
)
{
let
bool
=
this
.
addList
.
every
(
item
=>
{
const
bool
=
this
.
addList
.
every
(
item
=>
{
return
item
.
number
&&
item
.
mc
&&
item
.
zl
return
item
.
number
&&
item
.
mc
&&
item
.
zl
})
})
if
(
!
bool
)
{
if
(
!
bool
)
{
this
.
$toast
.
fail
(
'
请输入完整
'
)
this
.
$toast
.
fail
(
'
请输入完整
'
)
return
return
}
}
for
(
let
i
=
0
;
i
<
this
.
addList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
this
.
addList
.
length
;
i
++
)
{
if
(
this
.
addList
[
i
].
number
==
0
)
{
if
(
this
.
addList
[
i
].
number
==
0
)
{
this
.
$toast
(
'
耗材个数不能为0
'
)
this
.
$toast
(
'
耗材个数不能为0
'
)
return
return
}
}
...
@@ -311,13 +341,28 @@ export default {
...
@@ -311,13 +341,28 @@ export default {
// const _this = this
// const _this = this
this
.
$http
.
post
(
this
.
$myApi
.
REPAIR_ORDER
,
curParams
)
this
.
$http
.
post
(
this
.
$myApi
.
REPAIR_ORDER
,
curParams
)
.
then
(
res
=>
{
.
then
(
res
=>
{
console
.
log
(
'
执行了吗
'
)
;
console
.
log
(
'
执行了吗
'
)
this
.
$toast
.
success
(
'
发起成功
'
)
this
.
$toast
.
success
(
'
发起成功
'
)
this
.
$router
.
go
(
-
1
)
this
.
$router
.
go
(
-
1
)
setLocalStorage
(
REFRESH_LIST
,
true
)
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
fetchData
(
to
,
from
)
{
this
.
repair_order_id
=
to
.
query
?
to
.
query
.
id
:
''
if
(
this
.
repair_order_id
)
{
this
.
getDetail
()
}
}
},
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
vm
.
fetchData
(
to
,
from
,
next
)
})
},
beforeRouteLeave
(
to
,
from
,
next
)
{
next
()
}
}
}
</
script
>
</
script
>
...
@@ -326,8 +371,9 @@ export default {
...
@@ -326,8 +371,9 @@ export default {
min-height
:
100vh
;
min-height
:
100vh
;
background
:
#fff
;
background
:
#fff
;
padding-top
:
0
.2rem
;
padding-top
:
0
.2rem
;
font-size
:
0
.4rem
;
}
}
.backBtn
{
.backBtn
{
width
:
1rem
;
width
:
1rem
;
height
:
1rem
;
height
:
1rem
;
background
:
#fff
;
background
:
#fff
;
...
@@ -339,7 +385,7 @@ export default {
...
@@ -339,7 +385,7 @@ export default {
border-radius
:
50%
;
border-radius
:
50%
;
padding
:
0
.1rem
;
padding
:
0
.1rem
;
}
}
.backBtn
img
{
.backBtn
img
{
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
border-radius
:
50%
;
border-radius
:
50%
;
...
@@ -353,29 +399,30 @@ export default {
...
@@ -353,29 +399,30 @@ export default {
margin
:
0rem
auto
;
margin
:
0rem
auto
;
}
}
.item
{
.item
{
height
:
0
.3rem
;
// height: 0.3rem;
margin-bottom
:
0
.4rem
;
margin-bottom
:
0
.2rem
;
font-size
:
0
.4rem
;
}
}
.title
{
.title
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.32
rem
;
// font-size: 0.4
rem;
font-weight
:
bold
;
font-weight
:
bold
;
}
}
.item-title
{
.item-title
{
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.3
rem
;
// font-size: 0.4
rem;
white-space
:
nowrap
;
white-space
:
nowrap
;
}
}
.hc_field
{
.hc_field
{
padding
:
0
;
padding
:
0
;
}
}
.item-desc
{
.item-desc
{
color
:
#727272
;
color
:
#727272
;
font-size
:
0
.3rem
;
//
font-size: 0.3rem;
}
}
.que-desc
{
.que-desc
{
margin-top
:
0
.
4
rem
;
margin-top
:
0
.
2
rem
;
margin-bottom
:
0
.
4
rem
;
margin-bottom
:
0
.
2
rem
;
}
}
.phone
{
.phone
{
color
:
#0054ff
;
color
:
#0054ff
;
...
@@ -384,7 +431,7 @@ export default {
...
@@ -384,7 +431,7 @@ export default {
width
:
1
.2rem
;
width
:
1
.2rem
;
height
:
1
.2rem
;
height
:
1
.2rem
;
border-radius
:
0
.08rem
;
border-radius
:
0
.08rem
;
margin-top
:
0
.8rem
;
//
margin-top: 0.8rem;
margin-right
:
0
.16rem
;
margin-right
:
0
.16rem
;
border-radius
:
0
.08rem
;
border-radius
:
0
.08rem
;
}
}
...
@@ -403,7 +450,7 @@ export default {
...
@@ -403,7 +450,7 @@ export default {
}
}
.things_title
{
.things_title
{
color
:
#000000
;
color
:
#000000
;
font-size
:
0
.
3
rem
;
font-size
:
0
.
4
rem
;
font-weight
:
bold
;
font-weight
:
bold
;
margin-bottom
:
0
.4rem
;
margin-bottom
:
0
.4rem
;
}
}
...
@@ -413,11 +460,11 @@ export default {
...
@@ -413,11 +460,11 @@ export default {
}
}
.title_r
{
.title_r
{
color
:
#727272
;
color
:
#727272
;
font-size
:
0
.
3
rem
;
font-size
:
0
.
4
rem
;
}
}
.select
.select_txt
{
.select
.select_txt
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.
3
rem
;
font-size
:
0
.
4
rem
;
margin-right
:
0
.2rem
;
margin-right
:
0
.2rem
;
}
}
.select
img
{
.select
img
{
...
@@ -431,12 +478,13 @@ export default {
...
@@ -431,12 +478,13 @@ export default {
}
}
.add-btn
{
.add-btn
{
color
:
#0054ff
;
color
:
#0054ff
;
font-size
:
0
.
3
rem
;
font-size
:
0
.
4
rem
;
margin
:
0
.2rem
auto
0
;
margin
:
0
.2rem
auto
0
;
}
}
.list-item
{
.list-item
{
margin-bottom
:
0
.8rem
;
margin-bottom
:
0
.8rem
;
position
:
relative
;
position
:
relative
;
font-size
:
0
.4rem
;
}
}
.delete-btn
{
.delete-btn
{
width
:
0
.4rem
;
width
:
0
.4rem
;
...
@@ -445,7 +493,7 @@ export default {
...
@@ -445,7 +493,7 @@ export default {
bottom
:
0rem
;
bottom
:
0rem
;
right
:
0rem
;
right
:
0rem
;
}
}
.delete-btn
img
{
.delete-btn
img
{
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
}
}
...
@@ -457,7 +505,7 @@ export default {
...
@@ -457,7 +505,7 @@ export default {
width
:
100%
;
width
:
100%
;
height
:
1
.04rem
;
height
:
1
.04rem
;
background
:
#ffffff
;
background
:
#ffffff
;
padding-left
:
0
.3rem
;
padding-left
:
0
.3
4
rem
;
padding-right
:
0
.3rem
;
padding-right
:
0
.3rem
;
position
:
fixed
;
position
:
fixed
;
left
:
0
;
left
:
0
;
...
@@ -465,7 +513,7 @@ export default {
...
@@ -465,7 +513,7 @@ export default {
}
}
.left
{
.left
{
color
:
#000
;
color
:
#000
;
font-size
:
0
.
28
rem
;
font-size
:
0
.
36
rem
;
}
}
.left
span
{
.left
span
{
color
:
#0054ff
;
color
:
#0054ff
;
...
@@ -478,16 +526,21 @@ export default {
...
@@ -478,16 +526,21 @@ export default {
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.76rem
;
line-height
:
0
.76rem
;
color
:
#ffffff
;
color
:
#ffffff
;
font-size
:
0
.26rem
;
// font-size: 0.26rem;
font-size
:
0
.36rem
;
}
}
.skBtn
{
.skBtn
{
width
:
3
rem
;
width
:
2
.6
rem
;
height
:
0
.76rem
;
height
:
0
.76rem
;
background
:
#0054ff
;
background
:
#0054ff
;
border-radius
:
0
.38rem
;
border-radius
:
0
.38rem
;
text-align
:
center
;
text-align
:
center
;
line-height
:
0
.76rem
;
line-height
:
0
.76rem
;
color
:
#ffffff
;
color
:
#ffffff
;
font-size
:
0
.26rem
;
// font-size: 0.26rem;
font-size
:
0
.36rem
;
}
/
deep
/
.things
.van-ellipsis
{
font-size
:
0
.4rem
!
important
;
}
}
</
style
>
</
style
>
src/views/my/lookEvaluate.vue
View file @
48cf7b31
...
@@ -2,24 +2,48 @@
...
@@ -2,24 +2,48 @@
<div
class=
"cont"
>
<div
class=
"cont"
>
<div
class=
"evaluate-cont"
>
<div
class=
"evaluate-cont"
>
<div
class=
"title"
>
整体评价
</div>
<div
class=
"title"
>
整体评价
</div>
<van-rate
readonly
void-icon=
"star"
v-model=
"totalStar"
void-color=
"#eee"
color=
"#FFA300"
/>
<van-rate
readonly
void-icon=
"star"
v-model=
"totalStar"
void-color=
"#eee"
color=
"#FFA300"
/>
<div
class=
"eva_detail"
>
详细评价
</div>
<div
class=
"eva_detail"
>
详细评价
</div>
<div
class=
"flex-h star-item"
>
<div
class=
"flex-h star-item"
>
<div
class=
"left_title"
>
速度
</div>
<div
class=
"left_title"
>
速度
</div>
<van-rate
readonly
void-icon=
"star"
v-model=
"speedStar"
void-color=
"#eee"
color=
"#FFA300"
/>
<van-rate
readonly
void-icon=
"star"
v-model=
"speedStar"
void-color=
"#eee"
color=
"#FFA300"
/>
</div>
</div>
<div
class=
"flex-h star-item"
>
<div
class=
"flex-h star-item"
>
<div
class=
"left_title"
>
质量
</div>
<div
class=
"left_title"
>
质量
</div>
<van-rate
readonly
void-icon=
"star"
v-model=
"qualityStar"
void-color=
"#eee"
color=
"#FFA300"
/>
<van-rate
readonly
void-icon=
"star"
v-model=
"qualityStar"
void-color=
"#eee"
color=
"#FFA300"
/>
</div>
</div>
<div
class=
"flex-h star-item"
>
<div
class=
"flex-h star-item"
>
<div
class=
"left_title"
>
态度
</div>
<div
class=
"left_title"
>
态度
</div>
<van-rate
readonly
void-icon=
"star"
v-model=
"attitudeStar"
void-color=
"#eee"
color=
"#FFA300"
/>
<van-rate
readonly
void-icon=
"star"
v-model=
"attitudeStar"
void-color=
"#eee"
color=
"#FFA300"
/>
</div>
</div>
<div
class=
"line"
></div>
<div
class=
"line"
></div>
<div
class=
"comments"
>
<div
class=
"comments"
>
<div
class=
"title"
>
评价内容
</div>
<div
class=
"title"
>
评价内容
</div>
<div
class=
"content"
>
{{
comment
.
content
}}
</div>
<div
class=
"content"
>
{{
comment
.
content
}}
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -27,18 +51,18 @@
...
@@ -27,18 +51,18 @@
<
script
>
<
script
>
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
totalStar
:
0
,
totalStar
:
0
,
speedStar
:
0
,
speedStar
:
0
,
qualityStar
:
0
,
qualityStar
:
0
,
attitudeStar
:
0
,
attitudeStar
:
0
,
repair_order_id
:
''
,
repair_order_id
:
''
,
comment
:
''
,
comment
:
''
}
}
},
},
created
()
{
created
()
{
console
.
log
(
'
接收的id啊
'
,
this
.
$route
.
query
.
id
);
console
.
log
(
'
接收的id啊
'
,
this
.
$route
.
query
.
id
)
this
.
repair_order_id
=
this
.
$route
.
query
.
id
this
.
repair_order_id
=
this
.
$route
.
query
.
id
this
.
look_comment
()
this
.
look_comment
()
// this.getStatus()
// this.getStatus()
...
@@ -58,12 +82,12 @@ export default {
...
@@ -58,12 +82,12 @@ export default {
this
.
attitudeStar
=
Number
(
data
.
attitude_stars
)
this
.
attitudeStar
=
Number
(
data
.
attitude_stars
)
this
.
totalStar
=
Number
(
data
.
stars
)
this
.
totalStar
=
Number
(
data
.
stars
)
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
}
,
}
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/my/lookEvaluate.scss"
;
@import
'@assets/styles/my/lookEvaluate.scss'
;
</
style
>
</
style
>
src/views/my/order_detail.vue
View file @
48cf7b31
...
@@ -5,76 +5,84 @@
...
@@ -5,76 +5,84 @@
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
<div
class=
"title"
class=
"title"
v-if=
"order.pid==0&&order.son_count>
0"
v-if=
"order.pid == 0 && order.son_count >
0"
>
{{
order
.
order_status_display
}}
(负责人)
</div>
>
{{
order
.
order_status_display
}}
(负责人)
</div>
<div
class=
"title"
v-else
>
{{
order
.
order_status_display
}}
</div>
<div
class=
"title"
v-else
>
{{
order
.
order_status_display
}}
</div>
</div>
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-desc que-desc"
>
{{
order
.
repair_type
.
type_name
}}
-
{{
order
.
description
}}
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
服务地址:
</div>
<div
<div
class=
"item-desc"
class=
"item-desc que-desc"
>
{{
order
.
region
.
region_name
}}
-
{{
order
.
room
.
room_name
}}
-
{{
order
.
address
}}
</div>
>
{{
order
.
repair_type
.
type_name
}}
-
{{
order
.
description
}}
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
服务地址:
</div>
<div
class=
"item-desc"
>
{{
order
.
region
.
region_name
}}
-
{{
order
.
room
.
room_name
}}
-
{{
order
.
address
}}
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-desc"
>
{{
order
.
realname
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(order)"
>
{{
order
.
telephone
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
realname
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-desc"
>
2021-06-17 09:28:43
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(order)"
>
{{
order
.
telephone
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
图片详情:
</div>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-desc"
>
{{
order
.
created_at
}}
</div>
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
图片详情:
</div>
<div
<div
class=
"img"
class=
"img"
v-for=
"(child, index) in order.image"
v-for=
"(child, index) in order.image"
:key=
"index"
:key=
"index"
@
click=
"preview(order.image,
index)"
@
click=
"preview(order.image,
index)"
>
>
<img
:src=
"child.url"
alt
/>
<img
:src=
"child.url"
alt
/>
</div>
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
派工对象:
</div>
<div
class=
"item-title"
>
派工对象:
</div>
<div
class=
"item-desc"
>
{{
order
.
work_name
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
work_name
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-desc"
>
{{
order
.
telephone
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
telephone
}}
</div>
</div>
</div>
<div
class=
"material"
v-if=
"order.no_pay_order"
>
<div
class=
"material"
v-if=
"order.no_pay_order"
>
<div
class=
"item-title bz-title"
>
待支付耗材
</div>
<div
class=
"item-title bz-title specile-text"
>
待支付耗材:
</div>
<div
<div
class=
"no-pay ma-item flex-h flex-hb"
class=
"no-pay ma-item flex-h flex-hb"
v-for=
"(child, index) in order.no_pay_order.goods"
v-for=
"(child, index) in order.no_pay_order.goods"
:key=
"index"
:key=
"index"
>
>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
</div>
</div>
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<div
class=
"material"
v-if=
"order.pay_order != ''"
>
<div
class=
"material"
v-if=
"order.pay_order != ''"
>
<div
class=
"item-title"
>
已支付耗材
</div>
<div
class=
"item-title"
>
已支付耗材
</div>
<div
v-for=
"(parent, index) in order.pay_order"
:key=
"index"
>
<div
v-for=
"(parent, index) in order.pay_order"
:key=
"index"
>
<div
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in parent.goods"
:key=
"index"
>
<div
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in parent.goods"
:key=
"index"
>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<!--
<div
class=
"one"
>
{{
child
.
good_detail
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<!--
<div
class=
"one"
>
{{
child
.
good_detail
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
</div>
</div>
</div>
</div>
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
...
@@ -83,13 +91,17 @@
...
@@ -83,13 +91,17 @@
<div
class=
"item-title bz-title"
>
备注耗材
</div>
<div
class=
"item-title bz-title"
>
备注耗材
</div>
<div
<div
class=
"ma-item flex-h flex-hb"
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in order.free_material_order.goods"
v-for=
"(child, index) in order.free_material_order
.goods"
:key=
"index"
:key=
"index"
>
>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
@
click=
"showAll(item,$event)"
>
{{
child
.
goods_name
}}
</div>
<div
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
class=
"_one text-line-one"
@
click=
"showAll(item, $event)"
>
{{
child
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3 text-line-one"
>
¥0
</div>
<div
class=
"one one3 text-line-one"
>
¥0
</div>
</div>
</div>
...
@@ -97,39 +109,51 @@
...
@@ -97,39 +109,51 @@
</div>
</div>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_transfer"
>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_transfer"
>
<div
class=
"item-title"
>
转单备注:
</div>
<div
class=
"item-title"
>
转单备注:
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_transfer
.
remark
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_transfer
.
remark
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_cancel"
>
<div
class=
"item flex-h flex-start"
v-if=
"order.orderlog_cancel"
>
<div
class=
"item-title"
>
退回备注:
</div>
<div
class=
"item-title"
>
退回备注:
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_cancel
.
remark
}}
</div>
<div
class=
"item-desc"
>
{{
order
.
orderlog_cancel
.
remark
}}
</div>
</div>
</div>
<div
class=
"btn flex-h flex-hr"
v-if=
"btnShow"
>
<div
class=
"btn flex-h flex-hr flex-hw"
v-if=
"btnShow"
>
<div
v-if=
"order.is_can_remark_material==1"
class=
"btn-item bz-btn"
@
click=
"bz_click"
>
备注耗材
</div>
<div
v-if=
"order.is_can_remark_material == 1"
class=
"btn-item bz-btn"
@
click=
"bz_click"
>
备注耗材
</div>
<div
<div
v-if=
"order.is_can_confirm_complete==
1"
v-if=
"order.is_can_confirm_complete ==
1"
class=
"btn-item qr-btn"
class=
"btn-item qr-btn"
@
click=
"sure_click()"
@
click=
"sure_click()"
>
确认完成
</div>
>
确认完成
</div>
<div
<div
v-if=
"order.is_can_initiate_charge==
1"
v-if=
"order.is_can_initiate_charge ==
1"
class=
"btn-item sf-btn"
class=
"btn-item sf-btn"
@
click=
"tz_charge(order.id)"
@
click=
"tz_charge(order.id)"
>
发起收费
</div>
>
发起收费
</div>
<div
<div
v-if=
"order.is_can_initiate_transfer_order==
1"
v-if=
"order.is_can_initiate_transfer_order ==
1"
class=
"btn-item"
class=
"btn-item"
@
click=
"zd_click"
@
click=
"zd_click"
>
发起转单
</div>
>
发起转单
</div>
<div
v-if=
"order.is_can_back==1"
class=
"btn-item"
@
click=
"back_click"
>
发起退回
</div>
<div
v-if=
"order.is_can_back == 1"
class=
"btn-item"
@
click=
"back_click"
>
发起退回
</div>
<div
v-if=
"order.is_can_begin_repair==1"
class=
"btn-item"
@
click=
"starRepir"
>
开始维修
</div>
<div
<div
v-if=
"order.is_can_see_material==1"
class=
"btn-item sf-btn"
@
click=
"look_click"
>
查看耗材
</div>
v-if=
"order.is_can_begin_repair == 1"
class=
"btn-item"
@
click=
"starRepir"
>
开始维修
</div>
<div
v-if=
"order.is_can_see_material == 1"
class=
"btn-item sf-btn"
@
click=
"look_click"
>
查看耗材
</div>
</div>
</div>
<!-- 弹窗 -->
<!-- 弹窗 -->
<!-- 备注耗材弹窗 -->
<!-- 备注耗材弹窗 -->
<van-popup
v-model=
"hcShow"
close-icon=
"close"
>
<van-popup
v-model=
"hcShow"
close-icon=
"close"
>
<div
class=
"cancel_cont"
>
<div
class=
"cancel_cont"
>
<div
class=
"pop_title"
>
备注耗材
</div>
<div
class=
"pop_title"
>
备注耗材
</div>
<div
class=
"list-item"
v-for=
"(item,
index) in addList"
:key=
"index"
>
<div
class=
"list-item"
v-for=
"(item,
index) in addList"
:key=
"index"
>
<input
<input
class=
"input"
class=
"input"
maxlength=
"20"
maxlength=
"20"
...
@@ -146,7 +170,7 @@
...
@@ -146,7 +170,7 @@
/>
/>
</div>
</div>
<div
class=
"math-btn flex-h flex-vc flex-hb"
>
<div
class=
"math-btn flex-h flex-vc flex-hb"
>
<div
v-if=
"addList.length>
1"
class=
"del-btn"
@
click=
"delMeth"
>
-删除
</div>
<div
v-if=
"addList.length >
1"
class=
"del-btn"
@
click=
"delMeth"
>
-删除
</div>
<div
class=
"add-btn"
@
click=
"addMeth"
>
+新增
</div>
<div
class=
"add-btn"
@
click=
"addMeth"
>
+新增
</div>
</div>
</div>
<div
class=
"btnItem flex-h"
>
<div
class=
"btnItem flex-h"
>
...
@@ -189,16 +213,24 @@
...
@@ -189,16 +213,24 @@
>
>
<div
<div
class=
"one one1 one_title text-line-one"
class=
"one one1 one_title text-line-one"
>
{{
item
.
parent_detail
?
item
.
parent_detail
.
goods_name
:
'
其它
'
}}
</div>
>
{{
item
.
parent_detail
?
item
.
parent_detail
.
goods_name
:
'
其它
'
}}
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
<div
class=
"_one text-line-one"
>
class=
"_one text-line-one"
{{
>
{{
item
.
is_free
==
2
?
item
.
good_detail
.
goods_name
:
item
.
goods_name
}}
</div>
item
.
is_free
==
2
<div
class=
"_two text-line-one"
>
*
{{
item
.
number
}}
</div>
?
item
.
good_detail
.
goods_name
:
item
.
goods_name
}}
</div>
</div>
<div
class=
"one one3"
>
¥
{{
item
.
price
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
item
.
number
}}
</div>
</div>
<div
class=
"one one3"
>
¥
{{
item
.
price
}}
</div>
</div>
<div
class=
"hc_total"
>
共计
{{
expend_detail
.
number
}}
件,总价: ¥
{{
expend_detail
.
price
}}
</div>
</div>
<div
class=
"hc_total"
>
共计
{{
expend_detail
.
number
}}
件,总价: ¥
{{
expend_detail
.
price
}}
</div>
<div
class=
"sure-btn"
@
click=
"cancel"
>
确定
</div>
<div
class=
"sure-btn"
@
click=
"cancel"
>
确定
</div>
</div>
</div>
</van-popup>
</van-popup>
...
@@ -209,17 +241,18 @@
...
@@ -209,17 +241,18 @@
</div>
</div>
</div>
</div>
<div
v-else
>
<div
v-else
>
<img
class=
"none-img"
src=
"https://img01.yzcdn.cn/vant/empty-image-default.png"
>
<img
class=
"none-img"
src=
"https://img01.yzcdn.cn/vant/empty-image-default.png"
/
>
<p
class=
"none-p"
>
暂无工单哦!
</p>
<p
class=
"none-p"
>
暂无工单哦!
</p>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
ImagePreview
}
from
'
vant
'
;
import
{
ImagePreview
}
from
'
vant
'
import
{
trimStrSpace
}
from
'
@assets/js/format.js
'
import
{
trimStrSpace
}
from
'
@assets/js/format.js
'
import
{
REFRESH_LIST
,
getLocalStorage
,
removeLocalStorage
}
from
'
@assets/js/self.js
'
export
default
{
export
default
{
name
:
'
order_detail
'
,
name
:
'
order_detail
'
,
data
()
{
data
()
{
return
{
return
{
locked
:
false
,
locked
:
false
,
isloading
:
false
,
isloading
:
false
,
...
@@ -237,30 +270,24 @@ export default {
...
@@ -237,30 +270,24 @@ export default {
lookShow
:
false
,
// 查看耗材弹窗
lookShow
:
false
,
// 查看耗材弹窗
reason
:
''
,
// 转单原因
reason
:
''
,
// 转单原因
zdShow
:
false
,
// 发起转单弹窗
zdShow
:
false
,
// 发起转单弹窗
backShow
:
false
,
//工人退回弹窗
backShow
:
false
,
// 工人退回弹窗
back_reason
:
''
,
//工人退回原因
back_reason
:
''
,
// 工人退回原因
lookShow
:
false
,
// 查看耗材弹窗
expend_detail
:
{}
// 耗材详情
expend_detail
:
{},
// 耗材详情
}
}
},
},
created
()
{
this
.
order_id
=
this
.
$route
.
query
.
id
// this.order_id = 211
this
.
getDetail
()
},
methods
:
{
methods
:
{
preview
(
img
,
index
)
{
preview
(
img
,
index
)
{
let
temp
=
img
.
map
(
item
=>
{
const
temp
=
img
.
map
(
item
=>
{
return
item
.
url
return
item
.
url
})
})
ImagePreview
({
ImagePreview
({
images
:
temp
,
images
:
temp
,
startPosition
:
index
,
startPosition
:
index
});
})
},
},
// 确认完成
// 确认完成
sure_click
(
item
,
index
)
{
sure_click
(
item
,
index
)
{
const
vm
=
this
//
const vm = this
this
.
$dialog
.
confirm
({
this
.
$dialog
.
confirm
({
title
:
'
提示
'
,
title
:
'
提示
'
,
message
:
'
确认完成维修?
'
message
:
'
确认完成维修?
'
...
@@ -275,9 +302,9 @@ export default {
...
@@ -275,9 +302,9 @@ export default {
this
.
$toast
(
'
操作成功
'
)
this
.
$toast
(
'
操作成功
'
)
this
.
order
=
data
this
.
order
=
data
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
onRefresh
()
{
onRefresh
()
{
if
(
!
this
.
locked
)
{
if
(
!
this
.
locked
)
{
...
@@ -295,6 +322,7 @@ export default {
...
@@ -295,6 +322,7 @@ export default {
this
.
order
=
res
.
order
this
.
order
=
res
.
order
this
.
locked
=
false
this
.
locked
=
false
this
.
isloading
=
false
this
.
isloading
=
false
removeLocalStorage
(
REFRESH_LIST
)
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
this
.
locked
=
false
this
.
locked
=
false
...
@@ -389,9 +417,9 @@ export default {
...
@@ -389,9 +417,9 @@ export default {
})
})
},
},
// 开始维修
// 开始维修
starRepir
(
id
,
)
{
starRepir
(
id
)
{
// console.log(index)
// console.log(index)
const
vm
=
this
//
const vm = this
const
curParams
=
{
const
curParams
=
{
repair_order_id
:
this
.
order_id
repair_order_id
:
this
.
order_id
}
}
...
@@ -400,17 +428,17 @@ export default {
...
@@ -400,17 +428,17 @@ export default {
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
this
.
order
=
data
this
.
order
=
data
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
back_click
()
{
back_click
()
{
this
.
back_reason
=
''
this
.
back_reason
=
''
this
.
backShow
=
true
this
.
backShow
=
true
},
},
back_cancel
()
{
back_cancel
()
{
this
.
backShow
=
false
this
.
backShow
=
false
},
},
//
发起退回
//
发起退回
back_submit
()
{
back_submit
()
{
if
(
this
.
back_reason
===
''
)
{
if
(
this
.
back_reason
===
''
)
{
this
.
$toast
(
'
退回原因不可为空
'
)
this
.
$toast
(
'
退回原因不可为空
'
)
return
return
...
@@ -442,25 +470,45 @@ export default {
...
@@ -442,25 +470,45 @@ export default {
this
.
expend_detail
=
data
this
.
expend_detail
=
data
this
.
lookShow
=
true
this
.
lookShow
=
true
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
cancel
()
{
cancel
()
{
this
.
zdShow
=
false
this
.
zdShow
=
false
this
.
hcShow
=
false
this
.
hcShow
=
false
this
.
lookShow
=
false
this
.
lookShow
=
false
},
},
goBack
()
{
goBack
()
{
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'
/
'
path
:
'
/
'
})
})
},
},
fetchData
(
to
,
from
)
{
this
.
order_id
=
to
.
query
?
to
.
query
.
id
:
''
if
(
from
.
path
!==
undefined
&&
from
.
path
.
indexOf
(
'
/charge
'
)
!==
-
1
)
{
if
(
getLocalStorage
(
REFRESH_LIST
))
{
this
.
getDetail
()
}
}
else
{
if
(
this
.
order_id
)
{
this
.
getDetail
()
}
}
}
},
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
vm
.
fetchData
(
to
,
from
,
next
)
})
},
beforeRouteLeave
(
to
,
from
,
next
)
{
next
()
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/tabbar/index.scss"
;
@import
'@assets/styles/tabbar/index.scss'
;
.backBtn
{
.backBtn
{
width
:
0
.8rem
;
width
:
0
.8rem
;
height
:
0
.8rem
;
height
:
0
.8rem
;
...
@@ -478,11 +526,11 @@ export default {
...
@@ -478,11 +526,11 @@ export default {
height
:
100%
;
height
:
100%
;
border-radius
:
50%
;
border-radius
:
50%
;
}
}
.none-img
{
.none-img
{
display
:
block
;
display
:
block
;
margin
:
0
auto
;
margin
:
0
auto
;
}
}
.none-p
{
.none-p
{
text-align
:
center
;
text-align
:
center
;
}
}
</
style
>
</
style
>
src/views/tabbar/Home.vue
View file @
48cf7b31
...
@@ -2,12 +2,12 @@
...
@@ -2,12 +2,12 @@
<div
class=
"cont"
>
<div
class=
"cont"
>
<div
class=
"top flex-h flex-vc"
>
<div
class=
"top flex-h flex-vc"
>
<div
class=
"point"
></div>
<div
class=
"point"
></div>
<div
class=
"status"
>
{{
user
.
online_status_display
}}
</div>
<div
class=
"status"
>
{{
user
.
online_status_display
}}
</div>
</div>
</div>
<div
class=
"menu flex-h flex-hb
"
>
<div
class=
"menu flex-h flex-hb flex-vc
"
>
<div
class=
"hc_total"
>
共
{{
count
}}
个工单
</div>
<div
class=
"hc_total"
>
共
{{
count
}}
个工单
</div>
<div
class=
"options"
>
<div
class=
"options"
>
<div
@
click=
"chooseTab"
>
{{
curSelect
.
name
}}
</div>
<div
@
click=
"chooseTab"
>
{{
curSelect
.
name
}}
</div>
<div
class=
"option-box"
v-show=
"tabShow"
>
<div
class=
"option-box"
v-show=
"tabShow"
>
<div
<div
class=
"option-item"
class=
"option-item"
...
@@ -15,14 +15,14 @@
...
@@ -15,14 +15,14 @@
:key=
"item.type"
:key=
"item.type"
:value=
"item.name"
:value=
"item.name"
@
click=
"changeItem(item)"
@
click=
"changeItem(item)"
>
{{
item
.
name
}}
</div>
>
{{
item
.
name
}}
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"date flex-h flex-hb flex-vc"
v-if=
"this.curSelect.type==
4"
>
<div
class=
"date flex-h flex-hb flex-vc"
v-if=
"this.curSelect.type ==
4"
>
<div
class=
"start"
@
click=
"stShow"
>
{{
startTime
}}
</div>
<div
class=
"start"
@
click=
"stShow"
>
{{
startTime
}}
</div>
<div
class=
"blue"
></div>
<div
class=
"blue"
></div>
<div
class=
"end"
@
click=
"endShow"
>
{{
endTime
}}
</div>
<div
class=
"end"
@
click=
"endShow"
>
{{
endTime
}}
</div>
</div>
</div>
<van-pull-refresh
v-model=
"isloading"
@
refresh=
"onRefresh"
>
<van-pull-refresh
v-model=
"isloading"
@
refresh=
"onRefresh"
>
...
@@ -34,38 +34,48 @@
...
@@ -34,38 +34,48 @@
v-if=
"list.length"
v-if=
"list.length"
>
>
<div
class=
"order-item"
v-for=
"(item, index) in list"
:key=
"item.id"
>
<div
class=
"order-item"
v-for=
"(item, index) in list"
:key=
"item.id"
>
<div
class=
"title"
v-if=
"item.pid==0&&item.son_count>0"
>
{{
item
.
order_status_display
}}
(负责人)
</div>
<div
<div
class=
"title"
v-else
>
{{
item
.
order_status_display
}}
</div>
class=
"title"
v-if=
"item.pid == 0 && item.son_count > 0"
>
{{
item
.
order_status_display
}}
(负责人)
</div>
<div
class=
"title"
v-else
>
{{
item
.
order_status_display
}}
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
预约时间:
</div>
<div
class=
"item-title"
>
预约时间:
</div>
<div
<div
class=
"item-desc"
>
class=
"item-desc"
{{
item
.
appointment_date
}}
>
{{
item
.
appointment_date
}}
{{
item
.
appointment_time
.
start_time
}}
-
{{
item
.
appointment_time
.
end_time
}}
</div>
{{
item
.
appointment_time
.
start_time
}}
-
{{
item
.
appointment_time
.
end_time
}}
</div>
</div>
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-desc que-desc"
>
{{
item
.
repair_type
.
type_name
}}
-
{{
item
.
description
}}
</div>
<div
class=
"item-desc que-desc"
>
{{
item
.
repair_type
.
type_name
}}
-
{{
item
.
description
}}
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
服务地址:
</div>
<div
class=
"item-title"
>
服务地址:
</div>
<div
<div
class=
"item-desc"
>
class=
"item-desc"
{{
item
.
region
.
region_name
}}
-
{{
>
{{
item
.
region
.
region_name
}}
-
{{
item
.
room
.
room_name
}}
-
{{
item
.
address
}}
</div>
item
.
room
.
room_name
}}
-
{{
item
.
address
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-title"
>
客户姓名:
</div>
<div
class=
"item-desc"
>
{{
item
.
realname
}}
</div>
<div
class=
"item-desc"
>
{{
item
.
realname
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(item)"
>
{{
item
.
telephone
}}
</div>
<div
class=
"item-desc phone"
@
click=
"callPhone(item)"
>
{{
item
.
telephone
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item flex-h flex-vc"
>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-title"
>
提交时间:
</div>
<div
class=
"item-desc"
>
{{
item
.
created_at
}}
</div>
<div
class=
"item-desc"
>
{{
item
.
created_at
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
图片详情:
</div>
<div
class=
"item-title"
>
图片详情:
</div>
<div
<div
@
click=
"preview(item.image,
index)"
@
click=
"preview(item.image,
index)"
class=
"img flex-h"
class=
"img flex-h"
v-for=
"(child, index) in item.image"
v-for=
"(child, index) in item.image"
:key=
"index"
:key=
"index"
...
@@ -76,25 +86,25 @@
...
@@ -76,25 +86,25 @@
<div
class=
"line"
></div>
<div
class=
"line"
></div>
<div
class=
"item flex-h flex-vc"
v-if=
"item.worker"
>
<div
class=
"item flex-h flex-vc"
v-if=
"item.worker"
>
<div
class=
"item-title"
>
派工对象:
</div>
<div
class=
"item-title"
>
派工对象:
</div>
<div
class=
"item-desc"
>
{{
item
.
worker
.
name
}}
</div>
<div
class=
"item-desc"
>
{{
item
.
worker
.
name
}}
</div>
</div>
</div>
<div
class=
"item flex-h flex-vc"
v-if=
"item.worker"
>
<div
class=
"item flex-h flex-vc"
v-if=
"item.worker"
>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-title"
>
联系电话:
</div>
<div
class=
"item-desc"
>
{{
item
.
worker
.
phone
}}
</div>
<div
class=
"item-desc"
>
{{
item
.
worker
.
phone
}}
</div>
</div>
</div>
<div
class=
"material"
v-if=
"item.no_pay_order"
>
<div
class=
"material"
v-if=
"item.no_pay_order"
>
<div
class=
"item-title bz-title"
>
待支付耗材
</div>
<div
class=
"item-title bz-title specile-text"
>
待支付耗材:
</div>
<div
<div
class=
"no-pay ma-item flex-h flex-hb"
class=
"no-pay ma-item flex-h flex-hb"
v-for=
"(child, index) in item.no_pay_order.goods"
v-for=
"(child, index) in item.no_pay_order.goods"
:key=
"index"
:key=
"index"
>
>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
</div>
</div>
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
...
@@ -106,61 +116,73 @@
...
@@ -106,61 +116,73 @@
v-for=
"(child, index) in parent.goods"
v-for=
"(child, index) in parent.goods"
:key=
"index"
:key=
"index"
>
>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<!--
<div
class=
"one"
>
{{
child
.
good_detail
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<!--
<div
class=
"one"
>
{{
child
.
good_detail
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
<div
class=
"one one3"
>
¥
{{
child
.
price
}}
</div>
</div>
</div>
</div>
</div>
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<!--
<div
class=
"line"
></div>
-->
<!--
<div
class=
"line"
></div>
-->
<div
class=
"material"
v-if=
"item.free_material_order"
>
<div
class=
"material"
v-if=
"item.free_material_order"
>
<div
class=
"item-title bz-title"
>
备注耗材
</div>
<div
class=
"item-title bz-title"
>
备注耗材:
</div>
<div
<div
class=
"ma-item flex-h flex-hb"
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in item.free_material_order.goods"
v-for=
"(child, index) in item.free_material_order
.goods"
:key=
"index"
:key=
"index"
>
>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
@
click=
"showAll(item,$event)"
>
{{
child
.
goods_name
}}
</div>
<div
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
class=
"_one text-line-one"
@
click=
"showAll(item, $event)"
>
{{
child
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<!--
<div
class=
"one one2 text-line-one"
>
{{
child
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<!--
<div
class=
"one one2 text-line-one"
>
{{
child
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<div
class=
"one one3 text-line-one"
>
¥0
</div>
<div
class=
"one one3 text-line-one"
>
¥0
</div>
</div>
</div>
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<div
class=
"btn flex-h flex-hr
"
>
<div
class=
"btn flex-h flex-hr flex-hw
"
>
<div
<div
v-if=
"item.is_can_remark_material==
1"
v-if=
"item.is_can_remark_material ==
1"
class=
"btn-item bz-btn"
class=
"btn-item bz-btn"
@
click=
"bz_click(item)"
@
click=
"bz_click(item)"
>
备注耗材
</div>
>
备注耗材
</div>
<div
<div
v-if=
"item.is_can_confirm_complete==
1"
v-if=
"item.is_can_confirm_complete ==
1"
class=
"btn-item qr-btn"
class=
"btn-item qr-btn"
@
click=
"sure_click(item, index)"
@
click=
"sure_click(item, index)"
>
确认完成
</div>
>
确认完成
</div>
<div
<div
v-if=
"item.is_can_initiate_charge==
1"
v-if=
"item.is_can_initiate_charge ==
1"
class=
"btn-item sf-btn"
class=
"btn-item sf-btn"
@
click=
"tz_charge(item.id)"
@
click=
"tz_charge(item.id)"
>
发起收费
</div>
>
发起收费
</div>
<div
<div
v-if=
"item.is_can_initiate_transfer_order==
1"
v-if=
"item.is_can_initiate_transfer_order ==
1"
class=
"btn-item"
class=
"btn-item"
@
click=
"zd_click(item)"
@
click=
"zd_click(item)"
>
发起转单
</div>
>
发起转单
</div>
<div
v-if=
"item.is_can_back==1"
class=
"btn-item"
@
click=
"back_click(item)"
>
发起退回
</div>
<div
<div
v-if=
"item.is_can_begin_repair==1"
v-if=
"item.is_can_back == 1"
class=
"btn-item"
@
click=
"back_click(item)"
>
发起退回
</div>
<div
v-if=
"item.is_can_begin_repair == 1"
class=
"btn-item"
class=
"btn-item"
@
click=
"starRepir(item.id,
index)"
@
click=
"starRepir(item.id,
index)"
>
开始维修
</div>
>
开始维修
</div>
<!--
<div
<!--
<div
v-if=
"item.is_can_see_appraisal==1"
v-if=
"item.is_can_see_appraisal==1"
...
@@ -168,7 +190,7 @@
...
@@ -168,7 +190,7 @@
@
click=
"look_comment(item)"
@
click=
"look_comment(item)"
>
查看评价
</div>
-->
>
查看评价
</div>
-->
<div
<div
v-if=
"item.is_can_see_material==
1"
v-if=
"item.is_can_see_material ==
1"
class=
"btn-item sf-btn"
class=
"btn-item sf-btn"
@
click=
"look_click(item)"
@
click=
"look_click(item)"
>
查看耗材
</div>
>
查看耗材
</div>
...
@@ -205,7 +227,7 @@
...
@@ -205,7 +227,7 @@
<van-popup
v-model=
"hcShow"
close-icon=
"close"
>
<van-popup
v-model=
"hcShow"
close-icon=
"close"
>
<div
class=
"cancel_cont"
>
<div
class=
"cancel_cont"
>
<div
class=
"pop_title"
>
备注耗材
</div>
<div
class=
"pop_title"
>
备注耗材
</div>
<div
class=
"list-item"
v-for=
"(item,
index) in addList"
:key=
"index"
>
<div
class=
"list-item"
v-for=
"(item,
index) in addList"
:key=
"index"
>
<input
<input
class=
"input"
class=
"input"
maxlength=
"20"
maxlength=
"20"
...
@@ -223,7 +245,7 @@
...
@@ -223,7 +245,7 @@
/>
/>
</div>
</div>
<div
class=
"math-btn flex-h flex-vc flex-hb"
>
<div
class=
"math-btn flex-h flex-vc flex-hb"
>
<div
v-if=
"addList.length>
1"
class=
"del-btn"
@
click=
"delMeth"
>
-删除
</div>
<div
v-if=
"addList.length >
1"
class=
"del-btn"
@
click=
"delMeth"
>
-删除
</div>
<div
class=
"add-btn"
@
click=
"addMeth"
>
+新增
</div>
<div
class=
"add-btn"
@
click=
"addMeth"
>
+新增
</div>
</div>
</div>
<div
class=
"btnItem flex-h"
>
<div
class=
"btnItem flex-h"
>
...
@@ -242,18 +264,30 @@
...
@@ -242,18 +264,30 @@
v-for=
"(item, index) in expend_detail.list"
v-for=
"(item, index) in expend_detail.list"
:key=
"index"
:key=
"index"
>
>
<div
<div
class=
"one one1 one_title text-line-one"
>
class=
"one one1 one_title text-line-one"
{{
>
{{
item
.
parent_detail
?
item
.
parent_detail
.
goods_name
:
'
其它
'
}}
</div>
item
.
parent_detail
?
item
.
parent_detail
.
goods_name
:
'
其它
'
}}
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
<div
class=
"_one text-line-one"
>
class=
"_one text-line-one"
{{
>
{{
item
.
is_free
==
2
?
item
.
good_detail
.
goods_name
:
item
.
goods_name
}}
</div>
item
.
is_free
==
2
<div
class=
"_two text-line-one"
>
*
{{
item
.
number
}}
</div>
?
item
.
good_detail
.
goods_name
:
item
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
item
.
number
}}
</div>
</div>
</div>
<div
class=
"one one3"
>
¥
{{
item
.
price
}}
</div>
<div
class=
"one one3"
>
¥
{{
item
.
price
}}
</div>
</div>
<div
class=
"hc_total"
>
共计
{{
expend_detail
.
number
}}
件,总价: ¥
{{
expend_detail
.
price
}}
</div>
</div>
<div
class=
"hc_total"
>
共计
{{
expend_detail
.
number
}}
件,总价: ¥
{{
expend_detail
.
price
}}
</div>
<div
class=
"sure-btn"
@
click=
"cancel"
>
确定
</div>
<div
class=
"sure-btn"
@
click=
"cancel"
>
确定
</div>
</div>
</div>
</van-popup>
</van-popup>
...
@@ -291,8 +325,9 @@
...
@@ -291,8 +325,9 @@
<
script
>
<
script
>
import
myTabbar
from
'
@components/common/tabbar.vue
'
import
myTabbar
from
'
@components/common/tabbar.vue
'
import
{
trimStrSpace
}
from
'
@assets/js/format.js
'
import
{
trimStrSpace
}
from
'
@assets/js/format.js
'
import
{
ImagePreview
,
Toast
}
from
'
vant
'
;
import
{
ImagePreview
}
from
'
vant
'
import
{
share
}
from
'
@/api/wxShare.js
'
import
{
share
}
from
'
@/api/wxShare.js
'
import
{
REFRESH_LIST
,
getLocalStorage
,
removeLocalStorage
}
from
'
@assets/js/self.js
'
export
default
{
export
default
{
name
:
'
home
'
,
name
:
'
home
'
,
components
:
{
components
:
{
...
@@ -336,41 +371,41 @@ export default {
...
@@ -336,41 +371,41 @@ export default {
],
// 添加的备注耗材数据
],
// 添加的备注耗材数据
hcShow
:
false
,
// 耗材弹窗
hcShow
:
false
,
// 耗材弹窗
lookShow
:
false
,
// 查看耗材弹窗
lookShow
:
false
,
// 查看耗材弹窗
expend_detail
:
{},
// 耗材详情
expend_detail
:
{},
// 耗材详情
user
:
''
,
user
:
''
,
startTime
:
'
请选择开始日期
'
,
startTime
:
'
请选择开始日期
'
,
showStart
:
false
,
showStart
:
false
,
startObj
:{
startObj
:
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
},
},
endObj
:{
endObj
:
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
},
},
currentDate
:
new
Date
(),
currentDate
:
new
Date
(),
showEnd
:
false
,
showEnd
:
false
,
endTime
:
"
请选择截止日期
"
,
endTime
:
'
请选择截止日期
'
,
backShow
:
false
,
//
工人退回弹窗
backShow
:
false
,
//
工人退回弹窗
back_reason
:
''
,
//
工人退回原因
back_reason
:
''
//
工人退回原因
}
}
},
},
created
()
{
created
()
{
share
()
share
()
this
.
getList
()
//
this.getList()
this
.
getUserInfo
()
//
this.getUserInfo()
},
},
methods
:
{
methods
:
{
back_click
(
item
)
{
back_click
(
item
)
{
this
.
curItem
=
item
this
.
curItem
=
item
this
.
back_reason
=
''
this
.
back_reason
=
''
this
.
backShow
=
true
this
.
backShow
=
true
},
},
back_cancel
()
{
back_cancel
()
{
this
.
backShow
=
false
this
.
backShow
=
false
},
},
//
发起退回
//
发起退回
back_submit
()
{
back_submit
()
{
if
(
this
.
back_reason
===
''
)
{
if
(
this
.
back_reason
===
''
)
{
this
.
$toast
(
'
退回原因不可为空
'
)
this
.
$toast
(
'
退回原因不可为空
'
)
return
return
...
@@ -387,90 +422,89 @@ export default {
...
@@ -387,90 +422,89 @@ export default {
const
idx
=
this
.
list
.
findIndex
(
item
=>
item
.
id
===
this
.
curItem
.
id
)
const
idx
=
this
.
list
.
findIndex
(
item
=>
item
.
id
===
this
.
curItem
.
id
)
if
(
idx
!==
-
1
)
{
if
(
idx
!==
-
1
)
{
this
.
list
.
splice
(
idx
,
1
)
this
.
list
.
splice
(
idx
,
1
)
this
.
count
=
this
.
count
-
1
this
.
count
=
this
.
count
-
1
}
}
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
this
.
backShow
=
false
this
.
backShow
=
false
})
})
},
},
showAll
(
item
,
e
)
{
showAll
(
item
,
e
)
{
this
.
$toast
(
e
.
target
.
innerHTML
,
{
this
.
$toast
(
e
.
target
.
innerHTML
,
{
duration
:
0
duration
:
0
})
})
},
},
callPhone
(
item
)
{
callPhone
(
item
)
{
console
.
log
(
'
电话
'
,
item
)
console
.
log
(
'
电话
'
,
item
)
le
t
phoneNumber
=
item
.
telephone
cons
t
phoneNumber
=
item
.
telephone
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
},
},
onmore
()
{
onmore
()
{
this
.
getList
()
this
.
getList
()
},
},
preview
(
img
,
index
)
{
preview
(
img
,
index
)
{
let
temp
=
img
.
map
(
item
=>
{
const
temp
=
img
.
map
(
item
=>
{
return
item
.
url
return
item
.
url
})
})
ImagePreview
({
ImagePreview
({
images
:
temp
,
images
:
temp
,
startPosition
:
index
,
startPosition
:
index
})
;
})
},
},
endShow
()
{
endShow
()
{
this
.
showEnd
=
true
this
.
showEnd
=
true
},
},
stShow
()
{
stShow
()
{
this
.
showStart
=
true
this
.
showStart
=
true
},
},
formatter
(
type
,
val
)
{
formatter
(
type
,
val
)
{
if
(
type
===
'
year
'
)
{
if
(
type
===
"
year
"
)
{
return
`
${
val
}
年`
return
`
${
val
}
年`
;
}
else
if
(
type
===
'
month
'
)
{
}
else
if
(
type
===
"
month
"
)
{
return
`
${
val
}
月`
return
`
${
val
}
月`
;
}
else
if
(
type
===
'
day
'
)
{
}
else
if
(
type
===
"
day
"
)
{
return
`
${
val
}
日`
return
`
${
val
}
日`
;
}
}
return
val
;
return
val
},
},
birConfirm
(
value
)
{
birConfirm
(
value
)
{
this
.
showStart
=
false
this
.
showStart
=
false
if
(
this
.
startTime
==
this
.
conversionTime
(
value
))
{
if
(
this
.
startTime
==
this
.
conversionTime
(
value
))
{
return
return
}
}
console
.
log
(
'
啊啊啊
'
,
value
);
console
.
log
(
'
啊啊啊
'
,
value
)
this
.
startTime
=
this
.
conversionTime
(
value
)
this
.
startTime
=
this
.
conversionTime
(
value
)
this
.
$set
(
this
.
endObj
,
'
minDate
'
,
value
)
this
.
$set
(
this
.
endObj
,
'
minDate
'
,
value
)
this
.
anginList
()
this
.
anginList
()
console
.
log
(
'
开始时间
'
,
this
.
startTime
);
console
.
log
(
'
开始时间
'
,
this
.
startTime
)
},
},
conversionTime
(
temp
)
{
conversionTime
(
temp
)
{
let
mounth
=
(
temp
.
getMonth
()
+
1
)
<
10
?
'
0
'
+
(
temp
.
getMonth
()
+
1
)
:
(
temp
.
getMonth
()
+
1
)
const
mounth
=
(
temp
.
getMonth
()
+
1
)
<
10
?
'
0
'
+
(
temp
.
getMonth
()
+
1
)
:
(
temp
.
getMonth
()
+
1
)
let
date
=
temp
.
getDate
()
<
10
?
'
0
'
+
temp
.
getDate
()
:
temp
.
getDate
()
const
date
=
temp
.
getDate
()
<
10
?
'
0
'
+
temp
.
getDate
()
:
temp
.
getDate
()
return
temp
.
getFullYear
()
+
return
temp
.
getFullYear
()
+
"
-
"
+
'
-
'
+
mounth
+
mounth
+
"
-
"
+
'
-
'
+
date
date
},
},
birCancel
()
{
birCancel
()
{
this
.
showStart
=
false
;
this
.
showStart
=
false
},
},
endTimeConfirm
(
value
)
{
endTimeConfirm
(
value
)
{
this
.
showEnd
=
false
this
.
showEnd
=
false
if
(
this
.
endTime
==
this
.
conversionTime
(
value
))
{
if
(
this
.
endTime
==
this
.
conversionTime
(
value
))
{
return
return
}
}
this
.
endTime
=
this
.
conversionTime
(
value
)
this
.
endTime
=
this
.
conversionTime
(
value
)
this
.
$set
(
this
.
startObj
,
'
maxDate
'
,
value
)
this
.
$set
(
this
.
startObj
,
'
maxDate
'
,
value
)
this
.
anginList
()
this
.
anginList
()
console
.
log
(
'
结束时间
'
,
this
.
endTime
);
console
.
log
(
'
结束时间
'
,
this
.
endTime
)
},
},
endTimeCancel
()
{
endTimeCancel
()
{
this
.
showEnd
=
false
;
this
.
showEnd
=
false
},
},
anginList
()
{
anginList
()
{
if
(
this
.
startTime
!=
'
请选择开始日期
'
&&
this
.
endTime
!=
'
请选择截止日期
'
)
{
if
(
this
.
startTime
!=
'
请选择开始日期
'
&&
this
.
endTime
!=
'
请选择截止日期
'
)
{
this
.
initData
()
this
.
initData
()
this
.
getList
()
this
.
getList
()
}
}
...
@@ -484,7 +518,7 @@ export default {
...
@@ -484,7 +518,7 @@ export default {
this
.
isloading
=
false
this
.
isloading
=
false
this
.
loading
=
false
this
.
loading
=
false
this
.
finished
=
false
this
.
finished
=
false
this
.
getUserInfo
()
//
this.getUserInfo()
},
},
getStatus
()
{
getStatus
()
{
this
.
$http
this
.
$http
...
@@ -493,34 +527,35 @@ export default {
...
@@ -493,34 +527,35 @@ export default {
console
.
log
(
res
)
console
.
log
(
res
)
this
.
status
=
res
this
.
status
=
res
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
getUserInfo
()
{
getUserInfo
()
{
this
.
$http
this
.
$http
.
get
(
this
.
$myApi
.
USERINFO
)
.
get
(
this
.
$myApi
.
USERINFO
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
this
.
user
=
res
this
.
user
=
res
this
.
getList
()
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
// 获取工单列表
// 获取工单列表
getList
()
{
getList
()
{
if
(
this
.
more
&&
!
this
.
isloading
)
{
if
(
this
.
more
&&
!
this
.
isloading
)
{
this
.
isloading
=
true
this
.
isloading
=
true
let
curParams
=
{}
let
curParams
=
{}
if
(
this
.
curSelect
.
type
==
4
)
{
if
(
this
.
curSelect
.
type
==
4
)
{
curParams
=
{
curParams
=
{
time_type
:
this
.
curSelect
.
type
,
time_type
:
this
.
curSelect
.
type
,
page
:
this
.
page
,
page
:
this
.
page
,
limit
:
this
.
limit
,
limit
:
this
.
limit
,
start
:
this
.
startTime
,
start
:
this
.
startTime
,
end
:
this
.
endTime
,
end
:
this
.
endTime
}
}
}
else
{
}
else
{
curParams
=
{
curParams
=
{
time_type
:
this
.
curSelect
.
type
,
time_type
:
this
.
curSelect
.
type
,
page
:
this
.
page
,
page
:
this
.
page
,
limit
:
this
.
limit
,
limit
:
this
.
limit
}
}
}
}
this
.
$http
this
.
$http
...
@@ -533,7 +568,8 @@ export default {
...
@@ -533,7 +568,8 @@ export default {
this
.
isloading
=
false
this
.
isloading
=
false
this
.
count
=
data
.
count
this
.
count
=
data
.
count
this
.
loading
=
false
this
.
loading
=
false
this
.
finished
=
!
data
.
more
;
this
.
finished
=
!
data
.
more
removeLocalStorage
(
REFRESH_LIST
)
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
this
.
locked
=
false
this
.
locked
=
false
...
@@ -558,16 +594,16 @@ export default {
...
@@ -558,16 +594,16 @@ export default {
this
.
curSelect
=
item
this
.
curSelect
=
item
this
.
tabShow
=
false
this
.
tabShow
=
false
if
(
this
.
curSelect
.
type
==
4
)
{
if
(
this
.
curSelect
.
type
==
4
)
{
this
.
startTime
=
'
请选择开始日期
'
this
.
startTime
=
'
请选择开始日期
'
this
.
endTime
=
'
请选择截止日期
'
this
.
endTime
=
'
请选择截止日期
'
this
.
startObj
=
{
this
.
startObj
=
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
}
}
this
.
endObj
=
{
this
.
endObj
=
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
}
}
return
return
}
}
...
@@ -587,7 +623,7 @@ export default {
...
@@ -587,7 +623,7 @@ export default {
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
vm
.
$set
(
vm
.
list
,
index
,
data
)
vm
.
$set
(
vm
.
list
,
index
,
data
)
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
// 转单弹窗
// 转单弹窗
zd_click
(
item
)
{
zd_click
(
item
)
{
...
@@ -613,7 +649,7 @@ export default {
...
@@ -613,7 +649,7 @@ export default {
const
idx
=
this
.
list
.
findIndex
(
item
=>
item
.
id
===
this
.
curItem
.
id
)
const
idx
=
this
.
list
.
findIndex
(
item
=>
item
.
id
===
this
.
curItem
.
id
)
if
(
idx
!==
-
1
)
{
if
(
idx
!==
-
1
)
{
this
.
list
.
splice
(
idx
,
1
)
this
.
list
.
splice
(
idx
,
1
)
this
.
count
=
this
.
count
-
1
this
.
count
=
this
.
count
-
1
}
}
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
...
@@ -696,7 +732,7 @@ export default {
...
@@ -696,7 +732,7 @@ export default {
this
.
expend_detail
=
data
this
.
expend_detail
=
data
this
.
lookShow
=
true
this
.
lookShow
=
true
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
// 查看评论
// 查看评论
look_comment
(
item
)
{
look_comment
(
item
)
{
...
@@ -736,9 +772,9 @@ export default {
...
@@ -736,9 +772,9 @@ export default {
vm
.
$set
(
vm
.
list
,
index
,
data
)
vm
.
$set
(
vm
.
list
,
index
,
data
)
this
.
$toast
(
'
操作成功
'
)
this
.
$toast
(
'
操作成功
'
)
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
// 取消按钮
// 取消按钮
...
@@ -751,14 +787,40 @@ export default {
...
@@ -751,14 +787,40 @@ export default {
tz_charge
(
id
)
{
tz_charge
(
id
)
{
console
.
log
(
id
,
'
jaeofne
'
)
console
.
log
(
id
,
'
jaeofne
'
)
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'
/charge
'
,
name
:
'
charge
'
,
query
:
{
id
}
query
:
{
id
:
id
}
})
})
},
fetchData
(
to
,
from
)
{
console
.
log
(
from
.
path
,
'
from----------------
'
)
if
(
from
.
path
!==
undefined
&&
from
.
path
.
indexOf
(
'
/charge
'
)
!==
-
1
)
{
console
.
log
(
!
this
.
list
.
length
,
'
!this.list.length-------
'
,
this
.
list
)
console
.
log
(
getLocalStorage
(
REFRESH_LIST
),
'
getLocalStorage(REFRESH_LIST)-------
'
)
if
(
!
this
.
list
.
length
||
getLocalStorage
(
REFRESH_LIST
))
{
this
.
initData
()
this
.
getList
()
}
}
else
{
this
.
initData
()
this
.
getUserInfo
()
}
}
}
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
vm
.
fetchData
(
to
,
from
,
next
)
})
},
beforeRouteLeave
(
to
,
from
,
next
)
{
console
.
log
(
this
.
list
,
'
this.list-------------
'
)
// return
next
()
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/tabbar/index.scss"
;
@import
'@assets/styles/tabbar/index.scss'
;
</
style
>
</
style
>
src/views/tabbar/admin_home.vue
View file @
48cf7b31
...
@@ -56,7 +56,11 @@
...
@@ -56,7 +56,11 @@
<div
class=
"tc-box"
>
<div
class=
"tc-box"
>
<div
class=
"tc-title"
>
选择工人
</div>
<div
class=
"tc-title"
>
选择工人
</div>
<div
class=
"workers"
>
<div
class=
"workers"
>
<div
class=
"gr-item"
v-for=
"(child_item,child_index) in columns"
:key=
"child_index"
>
<div
class=
"gr-item"
v-for=
"(child_item,child_index) in columns"
:key=
"child_index"
>
<div
class=
"bm-item"
>
{{
child_item
.
name
}}
</div>
<div
class=
"bm-item"
>
{{
child_item
.
name
}}
</div>
<div
v-if=
"child_item.user.length"
>
<div
v-if=
"child_item.user.length"
>
<div
<div
...
@@ -66,16 +70,19 @@
...
@@ -66,16 +70,19 @@
@
click=
"chooseWorker(lchild_item,lchild_index,index)"
@
click=
"chooseWorker(lchild_item,lchild_index,index)"
>
>
<div
class=
"flex-h flex-vc"
>
<div
class=
"flex-h flex-vc"
>
<img
class=
"gr-img"
:src=
gr_img
/>
<img
class=
"gr-img"
:src=
"grImg"
/>
<div
<div
class=
"gr-name"
class=
"gr-name"
v-if=
"lchild_item.repired_count !== 0 || lchild_item.repiring_count !== 0"
v-if=
"lchild_item.repired_count !== 0 || lchild_item.repiring_count !== 0"
>
{{
lchild_item
.
name
}}
(已派工:
{{
lchild_item
.
repired_count
}}
;维修中:
{{
lchild_item
.
repiring_count
}}
)
</div>
>
{{
lchild_item
.
name
}}
(已派工:
{{
lchild_item
.
repired_count
}}
;维修中:
{{
lchild_item
.
repiring_count
}}
)
</div>
<div
class=
"gr-name"
v-else
>
{{
lchild_item
.
name
}}
(休息中)
</div>
<div
class=
"gr-name"
v-else
>
{{
lchild_item
.
name
}}
(休息中)
</div>
</div>
</div>
<img
<img
class=
"k-img"
class=
"k-img"
:src=
"item.temporaryId && item.temporaryId.includes(lchild_item.id) ? select_img : unselect_i
mg"
:src=
"item.temporaryId && item.temporaryId.includes(lchild_item.id) ? selectImg : unselectI
mg"
/>
/>
</div>
</div>
</div>
</div>
...
@@ -96,7 +103,9 @@
...
@@ -96,7 +103,9 @@
>
{{
item
.
appointment_date
}}
{{
item
.
appointment_time
.
start_time
}}
-
{{
item
.
appointment_time
.
end_time
}}
</div>
>
{{
item
.
appointment_date
}}
{{
item
.
appointment_time
.
start_time
}}
-
{{
item
.
appointment_time
.
end_time
}}
</div>
</div>
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-title"
>
问题描述:
</div>
<div
class=
"item-desc que-desc"
>
{{
item
.
repair_type
.
type_name
}}
-
{{
item
.
description
}}
</div>
<div
class=
"item-desc que-desc"
>
{{
item
.
repair_type
.
type_name
}}
-
{{
item
.
description
}}
</div>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item flex-h flex-start"
>
<div
class=
"item-title"
>
服务地址:
</div>
<div
class=
"item-title"
>
服务地址:
</div>
<div
<div
...
@@ -128,7 +137,7 @@
...
@@ -128,7 +137,7 @@
</div>
</div>
</div>
</div>
<div
class=
"material"
v-if=
"item.no_pay_order"
>
<div
class=
"material"
v-if=
"item.no_pay_order"
>
<div
class=
"item-title bz-title"
>
待支付耗材
</div>
<div
class=
"item-title bz-title specile-text"
>
待支付耗材:
</div>
<div
<div
class=
"no-pay ma-item flex-h flex-hb"
class=
"no-pay ma-item flex-h flex-hb"
v-for=
"(child, index) in item.no_pay_order.goods"
v-for=
"(child, index) in item.no_pay_order.goods"
...
@@ -144,14 +153,16 @@
...
@@ -144,14 +153,16 @@
<div
class=
"item_line"
></div>
<div
class=
"item_line"
></div>
</div>
</div>
<div
class=
"material"
v-if=
"item.pay_order != ''"
>
<div
class=
"material"
v-if=
"item.pay_order != ''"
>
<div
class=
"item-title bz-title"
>
已支付耗材
</div>
<div
class=
"item-title bz-title"
>
已支付耗材:
</div>
<div
v-for=
"(parent, index) in item.pay_order"
:key=
"index"
>
<div
v-for=
"(parent, index) in item.pay_order"
:key=
"index"
>
<div
<div
class=
"ma-item flex-h flex-hb"
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in parent.goods"
v-for=
"(child, index) in parent.goods"
:key=
"index"
:key=
"index"
>
>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<div
class=
"one one1 text-line-one"
>
{{
child
.
parent_detail
.
goods_name
}}
</div>
<!--
<div
class=
"one"
>
{{
child
.
good_detail
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<!--
<div
class=
"one"
>
{{
child
.
good_detail
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
>
{{
child
.
good_detail
.
goods_name
}}
</div>
...
@@ -164,7 +175,7 @@
...
@@ -164,7 +175,7 @@
</div>
</div>
<!--
<div
class=
"line"
></div>
-->
<!--
<div
class=
"line"
></div>
-->
<div
class=
"material"
v-if=
"item.free_material_order"
>
<div
class=
"material"
v-if=
"item.free_material_order"
>
<div
class=
"item-title bz-title"
>
备注耗材
</div>
<div
class=
"item-title bz-title"
>
备注耗材:
</div>
<div
<div
class=
"ma-item flex-h flex-hb"
class=
"ma-item flex-h flex-hb"
v-for=
"(child, index) in item.free_material_order.goods"
v-for=
"(child, index) in item.free_material_order.goods"
...
@@ -172,7 +183,10 @@
...
@@ -172,7 +183,10 @@
>
>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one1 text-line-one"
>
免费
</div>
<div
class=
"one one2 flex-h"
>
<div
class=
"one one2 flex-h"
>
<div
class=
"_one text-line-one"
@
click=
"showAll(item,$event)"
>
{{
child
.
goods_name
}}
</div>
<div
class=
"_one text-line-one"
@
click=
"showAll(item,$event)"
>
{{
child
.
goods_name
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
<div
class=
"_two text-line-one"
>
*
{{
child
.
number
}}
</div>
</div>
</div>
<!--
<div
class=
"one one2 text-line-one"
>
{{
child
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
<!--
<div
class=
"one one2 text-line-one"
>
{{
child
.
goods_name
}}
*
{{
child
.
number
}}
</div>
-->
...
@@ -215,7 +229,10 @@
...
@@ -215,7 +229,10 @@
@
click=
"workers(index)"
@
click=
"workers(index)"
>
>
<div
class=
"wo flex-h flex-vc"
>
<div
class=
"wo flex-h flex-vc"
>
<div
class=
"item-title"
v-if=
"item.order_status_display == '已派工'"
>
重新派工:
</div>
<div
class=
"item-title"
v-if=
"item.order_status_display == '已派工'"
>
重新派工:
</div>
<div
class=
"item-title"
v-else
>
派工对象:
</div>
<div
class=
"item-title"
v-else
>
派工对象:
</div>
<div
class=
"item-desc worker-name"
>
{{
item
.
realName
}}
</div>
<div
class=
"item-desc worker-name"
>
{{
item
.
realName
}}
</div>
</div>
</div>
...
@@ -233,7 +250,11 @@
...
@@ -233,7 +250,11 @@
class=
"button sureBtn"
class=
"button sureBtn"
@
click=
"sureOrder(item,index)"
@
click=
"sureOrder(item,index)"
>
确定
</div>
>
确定
</div>
<div
v-if=
"item.is_can_cancel==1"
class=
"button"
@
click=
"cancelOrder(item)"
>
取消
</div>
<div
v-if=
"item.is_can_cancel==1"
class=
"button"
@
click=
"cancelOrder(item)"
>
取消
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -284,23 +305,23 @@
...
@@ -284,23 +305,23 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
myTabbar
from
'
@components/common/tabbar.vue
'
//
import myTabbar from '@components/common/tabbar.vue'
import
{
trimStrSpace
}
from
'
@assets/js/format.js
'
//
import { trimStrSpace } from '@assets/js/format.js'
import
{
ImagePreview
,
CellGroup
}
from
'
vant
'
;
import
{
ImagePreview
}
from
'
vant
'
import
select
_i
mg
from
'
@assets/images/select.png
'
import
select
I
mg
from
'
@assets/images/select.png
'
import
unselect
_i
mg
from
'
@assets/images/un_select.png
'
import
unselect
I
mg
from
'
@assets/images/un_select.png
'
import
gr
_i
mg
from
'
@assets/images/gr.png
'
import
gr
I
mg
from
'
@assets/images/gr.png
'
export
default
{
export
default
{
name
:
'
home
'
,
name
:
'
home
'
,
components
:
{
components
:
{
myTabbar
//
myTabbar
},
},
data
()
{
data
()
{
return
{
return
{
select
_i
mg
,
select
I
mg
,
unselect
_i
mg
,
unselect
I
mg
,
gr
_i
mg
,
gr
I
mg
,
reson
:
''
,
//
取消原因
reson
:
''
,
//
取消原因
qxShow
:
false
,
// 发起转单弹窗
qxShow
:
false
,
// 发起转单弹窗
workerName
:
''
,
workerName
:
''
,
worker_id
:
''
,
worker_id
:
''
,
...
@@ -308,17 +329,17 @@ export default {
...
@@ -308,17 +329,17 @@ export default {
columns
:
[],
columns
:
[],
startTime
:
'
请选择开始日期
'
,
startTime
:
'
请选择开始日期
'
,
showStart
:
false
,
showStart
:
false
,
startObj
:{
startObj
:
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
},
},
endObj
:{
endObj
:
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
},
},
currentDate
:
new
Date
(),
currentDate
:
new
Date
(),
showEnd
:
false
,
showEnd
:
false
,
endTime
:
"
请选择截止日期
"
,
endTime
:
'
请选择截止日期
'
,
// 头部日期范围筛选
// 头部日期范围筛选
tabShow
:
false
,
// tab范围选择框是否显示
tabShow
:
false
,
// tab范围选择框是否显示
curSelect
:
{
type
:
'
1
'
,
name
:
'
今日
'
},
// 当前选择的日期范围
curSelect
:
{
type
:
'
1
'
,
name
:
'
今日
'
},
// 当前选择的日期范围
...
@@ -357,17 +378,13 @@ export default {
...
@@ -357,17 +378,13 @@ export default {
// 转单
// 转单
curItem
:
''
,
// 当前选中要操作的数据
curItem
:
''
,
// 当前选中要操作的数据
reason
:
''
,
// 原因
reason
:
''
,
// 原因
currentId
:
''
,
currentId
:
''
}
}
},
},
created
()
{
this
.
getList
()
this
.
getWorkers
()
},
methods
:
{
methods
:
{
// 选择完工人点击确定按钮
// 选择完工人点击确定按钮
keyConfirm
(
i
)
{
keyConfirm
(
i
)
{
if
(
!
this
.
list
[
i
].
temporaryId
.
length
)
{
if
(
!
this
.
list
[
i
].
temporaryId
.
length
)
{
this
.
$toast
(
'
请选择工人!
'
)
this
.
$toast
(
'
请选择工人!
'
)
return
return
}
}
...
@@ -376,43 +393,43 @@ export default {
...
@@ -376,43 +393,43 @@ export default {
this
.
list
[
i
].
worker_id
=
[...
this
.
list
[
i
].
temporaryId
]
this
.
list
[
i
].
worker_id
=
[...
this
.
list
[
i
].
temporaryId
]
this
.
list
[
i
].
showWorker
=
false
this
.
list
[
i
].
showWorker
=
false
},
},
chooseWorker
(
item
,
lchild_index
,
index
)
{
chooseWorker
(
item
,
lchild_index
,
index
)
{
if
(
this
.
list
[
index
].
temporaryId
.
includes
(
item
.
id
))
{
// 删除
if
(
this
.
list
[
index
].
temporaryId
.
includes
(
item
.
id
))
{
// 删除
le
t
name_i
=
this
.
list
[
index
].
temporaryId
.
indexOf
(
item
.
id
)
cons
t
name_i
=
this
.
list
[
index
].
temporaryId
.
indexOf
(
item
.
id
)
this
.
list
[
index
].
temporaryId
.
splice
(
name_i
,
1
)
this
.
list
[
index
].
temporaryId
.
splice
(
name_i
,
1
)
this
.
list
[
index
].
temporaryName
.
splice
(
name_i
,
1
)
this
.
list
[
index
].
temporaryName
.
splice
(
name_i
,
1
)
}
else
{
// 加入
}
else
{
// 加入
this
.
list
[
index
].
temporaryId
.
push
(
item
.
id
)
this
.
list
[
index
].
temporaryId
.
push
(
item
.
id
)
this
.
list
[
index
].
temporaryName
.
push
(
item
.
name
)
this
.
list
[
index
].
temporaryName
.
push
(
item
.
name
)
}
}
},
},
onmore
()
{
onmore
()
{
this
.
getList
()
this
.
getList
()
},
},
preview
(
img
,
index
)
{
preview
(
img
,
index
)
{
let
temp
=
img
.
map
(
item
=>
{
const
temp
=
img
.
map
(
item
=>
{
return
item
.
url
return
item
.
url
})
})
ImagePreview
({
ImagePreview
({
images
:
temp
,
images
:
temp
,
startPosition
:
index
,
startPosition
:
index
})
;
})
},
},
callPhone
(
item
)
{
callPhone
(
item
)
{
console
.
log
(
'
电话
'
,
item
)
console
.
log
(
'
电话
'
,
item
)
le
t
phoneNumber
=
item
.
telephone
cons
t
phoneNumber
=
item
.
telephone
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
window
.
location
.
href
=
'
tel://
'
+
phoneNumber
},
},
//指派工人
//
指派工人
sureOrder
(
item
,
index
)
{
sureOrder
(
item
,
index
)
{
const
vm
=
this
//
const vm = this
// const index = this.list.findIndex(item => item.id === this.curItem.id)
// const index = this.list.findIndex(item => item.id === this.curItem.id)
// console.log('index',index);
// console.log('index',index);
// console.log('1111',item);
// console.log('1111',item);
this
.
curItem
=
item
this
.
curItem
=
item
this
.
repair_order_id
=
item
.
id
this
.
repair_order_id
=
item
.
id
console
.
log
(
'
工人id
'
,
item
.
worker_id
);
console
.
log
(
'
工人id
'
,
item
.
worker_id
)
if
(
!
item
.
worker_id
.
length
)
{
if
(
!
item
.
worker_id
.
length
)
{
this
.
$toast
(
'
请选择工人
'
)
this
.
$toast
(
'
请选择工人
'
)
return
return
}
}
...
@@ -425,32 +442,32 @@ export default {
...
@@ -425,32 +442,32 @@ export default {
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
data
.
workerName
=
[]
data
.
workerName
=
[]
data
.
realName
=
''
data
.
realName
=
''
data
.
temporaryName
=
[]
data
.
temporaryName
=
[]
data
.
temporaryId
=
[]
data
.
temporaryId
=
[]
data
.
worker_id
=
[]
data
.
worker_id
=
[]
this
.
$toast
(
'
操作成功
'
)
this
.
$toast
(
'
操作成功
'
)
this
.
reason
=
''
this
.
reason
=
''
this
.
changeList
(
data
,
index
)
this
.
changeList
(
data
,
index
)
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
changeList
(
data
,
index
)
{
changeList
(
data
,
index
)
{
if
(
this
.
curSelectStatus
.
statustype
==
0
||
this
.
curSelectStatus
.
statustype
==
3
)
{
if
(
this
.
curSelectStatus
.
statustype
==
0
||
this
.
curSelectStatus
.
statustype
==
3
)
{
this
.
$set
(
this
.
list
,
index
,
data
)
this
.
$set
(
this
.
list
,
index
,
data
)
}
else
{
}
else
{
this
.
list
.
splice
(
index
,
1
)
this
.
list
.
splice
(
index
,
1
)
this
.
count
=
this
.
count
-
1
this
.
count
=
this
.
count
-
1
}
}
},
},
// 取消工单
// 取消工单
cancelOrder
(
item
)
{
cancelOrder
(
item
)
{
console
.
log
(
'
aaa
'
,
item
);
console
.
log
(
'
aaa
'
,
item
)
this
.
curItem
=
item
this
.
curItem
=
item
this
.
qxShow
=
true
;
this
.
qxShow
=
true
this
.
reason
=
''
this
.
reason
=
''
},
},
workers
(
index
)
{
workers
(
index
)
{
this
.
$set
(
this
.
list
,
index
,
{...
this
.
list
[
index
],
...{
showWorker
:
true
}
})
this
.
$set
(
this
.
list
,
index
,
{
...
this
.
list
[
index
],
...{
showWorker
:
true
}
})
},
},
// onConfirm(value,i) {
// onConfirm(value,i) {
// console.log('id啊',value.id);
// console.log('id啊',value.id);
...
@@ -458,75 +475,75 @@ export default {
...
@@ -458,75 +475,75 @@ export default {
// this.list[i].showWorker = false
// this.list[i].showWorker = false
// },
// },
Cancel
(
i
)
{
Cancel
(
i
)
{
this
.
list
[
i
].
showWorker
=
false
this
.
list
[
i
].
showWorker
=
false
},
},
endShow
()
{
endShow
()
{
this
.
showEnd
=
true
this
.
showEnd
=
true
},
},
stShow
()
{
stShow
()
{
this
.
showStart
=
true
this
.
showStart
=
true
},
},
formatter
(
type
,
val
)
{
formatter
(
type
,
val
)
{
if
(
type
===
"
year
"
)
{
if
(
type
===
'
year
'
)
{
return
`
${
val
}
年`
;
return
`
${
val
}
年`
}
else
if
(
type
===
"
month
"
)
{
}
else
if
(
type
===
'
month
'
)
{
return
`
${
val
}
月`
;
return
`
${
val
}
月`
}
else
if
(
type
===
"
day
"
)
{
}
else
if
(
type
===
'
day
'
)
{
return
`
${
val
}
日`
;
return
`
${
val
}
日`
}
}
return
val
;
return
val
},
},
birConfirm
(
value
)
{
birConfirm
(
value
)
{
this
.
showStart
=
false
this
.
showStart
=
false
console
.
log
(
'
啊啊啊
'
,
value
);
console
.
log
(
'
啊啊啊
'
,
value
)
if
(
this
.
startTime
==
this
.
conversionTime
(
value
))
{
if
(
this
.
startTime
==
this
.
conversionTime
(
value
))
{
return
return
}
}
this
.
startTime
=
this
.
conversionTime
(
value
)
this
.
startTime
=
this
.
conversionTime
(
value
)
this
.
$set
(
this
.
endObj
,
'
minDate
'
,
value
)
this
.
$set
(
this
.
endObj
,
'
minDate
'
,
value
)
this
.
anginList
()
this
.
anginList
()
console
.
log
(
'
开始时间
'
,
this
.
startTime
);
console
.
log
(
'
开始时间
'
,
this
.
startTime
)
},
},
conversionTime
(
temp
)
{
conversionTime
(
temp
)
{
let
mounth
=
(
temp
.
getMonth
()
+
1
)
<
10
?
'
0
'
+
(
temp
.
getMonth
()
+
1
)
:
(
temp
.
getMonth
()
+
1
)
const
mounth
=
(
temp
.
getMonth
()
+
1
)
<
10
?
'
0
'
+
(
temp
.
getMonth
()
+
1
)
:
(
temp
.
getMonth
()
+
1
)
let
date
=
temp
.
getDate
()
<
10
?
'
0
'
+
temp
.
getDate
()
:
temp
.
getDate
()
const
date
=
temp
.
getDate
()
<
10
?
'
0
'
+
temp
.
getDate
()
:
temp
.
getDate
()
return
temp
.
getFullYear
()
+
return
temp
.
getFullYear
()
+
"
-
"
+
'
-
'
+
mounth
+
mounth
+
"
-
"
+
'
-
'
+
date
date
},
},
birCancel
()
{
birCancel
()
{
this
.
showStart
=
false
;
this
.
showStart
=
false
},
},
endTimeConfirm
(
value
)
{
endTimeConfirm
(
value
)
{
this
.
showEnd
=
false
this
.
showEnd
=
false
if
(
this
.
endTime
==
this
.
conversionTime
(
value
))
{
if
(
this
.
endTime
==
this
.
conversionTime
(
value
))
{
return
return
}
}
this
.
endTime
=
this
.
conversionTime
(
value
)
this
.
endTime
=
this
.
conversionTime
(
value
)
this
.
$set
(
this
.
startObj
,
'
maxDate
'
,
value
)
this
.
$set
(
this
.
startObj
,
'
maxDate
'
,
value
)
this
.
anginList
()
this
.
anginList
()
console
.
log
(
'
结束时间
'
,
this
.
endTime
);
console
.
log
(
'
结束时间
'
,
this
.
endTime
)
},
},
anginList
()
{
anginList
()
{
if
(
this
.
startTime
!=
'
请选择开始日期
'
&&
this
.
endTime
!=
'
请选择截止日期
'
)
{
if
(
this
.
startTime
!=
'
请选择开始日期
'
&&
this
.
endTime
!=
'
请选择截止日期
'
)
{
this
.
initData
()
this
.
initData
()
this
.
getList
()
this
.
getList
()
}
}
},
},
endTimeCancel
()
{
endTimeCancel
()
{
this
.
showEnd
=
false
;
this
.
showEnd
=
false
},
},
//获取工人列表
//
获取工人列表
getWorkers
()
{
getWorkers
()
{
const
curParams
=
{}
const
curParams
=
{}
this
.
$http
this
.
$http
.
get
(
this
.
$myApi
.
GET_WORKER
,
curParams
)
.
get
(
this
.
$myApi
.
GET_WORKER
,
curParams
)
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
this
.
columns
=
data
this
.
columns
=
data
console
.
log
(
this
.
columns
,
'
工人
'
)
console
.
log
(
this
.
columns
,
'
工人
'
)
// var arr = []
// var arr = []
// for (let i in data) {
// for (let i in data) {
// let options = {
// let options = {
...
@@ -560,7 +577,7 @@ export default {
...
@@ -560,7 +577,7 @@ export default {
if
(
this
.
more
&&
!
this
.
isloading
)
{
if
(
this
.
more
&&
!
this
.
isloading
)
{
this
.
isloading
=
true
this
.
isloading
=
true
let
curParams
=
{}
let
curParams
=
{}
if
(
this
.
curSelect
.
type
==
4
)
{
if
(
this
.
curSelect
.
type
==
4
)
{
curParams
=
{
curParams
=
{
time_type
:
this
.
curSelect
.
type
,
time_type
:
this
.
curSelect
.
type
,
page
:
this
.
page
,
page
:
this
.
page
,
...
@@ -569,7 +586,7 @@ export default {
...
@@ -569,7 +586,7 @@ export default {
end
:
this
.
endTime
,
end
:
this
.
endTime
,
status
:
this
.
curSelectStatus
.
statustype
status
:
this
.
curSelectStatus
.
statustype
}
}
}
else
{
}
else
{
curParams
=
{
curParams
=
{
time_type
:
this
.
curSelect
.
type
,
time_type
:
this
.
curSelect
.
type
,
page
:
this
.
page
,
page
:
this
.
page
,
...
@@ -581,12 +598,12 @@ export default {
...
@@ -581,12 +598,12 @@ export default {
.
get
(
this
.
$myApi
.
REPAIR_LIST
,
curParams
)
.
get
(
this
.
$myApi
.
REPAIR_LIST
,
curParams
)
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
this
.
list
=
this
.
page
===
1
?
data
.
list
:
this
.
list
.
concat
(
data
.
list
)
this
.
list
=
this
.
page
===
1
?
data
.
list
:
this
.
list
.
concat
(
data
.
list
)
this
.
list
=
this
.
list
.
map
(
item
=>
{
this
.
list
=
this
.
list
.
map
(
item
=>
{
item
.
showWorker
=
false
item
.
showWorker
=
false
item
.
workerName
=
[]
item
.
workerName
=
[]
item
.
realName
=
''
item
.
realName
=
''
item
.
temporaryName
=
[]
item
.
temporaryName
=
[]
item
.
temporaryId
=
[]
item
.
temporaryId
=
[]
item
.
worker_id
=
[]
item
.
worker_id
=
[]
return
item
return
item
})
})
...
@@ -596,8 +613,8 @@ export default {
...
@@ -596,8 +613,8 @@ export default {
this
.
isloading
=
false
this
.
isloading
=
false
this
.
count
=
data
.
count
this
.
count
=
data
.
count
this
.
loading
=
false
this
.
loading
=
false
this
.
finished
=
!
data
.
more
;
this
.
finished
=
!
data
.
more
if
(
data
.
worker
)
{
if
(
data
.
worker
)
{
this
.
worker_id
=
data
.
worker
.
id
this
.
worker_id
=
data
.
worker
.
id
this
.
workerName
=
data
.
worker
.
name
this
.
workerName
=
data
.
worker
.
name
}
}
...
@@ -620,7 +637,7 @@ export default {
...
@@ -620,7 +637,7 @@ export default {
chooseTab
(
e
)
{
chooseTab
(
e
)
{
this
.
tabShow
=
!
this
.
tabShow
this
.
tabShow
=
!
this
.
tabShow
},
},
//点击选择工单状态
//
点击选择工单状态
chooseStatus
(
e
)
{
chooseStatus
(
e
)
{
this
.
statusShow
=
!
this
.
statusShow
this
.
statusShow
=
!
this
.
statusShow
},
},
...
@@ -629,16 +646,16 @@ export default {
...
@@ -629,16 +646,16 @@ export default {
if
(
item
.
type
!==
this
.
curSelect
.
type
)
{
if
(
item
.
type
!==
this
.
curSelect
.
type
)
{
this
.
curSelect
=
item
this
.
curSelect
=
item
this
.
tabShow
=
false
this
.
tabShow
=
false
if
(
this
.
curSelect
.
type
==
4
)
{
if
(
this
.
curSelect
.
type
==
4
)
{
this
.
startTime
=
'
请选择开始日期
'
this
.
startTime
=
'
请选择开始日期
'
this
.
endTime
=
'
请选择截止日期
'
this
.
endTime
=
'
请选择截止日期
'
this
.
startObj
=
{
this
.
startObj
=
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
}
}
this
.
endObj
=
{
this
.
endObj
=
{
minDate
:
new
Date
(
2021
,
0
,
1
),
minDate
:
new
Date
(
2021
,
0
,
1
),
maxDate
:
new
Date
(),
maxDate
:
new
Date
()
}
}
return
return
}
}
...
@@ -648,7 +665,7 @@ export default {
...
@@ -648,7 +665,7 @@ export default {
},
0
)
},
0
)
}
}
},
},
//订单状态变化
//
订单状态变化
changeStatus
(
item
)
{
changeStatus
(
item
)
{
if
(
item
.
statustype
!==
this
.
curSelectStatus
.
statustype
)
{
if
(
item
.
statustype
!==
this
.
curSelectStatus
.
statustype
)
{
this
.
curSelectStatus
=
item
this
.
curSelectStatus
=
item
...
@@ -677,7 +694,7 @@ export default {
...
@@ -677,7 +694,7 @@ export default {
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
this
.
qxShow
=
false
this
.
qxShow
=
false
this
.
$toast
(
'
操作成功
'
)
this
.
$toast
(
'
操作成功
'
)
this
.
changeList
(
data
,
index
)
this
.
changeList
(
data
,
index
)
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
this
.
qxShow
=
false
this
.
qxShow
=
false
...
@@ -687,10 +704,24 @@ export default {
...
@@ -687,10 +704,24 @@ export default {
cancel
()
{
cancel
()
{
this
.
qxShow
=
false
this
.
qxShow
=
false
},
},
fetchData
(
to
,
from
)
{
this
.
getList
()
this
.
getWorkers
()
}
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
vm
.
fetchData
(
to
,
from
,
next
)
})
},
beforeRouteLeave
(
to
,
from
,
next
)
{
next
()
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/tabbar/admin_index.scss"
;
@import
'@assets/styles/tabbar/admin_index.scss'
;
</
style
>
</
style
>
src/views/tabbar/mine.vue
View file @
48cf7b31
...
@@ -5,11 +5,11 @@
...
@@ -5,11 +5,11 @@
<div
class=
"photo"
>
<div
class=
"photo"
>
<img
src=
"@assets/images/my/touxiang.png"
alt
/>
<img
src=
"@assets/images/my/touxiang.png"
alt
/>
</div>
</div>
<div
class=
"btn"
>
{{
user
.
online_status_display
}}
</div>
<div
class=
"btn"
>
{{
user
.
online_status_display
}}
</div>
<div
class=
"name"
>
{{
user
.
name
}}
</div>
<div
class=
"name"
>
{{
user
.
name
}}
</div>
<div
class=
"group"
>
{{
user
.
department
.
name
}}
</div>
<div
class=
"group"
>
{{
user
.
department
.
name
}}
</div>
<div
class=
"tel flex-h"
@
click=
"goPhone"
>
<div
class=
"tel flex-h"
@
click=
"goPhone"
>
<div
class=
"telNumber"
>
{{
telToHide
(
user
.
phone
)
}}
</div>
<div
class=
"telNumber"
>
{{
telToHide
(
user
.
phone
)
}}
</div>
<img
src=
"@assets/images/my/bianji.png"
alt
/>
<img
src=
"@assets/images/my/bianji.png"
alt
/>
</div>
</div>
</div>
</div>
...
@@ -30,14 +30,11 @@ export default {
...
@@ -30,14 +30,11 @@ export default {
user
:
''
user
:
''
}
}
},
},
created
()
{
this
.
getUserInfo
()
},
methods
:
{
methods
:
{
goPhone
()
{
goPhone
()
{
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'
/modifyPhone
'
,
path
:
'
/modifyPhone
'
,
query
:
{
phone
:
this
.
user
.
phone
}
query
:
{
phone
:
this
.
user
.
phone
}
})
})
},
},
getUserInfo
()
{
getUserInfo
()
{
...
@@ -46,12 +43,23 @@ export default {
...
@@ -46,12 +43,23 @@ export default {
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
this
.
user
=
res
this
.
user
=
res
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
telToHide
(
tel
)
{
telToHide
(
tel
)
{
var
phone
=
tel
.
substr
(
0
,
3
)
+
'
****
'
+
tel
.
substring
(
7
,
11
);
var
phone
=
tel
.
substr
(
0
,
3
)
+
'
****
'
+
tel
.
substring
(
7
,
11
)
return
phone
;
return
phone
},
fetchData
(
to
,
from
)
{
this
.
getUserInfo
()
}
}
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
vm
.
fetchData
(
to
,
from
,
next
)
})
},
beforeRouteLeave
(
to
,
from
,
next
)
{
next
()
}
}
}
}
</
script
>
</
script
>
...
...
src/views/tabbar/modifyPhone.vue
View file @
48cf7b31
<
template
>
<
template
>
<div
class=
"cont"
>
<div
class=
"cont"
>
<div
class=
"tel"
>
<div
class=
"tel"
>
<input
v-model.trim=
"old_tel"
maxlength=
"11"
type=
"tel"
placeholder=
"请输入原手机号"
/>
<input
v-model.trim=
"old_tel"
maxlength=
"11"
type=
"tel"
placeholder=
"请输入原手机号"
/>
</div>
</div>
<div
class=
"tel"
>
<div
class=
"tel"
>
<input
v-model.trim=
"tel"
maxlength=
"11"
type=
"tel"
placeholder=
"请输入新的手机号"
/>
<input
v-model.trim=
"tel"
maxlength=
"11"
type=
"tel"
placeholder=
"请输入新的手机号"
/>
</div>
</div>
<div
class=
"code flex-h"
>
<div
class=
"code flex-h"
>
<van-field
class=
"code_field"
v-model.trim=
"code"
type=
"text"
placeholder=
"请输入验证码"
maxlength=
"6"
/>
<van-field
<div
class=
"getCode"
@
click=
"getCode"
>
{{
buttonText
}}
</div>
class=
"code_field"
v-model.trim=
"code"
type=
"text"
placeholder=
"请输入验证码"
maxlength=
"6"
/>
<div
class=
"getCode"
@
click=
"getCode"
>
{{
buttonText
}}
</div>
</div>
</div>
<div
class=
"submit-btn"
@
click=
"submit"
>
提交
</div>
<div
class=
"submit-btn"
@
click=
"submit"
>
提交
</div>
</div>
</div>
...
@@ -18,7 +34,7 @@
...
@@ -18,7 +34,7 @@
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
old_tel
:
''
,
//
旧手机号
old_tel
:
''
,
//
旧手机号
tel
:
''
,
// 手机号
tel
:
''
,
// 手机号
code
:
''
,
// 验证码
code
:
''
,
// 验证码
buttonText
:
'
获取验证码
'
,
buttonText
:
'
获取验证码
'
,
...
@@ -29,7 +45,7 @@ export default {
...
@@ -29,7 +45,7 @@ export default {
},
},
methods
:
{
methods
:
{
checkData
()
{
checkData
()
{
if
(
!
this
.
checkCon
())
{
if
(
!
this
.
checkCon
())
{
return
return
}
}
if
(
this
.
code
.
length
!==
6
)
{
if
(
this
.
code
.
length
!==
6
)
{
...
@@ -38,7 +54,7 @@ export default {
...
@@ -38,7 +54,7 @@ export default {
}
}
return
true
return
true
},
},
checkCon
()
{
checkCon
()
{
if
(
this
.
old_tel
!=
this
.
$route
.
query
.
phone
)
{
if
(
this
.
old_tel
!=
this
.
$route
.
query
.
phone
)
{
this
.
$toast
(
'
请正确输入原手机号码
'
)
this
.
$toast
(
'
请正确输入原手机号码
'
)
return
false
return
false
...
@@ -55,7 +71,7 @@ export default {
...
@@ -55,7 +71,7 @@ export default {
},
},
getCode
()
{
getCode
()
{
if
(
this
.
isSending
)
return
if
(
this
.
isSending
)
return
if
(
!
this
.
checkCon
())
{
if
(
!
this
.
checkCon
())
{
return
return
}
}
const
curParams
=
{
const
curParams
=
{
...
@@ -68,7 +84,7 @@ export default {
...
@@ -68,7 +84,7 @@ export default {
this
.
isSending
=
true
this
.
isSending
=
true
this
.
countDown
()
this
.
countDown
()
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
countDown
()
{
countDown
()
{
let
seconds
=
60
let
seconds
=
60
...
@@ -93,7 +109,7 @@ export default {
...
@@ -93,7 +109,7 @@ export default {
this
.
$toast
(
'
修改成功
'
)
this
.
$toast
(
'
修改成功
'
)
this
.
$router
.
go
(
-
1
)
this
.
$router
.
go
(
-
1
)
})
})
.
catch
(()
=>
{})
.
catch
(()
=>
{
})
},
},
fetchData
(
to
,
from
)
{
fetchData
(
to
,
from
)
{
this
.
tel
=
''
// 手机号
this
.
tel
=
''
// 手机号
...
@@ -119,5 +135,5 @@ export default {
...
@@ -119,5 +135,5 @@ export default {
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"@assets/styles/tabbar/modifyPhone.scss"
;
@import
'@assets/styles/tabbar/modifyPhone.scss'
;
</
style
>
</
style
>
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