Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
SURPRISED
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
华国豪
SURPRISED
Commits
41c4aff3
Commit
41c4aff3
authored
Sep 02, 2025
by
youjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
意见调查
parent
8a1eb67c
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
85 additions
and
17 deletions
+85
-17
guestSign.html
html/ImpressionOpinionSurvey/guestSign.html
+83
-16
guestlogin.html
html/ImpressionOpinionSurvey/guestlogin.html
+2
-1
No files found.
html/ImpressionOpinionSurvey/guestSign.html
View file @
41c4aff3
...
...
@@ -48,6 +48,7 @@
var
newMsg
=
{}
var
priceInfo
=
null
var
dataList
=
null
var
dataListAll
=
null
var
GuestSurveyInfo
=
null
var
userInfo
=
getLocalStorage
()
...
...
@@ -71,7 +72,6 @@
t
:
userInfo
.
t
,
g
:
userInfo
.
g
,
}
}
else
{
qMsg
=
query
()
}
...
...
@@ -83,9 +83,10 @@
getCheckbox
()
GetBusSurveyInfo
()
function
clickRadio
(
i
)
{
function
clickRadio
(
i
,
index
,
ID
)
{
const
Radiobox
=
document
.
getElementById
(
`my_Radio
${
i
}
`
);
Radiobox
.
click
()
dataList
[
index
].
ScoreNum
=
ID
}
function
getRadio
()
{
...
...
@@ -96,15 +97,27 @@
radio
.
addEventListener
(
'click'
,
function
()
{
x
.
ScoreNum
=
radio
.
value
});
if
(
x
.
SurveyType
==
2
&&
y
.
IsCheck
==
'1'
&&
radio
.
value
==
y
.
ID
){
radio
.
click
()
x
.
ScoreNum
=
radio
.
value
}
});
})
})
}
function
clickCheckbox
(
i
)
{
function
clickCheckbox
(
i
,
index
,
index2
,
ID
)
{
const
checkbox
=
document
.
getElementById
(
`my_checkbox
${
i
}
`
);
checkbox
.
click
()
let
findIndex
=
dataList
[
index
].
IsCheckS
.
findIndex
(
item
=>
item
==
ID
)
if
(
findIndex
==-
1
)
{
dataList
[
index
].
IsCheckS
.
push
(
ID
)
}
else
{
dataList
[
index
].
IsCheckS
=
dataList
[
index
].
IsCheckS
.
filter
(
item
=>
item
!=
ID
)
}
}
function
getCheckbox
()
{
...
...
@@ -113,11 +126,14 @@
const
checkbox
=
document
.
getElementsByName
(
`my_checkbox
${
i
+
1
}
`
);
checkbox
.
forEach
(
checkbox
=>
{
checkbox
.
addEventListener
(
'click'
,
function
()
{
if
(
checkbox
.
checked
)
y
.
IsCheckS
.
push
(
checkbox
.
value
)
if
(
!
checkbox
.
checked
)
y
.
IsCheckS
=
y
.
IsCheckS
.
filter
(
z
=>
{
if
(
checkbox
.
checked
)
x
.
IsCheckS
.
push
(
checkbox
.
value
)
if
(
!
checkbox
.
checked
)
x
.
IsCheckS
=
y
.
IsCheckS
.
filter
(
z
=>
{
return
z
!=
checkbox
.
value
})
});
if
(
x
.
SurveyType
==
3
&&
y
.
IsCheck
==
'1'
&&
checkbox
.
value
==
y
.
ID
){
checkbox
.
click
()
}
});
})
})
...
...
@@ -130,6 +146,9 @@
if
(
word
&&
word
.
value
)
{
x
.
TextContent
=
word
.
value
}
if
(
x
.
TextContent
){
word
.
value
=
x
.
TextContent
}
})
}
...
...
@@ -154,12 +173,15 @@
if
(
item
.
SurveyType
==
2
)
{
if
(
item
.
ScoreNum
==
y
.
ID
)
{
y
.
IsCheck
=
"1"
;
}
else
{
y
.
IsCheck
=
"0"
;
}
}
//多选
if
(
item
.
SurveyType
==
3
)
{
y
.
IsCheck
=
"0"
;
if
(
y
.
IsCheckS
)
{
let
fildIndex
=
item
.
IsCheckS
.
findIndex
(
x
=>
x
==
y
.
ID
)
if
(
fildIndex
!=-
1
)
{
y
.
IsCheck
=
"1"
;
}
}
...
...
@@ -178,12 +200,13 @@
data
:
getAjaxData
(
"survey_post_SetGuestSurvey"
,
postMsg
),
async
:
false
,
success
:
function
(
res
)
{
$
(
'#submitB'
).
attr
(
'disabled'
,
false
)
if
(
res
.
resultCode
===
1
)
{
return
window
.
location
.
href
=
'success.html'
}
else
{
layer
.
msg
(
res
.
message
)
}
$
(
'#submitB'
).
attr
(
'disabled'
,
false
)
document
.
getElementById
(
"submitB"
).
classList
.
remove
(
"active"
)
},
error
:
function
(
message
)
{
...
...
@@ -243,21 +266,22 @@
let
data
=
res
.
data
data
.
map
(
item
=>
{
if
(
item
.
SurveyType
===
2
)
{
item
.
SurveyOptionsList
.
map
((
cItem
,
cIndex
)
=>
{
cItem
.
IsCheckS
=
false
})
item
.
IsCheckS
=
false
}
if
(
item
.
SurveyType
===
3
)
{
item
.
SurveyOptionsList
.
map
((
cItem
,
cIndex
)
=>
{
cItem
.
IsCheckS
=
[]
})
item
.
IsCheckS
=
[]
}
if
(
item
.
SurveyType
===
1
)
{
item
.
ScoreNum
=
5
;
}
})
dataListAll
=
data
dataList
=
data
if
(
localStorage
.
TakeoutVersion
==
1
){
getSurveyDetails
()
}
else
{
renderStar
()
}
}
else
{
layer
.
msg
(
res
.
message
)
}
...
...
@@ -299,6 +323,49 @@
});
}
function
getSurveyDetails
()
{
var
msg
=
{
...
newMsg
,
type
:
userInfo
.
type
,
guestMobile
:
userInfo
.
guestMobile
,
TCID
:
''
,
}
$
.
ajax
({
type
:
"POST"
,
url
:
`
${
getApiUrl
().
urlPost
}
`
,
contentType
:
"application/json"
,
data
:
getAjaxData
(
"miniProgram_price_GetGuestByPhone_V2"
,
msg
),
async
:
false
,
success
:
function
(
res
)
{
if
(
res
.
resultCode
===
1
)
{
if
(
res
.
data
&&
res
.
data
.
length
>
0
&&
res
.
data
[
0
].
SurverList
.
length
>
0
){
let
data
=
res
.
data
[
0
].
SurverList
data
.
map
(
item
=>
{
if
(
item
.
SurveyType
===
3
)
{
item
.
IsCheckS
=
[]
}
})
dataList
=
data
for
(
let
i
=
0
;
i
<
dataListAll
.
length
;
i
++
){
let
findIndex
=
dataList
.
findIndex
(
item
=>
item
.
ID
==
dataListAll
[
i
].
ID
)
if
(
findIndex
==-
1
){
dataList
.
push
(
dataListAll
[
i
])
}
}
renderStar
()
getTextarea
()
}
else
renderStar
()
}
else
{
layer
.
msg
(
res
.
message
)
}
},
error
:
function
(
message
)
{
alert
(
JSON
.
stringify
(
message
));
}
});
}
function
chgStar
(
num
,
i
)
{
dataList
[
i
].
ScoreNum
=
num
var
item
=
dataList
[
i
]
...
...
@@ -353,7 +420,7 @@
let
radioList
=
[]
if
(
item
.
SurveyOptionsList
.
length
>
0
)
item
.
SurveyOptionsList
.
forEach
((
radio
,
index
)
=>
{
radioList
.
push
(
`<div><input type="radio" value="
${
radio
.
ID
}
" name="my_Radio
${
i
+
1
}
" id="my_Radio
${
i
+
1
}${
index
+
1
}
"/><span onclick="clickRadio(
${
i
+
1
}${
index
+
1
}
)">
${
radio
.
OptionsName
}
</span></div>`
`<div><input type="radio" value="
${
radio
.
ID
}
" name="my_Radio
${
i
+
1
}
" id="my_Radio
${
i
+
1
}${
index
+
1
}
"/><span onclick="clickRadio(
${
i
+
1
}${
index
+
1
}
,
${
i
}
,
${
radio
.
ID
}
)">
${
radio
.
OptionsName
}
</span></div>`
)
})
if
(
radioList
.
length
>
0
)
{
...
...
@@ -368,7 +435,7 @@
let
MultipleList
=
[]
if
(
item
.
SurveyOptionsList
.
length
>
0
)
item
.
SurveyOptionsList
.
forEach
((
radio
,
index
)
=>
{
MultipleList
.
push
(
`<div><input type="checkbox" value="
${
radio
.
ID
}
" name="my_checkbox
${
i
+
1
}
" id="my_checkbox
${
i
+
1
}${
index
+
1
}
"/><span onclick="clickCheckbox(
${
i
+
1
}${
index
+
1
}
)">
${
radio
.
OptionsName
}
</span></div>`
`<div><input type="checkbox" value="
${
radio
.
ID
}
" name="my_checkbox
${
i
+
1
}
" id="my_checkbox
${
i
+
1
}${
index
+
1
}
"/><span onclick="clickCheckbox(
${
i
+
1
}${
index
+
1
}
,
${
i
}
,
${
index
}
,
${
radio
.
ID
}
)">
${
radio
.
OptionsName
}
</span></div>`
)
})
if
(
MultipleList
.
length
>
0
)
{
...
...
html/ImpressionOpinionSurvey/guestlogin.html
View file @
41c4aff3
...
...
@@ -17,7 +17,7 @@
<div
class=
"login_contentBox"
>
<div
class=
"login_content"
id=
"login_content"
>
<div
class=
"login_button"
id=
"login_button"
>
<button
id=
"buttonSJ"
onclick=
"changeLoginType(1)"
>
手机号验证
</button>
<button
id=
"buttonSJ"
class=
"active"
onclick=
"changeLoginType(1)"
>
手机号验证
</button>
<button
id=
"buttonHZ"
onclick=
"changeLoginType(2)"
>
护照号验证
</button>
</div>
</div>
...
...
@@ -153,6 +153,7 @@
t
:
query
().
t
,
g
:
query
().
g
,
guestMobile
:
msg
.
guestMobile
,
type
:
msg
.
type
,
}
localStorage
.
userInfo
=
JSON
.
stringify
(
datas
)
window
.
location
.
href
=
`guestSign.html`
...
...
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