From da4fd3a762db5857452be906c2cf35009db0cbc8 Mon Sep 17 00:00:00 2001 From: yystopf Date: Fri, 17 Dec 2021 15:35:30 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=98=93=E4=BF=AE=20to=20=E7=96=91?= =?UTF-8?q?=E4=BF=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 4 +- app/docs/slate/source/includes/_projects.md | 4 +- .../slate/source/includes/_repositories.md | 30 +++++----- app/docs/slate/source/includes/_users.md | 26 ++++---- app/models/message_template.rb | 16 ++--- app/models/message_template/issue_assigned.rb | 2 +- .../message_template/issue_assigner_expire.rb | 2 +- app/models/message_template/issue_atme.rb | 2 +- app/models/message_template/issue_changed.rb | 42 ++++++------- .../message_template/issue_creator_expire.rb | 2 +- app/models/message_template/issue_deleted.rb | 2 +- app/models/message_template/issue_journal.rb | 2 +- app/models/message_template/project_issue.rb | 2 +- .../project_setting_changed.rb | 6 +- .../create_or_assign.rb | 2 +- .../manage_project.rb | 2 +- app/models/template_message_setting/normal.rb | 2 +- config/locales/zh-CN.yml | 2 +- dir.md | 2 +- public/docs/api.html | 60 +++++++++---------- public/message_template/issue_assigned.html | 4 +- public/message_template/issue_changed.html | 4 +- public/message_template/issue_deleted.html | 4 +- public/message_template/project_issue.html | 4 +- 24 files changed, 114 insertions(+), 114 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ecb743b91..d0a865bba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,7 +23,7 @@ * Fix 版本库中附件下载400(#51625) * Fix loading页面优化(#51588) * Fix 提交详情页面优化(#51577) - * Fix 修复易修复制功能(#51569) + * Fix 修复疑修复制功能(#51569) * Fix 修复新建发行版用户信息显示错误的问题(#51665) * Fix 修复查看文件详细信息报错的问题(#51561) * Fix 修复提交记录中时间显示格式问题(#51526) @@ -62,7 +62,7 @@ ## [v3.0.3](https://forgeplus.trustie.net/projects/jasder/forgeplus/releases) - 2021-05-08 * BUGFIXES - * Fix 解决易修标题过长导致的排版问题(45469) + * Fix 解决疑修标题过长导致的排版问题(45469) * Fix 解决合并请求详情页面排版错误的问题(45457) * FIX 解决转移仓库界面专有名词描述错误的问题(45455) * Fix 解决markdown格式文件自动生成数字排序的问题(45454) diff --git a/app/docs/slate/source/includes/_projects.md b/app/docs/slate/source/includes/_projects.md index 2b6dd76d0..d4899a710 100644 --- a/app/docs/slate/source/includes/_projects.md +++ b/app/docs/slate/source/includes/_projects.md @@ -280,7 +280,7 @@ repo |是| |string |项目标识identifier ### 返回字段说明 参数 | 类型 | 字段说明 --------- | ----------- | ----------- -menu_name |string|导航名称, home:主页,code:代码库,issues:易修,pulls:合并请求,devops:工作流,versions:里程碑,activity:动态,setting:仓库设置 +menu_name |string|导航名称, home:主页,code:代码库,issues:疑修,pulls:合并请求,devops:工作流,versions:里程碑,activity:动态,setting:仓库设置 > 返回的JSON示例: @@ -408,7 +408,7 @@ await octokit.request('POST /api/yystopf/ceshi/project_units') ### 请求参数 参数 | 必选 | 默认 | 类型 | 字段说明 --------- | ------- | ------- | -------- | ---------- -|unit_types |是| |array | 项目模块内容, 支持以下参数:code:代码库,issues:易修,pulls:合并请求,devops:工作流,versions:里程碑 | +|unit_types |是| |array | 项目模块内容, 支持以下参数:code:代码库,issues:疑修,pulls:合并请求,devops:工作流,versions:里程碑 | ### 返回字段说明: diff --git a/app/docs/slate/source/includes/_repositories.md b/app/docs/slate/source/includes/_repositories.md index 3604689c8..a44d2b35d 100644 --- a/app/docs/slate/source/includes/_repositories.md +++ b/app/docs/slate/source/includes/_repositories.md @@ -1240,11 +1240,11 @@ await octokit.request('GET /api/yystopf/ceshi/webhooks/3/edit.json') |delete|分支或标签删除| |fork|仓库被fork| |push|git仓库推送| -|issue|易修已打开、已关闭、已重新打开或编辑| -|issue_assign|易修被指派| -|issue_label|易修标签被更新或删除| -|issue_milestone|易修被收入里程碑| -|issue_comment|易修评论| +|issue|疑修已打开、已关闭、已重新打开或编辑| +|issue_assign|疑修被指派| +|issue_label|疑修标签被更新或删除| +|issue_milestone|疑修被收入里程碑| +|issue_comment|疑修评论| |pull_request|合并请求| |pull_request_assign|合并请求被指派| |pull_request_label|合并请求被贴上标签| @@ -1337,11 +1337,11 @@ await octokit.request('POST /api/yystopf/ceshi/webhooks.json') |delete|分支或标签删除| |fork|仓库被fork| |push|git仓库推送| -|issue|易修已打开、已关闭、已重新打开或编辑| -|issue_assign|易修被指派| -|issue_label|易修标签被更新或删除| -|issue_milestone|易修被收入里程碑| -|issue_comment|易修评论| +|issue|疑修已打开、已关闭、已重新打开或编辑| +|issue_assign|疑修被指派| +|issue_label|疑修标签被更新或删除| +|issue_milestone|疑修被收入里程碑| +|issue_comment|疑修评论| |pull_request|合并请求| |pull_request_assign|合并请求被指派| |pull_request_label|合并请求被贴上标签| @@ -1440,11 +1440,11 @@ await octokit.request('PATCH /api/yystopf/ceshi/webhooks/7.json') |delete|分支或标签删除| |fork|仓库被fork| |push|git仓库推送| -|issue|易修已打开、已关闭、已重新打开或编辑| -|issue_assign|易修被指派| -|issue_label|易修标签被更新或删除| -|issue_milestone|易修被收入里程碑| -|issue_comment|易修评论| +|issue|疑修已打开、已关闭、已重新打开或编辑| +|issue_assign|疑修被指派| +|issue_label|疑修标签被更新或删除| +|issue_milestone|疑修被收入里程碑| +|issue_comment|疑修评论| |pull_request|合并请求| |pull_request_assign|合并请求被指派| |pull_request_label|合并请求被贴上标签| diff --git a/app/docs/slate/source/includes/_users.md b/app/docs/slate/source/includes/_users.md index 218a1a4b7..f416d488d 100644 --- a/app/docs/slate/source/includes/_users.md +++ b/app/docs/slate/source/includes/_users.md @@ -90,13 +90,13 @@ await octokit.request('GET /api/users/:login/messages.json') #### 消息来源source字段说明 类型|说明 --------- | ----------- -|IssueAssigned | 有新指派给我的易修 | -|IssueAssignerExpire | 我负责的易修截止日期到达最后一天 | -|IssueAtme | 在易修中@我 | -|IssueChanged | 我创建或负责的易修状态变更 | -|IssueCreatorExpire | 我创建的易修截止日期到达最后一天 | -|IssueDeleted | 我创建或负责的易修删除 | -|IssueJournal | 我创建或负责的易修有新的评论 | +|IssueAssigned | 有新指派给我的疑修 | +|IssueAssignerExpire | 我负责的疑修截止日期到达最后一天 | +|IssueAtme | 在疑修中@我 | +|IssueChanged | 我创建或负责的疑修状态变更 | +|IssueCreatorExpire | 我创建的疑修截止日期到达最后一天 | +|IssueDeleted | 我创建或负责的疑修删除 | +|IssueJournal | 我创建或负责的疑修有新的评论 | |LoginIpTip | 登录异常提示 | |OrganizationJoined | 账号被拉入组织 | |OrganizationLeft | 账号被移出组织 | @@ -104,7 +104,7 @@ await octokit.request('GET /api/users/:login/messages.json') |ProjectDeleted | 我关注的仓库被删除 | |ProjectFollowed | 我管理的仓库被关注 | |ProjectForked | 我管理的仓库被复刻 | -|ProjectIssue | 我管理/关注的仓库有新的易修 | +|ProjectIssue | 我管理/关注的仓库有新的疑修 | |ProjectJoined | 账号被拉入项目 | |ProjectLeft | 账号被移出项目 | |ProjectMemberJoined | 我管理的仓库有成员加入 | @@ -250,7 +250,7 @@ await octokit.request('POST /api/users/:login/messages.json') --------- | ----------- | ----------- |type | string | 消息类型 | |receivers_login | array | 需要发送消息的用户名数组| -|atmeable_type | string | atme消息对象,是从哪里@我的,比如评论:Journal、易修:Issue、合并请求:PullRequest | +|atmeable_type | string | atme消息对象,是从哪里@我的,比如评论:Journal、疑修:Issue、合并请求:PullRequest | |atmeable_id | integer | atme消息对象id | > 请求的JSON示例: @@ -469,7 +469,7 @@ await octokit.request('GET /api/template_message_settings.json') "total_settings_count": 4, "settings": [ { - "name": "易修被指派", + "name": "疑修被指派", "key": "IssueAssigned", "notification_disabled": true, "email_disabled": false @@ -488,7 +488,7 @@ await octokit.request('GET /api/template_message_settings.json') "total_settings_count": 4, "settings": [ { - "name": "有新的易修", + "name": "有新的疑修", "key": "Issue", "notification_disabled": true, "email_disabled": false @@ -875,7 +875,7 @@ await octokit.request('GET /api/users/:login/statistics/activity.json') 参数 | 类型 | 字段说明 --------- | ----------- | ----------- |dates |array |时间 | -|issues_count |array |易修数量| +|issues_count |array |疑修数量| |pull_requests_count |array |合并请求数量| |commtis_count |array |贡献数量| @@ -1084,7 +1084,7 @@ await octokit.request('GET /api/users/:login/project_trends.json') 参数 | 类型 | 字段说明 --------- | ----------- | ----------- |total_count |int |所选时间内的总动态数 | -|project_trends.trend_type |string|动态类型,Issue:易修,VersionRelease:版本发布,PullRequest:合并请求| +|project_trends.trend_type |string|动态类型,Issue:疑修,VersionRelease:版本发布,PullRequest:合并请求| |project_trends.action_type |string|操作类型| |project_trends.trend_id |integer|动态id| |project_trends.user_name |string|用户名称| diff --git a/app/models/message_template.rb b/app/models/message_template.rb index a6e894c70..f1d0baa85 100644 --- a/app/models/message_template.rb +++ b/app/models/message_template.rb @@ -17,15 +17,15 @@ class MessageTemplate < ApplicationRecord def self.build_init_data self.create(type: 'MessageTemplate::FollowedTip', sys_notice: '{nickname} 关注了你', notification_url: '{baseurl}/{login}') email_html = File.read("#{email_template_html_dir}/issue_assigned.html") - self.create(type: 'MessageTemplate::IssueAssigned', sys_notice: '{nickname1}在 {nickname2}/{repository} 指派给你一个易修:{title}', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}', email: email_html, email_title: 'GitLink: {nickname1} 在 {nickname2}/{repository} 指派给你一个易修') - self.create(type: 'MessageTemplate::IssueAssignerExpire', sys_notice: '您负责的易修 {title} 已临近截止日期,请尽快处理', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') - self.create(type: 'MessageTemplate::IssueAtme', sys_notice: '{nickname} 在易修 {title} 中@我', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') + self.create(type: 'MessageTemplate::IssueAssigned', sys_notice: '{nickname1}在 {nickname2}/{repository} 指派给你一个疑修:{title}', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}', email: email_html, email_title: 'GitLink: {nickname1} 在 {nickname2}/{repository} 指派给你一个疑修') + self.create(type: 'MessageTemplate::IssueAssignerExpire', sys_notice: '您负责的疑修 {title} 已临近截止日期,请尽快处理', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') + self.create(type: 'MessageTemplate::IssueAtme', sys_notice: '{nickname} 在疑修 {title} 中@我', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') email_html = File.read("#{email_template_html_dir}/issue_changed.html") - self.create(type: 'MessageTemplate::IssueChanged', sys_notice: '在项目 {nickname2}/{repository} 的易修 {title} 中:{ifassigner}{nickname1}将负责人从 {assigner1} 修改为 {assigner2} {endassigner}{ifstatus}{nickname1}将状态从 {status1} 修改为 {status2} {endstatus}{iftracker}{nickname1}将类型从 {tracker1} 修改为 {tracker2} {endtracker}{ifpriority}{nickname1}将优先级从 {priority1} 修改为 {priority2} {endpriority}{ifmilestone}{nickname1}将里程碑从 {milestone1} 修改为 {milestone2} {endmilestone}{iftag}{nickname1}将标记从 {tag1} 修改为 {tag2} {endtag}{ifdoneratio}{nickname1}将完成度从 {doneratio1} 修改为 {doneratio2} {enddoneratio}{ifbranch}{nickname1}将指定分支从 {branch1} 修改为 {branch2} {endbranch}{ifstartdate}{nickname1}将开始日期从 {startdate1} 修改为 {startdate2} {endstartdate}{ifduedate}{nickname1}将结束日期从 {duedate1} 修改为 {duedate2} {endduedate}', email: email_html, email_title: 'GitLink: 易修 {title} 有状态变更', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') - self.create(type: 'MessageTemplate::IssueCreatorExpire', sys_notice: '您发布的易修 {title} 已临近截止日期,请尽快处理', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') + self.create(type: 'MessageTemplate::IssueChanged', sys_notice: '在项目 {nickname2}/{repository} 的疑修 {title} 中:{ifassigner}{nickname1}将负责人从 {assigner1} 修改为 {assigner2} {endassigner}{ifstatus}{nickname1}将状态从 {status1} 修改为 {status2} {endstatus}{iftracker}{nickname1}将类型从 {tracker1} 修改为 {tracker2} {endtracker}{ifpriority}{nickname1}将优先级从 {priority1} 修改为 {priority2} {endpriority}{ifmilestone}{nickname1}将里程碑从 {milestone1} 修改为 {milestone2} {endmilestone}{iftag}{nickname1}将标记从 {tag1} 修改为 {tag2} {endtag}{ifdoneratio}{nickname1}将完成度从 {doneratio1} 修改为 {doneratio2} {enddoneratio}{ifbranch}{nickname1}将指定分支从 {branch1} 修改为 {branch2} {endbranch}{ifstartdate}{nickname1}将开始日期从 {startdate1} 修改为 {startdate2} {endstartdate}{ifduedate}{nickname1}将结束日期从 {duedate1} 修改为 {duedate2} {endduedate}', email: email_html, email_title: 'GitLink: 疑修 {title} 有状态变更', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') + self.create(type: 'MessageTemplate::IssueCreatorExpire', sys_notice: '您发布的疑修 {title} 已临近截止日期,请尽快处理', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') email_html = File.read("#{email_template_html_dir}/issue_deleted.html") - self.create(type: 'MessageTemplate::IssueDeleted', sys_notice: '{nickname}已将易修 {title} 删除', email: email_html, email_title: 'GitLink: 易修 {title} 有状态变更', notification_url: '') - self.create(type: 'MessageTemplate::IssueJournal', sys_notice: '{nickname}评论易修{title}:{notes}', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') + self.create(type: 'MessageTemplate::IssueDeleted', sys_notice: '{nickname}已将疑修 {title} 删除', email: email_html, email_title: 'GitLink: 疑修 {title} 有状态变更', notification_url: '') + self.create(type: 'MessageTemplate::IssueJournal', sys_notice: '{nickname}评论疑修{title}:{notes}', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}') self.create(type: 'MessageTemplate::LoginIpTip', sys_notice: '您的账号{nickname}于{login_time)在非常用的IP地址{ip}登录,如非本人操作,请立即修改密码', notification_url: '') email_html = File.read("#{email_template_html_dir}/organization_joined.html") self.create(type: 'MessageTemplate::OrganizationJoined', sys_notice: '你已加入 {organization} 组织', notification_url: '{baseurl}/{login}', email: email_html, email_title: 'GitLink: 你已加入 {organization} 组织') @@ -37,7 +37,7 @@ class MessageTemplate < ApplicationRecord self.create(type: 'MessageTemplate::ProjectFollowed', sys_notice: '{nickname} 关注了你管理的仓库', notification_url: '{baseurl}/{login}') self.create(type: 'MessageTemplate::ProjectForked', sys_notice: '{nickname1} 复刻了你管理的仓库{nickname1}/{repository1}到{nickname2}/{repository2}', notification_url: '{baseurl}/{owner}/{identifier}') email_html = File.read("#{email_template_html_dir}/project_issue.html") - self.create(type: 'MessageTemplate::ProjectIssue', sys_notice: '{nickname1}在 {nickname2}/{repository} 新建易修:{title}', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}', email: email_html, email_title: 'GitLink: {nickname1} 在 {nickname2}/{repository} 新建了一个易修') + self.create(type: 'MessageTemplate::ProjectIssue', sys_notice: '{nickname1}在 {nickname2}/{repository} 新建疑修:{title}', notification_url: '{baseurl}/{owner}/{identifier}/issues/{id}', email: email_html, email_title: 'GitLink: {nickname1} 在 {nickname2}/{repository} 新建了一个疑修') email_html = File.read("#{email_template_html_dir}/project_joined.html") self.create(type: 'MessageTemplate::ProjectJoined', sys_notice: '你已加入 {repository} 项目', notification_url: '{baseurl}/{owner}/{identifier}', email: email_html, email_title: 'GitLink: 你已加入 {repository} 项目') email_html = File.read("#{email_template_html_dir}/project_left.html") diff --git a/app/models/message_template/issue_assigned.rb b/app/models/message_template/issue_assigned.rb index 10ad5eb2d..7ce7f10c2 100644 --- a/app/models/message_template/issue_assigned.rb +++ b/app/models/message_template/issue_assigned.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# 有新指派给我的易修 +# 有新指派给我的疑修 class MessageTemplate::IssueAssigned < MessageTemplate # MessageTemplate::IssueAssigned.get_message_content(User.where(login: 'yystopf'), User.last, Issue.last) diff --git a/app/models/message_template/issue_assigner_expire.rb b/app/models/message_template/issue_assigner_expire.rb index 405d44bb4..610c51175 100644 --- a/app/models/message_template/issue_assigner_expire.rb +++ b/app/models/message_template/issue_assigner_expire.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# 我负责的易修截止日期到达最后一天 +# 我负责的疑修截止日期到达最后一天 class MessageTemplate::IssueAssignerExpire < MessageTemplate # MessageTemplate::IssueAssignerExpire.get_message_content(User.where(login: 'yystopf'), Issue.last) diff --git a/app/models/message_template/issue_atme.rb b/app/models/message_template/issue_atme.rb index d9dfd1957..04eb132e4 100644 --- a/app/models/message_template/issue_atme.rb +++ b/app/models/message_template/issue_atme.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# 在易修中@我 +# 在疑修中@我 class MessageTemplate::IssueAtme < MessageTemplate # MessageTemplate::IssueAtme.get_message_content(User.where(login: 'yystopf'), User.last, Issue.last) diff --git a/app/models/message_template/issue_changed.rb b/app/models/message_template/issue_changed.rb index 10007cfb0..4d9e132cb 100644 --- a/app/models/message_template/issue_changed.rb +++ b/app/models/message_template/issue_changed.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# 我创建或负责的易修状态变更 +# 我创建或负责的疑修状态变更 class MessageTemplate::IssueChanged < MessageTemplate # MessageTemplate::IssueChanged.get_message_content(User.where(login: 'yystopf'), User.last, Issue.last, {status_id: [1, 2], assigned_to_id: [nil, 203], tracker_id: [4, 3], priority_id: [2, 4], fixed_version_id: [nil, 5], due_date: ['', '2021-09-11'], done_ratio: [0, 40], issue_tags_value: ["", "7"], branch_name: ["", "master"]}) @@ -29,7 +29,7 @@ class MessageTemplate::IssueChanged < MessageTemplate content = MessageTemplate::IssueChanged.sys_notice.gsub('{nickname1}', operator&.real_name).gsub('{nickname2}', owner&.real_name).gsub('{repository}', project&.name).gsub('{title}', issue&.subject) url = notification_url.gsub('{owner}', owner&.login).gsub('{identifier}', project&.identifier).gsub('{id}', issue&.id.to_s) change_count = change_params.keys.size - # 易修负责人修改 + # 疑修负责人修改 if change_params[:assigned_to_id].present? assigner1 = User.find_by_id(change_params[:assigned_to_id][0]) assigner2 = User.find_by_id(change_params[:assigned_to_id][1]) @@ -44,7 +44,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifassigner})(.*)({endassigner})/, '') end - # 易修状态修改 + # 疑修状态修改 if change_params[:status_id].present? status1 = IssueStatus.find_by_id(change_params[:status_id][0]) status2 = IssueStatus.find_by_id(change_params[:status_id][1]) @@ -59,7 +59,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifstatus})(.*)({endstatus})/, '') end - # 易修类型修改 + # 疑修类型修改 if change_params[:tracker_id].present? tracker1 = Tracker.find_by_id(change_params[:tracker_id][0]) tracker2 = Tracker.find_by_id(change_params[:tracker_id][1]) @@ -74,7 +74,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({iftracker})(.*)({endtracker})/, '') end - # 易修里程碑修改 + # 疑修里程碑修改 if change_params[:fixed_version_id].present? fix_version1 = Version.find_by_id(change_params[:fixed_version_id][0]) fix_version2 = Version.find_by_id(change_params[:fixed_version_id][1]) @@ -89,7 +89,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifmilestone})(.*)({endmilestone})/, '') end - # 易修标记修改 + # 疑修标记修改 if change_params[:issue_tags_value].present? issue_tags1 = IssueTag.where(id: change_params[:issue_tags_value][0]).distinct issue_tags2 = IssueTag.where(id: change_params[:issue_tags_value][1]).distinct @@ -106,7 +106,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({iftag})(.*)({endtag})()/, '') end - # 易修优先级修改 + # 疑修优先级修改 if change_params[:priority_id].present? priority1 = IssuePriority.find_by_id(change_params[:priority_id][0]) priority2 = IssuePriority.find_by_id(change_params[:priority_id][1]) @@ -121,7 +121,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifpriority})(.*)({endpriority})/, '') end - # 易修完成度修改 + # 疑修完成度修改 if change_params[:done_ratio].present? doneratio1 = change_params[:done_ratio][0] doneratio2 = change_params[:done_ratio][1] @@ -136,7 +136,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifdoneratio})(.*)({enddoneratio})/, '') end - # 易修指定分支修改 + # 疑修指定分支修改 if change_params[:branch_name].present? branch1 = change_params[:branch_name][0].blank? ? '分支未指定' : change_params[:branch_name][0] branch2 = change_params[:branch_name][1].blank? ? '分支未指定' : change_params[:branch_name][1] @@ -151,7 +151,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifbranch})(.*)({endbranch})/, '') end - # 易修开始日期修改 + # 疑修开始日期修改 if change_params[:start_date].present? startdate1 = change_params[:start_date][0].blank? ? "未选择开始日期" : change_params[:start_date][0] startdate2 = change_params[:start_date][1].blank? ? "未选择开始日期" : change_params[:start_date][1] @@ -166,7 +166,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifstartdate})(.*)({endstartdate})/, '') end - # 易修结束日期修改 + # 疑修结束日期修改 if change_params[:due_date].present? duedate1 = change_params[:due_date][0].blank? ? '未选择结束日期' : change_params[:due_date][0] duedate2 = change_params[:due_date][1].blank? ? '未选择结束日期' : change_params[:due_date][1] @@ -207,7 +207,7 @@ class MessageTemplate::IssueChanged < MessageTemplate content.gsub!('{title}', issue&.subject) content.gsub!('{id}', issue&.id.to_s) change_count = change_params.keys.size - # 易修负责人修改 + # 疑修负责人修改 if change_params[:assigned_to_id].present? assigner1 = User.find_by_id(change_params[:assigned_to_id][0]) assigner2 = User.find_by_id(change_params[:assigned_to_id][1]) @@ -222,7 +222,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifassigner})(.*)({endassigner})/, '') end - # 易修状态修改 + # 疑修状态修改 if change_params[:status_id].present? status1 = IssueStatus.find_by_id(change_params[:status_id][0]) status2 = IssueStatus.find_by_id(change_params[:status_id][1]) @@ -237,7 +237,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifstatus})(.*)({endstatus})/, '') end - # 易修类型修改 + # 疑修类型修改 if change_params[:tracker_id].present? tracker1 = Tracker.find_by_id(change_params[:tracker_id][0]) tracker2 = Tracker.find_by_id(change_params[:tracker_id][1]) @@ -252,7 +252,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({iftracker})(.*)({endtracker})/, '') end - # 易修里程碑修改 + # 疑修里程碑修改 if change_params[:fixed_version_id].present? fix_version1 = Version.find_by_id(change_params[:fixed_version_id][0]) fix_version2 = Version.find_by_id(change_params[:fixed_version_id][1]) @@ -267,7 +267,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifmilestone})(.*)({endmilestone})/, '') end - # 易修标记修改 + # 疑修标记修改 if change_params[:issue_tags_value].present? issue_tags1 = IssueTag.where(id: change_params[:issue_tags_value][0]).distinct issue_tags2 = IssueTag.where(id: change_params[:issue_tags_value][1]).distinct @@ -284,7 +284,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({iftag})(.*)({endtag})()/, '') end - # 易修优先级修改 + # 疑修优先级修改 if change_params[:priority_id].present? priority1 = IssuePriority.find_by_id(change_params[:priority_id][0]) priority2 = IssuePriority.find_by_id(change_params[:priority_id][1]) @@ -299,7 +299,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifpriority})(.*)({endpriority})/, '') end - # 易修完成度修改 + # 疑修完成度修改 if change_params[:done_ratio].present? doneratio1 = change_params[:done_ratio][0] doneratio2 = change_params[:done_ratio][1] @@ -314,7 +314,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifdoneratio})(.*)({enddoneratio})/, '') end - # 易修指定分支修改 + # 疑修指定分支修改 if change_params[:branch_name].present? branch1 = change_params[:branch_name][0].blank? ? '分支未指定' : change_params[:branch_name][0] branch2 = change_params[:branch_name][1].blank? ? '分支未指定' : change_params[:branch_name][1] @@ -329,7 +329,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifbranch})(.*)({endbranch})/, '') end - # 易修开始日期修改 + # 疑修开始日期修改 if change_params[:start_date].present? startdate1 = change_params[:start_date][0].blank? ? "未选择开始日期" : change_params[:start_date][0] startdate2 = change_params[:start_date][1].blank? ? "未选择开始日期" : change_params[:start_date][1] @@ -344,7 +344,7 @@ class MessageTemplate::IssueChanged < MessageTemplate else content.gsub!(/({ifstartdate})(.*)({endstartdate})/, '') end - # 易修结束日期修改 + # 疑修结束日期修改 if change_params[:due_date].present? duedate1 = change_params[:due_date][0].blank? ? '未选择结束日期' : change_params[:due_date][0] duedate2 = change_params[:due_date][1].blank? ? '未选择结束日期' : change_params[:due_date][1] diff --git a/app/models/message_template/issue_creator_expire.rb b/app/models/message_template/issue_creator_expire.rb index 38ef2fe29..475c05ce0 100644 --- a/app/models/message_template/issue_creator_expire.rb +++ b/app/models/message_template/issue_creator_expire.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# 我创建的易修截止日期到达最后一天 +# 我创建的疑修截止日期到达最后一天 class MessageTemplate::IssueCreatorExpire < MessageTemplate # MessageTemplate::IssueCreatorExpire.get_message_content(User.where(login: 'yystopf'), Issue.last) diff --git a/app/models/message_template/issue_deleted.rb b/app/models/message_template/issue_deleted.rb index d51782cf1..a3eae75de 100644 --- a/app/models/message_template/issue_deleted.rb +++ b/app/models/message_template/issue_deleted.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# 我创建或负责的易修删除 +# 我创建或负责的疑修删除 class MessageTemplate::IssueDeleted < MessageTemplate # MessageTemplate::IssueDeleted.get_message_content(User.where(login: 'yystopf'), User.last, "hahah") diff --git a/app/models/message_template/issue_journal.rb b/app/models/message_template/issue_journal.rb index 0b3851475..3286776ae 100644 --- a/app/models/message_template/issue_journal.rb +++ b/app/models/message_template/issue_journal.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# TODO 我创建或负责的易修有新的评论 +# TODO 我创建或负责的疑修有新的评论 class MessageTemplate::IssueJournal < MessageTemplate # MessageTemplate::IssueJournal.get_message_content(User.where(login: 'yystopf')) diff --git a/app/models/message_template/project_issue.rb b/app/models/message_template/project_issue.rb index 8d7d99aa7..5904a4285 100644 --- a/app/models/message_template/project_issue.rb +++ b/app/models/message_template/project_issue.rb @@ -12,7 +12,7 @@ # email_title :string(255) # -# TODO 我管理/关注的仓库有新的易修 +# TODO 我管理/关注的仓库有新的疑修 class MessageTemplate::ProjectIssue < MessageTemplate # MessageTemplate::ProjectIssue.get_message_content(User.where(login: 'yystopf'), User.where(login: 'forgetest1'), User.last, Issue.last) diff --git a/app/models/message_template/project_setting_changed.rb b/app/models/message_template/project_setting_changed.rb index 3ce17433d..49cf7821a 100644 --- a/app/models/message_template/project_setting_changed.rb +++ b/app/models/message_template/project_setting_changed.rb @@ -15,7 +15,7 @@ # 我管理的仓库项目设置被更改 class MessageTemplate::ProjectSettingChanged < MessageTemplate - # MessageTemplate::ProjectSettingChanged.get_message_content(User.where(login: 'yystopf'), User.last, Project.last, {description: '测试修改项目简介', category: '大数据', language: 'Ruby', permission: '公有', navbar: '易修, 合并请求'}) + # MessageTemplate::ProjectSettingChanged.get_message_content(User.where(login: 'yystopf'), User.last, Project.last, {description: '测试修改项目简介', category: '大数据', language: 'Ruby', permission: '公有', navbar: '疑修, 合并请求'}) def self.get_message_content(receivers, operator, project, change_params) receivers.each do |receiver| if receiver.user_template_message_setting.present? @@ -135,7 +135,7 @@ class MessageTemplate::ProjectSettingChanged < MessageTemplate unit_types.unshift('主页') unit_types.append('动态') navbar = unit_types.join(',') - navbar.gsub!('issues', '易修') + navbar.gsub!('issues', '疑修') navbar.gsub!('pulls', '合并请求') navbar.gsub!('wiki', 'Wiki') navbar.gsub!('devops', '工作流') @@ -284,7 +284,7 @@ class MessageTemplate::ProjectSettingChanged < MessageTemplate unit_types.unshift('主页') unit_types.append('动态') navbar = unit_types.join(',') - navbar.gsub!('issues', '易修') + navbar.gsub!('issues', '疑修') navbar.gsub!('pulls', '合并请求') navbar.gsub!('wiki', 'Wiki') navbar.gsub!('devops', '工作流') diff --git a/app/models/template_message_setting/create_or_assign.rb b/app/models/template_message_setting/create_or_assign.rb index 2c9fa2076..50ef86433 100644 --- a/app/models/template_message_setting/create_or_assign.rb +++ b/app/models/template_message_setting/create_or_assign.rb @@ -25,7 +25,7 @@ class TemplateMessageSetting::CreateOrAssign < TemplateMessageSetting end def self.build_init_data - self.find_or_create_by(name: "易修状态变更", key: "IssueChanged") + self.find_or_create_by(name: "疑修状态变更", key: "IssueChanged") self.find_or_create_by(name: "合并请求状态变更", key: "PullRequestChanged") end end diff --git a/app/models/template_message_setting/manage_project.rb b/app/models/template_message_setting/manage_project.rb index 2aa9e4883..7a80c9999 100644 --- a/app/models/template_message_setting/manage_project.rb +++ b/app/models/template_message_setting/manage_project.rb @@ -25,7 +25,7 @@ class TemplateMessageSetting::ManageProject < TemplateMessageSetting end def self.build_init_data - self.find_or_create_by(name: "有新的易修", key: "Issue") + self.find_or_create_by(name: "有新的疑修", key: "Issue") self.find_or_create_by(name: "有新的合并请求", key: "PullRequest") self.find_or_create_by(name: "有成员变动", key: "Member") self.find_or_create_by(name: "仓库设置被更改", key: "SettingChanged") diff --git a/app/models/template_message_setting/normal.rb b/app/models/template_message_setting/normal.rb index 9090196d5..771fba2f2 100644 --- a/app/models/template_message_setting/normal.rb +++ b/app/models/template_message_setting/normal.rb @@ -27,7 +27,7 @@ class TemplateMessageSetting::Normal < TemplateMessageSetting self.find_or_create_by(name: "账号有权限变更", key: "Permission") self.find_or_create_by(name: "被拉入或移出组织", key: "Organization") self.find_or_create_by(name: "被拉入或移出项目", key: "Project") - self.find_or_create_by(name: "有新的易修指派给我", key: "IssueAssigned") + self.find_or_create_by(name: "有新的疑修指派给我", key: "IssueAssigned") self.find_or_create_by(name: "有新的合并请求指派给我", key: "PullRequestAssigned") end end diff --git a/config/locales/zh-CN.yml b/config/locales/zh-CN.yml index bed2d1e6a..62ea16966 100644 --- a/config/locales/zh-CN.yml +++ b/config/locales/zh-CN.yml @@ -15,7 +15,7 @@ zh-CN: 'refused': '已拒绝' 'agreed': '已同意' trend: - Issue: 易修(Issue) + Issue: 疑修(Issue) PullRequest: 合并请求(PR) VersionRelease: 版本发布 create: 创建了 diff --git a/dir.md b/dir.md index a4443ded3..1d3c35e3e 100644 --- a/dir.md +++ b/dir.md @@ -87,7 +87,7 @@ forgeplus │   │   │   │   └── tags(标签) │   │   │   ├── user(用户) │   │   │   └── versions(发行版) -│   │   ├── issues(易修) +│   │   ├── issues(疑修) │   │   ├── libraries │   │   ├── oauth │   │   ├── organizations(组织) diff --git a/public/docs/api.html b/public/docs/api.html index 3ed7a82dd..1df920eef 100644 --- a/public/docs/api.html +++ b/public/docs/api.html @@ -1138,31 +1138,31 @@ Success — a happy kitten is an authenticated kitten! IssueAssigned -有新指派给我的易修 +有新指派给我的疑修 IssueAssignerExpire -我负责的易修截止日期到达最后一天 +我负责的疑修截止日期到达最后一天 IssueAtme -在易修中@我 +在疑修中@我 IssueChanged -我创建或负责的易修状态变更 +我创建或负责的疑修状态变更 IssueCreatorExpire -我创建的易修截止日期到达最后一天 +我创建的疑修截止日期到达最后一天 IssueDeleted -我创建或负责的易修删除 +我创建或负责的疑修删除 IssueJournal -我创建或负责的易修有新的评论 +我创建或负责的疑修有新的评论 LoginIpTip @@ -1194,7 +1194,7 @@ Success — a happy kitten is an authenticated kitten! ProjectIssue -我管理/关注的仓库有新的易修 +我管理/关注的仓库有新的疑修 ProjectJoined @@ -1403,7 +1403,7 @@ Success — a happy kitten is an authenticated kitten! atmeable_type string -atme消息对象,是从哪里@我的,比如评论:Journal、易修:Issue、合并请求:PullRequest +atme消息对象,是从哪里@我的,比如评论:Journal、疑修:Issue、合并请求:PullRequest atmeable_id @@ -1706,7 +1706,7 @@ Success — a happy kitten is an authenticated kitten! "total_settings_count": 4, "settings": [ { - "name": "易修被指派", + "name": "疑修被指派", "key": "IssueAssigned", "notification_disabled": true, "email_disabled": false @@ -1725,7 +1725,7 @@ Success — a happy kitten is an authenticated kitten! "total_settings_count": 4, "settings": [ { - "name": "有新的易修", + "name": "有新的疑修", "key": "Issue", "notification_disabled": true, "email_disabled": false @@ -2245,7 +2245,7 @@ Success — a happy kitten is an authenticated kitten! issues_count array -易修数量 +疑修数量 pull_requests_count @@ -2493,7 +2493,7 @@ Success — a happy kitten is an authenticated kitten! project_trends.trend_type string -动态类型,Issue:易修,VersionRelease:版本发布,PullRequest:合并请求 +动态类型,Issue:疑修,VersionRelease:版本发布,PullRequest:合并请求 project_trends.action_type @@ -4968,7 +4968,7 @@ http://localhost:3000/api/yystopf/ceshi/menu_list | jq menu_name string -导航名称, home:主页,code:代码库,issues:易修,pulls:合并请求,devops:工作流,versions:里程碑,activity:动态,setting:仓库设置 +导航名称, home:主页,code:代码库,issues:疑修,pulls:合并请求,devops:工作流,versions:里程碑,activity:动态,setting:仓库设置 @@ -5131,7 +5131,7 @@ http://localhost:3000/api/yystopf/ceshi/project_units.json 是 array -项目模块内容, 支持以下参数:code:代码库,issues:易修,pulls:合并请求,devops:工作流,versions:里程碑 +项目模块内容, 支持以下参数:code:代码库,issues:疑修,pulls:合并请求,devops:工作流,versions:里程碑

返回字段说明:

@@ -8346,23 +8346,23 @@ http://localhost:3000/api/yystopf/ceshi/webhooks/3/edit.json issue -易修已打开、已关闭、已重新打开或编辑 +疑修已打开、已关闭、已重新打开或编辑 issue_assign -易修被指派 +疑修被指派 issue_label -易修标签被更新或删除 +疑修标签被更新或删除 issue_milestone -易修被收入里程碑 +疑修被收入里程碑 issue_comment -易修评论 +疑修评论 pull_request @@ -8568,23 +8568,23 @@ http://localhost:3000/api/yystopf/ceshi/webhooks.json issue -易修已打开、已关闭、已重新打开或编辑 +疑修已打开、已关闭、已重新打开或编辑 issue_assign -易修被指派 +疑修被指派 issue_label -易修标签被更新或删除 +疑修标签被更新或删除 issue_milestone -易修被收入里程碑 +疑修被收入里程碑 issue_comment -易修评论 +疑修评论 pull_request @@ -8833,23 +8833,23 @@ http://localhost:3000/api/yystopf/ceshi/webhooks/7.json issue -易修已打开、已关闭、已重新打开或编辑 +疑修已打开、已关闭、已重新打开或编辑 issue_assign -易修被指派 +疑修被指派 issue_label -易修标签被更新或删除 +疑修标签被更新或删除 issue_milestone -易修被收入里程碑 +疑修被收入里程碑 issue_comment -易修评论 +疑修评论 pull_request diff --git a/public/message_template/issue_assigned.html b/public/message_template/issue_assigned.html index 86952dd14..c45e8729f 100755 --- a/public/message_template/issue_assigned.html +++ b/public/message_template/issue_assigned.html @@ -1,6 +1,6 @@ - 有新的易修指派给我 + 有新的疑修指派给我