Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
semour
/
semour_web
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
b26390be
authored
Nov 25, 2022
by
肖康
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
购物车交互修改
parent
1869bf97
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
public/assets/js/car/car.js
resources/views/car/car.blade.php
public/assets/js/car/car.js
View file @
b26390be
...
@@ -63,6 +63,9 @@ define('car', ['tool', 'liexin_pop', 'artTemplate'], function (require, exports,
...
@@ -63,6 +63,9 @@ define('car', ['tool', 'liexin_pop', 'artTemplate'], function (require, exports,
var
parents
=
$
(
this
).
parents
(
".tr"
)
var
parents
=
$
(
this
).
parents
(
".tr"
)
var
max_num
=
Number
(
$
(
this
).
attr
(
"maxNum"
));
var
max_num
=
Number
(
$
(
this
).
attr
(
"maxNum"
));
var
min_num
=
Number
(
$
(
this
).
attr
(
"minNum"
));
var
min_num
=
Number
(
$
(
this
).
attr
(
"minNum"
));
var
mult
=
Number
(
$
(
this
).
attr
(
"mult"
));
num
=
Math
.
ceil
(
num
/
mult
)
*
mult
;
$
(
this
).
val
(
num
)
if
(
num
>
max_num
){
if
(
num
>
max_num
){
$
(
this
).
val
(
max_num
)
$
(
this
).
val
(
max_num
)
liexin_pop
.
Tip
({
title
:
"At Most "
+
max_num
})
liexin_pop
.
Tip
({
title
:
"At Most "
+
max_num
})
...
@@ -89,7 +92,7 @@ define('car', ['tool', 'liexin_pop', 'artTemplate'], function (require, exports,
...
@@ -89,7 +92,7 @@ define('car', ['tool', 'liexin_pop', 'artTemplate'], function (require, exports,
}
}
})
})
},
3
00
))
},
6
00
))
//删除购物车
//删除购物车
$
(
".delcarsd"
).
click
(
function
(){
$
(
".delcarsd"
).
click
(
function
(){
var
arr_
=
[]
var
arr_
=
[]
...
...
resources/views/car/car.blade.php
View file @
b26390be
...
@@ -120,7 +120,7 @@
...
@@ -120,7 +120,7 @@
</div>
</div>
<div class="
td
w119
">
{
{value.hk_delivery_time}
}
</div>
<div class="
td
w119
">
{
{value.hk_delivery_time}
}
</div>
<div class="
td
w93
">
<div class="
td
w93
">
<input type="
text
" class="
valuep
" goods_id="
{{
value
.
goods_id
}}
" minNum="
{{
value
.
moq
}}
" maxNum="
{{
value
.
max_buy_stock
}}
" value="
{{
value
.
buy_number
}}
" onkeyup="
if
(
this
.
value
.
length
==
1
){
this
.
value
=
this
.
value
.
replace
(
/
[
^
1
-
9
]
/
g
,
''
)}
else
{
this
.
value
=
this
.
value
.
replace
(
/
\D
/
g
,
''
)}
" onafterpaste="
if
(
this
.
value
.
length
==
1
){
this
.
value
=
this
.
value
.
replace
(
/
[
^
1
-
9
]
/
g
,
''
)}
else
{
this
.
value
=
this
.
value
.
replace
(
/
\D
/
g
,
''
)}
">
<input type="
text
" class="
valuep
" goods_id="
{{
value
.
goods_id
}}
" m
ult="
{{
value
.
mult
}}
" m
inNum="
{{
value
.
moq
}}
" maxNum="
{{
value
.
max_buy_stock
}}
" value="
{{
value
.
buy_number
}}
" onkeyup="
if
(
this
.
value
.
length
==
1
){
this
.
value
=
this
.
value
.
replace
(
/
[
^
1
-
9
]
/
g
,
''
)}
else
{
this
.
value
=
this
.
value
.
replace
(
/
\D
/
g
,
''
)}
" onafterpaste="
if
(
this
.
value
.
length
==
1
){
this
.
value
=
this
.
value
.
replace
(
/
[
^
1
-
9
]
/
g
,
''
)}
else
{
this
.
value
=
this
.
value
.
replace
(
/
\D
/
g
,
''
)}
">
</div>
</div>
<div class="
td
w110
">
{
{value.stock}
}
</div>
<div class="
td
w110
">
{
{value.stock}
}
</div>
<div class="
td
w92
">$<span class="
rowdj
">
{
{value.buy_price}
}
</span></div>
<div class="
td
w92
">$<span class="
rowdj
">
{
{value.buy_price}
}
</span></div>
...
...
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