Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
32dd42f0
Commit
32dd42f0
authored
Sep 16, 2021
by
Florie Guibert
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merge boards Apollo client
Changelog: changed
parent
14d84f97
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
29 additions
and
18 deletions
+29
-18
app/assets/javascripts/boards/boards_util.js
app/assets/javascripts/boards/boards_util.js
+2
-1
app/assets/javascripts/boards/graphql.js
app/assets/javascripts/boards/graphql.js
+6
-1
app/assets/javascripts/boards/graphql/issue.fragment.graphql
app/assets/javascripts/boards/graphql/issue.fragment.graphql
+2
-4
app/assets/javascripts/graphql_shared/fragments/milestone.fragment.graphql
...ripts/graphql_shared/fragments/milestone.fragment.graphql
+6
-0
app/assets/javascripts/main.js
app/assets/javascripts/main.js
+1
-1
ee/app/assets/javascripts/boards/graphql/issue.fragment.graphql
.../assets/javascripts/boards/graphql/issue.fragment.graphql
+2
-4
ee/spec/features/boards/swimlanes/epics_swimlanes_drag_drop_spec.rb
...atures/boards/swimlanes/epics_swimlanes_drag_drop_spec.rb
+8
-6
spec/frontend/boards/stores/actions_spec.js
spec/frontend/boards/stores/actions_spec.js
+2
-1
No files found.
app/assets/javascripts/boards/boards_util.js
View file @
32dd42f0
...
...
@@ -146,7 +146,8 @@ export function getMoveData(state, params) {
}
export
function
moveItemListHelper
(
item
,
fromList
,
toList
)
{
const
updatedItem
=
item
;
const
updatedItem
=
cloneDeep
(
item
);
if
(
toList
.
listType
===
ListType
.
label
&&
!
updatedItem
.
labels
.
find
((
label
)
=>
label
.
id
===
toList
.
label
.
id
)
...
...
app/assets/javascripts/boards/graphql.js
View file @
32dd42f0
import
{
IntrospectionFragmentMatcher
}
from
'
apollo-cache-inmemory
'
;
import
{
IntrospectionFragmentMatcher
,
defaultDataIdFromObject
}
from
'
apollo-cache-inmemory
'
;
import
createDefaultClient
from
'
~/lib/graphql
'
;
import
introspectionQueryResultData
from
'
~/sidebar/fragmentTypes.json
'
;
...
...
@@ -10,6 +10,11 @@ export const gqlClient = createDefaultClient(
{},
{
cacheConfig
:
{
dataIdFromObject
:
(
object
)
=>
{
// eslint-disable-next-line no-underscore-dangle
return
object
.
__typename
===
'
BoardList
'
?
object
.
iid
:
defaultDataIdFromObject
(
object
);
},
fragmentMatcher
,
},
assumeImmutableResults
:
true
,
...
...
app/assets/javascripts/boards/graphql/issue.fragment.graphql
View file @
32dd42f0
#import "~/graphql_shared/fragments/milestone.fragment.graphql"
#import "~/graphql_shared/fragments/user.fragment.graphql"
fragment
IssueNode
on
Issue
{
...
...
@@ -16,10 +17,7 @@ fragment IssueNode on Issue {
webUrl
relativePosition
milestone
{
expired
id
state
title
...
MilestoneFragment
}
assignees
{
nodes
{
...
...
app/assets/javascripts/graphql_shared/fragments/milestone.fragment.graphql
0 → 100644
View file @
32dd42f0
fragment
MilestoneFragment
on
Milestone
{
expired
id
state
title
}
app/assets/javascripts/main.js
View file @
32dd42f0
...
...
@@ -14,6 +14,7 @@ import { GlBreakpointInstance as bp } from '@gitlab/ui/dist/utils';
import
{
initRails
}
from
'
~/lib/utils/rails_ujs
'
;
import
*
as
popovers
from
'
~/popovers
'
;
import
*
as
tooltips
from
'
~/tooltips
'
;
import
{
initHeaderSearchApp
}
from
'
~/header_search
'
;
import
initAlertHandler
from
'
./alert_handler
'
;
import
{
removeFlashClickListener
}
from
'
./flash
'
;
import
initTodoToggle
from
'
./header
'
;
...
...
@@ -35,7 +36,6 @@ import GlFieldErrors from './gl_field_errors';
import
initUserPopovers
from
'
./user_popovers
'
;
import
initBroadcastNotifications
from
'
./broadcast_notification
'
;
import
{
initTopNav
}
from
'
./nav
'
;
import
{
initHeaderSearchApp
}
from
'
~/header_search
'
;
import
'
ee_else_ce/main_ee
'
;
import
'
jh_else_ce/main_jh
'
;
...
...
ee/app/assets/javascripts/boards/graphql/issue.fragment.graphql
View file @
32dd42f0
#import "~/graphql_shared/fragments/milestone.fragment.graphql"
#import "~/graphql_shared/fragments/user.fragment.graphql"
fragment
IssueNode
on
Issue
{
...
...
@@ -26,10 +27,7 @@ fragment IssueNode on Issue {
}
}
milestone
{
expired
id
state
title
...
MilestoneFragment
}
labels
{
nodes
{
...
...
ee/spec/features/boards/swimlanes/epics_swimlanes_drag_drop_spec.rb
View file @
32dd42f0
...
...
@@ -119,14 +119,16 @@ RSpec.describe 'epics swimlanes', :js do
end
it
'between lists and epics'
do
wait_for_board_cards
(
1
,
2
)
wait_for_board_cards_in_second_epic
(
1
,
1
)
inspect_requests
(
inject_headers:
{
'X-GITLAB-DISABLE-SQL-QUERY-LIMIT'
=>
'https://gitlab.com/gitlab-org/gitlab/-/issues/323426'
})
do
wait_for_board_cards
(
1
,
2
)
wait_for_board_cards_in_second_epic
(
1
,
1
)
drag
(
list_from_index:
4
,
list_to_index:
2
)
drag
(
list_from_index:
4
,
list_to_index:
2
)
wait_for_board_cards
(
2
,
0
)
wait_for_board_cards
(
3
,
2
)
wait_for_board_cards_in_first_epic
(
2
,
2
)
wait_for_board_cards
(
2
,
0
)
wait_for_board_cards
(
3
,
2
)
wait_for_board_cards_in_first_epic
(
2
,
2
)
end
end
end
...
...
spec/frontend/boards/stores/actions_spec.js
View file @
32dd42f0
...
...
@@ -21,9 +21,10 @@ import {
getMoveData
,
updateListPosition
,
}
from
'
~/boards/boards_util
'
;
import
{
gqlClient
}
from
'
~/boards/graphql
'
;
import
destroyBoardListMutation
from
'
~/boards/graphql/board_list_destroy.mutation.graphql
'
;
import
issueCreateMutation
from
'
~/boards/graphql/issue_create.mutation.graphql
'
;
import
actions
,
{
gqlClient
}
from
'
~/boards/stores/actions
'
;
import
actions
from
'
~/boards/stores/actions
'
;
import
*
as
types
from
'
~/boards/stores/mutation_types
'
;
import
mutations
from
'
~/boards/stores/mutations
'
;
...
...
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