Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
Admin
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
osuny
Admin
Commits
df91a402
Commit
df91a402
authored
2 years ago
by
alexisben
Browse files
Options
Downloads
Patches
Plain Diff
Fix vue loading
parent
a9f9465a
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
app/assets/stylesheets/commons/_block.sass
+1
-1
1 addition, 1 deletion
app/assets/stylesheets/commons/_block.sass
app/views/server/universities/_sso_mapping.html.erb
+43
-42
43 additions, 42 deletions
app/views/server/universities/_sso_mapping.html.erb
with
44 additions
and
43 deletions
app/assets/stylesheets/commons/_block.sass
+
1
−
1
View file @
df91a402
[
v-cloak
]
form
form
,
.app-form
display
:
none
[
data-v-app
]
.spinner-border
...
...
This diff is collapsed.
Click to expand it.
app/views/server/universities/_sso_mapping.html.erb
+
43
−
42
View file @
df91a402
...
...
@@ -5,53 +5,54 @@
<div
class=
"spinner-border text-primary"
role=
"status"
>
<span
class=
"sr-only"
>
<%=
t
'loading'
%>
</span>
</div>
<draggable
:list=
"fields"
>
<div
v-for=
"(field, index) in fields"
>
<div
class=
"card"
>
<div
class=
"card-header d-flex justify-content-between pb-0"
>
1. {{ field.sso_key }} -> {{ field.internal_key}}
<a
v-on:click=
"fields.splice(fields.indexOf(field), 1)"
title=
"Remove field"
>
<i
class=
"far fa-trash-alt"
></i>
</a>
</div>
<div
class=
"card-body"
>
<div
class=
"form-group"
>
<label
for=
""
class=
"form-control-label"
>
<%=
t
(
'university.sso_key'
)
%>
<abbr
title=
"required"
>
*
</abbr></label>
<input
v-model=
"field.sso_key"
type=
"text"
class=
"form-control"
>
<div
class=
"app-form"
>
<draggable
:list=
"fields"
>
<div
v-for=
"(field, index) in fields"
>
<div
class=
"card"
>
<div
class=
"card-header d-flex justify-content-between pb-0"
>
1. {{ field.sso_key }} -> {{ field.internal_key}}
<a
v-on:click=
"fields.splice(fields.indexOf(field), 1)"
title=
"Remove field"
>
<i
class=
"far fa-trash-alt"
></i>
</a>
</div>
<div
class=
"form-group"
>
<label
for=
""
class=
"form-control-label"
>
<%=
t
(
'university.internal_key'
)
%>
<abbr
title=
"required"
>
*
</abbr></label>
<select
v-model=
"field.internal_key"
id=
""
class=
"form-select"
required
>
<option
value=
"email"
>
Email
</option>
<option
value=
"first_name"
>
First Name
</option>
<option
value=
"last_name"
>
Last Name
</option>
<option
value=
"role"
>
Role
</option>
<option
value=
"phone"
>
Phone
</option>
<option
value=
"language"
>
Language
</option>
<option
value=
"picture_url"
>
Picture URL
</option>
</select>
</div>
<div
v-if=
"field.internal_key === 'role'"
>
<%
User
.
roles
.
keys
.
each
do
|
role
|
%>
<div
class=
"form-group"
>
<label
for=
""
class=
"form-label"
>
<%=
role
%>
</label>
<input
v-model=
"field.roles.
<%=
role
%>
"
type=
"text"
class=
"form-control"
>
</div>
<%
end
%>
<div
class=
"card-body"
>
<div
class=
"form-group"
>
<label
for=
""
class=
"form-control-label"
>
<%=
t
(
'university.sso_key'
)
%>
<abbr
title=
"required"
>
*
</abbr></label>
<input
v-model=
"field.sso_key"
type=
"text"
class=
"form-control"
>
</div>
<div
class=
"form-group"
>
<label
for=
""
class=
"form-control-label"
>
<%=
t
(
'university.internal_key'
)
%>
<abbr
title=
"required"
>
*
</abbr></label>
<select
v-model=
"field.internal_key"
id=
""
class=
"form-select"
required
>
<option
value=
"email"
>
Email
</option>
<option
value=
"first_name"
>
First Name
</option>
<option
value=
"last_name"
>
Last Name
</option>
<option
value=
"role"
>
Role
</option>
<option
value=
"phone"
>
Phone
</option>
<option
value=
"language"
>
Language
</option>
<option
value=
"picture_url"
>
Picture URL
</option>
</select>
</div>
<div
v-if=
"field.internal_key === 'role'"
>
<%
User
.
roles
.
keys
.
each
do
|
role
|
%>
<div
class=
"form-group"
>
<label
for=
""
class=
"form-label"
>
<%=
role
%>
</label>
<input
v-model=
"field.roles.
<%=
role
%>
"
type=
"text"
class=
"form-control"
>
</div>
<%
end
%>
</div>
</div>
</div>
</div>
</div>
</draggable>
</draggable>
<a
v-on:click=
"fields.push({sso_key: 'email', internal_key: 'key', roles: {}})"
class=
"btn btn-primary btn-sm"
>
<%=
t
'add_field'
%>
</a>
<a
v-on:click=
"fields.push({sso_key: 'email', internal_key: 'key', roles: {}})"
class=
"btn btn-primary btn-sm"
>
<%=
t
'add_field'
%>
</a>
</div>
<textarea
name=
"university[sso_mapping]"
id=
"university_sso_mapping"
rows=
"20"
cols=
"200"
class=
"d-none"
>
{{ JSON.stringify(fields) }}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment