Fixing watchers refresh
parent
360aa0c5ac
commit
4a8a59a771
|
@ -17,14 +17,18 @@
|
|||
# File: components/wysiwyg/comment-wysiwyg.directive.coffee
|
||||
###
|
||||
|
||||
CommentWysiwyg = (attachmentsFullService) ->
|
||||
CommentWysiwyg = ($modelTransform, $rootscope, $confirm, attachmentsFullService) ->
|
||||
link = ($scope, $el, $attrs) ->
|
||||
$scope.editableDescription = false
|
||||
|
||||
$scope.saveComment = (description, cb) ->
|
||||
$scope.content = ''
|
||||
$scope.vm.type.comment = description
|
||||
$scope.vm.onAddComment({callback: cb})
|
||||
|
||||
transform = $modelTransform.save (item) -> return
|
||||
transform.then ->
|
||||
$rootscope.$broadcast("object:updated")
|
||||
transform.finally(cb)
|
||||
|
||||
types = {
|
||||
epics: "epic",
|
||||
|
@ -70,4 +74,8 @@ CommentWysiwyg = (attachmentsFullService) ->
|
|||
}
|
||||
|
||||
angular.module("taigaComponents")
|
||||
.directive("tgCommentWysiwyg", ["tgAttachmentsFullService", CommentWysiwyg])
|
||||
.directive("tgCommentWysiwyg", [
|
||||
"$tgQueueModelTransformation",
|
||||
"$rootScope",
|
||||
"tgAttachmentsFullService",
|
||||
CommentWysiwyg])
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
ItemWysiwyg = ($modelTransform, $rootscope, $confirm, attachmentsFullService, $translate) ->
|
||||
link = ($scope, $el, $attrs) ->
|
||||
$scope.editableDescription = false
|
||||
|
||||
$scope.saveDescription = (description, cb) ->
|
||||
transform = $modelTransform.save (item) ->
|
||||
item.description = description
|
||||
|
|
|
@ -94,7 +94,7 @@ class HistorySectionController
|
|||
@.editing = null
|
||||
|
||||
addComment: (cb) ->
|
||||
@repo.save(@.type).then =>
|
||||
return @repo.save(@.type).then =>
|
||||
@._loadHistory()
|
||||
cb()
|
||||
|
||||
|
|
|
@ -33,13 +33,13 @@ class ImportTaigaController
|
|||
|
||||
file = files[0]
|
||||
|
||||
loader = @confirm.loader(@translate.instant('PROJECT.IMPORT.IN_PROGRESS.TITLE'), @translate.instant('PROJECT.IMPORT.IN_PROGRESS.DESCRIPTION'), true)
|
||||
loader = @confirm.loader(@translate.instant('PROJECT.IMPORT.IN_PROGRESS.TITLE'),
|
||||
@translate.instant('PROJECT.IMPORT.IN_PROGRESS.DESCRIPTION'), true)
|
||||
|
||||
loader.start()
|
||||
|
||||
promise = @rs.projects.import(file, loader.update)
|
||||
|
||||
@importProjectService.importPromise(promise).finally () => loader.stop()
|
||||
@importProjectService.importPromise(promise).finally () -> loader.stop()
|
||||
|
||||
return
|
||||
|
||||
|
|
|
@ -112,6 +112,7 @@ div.wrapper(
|
|||
div.ticket-watchers(
|
||||
tg-watchers
|
||||
ng-model="us"
|
||||
item="us"
|
||||
required-perm="modify_us"
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue