Commit 7b68057f authored by Vasyl Bodnaruk's avatar Vasyl Bodnaruk

Add function to make Company for AITopics

parent 7a6d1a92
......@@ -18,6 +18,8 @@ class CompanyMaker:
self._make_list_for_mhn()
elif media == 'tc':
self._make_list_for_tc()
elif media == 'aitop':
self._make_list_for_aitop()
def get_companies(self):
return self.companies
......@@ -40,4 +42,10 @@ class CompanyMaker:
tag = tag.replace(' ', '-')
if tag.find('.'):
tag = tag.replace('.', '-')
self.companies.append(Company(i.id, 'https://techcrunch.com/tag/' + tag, 81, 2, 2, i.name))
\ No newline at end of file
self.companies.append(Company(i.id, 'https://techcrunch.com/tag/' + tag, 81, 2, 2, i.name))
def _make_list_for_aitop(self):
for i in self.in_site:
self.companies.append(Company(i.id, 'https://aitopics.org/search?view=&filters=&sort=score+desc&q=' + i.name,
129, 2, 2, i.name))
\ No newline at end of file
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