Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
my-yaf-project
Project
Project
Details
Activity
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
chenchuanwen
my-yaf-project
Commits
94aaa1ed
Commit
94aaa1ed
authored
Feb 13, 2019
by
lingqingmei
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'ccw' of
http://git.shenbd.com/api-project-dev/api.shenbd.com
into master_dev
parents
7338bdb8
6daf46da
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
3 deletions
+12
-3
goods.phtml
application/views/index/goods.phtml
+12
-3
No files found.
application/views/index/goods.phtml
View file @
94aaa1ed
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
.price
{
color
:
#ff8519
;
font-size
:
40px
;
margin-top
:
20px
;}
.price
{
color
:
#ff8519
;
font-size
:
40px
;
margin-top
:
20px
;}
.price
#price
{
font-size
:
30px
;
text-decoration
:
line-through
;}
.price
#price
{
font-size
:
30px
;
text-decoration
:
line-through
;}
.qrcode
{
background
:
url(/data/img/flower.png)
;
height
:
388px
;
margin
:
40px
auto
0
auto
;
padding-top
:
100px
;}
.qrcode
{
background
:
url(/data/img/flower.png)
;
height
:
388px
;
margin
:
40px
auto
0
auto
;
padding-top
:
100px
;}
#qrImg
{
margin-top
:
80px
;}
/*#qrImg {margin-top:80px;}*/
#qrcodeImg
img
{
margin
:
0
auto
;}
#qrcodeImg
img
{
margin
:
0
auto
;}
.footer
{
font-size
:
30px
;
height
:
66px
;
line-height
:
66px
;
padding
:
20px
0
55px
0
;}
.footer
{
font-size
:
30px
;
height
:
66px
;
line-height
:
66px
;
padding
:
20px
0
55px
0
;}
.footer
img
{
vertical-align
:
bottom
;
display
:
inline-block
;}
.footer
img
{
vertical-align
:
bottom
;
display
:
inline-block
;}
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
<span
id=
"price"
></span>
<span
id=
"price"
></span>
</div>
</div>
<div
class=
"qrcode"
id=
"qrcode"
>
<div
class=
"qrcode"
id=
"qrcode"
>
<!-- <img id="qrImg" width="250" height="250" src="" />--
>
<img
id=
"qrImg"
width=
"250"
height=
"250"
src=
""
/
>
<div
id=
"qrcodeImg"
></div>
<div
id=
"qrcodeImg"
></div>
<p
id=
"tip"
></p>
<p
id=
"tip"
></p>
</div>
</div>
...
@@ -42,6 +42,12 @@
...
@@ -42,6 +42,12 @@
</div>
</div>
<script
type=
"text/javascript"
src=
"/data/js/qrcode.min.js"
></script>
<script
type=
"text/javascript"
src=
"/data/js/qrcode.min.js"
></script>
<script
type=
"text/javascript"
>
<script
type=
"text/javascript"
>
function
removeElement
(
_element
){
var
_parentElement
=
_element
.
parentNode
;
if
(
_parentElement
){
_parentElement
.
removeChild
(
_element
);
}
}
var
pageObj
=
{
var
pageObj
=
{
type
:
"
<?php
echo
$params
[
'shareType'
];
?>
"
,
//1或2是小程序码,其它是二维码
type
:
"
<?php
echo
$params
[
'shareType'
];
?>
"
,
//1或2是小程序码,其它是二维码
id
:
"
<?php
echo
$params
[
'id'
];
?>
"
,
//1是小程序码,2是二维码,
id
:
"
<?php
echo
$params
[
'id'
];
?>
"
,
//1是小程序码,2是二维码,
...
@@ -64,8 +70,11 @@
...
@@ -64,8 +70,11 @@
if
(
pageObj
.
price
!=
pageObj
.
discount
)
if
(
pageObj
.
price
!=
pageObj
.
discount
)
document
.
getElementById
(
"price"
).
innerHTML
=
"<span style='font-size:30px;'>¥</span>"
+
(
pageObj
.
price
/
100
).
toFixed
(
2
);
document
.
getElementById
(
"price"
).
innerHTML
=
"<span style='font-size:30px;'>¥</span>"
+
(
pageObj
.
price
/
100
).
toFixed
(
2
);
if
(
pageObj
.
type
<=
2
){
if
(
pageObj
.
type
<=
2
){
document
.
getElementById
(
"qrImg"
).
src
=
pageObj
.
qrImg
;}
document
.
getElementById
(
"qrImg"
).
src
=
pageObj
.
qrImg
;
}
else
{
else
{
var
ele
=
document
.
getElementById
(
'qrImg'
);
removeElement
(
ele
);
new
QRCode
(
document
.
getElementById
(
'qrcodeImg'
),
pageObj
.
url
);
new
QRCode
(
document
.
getElementById
(
'qrcodeImg'
),
pageObj
.
url
);
}
}
...
...
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