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
e761deca
authored
Mar 22, 2019
by
朱继来
Browse files
Options
_('Browse Files')
Download
Plain Diff
Merge branch 'zjl_discount_20190322' into development
parents
c6111dfa
26a16eb0
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
51 additions
and
10 deletions
public/js/order.js
resources/views/detail/changeOrder.blade.php
resources/views/detail/content.blade.php
public/js/order.js
View file @
e761deca
...
@@ -1212,7 +1212,9 @@
...
@@ -1212,7 +1212,9 @@
});
});
// 调整价格
// 调整价格
$
(
'.order-change-table input'
).
on
(
'blur'
,
function
(){
$
(
'.order-change-table input'
).
off
().
on
(
'blur'
,
function
(
e
){
e
.
preventDefault
();
var
table
=
$
(
'.order-change-table'
);
var
table
=
$
(
'.order-change-table'
);
var
goods_total
=
0
;
var
goods_total
=
0
;
var
supplier
=
[];
var
supplier
=
[];
...
@@ -1220,6 +1222,7 @@
...
@@ -1220,6 +1222,7 @@
$
(
table
).
find
(
'tbody tr'
).
each
(
function
(){
$
(
table
).
find
(
'tbody tr'
).
each
(
function
(){
var
num
=
parseInt
(
$
(
this
).
find
(
'.num'
).
val
())
||
0
;
var
num
=
parseInt
(
$
(
this
).
find
(
'.num'
).
val
())
||
0
;
var
price
=
parseFloat
(
$
(
this
).
find
(
'.price'
).
val
())
||
0
;
var
price
=
parseFloat
(
$
(
this
).
find
(
'.price'
).
val
())
||
0
;
goods_total
+=
parseFloat
(
num
*
price
);
goods_total
+=
parseFloat
(
num
*
price
);
var
sup
=
$
(
this
).
data
(
'sup'
);
var
sup
=
$
(
this
).
data
(
'sup'
);
...
@@ -1243,7 +1246,7 @@
...
@@ -1243,7 +1246,7 @@
var
total
=
parseFloat
(
goods_total
+
fee
).
toFixed
(
2
);
var
total
=
parseFloat
(
goods_total
+
fee
).
toFixed
(
2
);
goods_total
=
goods_total
.
toFixed
(
2
);
goods_total
=
goods_total
.
toFixed
(
2
);
$
(
'.goods_total'
).
html
(
goods_total
);
$
(
'.goods_total'
).
html
(
goods_total
);
$
(
'input[name="goods_amount"]'
).
val
(
goods_total
);
$
(
'input[name="goods_amount"]'
).
val
(
goods_total
);
$
(
'input[name="order_amount"]'
).
val
(
total
);
$
(
'input[name="order_amount"]'
).
val
(
total
);
...
@@ -1258,6 +1261,8 @@
...
@@ -1258,6 +1261,8 @@
// } else {
// } else {
// checkPayType(total, orderPayType, 1500, 7800);
// checkPayType(total, orderPayType, 1500, 7800);
// }
// }
return
false
;
})
})
// 根据供应商调整附加费
// 根据供应商调整附加费
...
@@ -1367,6 +1372,37 @@
...
@@ -1367,6 +1372,37 @@
// // }
// // }
// })
// })
// 设置折扣
$
(
'.set_goods_price'
).
off
().
on
(
'blur'
,
function
(){
var
val
=
$
(
this
).
val
();
if
(
!
val
)
{
layer
.
msg
(
'折扣值不能为空'
);
val
=
1
;
}
if
(
isNaN
(
parseFloat
(
val
)))
{
layer
.
msg
(
'折扣值只能是数字和小数组成'
);
val
=
1
;
}
if
(
val
<=
0
||
val
>
1
)
{
layer
.
msg
(
'折扣值只能大于0且小于等于1'
);
val
=
1
;
}
var
discount
=
parseFloat
(
val
).
toFixed
(
2
);
$
(
this
).
val
(
discount
);
$
(
'.order-change-table'
).
find
(
'tbody tr'
).
each
(
function
(){
var
price
=
$
(
this
).
find
(
'.price'
).
val
();
var
discount_price
=
parseFloat
(
price
*
discount
).
toFixed
(
2
);
$
(
this
).
find
(
'.price'
).
val
(
discount_price
);
})
$
(
'.order-change-table input'
).
triggerHandler
(
'blur'
);
// 自动触发
})
// 选择付款时间
// 选择付款时间
$
(
'.payTime'
).
change
(
function
(){
$
(
'.payTime'
).
change
(
function
(){
var
val
=
$
(
this
).
val
();
var
val
=
$
(
this
).
val
();
...
...
resources/views/detail/changeOrder.blade.php
View file @
e761deca
...
@@ -147,6 +147,18 @@
...
@@ -147,6 +147,18 @@
</tbody>
</tbody>
</table>
</table>
@if ($order_info['order_goods_type'] == 2)
<table
class=
"table table-bordered table-hover"
>
<tr>
<th
width=
"20%"
>
批量调价
</th>
<td>
<input
type=
"text"
class=
"set_goods_price"
name=
"set_goods_price"
value=
"1"
>
<span
class=
"text-danger"
>
(批量设置单价,默认值1,折扣范围 0
<
值
<=
1
)</
span
>
</td>
</tr>
</table>
@endif
<?php
$extend_fee_items
=
json_decode
(
$order_temp_info
[
'extend_fee_items'
],
true
);
?>
<?php
$extend_fee_items
=
json_decode
(
$order_temp_info
[
'extend_fee_items'
],
true
);
?>
<!-- 供应商附加费 -->
<!-- 供应商附加费 -->
...
@@ -221,13 +233,6 @@
...
@@ -221,13 +233,6 @@
</tr>
</tr>
@endif
@endif
<!-- <tr>
<th>说明</th>
<td>
<textarea name="extra_fee_description" id="" cols="30" rows="5">{$detail.extra_fee_description}</textarea>
</td>
</tr> -->
<tr>
<tr>
<th
width=
"20%"
>
订单总额
</th>
<th
width=
"20%"
>
订单总额
</th>
<td>
<td>
...
...
resources/views/detail/content.blade.php
View file @
e761deca
...
@@ -559,7 +559,7 @@
...
@@ -559,7 +559,7 @@
@endif
@endif
<tr>
<tr>
<td>
{{ isset($order_temp_info)
&&
$order_temp_info['order_type'] == 3
&&
!$order_temp_info['business_type'] ? '(自营内部采购下单享95折优惠)' : '' }}
订单总额:
</td>
<td>
订单总额:
</td>
<td>
<td>
<span
style=
"color:red;font-size:20px"
>
{{$currency}}
<span
style=
"color:red;font-size:20px"
>
{{$currency}}
<span
class=
"amount"
>
{{$order_info['order_amount']}}
</span>
<span
class=
"amount"
>
{{$order_info['order_amount']}}
</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