Epic in Admin > Project > Reports

stable
David Barragán Merino 2016-08-24 15:21:57 +02:00
parent ad01386a79
commit a9fca5e43b
5 changed files with 31 additions and 4 deletions

View File

@ -425,6 +425,10 @@ class CsvExporterController extends taiga.Controller
@._generateUuid()
class CsvExporterEpicsController extends CsvExporterController
type: "epics"
class CsvExporterUserstoriesController extends CsvExporterController
type: "userstories"
@ -437,6 +441,7 @@ class CsvExporterIssuesController extends CsvExporterController
type: "issues"
module.controller("CsvExporterEpicsController", CsvExporterEpicsController)
module.controller("CsvExporterUserstoriesController", CsvExporterUserstoriesController)
module.controller("CsvExporterTasksController", CsvExporterTasksController)
module.controller("CsvExporterIssuesController", CsvExporterIssuesController)
@ -446,6 +451,21 @@ module.controller("CsvExporterIssuesController", CsvExporterIssuesController)
## CSV Directive
#############################################################################
CsvEpicDirective = ($translate) ->
link = ($scope) ->
$scope.sectionTitle = "ADMIN.CSV.SECTION_TITLE_EPIC"
return {
controller: "CsvExporterEpicsController",
controllerAs: "ctrl",
templateUrl: "admin/project-csv.html",
link: link,
scope: true
}
module.directive("tgCsvEpic", ["$translate", CsvEpicDirective])
CsvUsDirective = ($translate) ->
link = ($scope) ->
$scope.sectionTitle = "ADMIN.CSV.SECTION_TITLE_US"

View File

@ -161,6 +161,7 @@ urls = {
"webhooklogs-resend": "/webhooklogs/%s/resend"
# Reports - CSV
"epics-csv": "/epics/csv?uuid=%s"
"userstories-csv": "/userstories/csv?uuid=%s"
"tasks-csv": "/tasks/csv?uuid=%s"
"issues-csv": "/issues/csv?uuid=%s"

View File

@ -61,18 +61,22 @@ resourceProvider = ($config, $repo, $http, $urls, $auth, $q, $translate) ->
url = $urls.resolve("bulk-update-projects-order")
return $http.post(url, bulkData)
service.regenerate_epics_csv_uuid = (projectId) ->
url = "#{$urls.resolve("projects")}/#{projectId}/regenerate_epics_csv_uuid"
return $http.post(url)
service.regenerate_userstories_csv_uuid = (projectId) ->
url = "#{$urls.resolve("projects")}/#{projectId}/regenerate_userstories_csv_uuid"
return $http.post(url)
service.regenerate_issues_csv_uuid = (projectId) ->
url = "#{$urls.resolve("projects")}/#{projectId}/regenerate_issues_csv_uuid"
return $http.post(url)
service.regenerate_tasks_csv_uuid = (projectId) ->
url = "#{$urls.resolve("projects")}/#{projectId}/regenerate_tasks_csv_uuid"
return $http.post(url)
service.regenerate_issues_csv_uuid = (projectId) ->
url = "#{$urls.resolve("projects")}/#{projectId}/regenerate_issues_csv_uuid"
return $http.post(url)
service.leave = (projectId) ->
url = "#{$urls.resolve("projects")}/#{projectId}/leave"
return $http.post(url)

View File

@ -559,6 +559,7 @@
"REGENERATE_SUBTITLE": "You going to change the CSV data access url. The previous url will be disabled. Are you sure?"
},
"CSV": {
"SECTION_TITLE_EPIC": "epics reports",
"SECTION_TITLE_US": "user stories reports",
"SECTION_TITLE_TASK": "tasks reports",
"SECTION_TITLE_ISSUE": "issues reports",

View File

@ -18,6 +18,7 @@ div.wrapper(
p(translate="ADMIN.REPORTS.DESCRIPTION")
div.admin-attributes-section(tg-csv-epic)
div.admin-attributes-section(tg-csv-us)
div.admin-attributes-section(tg-csv-task)
div.admin-attributes-section(tg-csv-issue)