| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package Goo::Thing::task::Editor; |
|
2
|
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
############################################################################### |
|
4
|
|
|
|
|
|
|
# Turbo10.com |
|
5
|
|
|
|
|
|
|
# |
|
6
|
|
|
|
|
|
|
# Copyright Turbo10.com 2005 |
|
7
|
|
|
|
|
|
|
# All Rights Reserved |
|
8
|
|
|
|
|
|
|
# |
|
9
|
|
|
|
|
|
|
# Author: Nigel Hamilton |
|
10
|
|
|
|
|
|
|
# Filename: Goo::Thing::task::Editor |
|
11
|
|
|
|
|
|
|
# Description: Edit a task |
|
12
|
|
|
|
|
|
|
# |
|
13
|
|
|
|
|
|
|
# Date Change |
|
14
|
|
|
|
|
|
|
# ----------------------------------------------------------------------------- |
|
15
|
|
|
|
|
|
|
# 16/10/2005 Auto generated file |
|
16
|
|
|
|
|
|
|
# 16/10/2005 Need to create a task object |
|
17
|
|
|
|
|
|
|
# |
|
18
|
|
|
|
|
|
|
############################################################################### |
|
19
|
|
|
|
|
|
|
|
|
20
|
1
|
|
|
1
|
|
3659
|
use strict; |
|
|
1
|
|
|
|
|
3
|
|
|
|
1
|
|
|
|
|
29
|
|
|
21
|
|
|
|
|
|
|
|
|
22
|
1
|
|
|
1
|
|
376
|
use Object; |
|
|
0
|
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
use Prompter; |
|
24
|
|
|
|
|
|
|
use GooDatabase; |
|
25
|
|
|
|
|
|
|
use Goo::Prompter; |
|
26
|
|
|
|
|
|
|
use base qw(Object); |
|
27
|
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
############################################################################### |
|
30
|
|
|
|
|
|
|
# |
|
31
|
|
|
|
|
|
|
# run - edit a task |
|
32
|
|
|
|
|
|
|
# |
|
33
|
|
|
|
|
|
|
############################################################################### |
|
34
|
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
sub run { |
|
36
|
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
my ($this, $thing) = @_; |
|
38
|
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
Prompter::clear(); |
|
40
|
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
Goo::Prompter::showDetailedHeader("TaskEditor", $thing->get_filename()); |
|
42
|
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
Prompter::say(); |
|
44
|
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
# grab the task |
|
46
|
|
|
|
|
|
|
my $task = $thing->get_database_object("task", $thing->get_prefix()); |
|
47
|
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
$task->{title} = Prompter::ask("Edit the task?"), $task->{title}); |
|
49
|
|
|
|
|
|
|
$task->{description} = Prompter::ask("Edit the description?"), $task->{description}); |
|
50
|
|
|
|
|
|
|
$task->{requestedby} = Prompter::pick_one("requested by?", qw(nigel megan rena |
|
51
|
|
|
|
|
|
|
sven)); |
|
52
|
|
|
|
|
|
|
$task->{importance} = Prompter::ask("How important is this (1-10)?", $task->{importance}); |
|
53
|
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
# what is the pain associated with this task??? |
|
55
|
|
|
|
|
|
|
GooDatabase::execute($query); |
|
56
|
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
Prompter::say("New task created."); |
|
58
|
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
if (Prompter::confirm("Create another task?")) { |
|
60
|
|
|
|
|
|
|
$this->run($filename); |
|
61
|
|
|
|
|
|
|
} |
|
62
|
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
} |
|
64
|
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
1; |
|
67
|
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
__END__ |
|
70
|
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=head1 NAME |
|
72
|
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
Goo::Thing::task::Editor - Edit a task |
|
74
|
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=head1 SYNOPSIS |
|
76
|
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
use Goo::Thing::task::Editor; |
|
78
|
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=head1 DESCRIPTION |
|
80
|
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
=head1 METHODS |
|
84
|
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
=over |
|
86
|
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
=item run |
|
88
|
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
edit a task |
|
90
|
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
=back |
|
93
|
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
=head1 AUTHOR |
|
95
|
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
Nigel Hamilton <nigel@turbo10.com> |
|
97
|
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
=head1 SEE ALSO |
|
99
|
|
|
|
|
|
|
|