softbot补充和调整接口字段
This commit is contained in:
parent
f0dca4c0c1
commit
abaec8c115
|
@ -1,4 +1,5 @@
|
||||||
json.partial! "commons/success"
|
json.partial! "commons/success"
|
||||||
|
if @bot.present?
|
||||||
json.extract! @bot, :id, :bot_name, :bot_des, :webhook, :is_public, :logo, :state, :web_url, :install_num, :owner_id, :create_time, :update_time
|
json.extract! @bot, :id, :bot_name, :bot_des, :webhook, :is_public, :logo, :state, :web_url, :install_num, :owner_id, :create_time, :update_time
|
||||||
|
end
|
||||||
|
|
||||||
|
|
|
@ -6,8 +6,10 @@ json.repositories do
|
||||||
project = Project.find_by(id: install_bot.store_id)
|
project = Project.find_by(id: install_bot.store_id)
|
||||||
if project.present?
|
if project.present?
|
||||||
json.id install_bot.store_id
|
json.id install_bot.store_id
|
||||||
json.url "#{base_url}/#{project.owner.login}/#{project.owner.identifier}.git"
|
json.url "#{base_url}/#{project.owner.login}/#{project.identifier}.git"
|
||||||
json.name project.owner.identifier
|
json.identifier project.identifier
|
||||||
|
json.name project.name
|
||||||
|
json.description Nokogiri::HTML(project.description).text
|
||||||
json.owner_name project.owner.login
|
json.owner_name project.owner.login
|
||||||
json.is_public project.is_public
|
json.is_public project.is_public
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue