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
88686e25
authored
Mar 09, 2020
by
朱继来
Browse files
Options
_('Browse Files')
Download
Plain Diff
Merge branch 'master' of
http://119.23.72.7/zhujilai/Order
into zjl_group_20200303
parents
d0560c41
0f3dc01e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
7 deletions
public/js/order.js
resources/views/detail/changeOrder.blade.php
public/js/order.js
View file @
88686e25
...
@@ -1664,7 +1664,7 @@
...
@@ -1664,7 +1664,7 @@
});
});
$
(
'.o
nly_number'
).
off
().
on
(
'keyup'
,
function
(){
$
(
'.o
rder-change-table'
).
delegate
(
'.only_number'
,
'keyup'
,
function
(){
if
(
!
$
(
this
).
val
()){
if
(
!
$
(
this
).
val
()){
return
false
;
return
false
;
}
}
...
@@ -1693,7 +1693,7 @@
...
@@ -1693,7 +1693,7 @@
});
});
// 调整价格
// 调整价格
$
(
'.order-change-table input'
).
off
().
on
(
'
blur
'
,
function
(
e
){
$
(
'.order-change-table input'
).
off
().
on
(
'
keyup
'
,
function
(
e
){
e
.
preventDefault
();
e
.
preventDefault
();
var
table
=
$
(
'.order-change-table'
);
var
table
=
$
(
'.order-change-table'
);
...
@@ -1748,7 +1748,7 @@
...
@@ -1748,7 +1748,7 @@
})
})
// 根据供应商调整附加费
// 根据供应商调整附加费
$
(
'.extend-fee-table input'
).
on
(
'
blur
'
,
function
(){
$
(
'.extend-fee-table input'
).
on
(
'
keyup
'
,
function
(){
var
table
=
$
(
'.extend-fee-table'
);
var
table
=
$
(
'.extend-fee-table'
);
var
goods_total
=
parseFloat
(
$
(
'.goods_total'
).
text
());
var
goods_total
=
parseFloat
(
$
(
'.goods_total'
).
text
());
var
freight_fee
=
$
(
'input[name="freight_fee"]'
).
val
()
?
parseFloat
(
$
(
'input[name="freight_fee"]'
).
val
())
:
0
;
// 运费
var
freight_fee
=
$
(
'input[name="freight_fee"]'
).
val
()
?
parseFloat
(
$
(
'input[name="freight_fee"]'
).
val
())
:
0
;
// 运费
...
@@ -1769,7 +1769,7 @@
...
@@ -1769,7 +1769,7 @@
})
})
// 调整运费
// 调整运费
$
(
'.freight_fee'
).
on
(
'
blur
'
,
function
()
{
$
(
'.freight_fee'
).
on
(
'
keyup
'
,
function
()
{
var
freight_fee
=
parseFloat
(
$
(
this
).
val
());
var
freight_fee
=
parseFloat
(
$
(
this
).
val
());
if
(
!
freight_fee
)
freight_fee
=
0
;
if
(
!
freight_fee
)
freight_fee
=
0
;
...
@@ -1881,7 +1881,7 @@
...
@@ -1881,7 +1881,7 @@
// })
// })
// 设置折扣
// 设置折扣
$
(
'.set_goods_price'
).
off
().
on
(
'
blur
'
,
function
(){
$
(
'.set_goods_price'
).
off
().
on
(
'
keyup
'
,
function
(){
var
val
=
$
(
this
).
val
();
var
val
=
$
(
this
).
val
();
if
(
!
val
)
{
if
(
!
val
)
{
...
@@ -1934,6 +1934,7 @@
...
@@ -1934,6 +1934,7 @@
var
sale_id
=
$
(
'input[name=sale_id]'
).
val
();
var
sale_id
=
$
(
'input[name=sale_id]'
).
val
();
var
order_goods_type
=
$
(
'input[name=order_goods_type]'
).
val
();
var
order_goods_type
=
$
(
'input[name=order_goods_type]'
).
val
();
var
order_id
=
$
(
'input[name=order_id]'
).
val
();
var
order_id
=
$
(
'input[name=order_id]'
).
val
();
var
business_type
=
$
(
'input[name=business_type]'
).
val
();
// 联营订单需要先指派业务员
// 联营订单需要先指派业务员
if
(
order_goods_type
==
1
&&
sale_id
==
0
)
{
if
(
order_goods_type
==
1
&&
sale_id
==
0
)
{
...
@@ -1961,6 +1962,33 @@
...
@@ -1961,6 +1962,33 @@
return
false
;
return
false
;
}
}
// 正常订单校验数量、单价
if
(
business_type
==
0
)
{
var
change_price
=
false
;
var
change_goods_number
=
false
;
var
change_str
=
''
;
$
(
'.order-change-table'
).
find
(
'tbody tr'
).
each
(
function
(){
var
goods_number
=
$
(
this
).
find
(
'.change_goods_number'
).
val
();
var
price
=
$
(
this
).
find
(
'.price'
).
val
();
var
goods_name
=
$
(
this
).
find
(
'.change_goods_name'
).
val
();
if
(
goods_number
==
''
||
goods_number
==
0
)
{
change_goods_number
=
true
;
change_str
+=
goods_name
+
'数量不能为0或空 '
;
}
if
(
price
==
''
||
price
==
0
)
{
change_price
=
true
;
change_str
+=
goods_name
+
'单价不能为0或空 '
;
}
})
if
(
change_price
||
change_goods_number
)
{
layer
.
alert
(
change_str
)
return
false
;
}
}
// 预付款
// 预付款
if
(
pay_type
==
2
)
{
if
(
pay_type
==
2
)
{
var
deposit_amount
=
$
(
'input[name=deposit_amount]'
).
val
();
var
deposit_amount
=
$
(
'input[name=deposit_amount]'
).
val
();
...
@@ -1998,7 +2026,7 @@
...
@@ -1998,7 +2026,7 @@
return
false
;
return
false
;
}
}
}
}
}
}
if
(
!
is_manager
&&
order_goods_type
!=
1
)
{
// 非管理员或经理权限和非联营订单需要判断商品价格是否低于80%以下
if
(
!
is_manager
&&
order_goods_type
!=
1
)
{
// 非管理员或经理权限和非联营订单需要判断商品价格是否低于80%以下
// 设置默认值false
// 设置默认值false
...
...
resources/views/detail/changeOrder.blade.php
View file @
88686e25
...
@@ -22,6 +22,7 @@
...
@@ -22,6 +22,7 @@
<input
type=
"hidden"
name=
"check_failed"
value=
""
>
<input
type=
"hidden"
name=
"check_failed"
value=
""
>
<input
type=
"hidden"
name=
"check_failed_info"
value=
""
>
<input
type=
"hidden"
name=
"check_failed_info"
value=
""
>
<input
type=
"hidden"
name=
"change_pay_type"
value=
""
>
<input
type=
"hidden"
name=
"change_pay_type"
value=
""
>
<input
type=
"hidden"
name=
"business_type"
value=
"{{$order_temp_info['business_type']}}"
>
<?php
$isNewClient
=
App\Http\Controllers\isNewClient
(
$order_info
[
'order_goods_type'
],
$order_info
[
'user_id'
],
$order_info
[
'create_time'
]);
?>
<?php
$isNewClient
=
App\Http\Controllers\isNewClient
(
$order_info
[
'order_goods_type'
],
$order_info
[
'user_id'
],
$order_info
[
'create_time'
]);
?>
@if ($isNewClient)
@if ($isNewClient)
...
@@ -121,7 +122,7 @@
...
@@ -121,7 +122,7 @@
<p>
{{$v['goods_name']}}
</p>
<p>
{{$v['goods_name']}}
</p>
</td>
</td>
<td>
<td>
<input
class=
"only_positive_nubme only_number num"
name=
"change_info[{{$v['rec_id']}}][goods_number]"
value=
"{{$v['goods_number']}}"
>
<input
class=
"only_positive_nubme only_number num
change_goods_number
"
name=
"change_info[{{$v['rec_id']}}][goods_number]"
value=
"{{$v['goods_number']}}"
>
</td>
</td>
<td>
<td>
<span>
{{$currency}}
</span>
<span>
{{$currency}}
</span>
...
...
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