Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
U
uni-app-huahai
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
单欣鑫
uni-app-huahai
Commits
583af469
Commit
583af469
authored
Sep 30, 2025
by
秦威威
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
最新版
parent
4b440e3c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
72 additions
and
86 deletions
+72
-86
upload-image.vue
components/upload-image.vue
+0
-7
feedback.vue
pages/my/feedback.vue
+72
-79
No files found.
components/upload-image.vue
View file @
583af469
...
...
@@ -43,8 +43,6 @@
images
:
{
immediate
:
true
,
handler
(
newVal
,
oldVal
)
{
// console.log(newVal)
// console.log(this.fileList)
this
.
fileList
=
[]
if
(
newVal
)
{
const
urlList
=
newVal
.
split
(
"
,
"
)
...
...
@@ -70,7 +68,6 @@
},
// 新增图片
async
afterRead
(
event
,
type
)
{
// console.log(event, type, "et")
let
lists
=
[].
concat
(
event
.
file
)
let
fileListLen
=
this
.
fileList
.
length
lists
.
map
((
item
)
=>
{
...
...
@@ -80,13 +77,9 @@
message
:
'
上传中
'
})
})
// console.log(lists, "listslistslistslists")
for
(
let
i
=
0
;
i
<
lists
.
length
;
i
++
)
{
const
result
=
await
this
.
$wskj
.
uploadImg
(
lists
[
i
].
url
)
// console.log(result, "resulttttt")
// console.log(this.fileList, "fileListfileList")
let
item
=
this
[[
type
]][
fileListLen
]
// console.log(item, "itemssss")
this
.
fileList
.
splice
(
fileListLen
,
1
,
Object
.
assign
(
item
,
{
status
:
'
success
'
,
message
:
''
,
...
...
pages/my/feedback.vue
View file @
583af469
...
...
@@ -4,20 +4,15 @@
<view
class=
"reason"
>
<view
class=
"title"
>
文字描述(必填)
</view>
<view
class=
"mt-30"
>
<u--textarea
v-model=
"reason"
height=
"260rpx"
maxlength=
"150"
placeholder=
"请输入(最低10个字)"
count
></u--textarea>
<u--textarea
v-model=
"reason"
height=
"260rpx"
maxlength=
"150"
placeholder=
"请输入(最低10个字)"
count
></u--textarea>
</view>
</view>
<view
class=
"mt-30"
>
<text>
相关图片(必填,最多9张)
</text>
<view
class=
"control"
>
<upload-image
v-model=
"images"
maxCount=
"3"
width=
"100"
height=
"100"
type=
"fullurl"
></upload-image>
<upload-image
v-model=
"images"
maxCount=
"3"
width=
"100"
height=
"100"
type=
"fullurl"
></upload-image>
</view>
</view>
</view>
...
...
@@ -41,10 +36,10 @@
</
template
>
<
script
>
export
default
{
export
default
{
data
()
{
return
{
reason
:
''
,
reason
:
''
,
submitShow
:
false
,
images
:
''
,
};
...
...
@@ -53,23 +48,23 @@ export default {
this
.
images
=
'
/assets/img/qrcode.png
'
},
methods
:
{
onSubmit
()
{
onSubmit
()
{
// console.log(this.images)
// this.images = ''
// console.log(this.images)
if
(
!
this
.
reason
)
{
if
(
!
this
.
reason
)
{
return
this
.
$u
.
toast
(
'
请输入内容
'
)
}
if
(
!
this
.
images
)
{
if
(
!
this
.
images
)
{
return
this
.
$u
.
toast
(
'
请至少上传一张照片
'
)
}
if
(
this
.
reason
.
length
<
10
)
{
if
(
this
.
reason
.
length
<
10
)
{
return
this
.
$u
.
toast
(
'
文字描述最低10个字
'
)
}
this
.
submitShow
=
true
},
// 提交
onConfirmSubmit
()
{
onConfirmSubmit
()
{
const
params
=
{
url
:
'
/api/user/yijian
'
,
loadingTip
:
''
,
...
...
@@ -82,7 +77,7 @@ export default {
this
.
$request
(
params
).
then
(
res
=>
{
// console.log(res)
this
.
submitShow
=
false
if
(
res
.
code
===
1
)
{
if
(
res
.
code
===
1
)
{
this
.
$u
.
toast
(
res
.
msg
||
'
提交成功
'
)
this
.
reason
=
''
...
...
@@ -96,29 +91,27 @@ export default {
})
}
},
};
};
</
script
>
<
style
scoped
>
.container
{
padding
:
30
rpx
;
}
.wapper
{
}
.wapper
{
}
.reason
{
.reason
{
}
}
.reason
>
.title
{
.reason
>
.title
{}
}
.reason
>
textarea
{
.reason
>
textarea
{
margin-top
:
20
rpx
;
padding
:
15
rpx
;
width
:
100%
!important
;
border
:
1px
solid
#ccc
!important
;
}
.control
{
margin-top
:
20
rpx
;
}
...
...
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