Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
self-support
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李俊赕
self-support
Commits
b39308e0
Commit
b39308e0
authored
May 21, 2021
by
linwenqing
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
https://git.banshouhui.com/lijundan/self-support
into test
parents
388968fe
466bac9a
Changes
9
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
138 additions
and
34 deletions
+138
-34
order.js
src/common/api/order.js
+7
-1
XhSelect.vue
src/components/createCom/XhSelect.vue
+3
-0
XhServiceMeasure.vue
src/components/createCom/XhServiceMeasure.vue
+3
-0
pages.json
src/pages.json
+7
-2
mine.vue
src/pages/index/mine.vue
+33
-7
order.vue
src/pages/index/order.vue
+1
-0
index.vue
src/pages/mine/superLogin/index.vue
+51
-0
complete.vue
src/pages/order/complete.vue
+32
-23
index.js
src/plugins/uploader/index.js
+1
-1
No files found.
src/common/api/order.js
View file @
b39308e0
...
@@ -166,6 +166,10 @@ let orderApiFun = function(vm){
...
@@ -166,6 +166,10 @@ let orderApiFun = function(vm){
let
payableRecord
=
async
(
params
=
{})
=>
await
vm
.
$u
.
post
(
settle
+
vm
.
vuex_token
+
'/payable/v2/queryPayableRecord'
,
params
,
formType
);
let
payableRecord
=
async
(
params
=
{})
=>
await
vm
.
$u
.
post
(
settle
+
vm
.
vuex_token
+
'/payable/v2/queryPayableRecord'
,
params
,
formType
);
// 获取我的钱包-师傅提现
// 获取我的钱包-师傅提现
let
workerApplyPay
=
async
()
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/applypay/batch/workerApplyPay'
);
let
workerApplyPay
=
async
()
=>
await
vm
.
$u
.
get
(
prefix
+
vm
.
vuex_token
+
'/applypay/batch/workerApplyPay'
);
// 是否有特殊登录权限
let
allowLogin
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
'other/auth/'
+
vm
.
vuex_token
+
'/allow/login'
,
params
);
// 特殊登录切换师傅
let
otherUser
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
prefix
+
'other/auth/'
+
vm
.
vuex_token
+
'/other/user'
,
params
);
const
orderApi
=
{
const
orderApi
=
{
listByRecommendOrder
,
listByRecommendOrder
,
...
@@ -204,6 +208,8 @@ let orderApiFun = function(vm){
...
@@ -204,6 +208,8 @@ let orderApiFun = function(vm){
listStatement
,
listStatement
,
payableRecord
,
payableRecord
,
workerApplyPay
,
workerApplyPay
,
allowLogin
,
otherUser
}
}
return
orderApi
return
orderApi
}
}
...
...
src/components/createCom/XhSelect.vue
View file @
b39308e0
...
@@ -120,6 +120,9 @@
...
@@ -120,6 +120,9 @@
height
:
38px
;
height
:
38px
;
.txt
{
.txt
{
font-size
:
14px
;
font-size
:
14px
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
}
}
}
}
</
style
>
</
style
>
src/components/createCom/XhServiceMeasure.vue
View file @
b39308e0
...
@@ -185,6 +185,9 @@
...
@@ -185,6 +185,9 @@
height
:
38px
;
height
:
38px
;
.txt
{
.txt
{
font-size
:
14px
;
font-size
:
14px
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
}
}
}
}
.text-view
{
.text-view
{
...
...
src/pages.json
View file @
b39308e0
...
@@ -255,9 +255,14 @@
...
@@ -255,9 +255,14 @@
"navigationBarTitleText"
:
"我的仓库"
,
"navigationBarTitleText"
:
"我的仓库"
,
"enablePullDownRefresh"
:
false
"enablePullDownRefresh"
:
false
}
}
}
},
{
"path"
:
"superLogin/index"
,
"style"
:
{
"navigationBarTitleText"
:
""
}
}
]
]
},
},
...
...
src/pages/index/mine.vue
View file @
b39308e0
...
@@ -16,6 +16,7 @@
...
@@ -16,6 +16,7 @@
<u-icon
class=
"tel-arrow-icon"
name=
"arrow-up-fill"
></u-icon>
<u-icon
class=
"tel-arrow-icon"
name=
"arrow-up-fill"
></u-icon>
</view>
</view>
</view>
</view>
<view
v-if=
"showSuperButton"
class=
"super-button"
><u-button
@
click=
"handleSuperButton"
>
切换用户
</u-button></view>
</view>
</view>
<view
class=
"list-view"
>
<view
class=
"list-view"
>
...
@@ -45,6 +46,7 @@
...
@@ -45,6 +46,7 @@
return
{
return
{
qnPath
:
process
.
uniEnv
.
qn_base_url
,
qnPath
:
process
.
uniEnv
.
qn_base_url
,
serviceTel
:
'18124099271'
,
serviceTel
:
'18124099271'
,
showSuperButton
:
false
}
}
},
},
computed
:
{
computed
:
{
...
@@ -134,9 +136,19 @@
...
@@ -134,9 +136,19 @@
},
},
onLoad
()
{
onLoad
()
{
app
.
trackPage
(
'我的首页'
)
app
.
trackPage
(
'我的首页'
)
if
(
this
.
vuex_token
&&
!
this
.
settled
)
{
console
.
log
(
'-------000-------'
)
if
(
this
.
vuex_token
)
{
console
.
log
(
'-------1111-------'
)
if
(
!
this
.
showSuperButton
)
{
this
.
allowLogin
()
}
if
(
!
this
.
settled
)
{
this
.
getData
()
this
.
getData
()
}
}
}
},
},
methods
:
{
methods
:
{
getData
()
{
getData
()
{
...
@@ -164,6 +176,17 @@
...
@@ -164,6 +176,17 @@
}
}
this
.
$u
.
route
({
url
:
"pages/login/index"
})
this
.
$u
.
route
({
url
:
"pages/login/index"
})
},
},
async
allowLogin
()
{
let
res
=
await
this
.
$u
.
api
.
allowLogin
()
console
.
log
(
res
)
if
(
res
)
{
this
.
showSuperButton
=
res
.
code
==
200
}
},
handleSuperButton
()
{
this
.
$u
.
route
({
url
:
'pages/mine/superLogin/index'
})
}
}
}
}
}
</
script
>
</
script
>
...
@@ -240,6 +263,9 @@
...
@@ -240,6 +263,9 @@
}
}
}
}
}
}
.super-button
{
margin-left
:
20rpx
;
}
}
}
.list-view
{
.list-view
{
...
...
src/pages/index/order.vue
View file @
b39308e0
...
@@ -301,6 +301,7 @@
...
@@ -301,6 +301,7 @@
+
"&categoryId="
+
item
.
categoryId
+
"&categoryId="
+
item
.
categoryId
+
"&orderServiceType="
+
item
.
orderServiceType
+
"&orderServiceType="
+
item
.
orderServiceType
+
"&inGuaranteePeriod="
+
item
.
inGuaranteePeriod
+
"&inGuaranteePeriod="
+
item
.
inGuaranteePeriod
+
"&partnerCompanyId="
+
item
.
partnerCompanyId
+
"&auditResultsId="
+
(
item
.
auditResults
?
Object
.
keys
(
item
.
auditResults
)[
Object
.
keys
(
item
.
auditResults
).
length
-
1
]:
''
)
+
"&auditResultsId="
+
(
item
.
auditResults
?
Object
.
keys
(
item
.
auditResults
)[
Object
.
keys
(
item
.
auditResults
).
length
-
1
]:
''
)
})
})
},
},
...
...
src/pages/mine/superLogin/index.vue
0 → 100644
View file @
b39308e0
<
template
>
<view
class=
"super-login"
>
<u-input
auto-focus
v-model=
"mobile"
focus
type=
"number"
placeholder=
"请输入手机号"
></u-input>
<view
class=
"line-view"
></view>
<view
class=
"button-view"
>
<u-button
class=
"change-button"
type=
"primary"
@
click=
"handleClick"
>
确认切换
</u-button>
</view>
</view>
</
template
>
<
script
>
export
default
{
data
()
{
return
{
mobile
:
''
}
},
methods
:
{
handleClick
()
{
this
.
otherUser
()
},
async
otherUser
()
{
let
res
=
await
this
.
$u
.
api
.
otherUser
({
mobile
:
this
.
mobile
})
console
.
log
(
res
)
if
(
res
&&
res
.
code
==
200
)
{
this
.
$u
.
vuex
(
"vuex_token"
,
res
.
data
);
uni
.
navigateBack
({
})
}
},
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.super-login
{
padding
:
30rpx
;
margin
:
30rpx
;
background-color
:
#FFFFFF
;
border-radius
:
12rpx
;
.line-view
{
background-color
:
#F4F5F7
;
height
:
2rpx
;
}
.button-view
{
margin-top
:
40rpx
;
}
}
</
style
>
src/pages/order/complete.vue
View file @
b39308e0
...
@@ -5,20 +5,20 @@
...
@@ -5,20 +5,20 @@
<u-navbar
:background=
"
{background: '#2272FF'}" back-icon-color="#fff" :title-size="32" title-color="#fff" :border-bottom="false" title="完工信息" title-bold>
</u-navbar>
<u-navbar
:background=
"
{background: '#2272FF'}" back-icon-color="#fff" :title-size="32" title-color="#fff" :border-bottom="false" title="完工信息" title-bold>
</u-navbar>
<u-tabs
class=
"order-tabs"
ref=
"tabs"
:current=
"tabIndex"
name=
"panelName"
:list=
"list"
@
change=
"tabsChange"
:is-scroll=
"false"
bg-color=
"#2272FF"
inactive-color=
"#a6c6ff"
active-color=
"#fff"
height=
"80"
font-size=
"32"
></u-tabs>
<u-tabs
class=
"order-tabs"
ref=
"tabs"
:current=
"tabIndex"
name=
"panelName"
:list=
"list"
@
change=
"tabsChange"
:is-scroll=
"false"
bg-color=
"#2272FF"
inactive-color=
"#a6c6ff"
active-color=
"#fff"
height=
"80"
font-size=
"32"
></u-tabs>
<view
class=
"u-menu-wrap"
>
<view
class=
"u-menu-wrap"
>
<scroll-view
scroll-y
scroll-with-animation
class=
"u-tab-view menu-scroll-view"
:scroll-top=
"scrollTop"
:scroll-into-view=
"itemId"
v-if=
"list[tabIndex].items.length > 1"
>
<scroll-view
scroll-y
scroll-with-animation
class=
"u-tab-view menu-scroll-view"
:scroll-top=
"scrollTop"
v-if=
"list[tabIndex].items.length > 1"
>
<view
v-for=
"(item,index) in list[tabIndex].items"
:key=
"index"
class=
"u-tab-item"
<view
v-for=
"(item,index) in list[tabIndex].items"
:key=
"index"
class=
"u-tab-item"
:class=
"[current == index ? 'u-tab-item-active' : '']"
@
tap
.
stop=
"swichMenu(index)"
>
:class=
"[current == index ? 'u-tab-item-active' : '']"
@
tap
.
stop=
"swichMenu(index)"
>
<text
class=
"u-line-1"
>
{{
item
.
name
}}
</text>
<text
class=
"u-line-1"
>
{{
item
.
name
}}
</text>
</view>
</view>
</scroll-view>
</scroll-view>
<scroll-view
:scroll-top=
"scrollRightTop"
:enhanced=
"true"
scroll-y
scroll-with-animation
class=
"right-box"
@
scroll=
"rightScroll
"
>
<scroll-view
:scroll-top=
"scrollRightTop"
scroll-y
scroll-with-animation
class=
"right-box"
@
scroll=
"rightScroll"
:scroll-into-view=
"itemId
"
>
<u-form
:model=
"form"
ref=
"uForm"
>
<u-form
:model=
"form"
ref=
"uForm"
>
<template
v-for=
"(groupItem, groupIndex) in (list.length>0?list[tabIndex].items:[])"
>
<template
v-for=
"(groupItem, groupIndex) in (list.length>0?list[tabIndex].items:[])"
>
<view
class=
"class-item"
:key=
"groupIndex"
>
<view
class=
"class-item"
:key=
"groupIndex"
>
<view
class=
"title"
v-if=
"groupItem.name !== '基本信息'"
>
{{
groupItem
.
name
}}
</view>
<view
class=
"title"
v-if=
"groupItem.name !== '基本信息'"
>
{{
groupItem
.
name
}}
</view>
<view
class=
"class-bd"
>
<view
class=
"class-bd"
>
<u-form-item
v-for=
"(item,itemIndex) in groupItem.items"
:key=
"itemIndex"
label-position=
"top"
<u-form-item
v-for=
"(item,itemIndex) in groupItem.items"
:key=
"itemIndex"
label-position=
"top"
:prop=
"item.fieldsName"
:border-bottom=
"false"
v-show=
"item.fieldsId != 200 || show200"
>
:prop=
"item.fieldsName"
:border-bottom=
"false"
v-show=
"item.fieldsId != 200 || show200"
:id=
"`item$
{item.fieldsId}`">
<view
:class=
"[
{'label-bold': groupItem.name === '基本信息'}, 'label']" v-if="item.formType!=='location'
&&
item.formType!=='form'
&&
item.formType!=='label'">
<view
:class=
"[
{'label-bold': groupItem.name === '基本信息'}, 'label']" v-if="item.formType!=='location'
&&
item.formType!=='form'
&&
item.formType!=='label'">
<image
class=
"item-image"
:src=
"mixingImage"
v-if=
"item.required"
></image>
<image
class=
"item-image"
:src=
"mixingImage"
v-if=
"item.required"
></image>
{{
item
.
fieldsTitle
}}
{{
item
.
fieldsTitle
}}
...
@@ -147,6 +147,7 @@
...
@@ -147,6 +147,7 @@
menuHeight
:
0
,
// 左边菜单的高度
menuHeight
:
0
,
// 左边菜单的高度
menuItemHeight
:
0
,
// 左边菜单item的高度
menuItemHeight
:
0
,
// 左边菜单item的高度
itemId
:
''
,
// 栏目右边scroll-view用于滚动的id
itemId
:
''
,
// 栏目右边scroll-view用于滚动的id
oldItemId
:
''
,
menuItemPos
:
[],
menuItemPos
:
[],
arr
:
[],
arr
:
[],
scrollRightTop
:
0
,
// 右边栏目scroll-view的滚动条高度
scrollRightTop
:
0
,
// 右边栏目scroll-view的滚动条高度
...
@@ -369,6 +370,7 @@
...
@@ -369,6 +370,7 @@
self
.
waitHandlerPanelIndex
=
panelIndex
self
.
waitHandlerPanelIndex
=
panelIndex
self
.
waitHandlerGroupIndex
=
groupIndex
self
.
waitHandlerGroupIndex
=
groupIndex
self
.
waitHandlerEleIndex
=
eleIndex
self
.
waitHandlerEleIndex
=
eleIndex
self
.
oldItemId
=
`item
${
ele
.
fieldsId
}
`
}
}
})
})
})
})
...
@@ -433,6 +435,7 @@
...
@@ -433,6 +435,7 @@
self
.
waitHandlerPanelIndex
=
panelIndex
self
.
waitHandlerPanelIndex
=
panelIndex
self
.
waitHandlerGroupIndex
=
groupIndex
self
.
waitHandlerGroupIndex
=
groupIndex
self
.
waitHandlerEleIndex
=
eleIndex
self
.
waitHandlerEleIndex
=
eleIndex
self
.
oldItemId
=
`item
${
ele
.
fieldsId
}
`
}
}
}
}
})
})
...
@@ -460,8 +463,8 @@
...
@@ -460,8 +463,8 @@
locationCompleteItem
(
panelIndex
,
groupIndex
,
eleIndex
){
// 页面定位到某一项
locationCompleteItem
(
panelIndex
,
groupIndex
,
eleIndex
){
// 页面定位到某一项
this
.
tabIndex
=
panelIndex
this
.
tabIndex
=
panelIndex
this
.
arr
=
[]
this
.
arr
=
[]
this
.
scrollRightTop
=
0
this
.
scrollRightTop
=
0
;
this
.
current
=
groupIndex
this
.
current
=
0
;
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
this
.
swichMenu
(
groupIndex
)
this
.
swichMenu
(
groupIndex
)
})
})
...
@@ -497,16 +500,6 @@
...
@@ -497,16 +500,6 @@
})
})
}
}
},
},
tabsChange
(
index
){
this
.
tabIndex
=
index
this
.
arr
=
[]
this
.
scrollRightTop
=
0
;
this
.
current
=
0
;
this
.
leftMenuStatus
(
0
)
this
.
$nextTick
(
function
()
{
this
.
getMenuItemTop
()
})
},
calMaterialCraftListAmount
(
arr
){
calMaterialCraftListAmount
(
arr
){
let
amount
=
0
let
amount
=
0
if
(
arr
){
if
(
arr
){
...
@@ -529,7 +522,7 @@
...
@@ -529,7 +522,7 @@
// 更新预计超出金额
// 更新预计超出金额
let
amount
=
this
.
calMaterialCraftListAmount
(
this
.
form
.
materialList
)
let
amount
=
this
.
calMaterialCraftListAmount
(
this
.
form
.
materialList
)
amount
+=
this
.
calMaterialCraftListAmount
(
this
.
form
.
craftList
)
amount
+=
this
.
calMaterialCraftListAmount
(
this
.
form
.
craftList
)
this
.
$set
(
this
.
form
,
'
allExtraAm
t'
,
amount
)
this
.
$set
(
this
.
form
,
'
overAmoun
t'
,
amount
)
},
},
// 字段的值更新
// 字段的值更新
fieldValueChange
(
data
)
{
fieldValueChange
(
data
)
{
...
@@ -563,13 +556,26 @@
...
@@ -563,13 +556,26 @@
this
.
tabIndex
++
this
.
tabIndex
++
this
.
arr
=
[]
this
.
arr
=
[]
this
.
scrollRightTop
=
0
this
.
scrollRightTop
=
0
this
.
current
=
0
this
.
leftMenuStatus
(
0
)
const
itemId
=
this
.
list
[
this
.
tabIndex
].
items
[
0
].
items
[
0
].
fieldsId
this
.
oldItemId
=
`item
${
itemId
}
`
this
.
$nextTick
(
async
()
=>
{
if
(
this
.
oldItemId
)
this
.
itemId
=
this
.
oldItemId
})
}
},
tabsChange
(
index
){
this
.
tabIndex
=
index
this
.
arr
=
[]
this
.
scrollRightTop
=
0
;
this
.
current
=
0
;
this
.
leftMenuStatus
(
0
)
this
.
leftMenuStatus
(
0
)
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
if
(
this
.
oldItemId
)
this
.
itemId
=
this
.
oldItemId
this
.
getMenuItemTop
()
this
.
getMenuItemTop
()
})
})
}
},
},
// ------------------------- 以下方法为上传组件相关 -------------------------
// ------------------------- 以下方法为上传组件相关 -------------------------
// 弹出上传选项
// 弹出上传选项
selectUpload
(
item
,
groupIndex
,
itemIndex
){
selectUpload
(
item
,
groupIndex
,
itemIndex
){
...
@@ -626,7 +632,8 @@
...
@@ -626,7 +632,8 @@
// 获取拍照规范
// 获取拍照规范
photograph
(){
photograph
(){
let
self
=
this
let
self
=
this
let
param
=
{
"partnerCompanyId"
:
this
.
partnerCompanyId
,
let
param
=
{
"partnerCompanyId"
:
this
.
partnerCompanyId
||
''
,
"categoryId"
:
this
.
categoryId
,
"categoryId"
:
this
.
categoryId
,
"brandId"
:
this
.
brandId
||
''
,
"brandId"
:
this
.
brandId
||
''
,
"fieldName"
:
this
.
photoItem
.
fieldsName
}
"fieldName"
:
this
.
photoItem
.
fieldsName
}
...
@@ -644,7 +651,7 @@
...
@@ -644,7 +651,7 @@
if
(
getApp
().
globalData
.
photo
.
waterSetting
){
if
(
getApp
().
globalData
.
photo
.
waterSetting
){
return
return
}
}
var
data
=
{
partnerCompanyId
:
this
.
partnerCompanyId
}
var
data
=
{
partnerCompanyId
:
this
.
partnerCompanyId
||
''
}
this
.
$u
.
api
.
getWatermark
(
data
).
then
((
res
)
=>
{
this
.
$u
.
api
.
getWatermark
(
data
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
)
{
if
(
res
.
code
==
200
)
{
getApp
().
globalData
.
photo
.
waterSetting
=
res
.
data
getApp
().
globalData
.
photo
.
waterSetting
=
res
.
data
...
@@ -664,7 +671,9 @@
...
@@ -664,7 +671,9 @@
if
(
index
==
this
.
current
)
return
;
if
(
index
==
this
.
current
)
return
;
this
.
scrollRightTop
=
this
.
oldScrollTop
;
this
.
scrollRightTop
=
this
.
oldScrollTop
;
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
this
.
scrollRightTop
=
this
.
arr
[
index
];
this
.
itemId
=
this
.
oldItemId
if
(
!
this
.
oldItemId
)
this
.
scrollRightTop
=
this
.
arr
[
index
];
this
.
oldItemId
=
''
this
.
current
=
index
;
this
.
current
=
index
;
this
.
leftMenuStatus
(
index
);
this
.
leftMenuStatus
(
index
);
})
})
...
...
src/plugins/uploader/index.js
View file @
b39308e0
...
@@ -184,7 +184,7 @@ uploader.requestError = function(e) {
...
@@ -184,7 +184,7 @@ uploader.requestError = function(e) {
throw
e
;
throw
e
;
}
else
{
}
else
{
uni
.
showToast
({
uni
.
showToast
({
title
:
"
网络错误,请检查一下网络
"
,
title
:
"
当前网络信号较差,请耐心等待或尝试切换网络环境
"
,
icon
:
"none"
icon
:
"none"
});
});
}
}
...
...
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