|
|
@@ -12,7 +12,8 @@ class FeishuNotifier implements Serializable {
|
|
|
}
|
|
|
|
|
|
void send(String status, String jobName, String buildNumber, String buildUrl,
|
|
|
- String duration, String branch, String commitMsg, String author) {
|
|
|
+ String duration, String branch, String commitMsg, String author,
|
|
|
+ String commitTime) { // 新增参数
|
|
|
def payload = [
|
|
|
msg_type: 'text',
|
|
|
content: [
|
|
|
@@ -24,13 +25,14 @@ class FeishuNotifier implements Serializable {
|
|
|
分支: ${branch}
|
|
|
提交: ${commitMsg}
|
|
|
作者: ${author}
|
|
|
+ 提交时间: ${commitTime} // 新增
|
|
|
查看详情: ${buildUrl}
|
|
|
""".stripIndent()
|
|
|
]
|
|
|
]
|
|
|
|
|
|
def jsonBody = JsonOutput.toJson(payload)
|
|
|
- println ">>> Feishu JSON: ${jsonBody}"
|
|
|
+ script.println ">>> Feishu JSON: ${jsonBody}"
|
|
|
|
|
|
script.httpRequest(
|
|
|
url : webhookUrl,
|