Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
D
doublescreen-back
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pengguangpu
doublescreen-back
Commits
69076a08
Commit
69076a08
authored
Feb 24, 2020
by
jiangjiantao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
价格校验&商品码校验
parent
f606d418
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
2 deletions
+13
-2
landkeybord.js
pages/components/landkeybord/landkeybord.js
+13
-2
No files found.
pages/components/landkeybord/landkeybord.js
View file @
69076a08
...
@@ -56,7 +56,9 @@ Component({
...
@@ -56,7 +56,9 @@ Component({
},
add0
(
e
)
{
},
add0
(
e
)
{
this
.
setData
({
result
:
this
.
data
.
result
+
"0"
});
this
.
setData
({
result
:
this
.
data
.
result
+
"0"
});
},
addpoint
(
e
)
{
},
addpoint
(
e
)
{
if
(
this
.
data
.
scenes
==
3
||
this
.
data
.
scenes
==
4
)
{
this
.
setData
({
result
:
this
.
data
.
result
+
"."
});
this
.
setData
({
result
:
this
.
data
.
result
+
"."
});
}
},
delete
(
e
)
{
},
delete
(
e
)
{
if
(
this
.
data
.
result
.
length
>
1
)
{
if
(
this
.
data
.
result
.
length
>
1
)
{
let
cur
=
this
.
data
.
result
;
let
cur
=
this
.
data
.
result
;
...
@@ -66,6 +68,15 @@ Component({
...
@@ -66,6 +68,15 @@ Component({
this
.
setData
({
result
:
''
});
this
.
setData
({
result
:
''
});
}
}
},
finish
(
e
)
{
},
finish
(
e
)
{
if
(
this
.
data
.
scenes
==
3
||
this
.
data
.
scenes
==
4
)
{
//判断价格是否参数合法
var
priceReg
=
/
(
^
[
1-9
]\d
*
(\.\d{1,2})?
$
)
|
(
^0
(\.\d{1,2})?
$
)
/
;
if
(
!
priceReg
.
test
(
this
.
data
.
result
))
{
//错误提示
return
}
}
this
.
props
.
onKeyBordFinished
(
this
.
data
.
result
);
this
.
props
.
onKeyBordFinished
(
this
.
data
.
result
);
},
closeKeybord
(
e
){
},
closeKeybord
(
e
){
this
.
props
.
onKeyBordClose
();
this
.
props
.
onKeyBordClose
();
...
...
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