Commit Graph
19 Commits
Author SHA1 Message Date
Dmitriy Zaporozhets 8ad9a75f88 Merge pull request #8030 from cirosantilli/factor-authorize
Factor authorize_push! and authorize_code_access!
2014-10-21 11:43:12 +03:00
Ciro Santilli 4d0d5e79ba Factor authorize_push! and authorize_code_access!
with existing method_missing. Pattern already used extensively,
so let's be consistent and use it everywhere.
2014-10-13 21:31:49 +02:00
Ciro Santilli 2d23522107 Use :message key, not :error for File::Service. 2014-10-13 20:55:09 +02:00
Ciro Santilli ad47993ac4 Factor error and success methods from services. 2014-09-21 11:43:05 +02:00
Dmitriy Zaporozhets 218219abbd Refactoring inside refactoring. We need to go deeper
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-09-08 21:54:52 +03:00
Dmitriy Zaporozhets 531f16beb0 Use new diff parsing logic
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-09-08 16:27:12 +03:00
Jo Hund df3c466e37 Don't remove trailing newline when editing a file in web UI editor:
* populate ACE editor content via API instead of HTML element inner text (to preserve trailing whitespace).
* remove hack in EditTreeController#preview that replaces any removed \n.

Fixes #5936
2014-06-27 10:50:36 -07:00
skv-headless d859d08094 Editing preview 2014-04-15 19:02:02 +04:00
Dmitriy Zaporozhets a9280de11f Better redirect for edit blod from MergeRequest
If you cancel edit you will be redirected back to merge request
If you submit changes you will be redirected back to merge request

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-02-26 14:06:31 +02:00
Dmitriy Zaporozhets e39f0de8ee Add edit button to MergeRequest diff
It will redirect you to file edit page.
After submit changes you will be redirected back to merge request.

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-02-20 16:39:13 +02:00
Dmitriy Zaporozhets 237ddd6024 Improve authorization for new/edit blob pages
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-01-24 21:29:52 +02:00
Dmitriy Zaporozhets 1d2bdb4d58 Move all Context classes into Services
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-01-16 19:03:42 +02:00
Takuya Nishigori e78b90ab1d Fix messages typo 2013-12-16 17:57:50 +09:00
Dmitriy Zaporozhets 160bd862be Refactoring for EditTree and NewTree controllers and contexts
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2013-11-05 12:21:11 +02:00
Johannes Schleifenbaum cc505f550d Check if a file is editied "on" a branch or a commit.
The previous behavior was a "disabled" link, which was still clickable
and linked to the edit file action.

If the 	user accesses a path like "/edit/master/README" show the file
edit form (just like before).

If the user accesses a path like
"/edit/8d5c1f375ce99e5df84e26b0eafbf1448c6a001e/README", redirect the
user to the file detail page with a note, that he cannot edit a file
"on" a commit.

fixes #5482
2013-10-30 11:34:26 +01:00
Dmitriy Zaporozhets 970d86b7c5 Refactor blob finding 2013-10-01 20:34:41 +03:00
Dmitriy Zaporozhets 836c870cc9 Fix edit file 2013-10-01 17:08:40 +03:00
Dmitriy Zaporozhets bb5e50e0f7 Fix edit files 2013-08-05 16:55:15 +03:00
Dmitriy Zaporozhets 2ed7cbfba4 Move projects controllers/views in Projects module 2013-06-23 19:47:22 +03:00