Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
a0f13d2f
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
a0f13d2f
编写于
6月 16, 2017
作者:
A
Alfredo Sumaran
提交者:
Dmitriy Zaporozhets
6月 16, 2017
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Expose correct path to group
上级
459d8d65
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
13 addition
and
4 deletion
+13
-4
app/assets/javascripts/groups/components/group_item.vue
app/assets/javascripts/groups/components/group_item.vue
+3
-3
app/assets/javascripts/groups/stores/groups_store.js
app/assets/javascripts/groups/stores/groups_store.js
+1
-0
app/serializers/group_entity.rb
app/serializers/group_entity.rb
+5
-1
spec/javascripts/groups/mock_data.js
spec/javascripts/groups/mock_data.js
+4
-0
未找到文件。
app/assets/javascripts/groups/components/group_item.vue
浏览文件 @
a0f13d2f
...
...
@@ -27,7 +27,7 @@ export default {
if
(
this
.
group
.
hasSubgroups
)
{
eventHub
.
$emit
(
'
toggleSubGroups
'
,
this
.
group
);
}
else
{
window
.
location
.
href
=
this
.
group
.
webUrl
;
window
.
location
.
href
=
this
.
group
.
groupPath
;
}
}
},
...
...
@@ -192,7 +192,7 @@ export default {
<div
class=
"avatar-container s40 hidden-xs"
>
<a
:href=
"group.
webUrl
"
>
:href=
"group.
groupPath
"
>
<img
class=
"avatar s40"
:src=
"group.avatarUrl"
...
...
@@ -202,7 +202,7 @@ export default {
<div
class=
"title"
>
<a
:href=
"group.
webUrl
"
>
{{
fullPath
}}
</a>
:href=
"group.
groupPath
"
>
{{
fullPath
}}
</a>
<template
v-if=
"group.permissions.humanGroupAccess"
>
as
<span
class=
"access-type"
>
{{
group
.
permissions
.
humanGroupAccess
}}
</span>
...
...
app/assets/javascripts/groups/stores/groups_store.js
浏览文件 @
a0f13d2f
...
...
@@ -122,6 +122,7 @@ export default class GroupsStore {
canEdit
:
rawGroup
.
can_edit
,
description
:
rawGroup
.
description
,
webUrl
:
rawGroup
.
web_url
,
groupPath
:
rawGroup
.
group_path
,
parentId
:
rawGroup
.
parent_id
,
visibility
:
rawGroup
.
visibility
,
leavePath
:
rawGroup
.
leave_path
,
...
...
app/serializers/group_entity.rb
浏览文件 @
a0f13d2f
...
...
@@ -5,11 +5,15 @@ class GroupEntity < Grape::Entity
include
GroupsHelper
expose
:id
,
:name
,
:path
,
:description
,
:visibility
expose
:web_url
expose
:full_name
,
:full_path
expose
:web_url
expose
:parent_id
expose
:created_at
,
:updated_at
expose
:group_path
do
|
group
|
group_path
(
group
)
end
expose
:permissions
do
expose
:human_group_access
do
|
group
,
options
|
group
.
group_members
.
find_by
(
user_id:
request
.
current_user
)
&
.
human_access
...
...
spec/javascripts/groups/mock_data.js
浏览文件 @
a0f13d2f
...
...
@@ -6,6 +6,7 @@ const group1 = {
visibility
:
'
public
'
,
avatar_url
:
null
,
web_url
:
'
http://localhost:3000/groups/level1
'
,
group_path
:
'
/level1
'
,
full_name
:
'
level1
'
,
full_path
:
'
level1
'
,
parent_id
:
null
,
...
...
@@ -28,6 +29,7 @@ const group14 = {
visibility
:
'
public
'
,
avatar_url
:
null
,
web_url
:
'
http://localhost:3000/groups/level1/level2/level3/level4
'
,
group_path
:
'
/level1/level2/level3/level4
'
,
full_name
:
'
level1 / level2 / level3 / level4
'
,
full_path
:
'
level1/level2/level3/level4
'
,
parent_id
:
1127
,
...
...
@@ -49,6 +51,7 @@ const group2 = {
visibility
:
'
public
'
,
avatar_url
:
null
,
web_url
:
'
http://localhost:3000/groups/devops
'
,
group_path
:
'
/devops
'
,
full_name
:
'
devops
'
,
full_path
:
'
devops
'
,
parent_id
:
null
,
...
...
@@ -70,6 +73,7 @@ const group21 = {
visibility
:
'
public
'
,
avatar_url
:
null
,
web_url
:
'
http://localhost:3000/groups/devops/chef
'
,
group_path
:
'
/devops/chef
'
,
full_name
:
'
devops / chef
'
,
full_path
:
'
devops/chef
'
,
parent_id
:
1119
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录