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
80dbc8b2
Commit
80dbc8b2
authored
Dec 19, 2017
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
经纪人详情修改
parent
a6f4165e
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
11 deletions
+29
-11
Broker.php
application/api/controller/Broker.php
+1
-1
Agents.php
application/model/Agents.php
+17
-3
Evaluate.php
application/model/Evaluate.php
+4
-4
JournalAccounts.php
application/model/JournalAccounts.php
+7
-3
index.php
public/resource/head_portrait/index.php
+0
-0
No files found.
application/api/controller/Broker.php
View file @
80dbc8b2
...
...
@@ -130,7 +130,7 @@ class Broker extends Basic{
$evalutate
=
new
Evaluate
();
$journal
=
new
JournalAccounts
();
$fields_evaluate
=
'house_id,user_id,user_nick,user_phone,user_pic,evaluate_grade,evaluate_content,evaluate_sign
,j.singntime
'
;
$fields_evaluate
=
'house_id,user_id,user_nick,user_phone,user_pic,evaluate_grade,evaluate_content,evaluate_sign'
;
$fields_journal
=
'a.house_id,j.singntime'
;
switch
(
$params
[
'type'
])
{
case
0
:
...
...
application/model/Agents.php
View file @
80dbc8b2
...
...
@@ -41,12 +41,25 @@ class Agents extends Model
->
page
(
$pageNo
)
->
select
();
}
$evaluate
=
new
Evaluate
();
foreach
(
$agent_data
as
$k
=>
$v
)
{
$v
->
head_portrait
=
$_SERVER
[
'SERVER_NAME'
]
.
'/user_header/'
.
$v
->
head_portrait
;
$data
[
$k
]
=
$v
->
toArray
();
}
return
$data
;
foreach
(
$data
as
$kk
=>
$vv
)
{
$evaluate_data
=
$evaluate
->
field
(
'avg(evaluate_grade) as evaluate_grade,count("*") as num'
)
->
where
([
'agents_id'
=>
$vv
[
'id'
],
'is_show'
=>
0
])
->
find
();
$data
[
$k
][
'evaluate_grade'
]
=
$evaluate_data
->
evaluate_grade
;
$data
[
$k
][
'evaluate'
]
=
$evaluate_data
->
num
;
}
return
$data
;
}
/**
...
...
@@ -89,10 +102,11 @@ class Agents extends Model
}
$result
[
'label'
]
=
array
(
0
=>
'待定标签数据'
,
1
=>
'待定标签数据'
);
$data
=
$result
;
}
else
{
$data
=
false
;
}
return
$
result
;
return
$
data
;
}
}
application/model/Evaluate.php
View file @
80dbc8b2
...
...
@@ -45,10 +45,10 @@ class Evaluate extends Model
$sign
=
new
EvaluateSign
();
$applies
=
new
Applies
();
$house
=
new
HouseInfos
();
$user
=
new
Users
();
foreach
(
$result
as
$k
=>
$v
)
{
$data
[
$k
]
=
$v
->
getData
();
$data
[
$k
]
=
$v
->
getData
();
$data
[
$k
][
'user_pic'
]
=
$_SERVER
[
'SERVER_NAME'
]
.
'/resource/head_portrait/'
.
$data
[
$k
][
'user_pic'
];
if
(
$v
[
'evaluate_sign'
])
{
$data
[
$k
][
'evaluate_sign'
]
=
$sign
->
field
(
'sign_name,point_obj'
)
->
where
(
'id'
,
'in'
,
$v
[
'evaluate_sign'
])
...
...
@@ -63,7 +63,7 @@ class Evaluate extends Model
$house_address
=
$house
->
field
(
'address'
)
->
where
(
'id'
,
$v
[
'house_id'
])
->
find
();
//商铺地址
$data
[
$k
][
'houserAddress'
]
=
$house
Info
?
$houseInfo
:
''
;
$data
[
$k
][
'houserAddress'
]
=
$house
_address
?
$house_address
:
''
;
$data
[
$k
][
'receptiontime'
]
=
$receptiontime
?
$receptiontime
:
''
;
}
...
...
application/model/JournalAccounts.php
View file @
80dbc8b2
...
...
@@ -43,7 +43,7 @@ class JournalAccounts extends Model
* @return type
*/
public
function
getJournalHouseInfo
(
$pageNo
=
1
,
$pageSize
=
15
,
$order_
=
'j.id desc'
,
$field
,
$params
,
$agent_id
=
''
)
{
if
(
$agent_id
)
{
$result
=
$this
->
db
->
field
(
$field
)
->
alias
(
'j'
)
->
join
(
'applies a'
,
'j.apply_id = a.id'
,
'LEFT'
)
...
...
@@ -64,10 +64,14 @@ class JournalAccounts extends Model
->
select
();
}
$fields_houinfo
=
'id,title,rent_type,price,room_area,room_area2,shangpu_type'
;
$fields_houinfo
=
'id,title,rent_type,price,room_area,room_area2,shangpu_t
ags,shangpu_t
ype'
;
//查找商铺或街铺的名字和图片
foreach
(
$result
as
$key
=>
$value
)
{
$data
[
$key
]
=
Db
::
table
(
'houseinfos'
)
->
field
(
$fields_houinfo
)
->
where
(
'id'
,
$value
[
'house_id'
])
->
find
();
$data
[
$key
]
=
Db
::
table
(
'houseinfos'
)
->
field
(
$fields_houinfo
)
->
where
(
'id'
,
$value
[
'house_id'
])
->
find
();
$data
[
$key
][
'singntime'
]
=
date
(
'Y-m-d'
,
strtotime
(
$value
[
'singntime'
]));
$data
[
$key
][
'shangpu_tags'
]
=
explode
(
','
,
$data
[
$key
][
'shangpu_tags'
]);
$img
=
Db
::
table
(
'houseimgs'
)
->
field
(
'imagename'
)
->
where
(
'house_id'
,
$value
[
'house_id'
])
->
where
(
'imgtype'
,
1
)
->
find
();
$data
[
$key
][
'img'
]
=
$img
[
'imagename'
];
...
...
public/resource/head_portrait/index.php
0 → 100644
View file @
80dbc8b2
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