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
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
ff7fb09e
Commit
ff7fb09e
authored
Apr 05, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated issue form to use new GLForm
parent
5dd01f57
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
6 deletions
+12
-6
app/assets/javascripts/dispatcher.js.coffee
app/assets/javascripts/dispatcher.js.coffee
+1
-1
app/assets/javascripts/gl_form.js.coffee
app/assets/javascripts/gl_form.js.coffee
+9
-3
app/views/projects/issues/_form.html.haml
app/views/projects/issues/_form.html.haml
+1
-1
app/views/shared/issuable/_form.html.haml
app/views/shared/issuable/_form.html.haml
+1
-1
No files found.
app/assets/javascripts/dispatcher.js.coffee
View file @
ff7fb09e
...
@@ -35,7 +35,7 @@ class Dispatcher
...
@@ -35,7 +35,7 @@ class Dispatcher
new
Diff
()
new
Diff
()
when
'projects:issues:new'
,
'projects:issues:edit'
when
'projects:issues:new'
,
'projects:issues:edit'
shortcut_handler
=
new
ShortcutsNavigation
()
shortcut_handler
=
new
ShortcutsNavigation
()
new
DropzoneInput
(
$
(
'.issue-form'
))
new
GLForm
(
$
(
'.issue-form'
))
new
IssuableForm
(
$
(
'.issue-form'
))
new
IssuableForm
(
$
(
'.issue-form'
))
when
'projects:merge_requests:new'
,
'projects:merge_requests:edit'
when
'projects:merge_requests:new'
,
'projects:merge_requests:edit'
new
Diff
()
new
Diff
()
...
...
app/assets/javascripts/gl_form.js.coffee
View file @
ff7fb09e
class
@
GLForm
class
@
GLForm
constructor
:
(
@
form
)
->
constructor
:
(
@
form
)
->
@
textarea
=
@
form
.
find
(
'
.js-note-tex
t'
)
@
textarea
=
@
form
.
find
(
'
textarea.js-gfm-inpu
t'
)
# Before we start, we should clean up any previous data for this form
@
destroy
()
# Setup the form
@
setupForm
()
@
setupForm
()
@
form
.
data
'gl-form'
,
@
@
form
.
data
'gl-form'
,
@
...
@@ -9,6 +13,8 @@ class @GLForm
...
@@ -9,6 +13,8 @@ class @GLForm
destroy
:
->
destroy
:
->
# Destroy actions
# Destroy actions
actions
=
@
form
.
data
'form-actions'
actions
=
@
form
.
data
'form-actions'
if
actions
?
actions
.
clearEventListeners
()
actions
.
clearEventListeners
()
@
form
.
data
'form-actions'
,
null
@
form
.
data
'form-actions'
,
null
...
...
app/views/projects/issues/_form.html.haml
View file @
ff7fb09e
=
form_for
[
@project
.
namespace
.
becomes
(
Namespace
),
@project
,
@issue
],
html:
{
class:
'form-horizontal issue-form
gfm
-form js-quick-submit js-requires-input'
}
do
|
f
|
=
form_for
[
@project
.
namespace
.
becomes
(
Namespace
),
@project
,
@issue
],
html:
{
class:
'form-horizontal issue-form
common-note
-form js-quick-submit js-requires-input'
}
do
|
f
|
=
render
'shared/issuable/form'
,
f:
f
,
issuable:
@issue
=
render
'shared/issuable/form'
,
f:
f
,
issuable:
@issue
:javascript
:javascript
...
...
app/views/shared/issuable/_form.html.haml
View file @
ff7fb09e
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
=
render
layout:
'projects/md_preview'
,
locals:
{
preview_class:
"md-preview"
,
referenced_users:
true
}
do
=
render
layout:
'projects/md_preview'
,
locals:
{
preview_class:
"md-preview"
,
referenced_users:
true
}
do
=
render
'projects/zen'
,
f:
f
,
attr: :description
,
=
render
'projects/zen'
,
f:
f
,
attr: :description
,
classes:
'
description form-control
'
classes:
'
note-textarea
'
=
render
'projects/notes/hints'
=
render
'projects/notes/hints'
.clearfix
.clearfix
.error-alert
.error-alert
...
...
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