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
48887e9e
authored
Nov 26, 2018
by
朱继来
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
调整更新订单发票
parent
0e84647c
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
51 additions
and
8 deletions
public/js/order.js
resources/views/changeInvoice/content.blade.php
resources/views/detail/content.blade.php
public/js/order.js
View file @
48887e9e
...
...
@@ -686,10 +686,28 @@
$
(
'#inv_type'
).
click
(
function
(){
var
val
=
$
(
this
).
val
();
if
(
val
==
2
)
{
if
(
val
==
1
)
{
// 不开票
$
(
'.tax_title_section'
).
hide
();
$
(
'.add_tax'
).
hide
();
$
(
'input[name=tax_title]'
).
val
(
''
);
$
(
'input[name=tax_no]'
).
val
(
''
);
$
(
'input[name=bank_name]'
).
val
(
''
);
$
(
'input[name=bank_account]'
).
val
(
''
);
$
(
'input[name=company_phone]'
).
val
(
''
);
$
(
'textarea[name=company_address]'
).
val
(
''
);
}
else
if
(
val
==
2
)
{
// 普票
$
(
'.tax_title_section'
).
show
();
$
(
'.add_tax'
).
hide
();
$
(
'.invoice_title'
).
attr
(
'colspan'
,
3
);
}
else
{
$
(
'input[name=tax_no]'
).
val
(
''
);
$
(
'input[name=bank_name]'
).
val
(
''
);
$
(
'input[name=bank_account]'
).
val
(
''
);
$
(
'input[name=company_phone]'
).
val
(
''
);
$
(
'textarea[name=company_address]'
).
val
(
''
);
}
else
{
// 增票
$
(
'.tax_title_section'
).
show
();
$
(
'.add_tax'
).
show
();
$
(
'.invoice_title'
).
attr
(
'colspan'
,
0
);
}
...
...
resources/views/changeInvoice/content.blade.php
View file @
48887e9e
...
...
@@ -48,7 +48,7 @@
</td>
</tr>
<tr>
<tr
class=
"tax_title_section"
>
<td>
发票抬头
</td>
<td
class=
"invoice_title"
>
<input
type=
"text"
name=
"tax_title"
value=
"{{$detail['tax_title']}}"
>
...
...
@@ -77,7 +77,7 @@
</td>
<td>
公司注册地址
</td>
<td>
<textarea
name=
"company_address"
id=
"company_address"
c
ols=
"50"
rows=
"2
"
placeholder=
"请填写详细地址"
>
{{$detail['company_address']}}
</textarea>
<textarea
name=
"company_address"
id=
"company_address"
c
lass=
"form-control
"
placeholder=
"请填写详细地址"
>
{{$detail['company_address']}}
</textarea>
</td>
</tr>
...
...
@@ -97,5 +97,19 @@
$
.
lie
.
order
.
details
();
var
inv_type
=
'{{$detail['
inv_type
']}}'
;
if
(
inv_type
==
1
)
{
$
(
'.tax_title_section'
).
hide
();
$
(
'.add_tax'
).
hide
();
}
else
if
(
inv_type
==
2
)
{
$
(
'.tax_title_section'
).
show
();
$
(
'.add_tax'
).
hide
();
$
(
'.invoice_title'
).
attr
(
'colspan'
,
3
);
}
else
{
$
(
'.tax_title_section'
).
show
();
$
(
'.add_tax'
).
show
();
$
(
'.invoice_title'
).
attr
(
'colspan'
,
0
);
}
$
(
'#inv_type'
).
val
(
inv_type
);
</script>
\ No newline at end of file
resources/views/detail/content.blade.php
View file @
48887e9e
...
...
@@ -221,11 +221,21 @@
<
a
href=
"/changeInvoice/{{$order_info['order_id']}}"
class=
"btn btn-success btn-sm changeBtn"
>
更改发票
</a>
@endif
@elseif (isset($_REQUEST['tags'])
&&
$_REQUEST['tags'] == 'self'
&&
!$extend)
<?php
$isChangeInvoice
=
App\Http\Controllers\isChangeInvoice
(
$order_info
[
'order_sn'
]);
?>
<?php
if
(
$order_info
[
'status'
]
>
3
)
{
// 已付款请求财务接口判断是否能修改发票
$isChangeInvoice
=
App\Http\Controllers\isChangeInvoice
(
$order_info
[
'order_sn'
]);
if
(
$isChangeInvoice
)
{
echo
'<a href="/changeInvoice/'
.
$order_info
[
'order_id'
]
.
'?tags='
.
$_REQUEST
[
'tags'
]
.
'" class="btn btn-success btn-sm changeBtn">更改发票</a>'
;
}
}
else
{
if
(
$order_invoice_info
[
'invoice_status'
]
<
2
&&
in_array
(
'self_order_update_invoice'
,
$userPerms
))
{
echo
'<a href="/changeInvoice/'
.
$order_info
[
'order_id'
]
.
'?tags='
.
$_REQUEST
[
'tags'
]
.
'" class="btn btn-success btn-sm changeBtn">更改发票</a>'
;
}
}
?>
<!-- in_array($order_info['status'], [1, 2, 3, 4]) && $order_invoice_info['invoice_status'] < 2 && in_array('self_order_update_invoice', $userPerms) -->
@if ($isChangeInvoice)
<a
href=
"/changeInvoice/{{$order_info['order_id']}}?tags={{$_REQUEST['tags']}}"
class=
"btn btn-success btn-sm changeBtn"
>
更改发票
</a>
@endif
}
@elseif (isset($_REQUEST['tags'])
&&
$_REQUEST['tags'] == 'erp')
<a
href=
"/changeInvoice/{{$order_info['order_id']}}?tags={{$_REQUEST['tags']}}"
class=
"btn btn-success btn-sm changeBtn"
>
更改发票
</a>
@endif
...
...
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