Commit a61e611f authored by Hsinli's avatar Hsinli

fix

parent adca59c2
Pipeline #9264 passed with stage
in 15 seconds
...@@ -177,17 +177,17 @@ class CollectionService extends Service { ...@@ -177,17 +177,17 @@ class CollectionService extends Service {
}, },
order: [['created_at', 'desc']] order: [['created_at', 'desc']]
} }
let collectionList = await ctx.realestateModel.Collection.all(filter); let list = await ctx.realestateModel.Collection.all(filter);
let count = 0; let count = 0;
if (collectionList.length > 0) { if (list.length > 0) {
let newHouseId = []; let newHouseId = [];
let rentalHouseId = []; let rentalHouseId = [];
for (let i in collectionList) { for (let i in list) {
if (Number(collectionList[i].house_style) === 1) { if (Number(list[i].house_style) === 1) {
newHouseId.push(collectionList[i].connect_id); newHouseId.push(list[i].connect_id);
} }
if (Number(collectionList[i].house_style) === 2) { if (Number(list[i].house_style) === 2) {
rentalHouseId.push(collectionList[i].connect_id); rentalHouseId.push(list[i].connect_id);
} }
} }
let newHousefilter = { let newHousefilter = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment