Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
朱继来
/
后台订单管理
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
2d02c691
authored
Mar 31, 2020
by
朱继来
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
调整审单新增无SKUID商品(供应商为digikey时,skuid必填)
parent
4244f186
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
2 deletions
app/Http/Controllers/AddOrderController.php
public/js/goods.js
resources/views/detail/addGoodsNoSkuid.blade.php
app/Http/Controllers/AddOrderController.php
View file @
2d02c691
...
...
@@ -837,6 +837,7 @@ Class AddOrderController extends Controller
$data
[
'add_goods_name'
]
=
$request
->
input
(
'add_goods_name'
,
''
);
$data
[
'add_brand_name'
]
=
$request
->
input
(
'add_brand_name'
,
''
);
$data
[
'add_supplier_name'
]
=
$request
->
input
(
'add_supplier_name'
,
''
);
$data
[
'add_goods_id'
]
=
$request
->
input
(
'add_goods_id'
,
0
);
$data
[
'add_goods_number'
]
=
$request
->
input
(
'add_goods_number'
,
0
);
$data
[
'add_goods_price'
]
=
$request
->
input
(
'add_goods_price'
,
0
);
$data
[
'add_delivery_time'
]
=
$request
->
input
(
'add_delivery_time'
,
''
);
...
...
public/js/goods.js
View file @
2d02c691
...
...
@@ -80,6 +80,19 @@
})
})
// 无SKUID --- 供应商
$
(
'#addGoodsNoSkuid'
).
delegate
(
'.add_supplier_name'
,
'keyup'
,
function
()
{
var
val
=
$
(
this
).
val
();
if
(
val
.
toLowerCase
()
==
'digikey'
)
{
$
(
'.skuid-info'
).
css
(
'display'
,
'block'
);
$
(
'.layui-layer-iframe .layui-layer-btn, .layui-layer-page .layui-layer-btn'
).
css
(
'padding-top'
,
'50px'
);
}
else
{
$
(
'.skuid-info'
).
css
(
'display'
,
'none'
);
$
(
'.layui-layer-iframe .layui-layer-btn, .layui-layer-page .layui-layer-btn'
).
css
(
'padding-top'
,
'0px'
);
}
})
$
(
'.order-change-main'
).
on
(
'click'
,
'.add_goods_no_skuid'
,
function
()
{
layer
.
open
({
area
:
[
'600px'
],
...
...
@@ -92,6 +105,7 @@
var
add_goods_name
=
$
(
'input[name=add_goods_name]'
).
val
();
var
add_brand_name
=
$
(
'input[name=add_brand_name]'
).
val
();
var
add_supplier_name
=
$
(
'input[name=add_supplier_name]'
).
val
();
var
add_goods_id
=
$
(
'input[name=add_goods_id]'
).
val
();
var
add_goods_number
=
$
(
'input[name=add_goods_number]'
).
val
();
var
add_goods_price
=
$
(
'input[name=add_goods_price]'
).
val
();
var
add_delivery_time
=
$
(
'input[name=add_delivery_time]'
).
val
();
...
...
@@ -115,6 +129,18 @@
return
false
;
}
if
(
add_supplier_name
.
toLowerCase
()
==
'digikey'
)
{
if
(
!
add_goods_id
)
{
layer
.
msg
(
'供应商为digikey,请输入SKUID'
);
return
false
;
}
if
(
!
reg
.
test
(
add_goods_id
))
{
layer
.
msg
(
'格式错误,请输入正确的SKUID'
);
return
false
;
}
}
if
(
!
add_goods_number
)
{
layer
.
msg
(
'请输入采购数量'
);
return
false
;
...
...
@@ -146,6 +172,7 @@
add_goods_name
:
add_goods_name
,
add_brand_name
:
add_brand_name
,
add_supplier_name
:
add_supplier_name
,
add_goods_id
:
add_goods_id
,
add_goods_number
:
add_goods_number
,
add_goods_price
:
add_goods_price
,
add_delivery_time
:
add_delivery_time
,
...
...
resources/views/detail/addGoodsNoSkuid.blade.php
View file @
2d02c691
<style>
#addGoodsNoSkuid
{
display
:
none
;
}
#addGoodsNoSkuid
,
#addGoodsNoSkuid
.skuid-info
{
display
:
none
;
}
#addGoodsNoSkuid
input
{
width
:
280px
;
height
:
35px
;
}
#addGoodsNoSkuid
textarea
{
width
:
280px
;
}
</style>
...
...
@@ -21,7 +21,13 @@
<div
class=
"form-group"
>
<label
for=
"inputEmail3"
class=
"col-sm-4 control-label"
><i
class=
"error"
>
*
</i>
供应商
</label>
<div
class=
"col-sm-8"
>
<input
class=
"form-control"
type=
"text"
name=
"add_supplier_name"
value=
""
placeholder=
"请输入供应商"
>
<input
class=
"form-control add_supplier_name"
type=
"text"
name=
"add_supplier_name"
value=
""
placeholder=
"请输入供应商"
>
</div>
</div>
<div
class=
"form-group skuid-info"
>
<label
for=
"inputEmail3"
class=
"col-sm-4 control-label"
><i
class=
"error"
>
*
</i>
SKUID
</label>
<div
class=
"col-sm-8"
>
<input
class=
"form-control"
type=
"text"
name=
"add_goods_id"
value=
""
placeholder=
"请输入商品SKUID"
>
</div>
</div>
<div
class=
"form-group"
>
...
...
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