Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
U
User
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
zhangjun
User
Commits
bcc8d3c2
Commit
bcc8d3c2
authored
Jun 25, 2024
by
fangliyan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
base_id 取消收藏
parent
a73ad66b
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
6 deletions
+17
-6
user_model.php
esf_core/models/user_model.php
+17
-6
No files found.
esf_core/models/user_model.php
View file @
bcc8d3c2
...
@@ -884,15 +884,29 @@ class User_model extends MY_Model
...
@@ -884,15 +884,29 @@ class User_model extends MY_Model
* @return string|array
* @return string|array
*/
*/
function
getCollectHouseIdByBaseID
(
$base_id
,
$kind
,
$houseid
,
$city
=
GB_CITY
,
$all
=
0
){
function
getCollectHouseIdByBaseID
(
$base_id
,
$kind
,
$houseid
,
$city
=
GB_CITY
,
$all
=
0
){
$base_id_where
=
"'"
.
$base_id
.
"'"
;
$base_id
=
explode
(
','
,
$base_id
);
$base_id
=
explode
(
','
,
$base_id
);
$data
=
$this
->
get_data
(
array
(
'form_name'
=>
'personal_collection'
,
'where_in'
=>
array
(
'base_id'
=>
$base_id
),
'where'
=>
array
(
'collect_id'
=>
$houseid
,
'city_name'
=>
$city
,
'kind'
=>
$kind
),
'select'
=>
array
(
'id'
)),
'esf'
);
if
(
count
(
$base_id
)
>
1
){
foreach
(
$base_id
as
$key
=>
$value
)
{
$base_id_where
.=
"'"
.
$value
.
"',"
;
}
$base_id_where
=
rtrim
(
$base_id_where
,
','
);
}
$sql
=
"select id from personal_collection where base_id in (
$base_id_where
) and collect_id =
$houseid
and city_name = '
$city
' and kind =
$kind
"
;
$query
=
$this
->
db_esfbak
->
query
(
$sql
);
$data
=
$query
->
result_array
();
if
(
!
empty
(
$data
[
0
]))
if
(
!
empty
(
$data
[
0
]))
{
{
$res
=
array
();
foreach
(
$data
as
$key
=>
$value
)
{
$res
[
$key
]
=
$value
[
'id'
];
}
if
(
$all
){
if
(
$all
){
return
$
data
;
return
$
res
;
}
}
return
$
data
[
0
];
return
$
res
[
0
];
}
else
{
}
else
{
return
0
;
return
0
;
}
}
...
@@ -2460,9 +2474,6 @@ if($searcharr['infotype']==4){
...
@@ -2460,9 +2474,6 @@ if($searcharr['infotype']==4){
{
{
//设置表
//设置表
$this
->
user_model
->
set_table
(
'personal_collection'
);
$this
->
user_model
->
set_table
(
'personal_collection'
);
if
(
is_array
(
$arr
)){
$arr
=
implode
(
','
,
$arr
);
}
//过滤表结构
//过滤表结构
$result
=
$this
->
user_model
->
del_mul
(
$arr
,
'id'
,
'esf'
);
$result
=
$this
->
user_model
->
del_mul
(
$arr
,
'id'
,
'esf'
);
return
$result
;
return
$result
;
...
...
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