Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
G
go-cqhttp
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nanahira
go-cqhttp
Commits
a9d08e5d
Commit
a9d08e5d
authored
Aug 27, 2020
by
Mrs4s
Committed by
GitHub
Aug 27, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #201 from yyuueexxiinngg/patch-1
Match netease music app id
parents
1c4cb96c
46747354
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
coolq/cqcode.go
coolq/cqcode.go
+1
-1
No files found.
coolq/cqcode.go
View file @
a9d08e5d
...
@@ -473,7 +473,7 @@ func (bot *CQBot) ToElement(t string, d map[string]string, group bool) (message.
...
@@ -473,7 +473,7 @@ func (bot *CQBot) ToElement(t string, d map[string]string, group bool) (message.
if
info
.
Get
(
"artists.0"
)
.
Exists
()
{
if
info
.
Get
(
"artists.0"
)
.
Exists
()
{
artistName
=
info
.
Get
(
"artists.0.name"
)
.
Str
artistName
=
info
.
Get
(
"artists.0.name"
)
.
Str
}
}
xml
:=
fmt
.
Sprintf
(
`<?xml version='1.0' encoding='UTF-8' standalone='yes' ?><msg serviceID="2" templateID="1" action="web" brief="[分享] %s" sourceMsgId="0" url="http://music.163.com/m/song/%s" flag="0" adverSign="0" multiMsgFlag="0"><item layout="2"><audio cover="%s?param=90y90" src="https://music.163.com/song/media/outer/url?id=%s.mp3" /><title>%s</title><summary>%s</summary></item><source name="网易云音乐" icon="https://pic.rmb.bdstatic.com/911423bee2bef937975b29b265d737b3.png" url="http://web.p.qq.com/qqmpmobile/aio/app.html?id=1
101079856
" action="app" a_actionData="com.netease.cloudmusic" i_actionData="tencent100495085://" appid="100495085" /></msg>`
,
xml
:=
fmt
.
Sprintf
(
`<?xml version='1.0' encoding='UTF-8' standalone='yes' ?><msg serviceID="2" templateID="1" action="web" brief="[分享] %s" sourceMsgId="0" url="http://music.163.com/m/song/%s" flag="0" adverSign="0" multiMsgFlag="0"><item layout="2"><audio cover="%s?param=90y90" src="https://music.163.com/song/media/outer/url?id=%s.mp3" /><title>%s</title><summary>%s</summary></item><source name="网易云音乐" icon="https://pic.rmb.bdstatic.com/911423bee2bef937975b29b265d737b3.png" url="http://web.p.qq.com/qqmpmobile/aio/app.html?id=1
00495085
" action="app" a_actionData="com.netease.cloudmusic" i_actionData="tencent100495085://" appid="100495085" /></msg>`
,
name
,
d
[
"id"
],
info
.
Get
(
"album.picUrl"
)
.
Str
,
d
[
"id"
],
name
,
artistName
)
name
,
d
[
"id"
],
info
.
Get
(
"album.picUrl"
)
.
Str
,
d
[
"id"
],
name
,
artistName
)
return
&
message
.
ServiceElement
{
return
&
message
.
ServiceElement
{
Id
:
60
,
Id
:
60
,
...
...
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