Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujun
tl_estate
Commits
de991dee
Commit
de991dee
authored
Jul 31, 2018
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
删除税费
parent
4f1e1858
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
4 deletions
+10
-4
Finance.php
application/index/controller/Finance.php
+1
-1
OTaxes.php
application/model/OTaxes.php
+9
-3
No files found.
application/index/controller/Finance.php
View file @
de991dee
...
@@ -1388,7 +1388,7 @@ class Finance extends Basic
...
@@ -1388,7 +1388,7 @@ class Finance extends Basic
return
$this
->
response
(
101
,
'参数错误'
);
return
$this
->
response
(
101
,
'参数错误'
);
$m_taxes
=
new
OTaxes
();
$m_taxes
=
new
OTaxes
();
$num
=
$m_taxes
->
updateTaxesById
(
$this
->
params
[
'taxes_id'
],[
'is_del'
=>
1
]);
$num
=
$m_taxes
->
updateTaxesById
(
[
'id_or_father_id'
=>
$this
->
params
[
'taxes_id'
]
],[
'is_del'
=>
1
]);
if
(
$num
>
0
)
{
if
(
$num
>
0
)
{
$result
[
'code'
]
=
200
;
$result
[
'code'
]
=
200
;
$result
[
'msg'
]
=
'删除成功'
;
$result
[
'msg'
]
=
'删除成功'
;
...
...
application/model/OTaxes.php
View file @
de991dee
...
@@ -259,19 +259,24 @@ class OTaxes extends BaseModel
...
@@ -259,19 +259,24 @@ class OTaxes extends BaseModel
/**
/**
* 修改信息
* 修改信息
*
*
* @param $
id
* @param $
where
* @param $params
* @param $params
* @return OTaxes
* @return OTaxes
*/
*/
public
function
updateTaxesById
(
$
id
,
$params
)
public
function
updateTaxesById
(
$
where
,
$params
)
{
{
$update_dta
=
[];
$update_dta
=
[];
if
(
isset
(
$params
[
'is_del'
]))
{
if
(
isset
(
$params
[
'is_del'
]))
{
$update_dta
[
'is_del'
]
=
1
;
$update_dta
[
'is_del'
]
=
1
;
}
}
if
(
isset
(
$where
[
'id_or_father_id'
]))
{
$where_
[]
=
[
'EXP'
,
'id ='
.
$where
[
'id_or_father_id'
]
.
' or father_id='
.
$where
[
'id_or_father_id'
]];
}
$update_dta
[
"update_time"
]
=
date
(
"Y-m-d H:i:s"
,
time
());
$update_dta
[
"update_time"
]
=
date
(
"Y-m-d H:i:s"
,
time
());
$result
=
$this
->
where
(
'id'
,
$id
)
->
update
(
$update_dta
);
$result
=
$this
->
where
(
$where_
)
->
update
(
$update_dta
);
return
$result
;
return
$result
;
}
}
}
}
\ No newline at end of file
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