/*
 * This file is a project template. It illustrates the basic features
 * of TaskJuggler and can be used as a base for your first projects.
 * You can put your own templates in 
 * 
 * ${KDEHOME}/share/apps/taskjuggler/Templates/${LANG}/
 *
 * Permission to read, modify and distribute this file without any
 * restrictions is granted.
 *
 * Please see the TaskJuggler manual for a more detailed
 * description of the various syntax elements. You can find more
 * information about TaskJuggler at http://www.taskjuggler.org!
 */
project yourID "Your Project" "1.0" @@projectstart@@ - @@projectend@@ {
  # Hide the clock time. Only show the date.
  timeformat "%Y-%m-%d"
  # The currency for all money values is EUR.
  currency "EUR"

  # We want to compare the baseline scenario, to one with a slightly
  # delayed start.
  scenario plan "Plan" {
    scenario delayed "Delayed"
  }
}

# Put your macros here.
# Macro with paramater:
# macro foo [
#   task foo { }
# ]
# Macro with one paramater
# macro bar [
#   task ${1} { }

# Put your flag declarations here. You can flag task, resources and
# accounts to use them as filter criteria when generating reports.
# flags important, dontcare
flags team

# In order to do a simple profit and loss analysis of the project we
# specify accounts. One for the development costs, one for the
# documentation costs and one account to credit the customer payments
# to.
account costs "Costs" cost
account rev "Payments" revenue

# Global vacations go here
# vacation "Labor Day" 2005-09-05
# 2 days Christmas break (27th not included!)
# vacation "Christmas" 2005-12-25 - 2005-12-27

# The daily default rate of all resources. This can be overriden for each
# resource. We specify this, so that we can do a good calculation of
# the costs of the project.
rate 300.0

# Put your resource definitions here:
# resource dev "Developers" {
#   resource dev1 "Paul Smith" { rate 330.0 }
#   resource dev2 "Sébastien Bono"
#   resource dev3 "Klaus Müller" { vacation 2005-02-01 - 2005-02-05 }
# }
# This resource does not do any work.
# resource confRoom "Conference Room" {
#   efficiency 0.0
# }

# Now we specify the work packages. The whole project is described as
# a task that contains sub tasks. These sub tasks are then broken down
# into smaller tasks and so on. The innermost tasks describe the real
# work and have resources allocated to them. Many attributes of tasks
# are inherited from the enclosing task. This saves you a lot of
# writing.
task myProject "My Project" {
  start @@projectstart@@
  
  # All work related costs will be booked to this account unless the
  # sub tasks specifies it differently.
  account costs

  task a "Task A"
  task b "Task B"
  task c "Task C"
}

# Bookings should be put here
# supplement resource r1 {
#   This is the work that has been done up until now by r1.
#   booking 2003-06-06 2003-06-07 t1 { sloppy 2 }
#   booking 2003-06-08 2003-06-09 t1 { sloppy 2 }
#   booking 2003-06-11 2003-06-12 t1 { sloppy 2 }
# }

# A traditional Gantt Chart for the TaskJugglerUI
taskreport "Gantt Chart" {
  headline "Project Gantt Chart"
  columns hierarchindex, name, start, end, effort, duration, chart
  # For this report we like to have the abbreviated weekday in front
  # of the date. %a is the tag for this.
  timeformat "%a %Y-%m-%d"
  loadunit days
  hideresource 1
}

# A list of tasks showing the resources assigned to each task.
taskreport "Task Usage" {
  headline "Task Usage Report"
  columns hierarchindex, name, start, end, effort { title "Work" }, duration,
          cost, revenue
  timeformat "%Y-%m-%d"
  loadunit days
  hideresource 0
}

# A list of all tasks with the percentage complete for each task
taskreport "Tracking Gantt" {
  headline "Tracking Gantt Chart"
  columns hierarchindex, name, start, end, effort { title "Work" }, duration,
          completed, chart
  timeformat "%a %Y-%m-%d"
  loadunit days
  hideresource 1
}

# A graph showing resource allocation. It identifies whether each
# resource is under- or over-allocated for.
resourcereport "Resource Graph" {
  headline "Resource Allocation Graph"
  columns no, name, rate, utilization, freeload, chart
  loadunit days
  hidetask 1
}

# A list of all project resources, both human and material resources,
# together with the costs for each.
resourcereport "Resource Sheet" {
  headline "Resource Sheet"
  columns no, name, efficiency, id, maxeffort, rate
  loadunit days
  hidetask 1
}

# A list of resources and each task associated with each resource.
resourcereport "Resource Usage" {
  headline "Resource Usage Report"
  columns no, name, utilization, freeload, cost
  loadunit days
  hidetask 0
}

# This report looks like a regular calendar that shows the tasks by
# their dates.
htmlweeklycalendar "Calendar.html" {
}

# This report is a status report for the current week. It also
# provides an outlook for the next week.
htmlstatusreport "Status-Report.html" {
}

# A P&L report for the project.
htmlaccountreport "Accounting.html" { 
  # Besides the number of the account and the name we have a column
  # with the total values (at the end of the project) and the values
  # for each month of the project.
  columns no, name, scenario, total, monthly 
  headline "P&L for the Project" 
  caption "The table shows the profit and loss
           analysis as well as the cashflow situation of the Accounting
           Software Project."
  # Since this is a cashflow calculation we show accumulated values
  # per account.
  accumulate
  scenarios plan, delayed 
}

