summaryrefslogtreecommitdiff
path: root/app/views/doorkeeper/applications
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/doorkeeper/applications')
-rw-r--r--app/views/doorkeeper/applications/_delete_form.html.haml6
-rw-r--r--app/views/doorkeeper/applications/_form.html.haml12
-rw-r--r--app/views/doorkeeper/applications/edit.html.haml4
-rw-r--r--app/views/doorkeeper/applications/index.html.haml33
-rw-r--r--app/views/doorkeeper/applications/new.html.haml4
-rw-r--r--app/views/doorkeeper/applications/show.html.haml12
6 files changed, 35 insertions, 36 deletions
diff --git a/app/views/doorkeeper/applications/_delete_form.html.haml b/app/views/doorkeeper/applications/_delete_form.html.haml
index 001a711b1dd..56af9a55130 100644
--- a/app/views/doorkeeper/applications/_delete_form.html.haml
+++ b/app/views/doorkeeper/applications/_delete_form.html.haml
@@ -2,9 +2,9 @@
= form_tag oauth_application_path(application) do
%input{:name => "_method", :type => "hidden", :value => "delete"}/
- if defined? small
- = button_tag type: "submit", class: "btn btn-transparent", data: { confirm: "Are you sure?" } do
+ = button_tag type: "submit", class: "btn btn-transparent", data: { confirm: "确定要继续么?" } do
%span.sr-only
- Destroy
+ 销毁
= icon('trash')
- else
- = submit_tag 'Destroy', data: { confirm: "Are you sure?" }, class: submit_btn_css
+ = submit_tag '销毁', data: { confirm: "确定要继续么?" }, class: submit_btn_css
diff --git a/app/views/doorkeeper/applications/_form.html.haml b/app/views/doorkeeper/applications/_form.html.haml
index 906b0676150..0e7962c6199 100644
--- a/app/views/doorkeeper/applications/_form.html.haml
+++ b/app/views/doorkeeper/applications/_form.html.haml
@@ -6,20 +6,20 @@
%li= msg
.form-group
- = f.label :name, class: 'label-light'
+ = f.label :name, "名称", class: 'label-light'
= f.text_field :name, class: 'form-control', required: true
.form-group
- = f.label :redirect_uri, class: 'label-light'
+ = f.label :redirect_uri, "重定向 URI", class: 'label-light'
= f.text_area :redirect_uri, class: 'form-control', required: true
%span.help-block
- Use one line per URI
+ 每个 URI 使用一行
- if Doorkeeper.configuration.native_redirect_uri
%span.help-block
- Use
+ 使用
%code= Doorkeeper.configuration.native_redirect_uri
- for local tests
+ 作为本地测试
.prepend-top-default
- = f.submit 'Save application', class: "btn btn-create"
+ = f.submit '保存应用程序', class: "btn btn-create"
diff --git a/app/views/doorkeeper/applications/edit.html.haml b/app/views/doorkeeper/applications/edit.html.haml
index fb6aa30acee..bdc54e1043c 100644
--- a/app/views/doorkeeper/applications/edit.html.haml
+++ b/app/views/doorkeeper/applications/edit.html.haml
@@ -1,3 +1,3 @@
-- page_title "Edit", @application.name, "Applications"
-%h3.page-title Edit application
+- page_title "编辑", @application.name, "应用"
+%h3.page-title 编辑应用
= render 'form', application: @application
diff --git a/app/views/doorkeeper/applications/index.html.haml b/app/views/doorkeeper/applications/index.html.haml
index ea0b66c932b..445e9c48333 100644
--- a/app/views/doorkeeper/applications/index.html.haml
+++ b/app/views/doorkeeper/applications/index.html.haml
@@ -1,4 +1,4 @@
-- page_title "Applications"
+- page_title "应用"
- header_title page_title, applications_profile_path
.row.prepend-top-default
@@ -7,14 +7,13 @@
= page_title
%p
- if user_oauth_applications?
- Manage applications that can use GitLab as an OAuth provider,
- and applications that you've authorized to use your account.
+ 管理应用程序可以使用OAuth GitLab作为提供者,授权使用你的帐户。
- else
- Manage applications that you've authorized to use your account.
+ 管理应用程序授权使用您的帐户。
.col-lg-9
- if user_oauth_applications?
%h5.prepend-top-0
- Add new application
+ 添加新应用程序
= render 'form', application: @application
%hr
- if user_oauth_applications?
@@ -26,9 +25,9 @@
%table.table
%thead
%tr
- %th Name
- %th Callback URL
- %th Clients
+ %th 名称
+ %th 回调链接
+ %th 客户端
%th.last-heading
%tbody
- @applications.each do |application|
@@ -41,25 +40,25 @@
%td
= link_to edit_oauth_application_path(application), class: "btn btn-transparent append-right-5" do
%span.sr-only
- Edit
+ 编辑
= icon('pencil')
= render 'delete_form', application: application, small: true
- else
.profile-settings-message.text-center
- You don't have any applications
+ 你没有任何应用程序
.oauth-authorized-applications.prepend-top-20.append-bottom-default
- if user_oauth_applications?
%h5
- Authorized applications (#{@authorized_tokens.size})
+ 授权应用程序 (#{@authorized_tokens.size})
- if @authorized_tokens.any?
.table-responsive
%table.table.table-striped
%thead
%tr
- %th Name
- %th Authorized At
- %th Scope
+ %th 名称
+ %th 授权时间
+ %th 权限
%th
%tbody
- @authorized_apps.each do |app|
@@ -72,12 +71,12 @@
- @authorized_anonymous_tokens.each do |token|
%tr
%td
- Anonymous
+ 匿名
%div.help-block
- %em Authorization was granted by entering your username and password in the application.
+ %em 授权通过输入您的用户名和密码被授予应用程序中。
%td= token.created_at
%td= token.scopes
%td= render 'delete_form', token: token
- else
.profile-settings-message.text-center
- You don't have any authorized applications
+ 你没有任何授权的应用程序
diff --git a/app/views/doorkeeper/applications/new.html.haml b/app/views/doorkeeper/applications/new.html.haml
index fd32a468b45..74dd035ec97 100644
--- a/app/views/doorkeeper/applications/new.html.haml
+++ b/app/views/doorkeeper/applications/new.html.haml
@@ -1,6 +1,6 @@
-- page_title "New Application"
+- page_title "新应用"
-%h3.page-title New Application
+%h3.page-title 新应用
%hr
diff --git a/app/views/doorkeeper/applications/show.html.haml b/app/views/doorkeeper/applications/show.html.haml
index 47442b78d48..d9a64ecfeb5 100644
--- a/app/views/doorkeeper/applications/show.html.haml
+++ b/app/views/doorkeeper/applications/show.html.haml
@@ -1,27 +1,27 @@
-- page_title @application.name, "Applications"
+- page_title @application.name, "应用"
%h3.page-title
- Application: #{@application.name}
+ 应用:#{@application.name}
.table-holder
%table.table
%tr
%td
- Application Id
+ 应用 Id
%td
%code#application_id= @application.uid
%tr
%td
- Secret:
+ 密匙:
%td
%code#secret= @application.secret
%tr
%td
- Callback url
+ 回调链接
%td
- @application.redirect_uri.split.each do |uri|
%div
%span.monospace= uri
.form-actions
- = link_to 'Edit', edit_oauth_application_path(@application), class: 'btn btn-primary wide pull-left'
+ = link_to '编辑', edit_oauth_application_path(@application), class: 'btn btn-primary wide pull-left'
= render 'delete_form', application: @application, submit_btn_css: 'btn btn-danger prepend-left-10'