Thread: [Codestriker-commits] CVS update: codestriker/bin CodestrikerClient.pm
Brought to you by:
sits
|
From: <si...@us...> - 2008-06-20 04:29:38
|
User: sits
Date: 08/06/19 21:29:36
Modified: bin CodestrikerClient.pm
Log:
Also a part of Rob's work.
Index: CodestrikerClient.pm
===================================================================
RCS file: /cvsroot/codestriker/codestriker/bin/CodestrikerClient.pm,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- CodestrikerClient.pm 5 Oct 2005 23:23:07 -0000 1.4
+++ CodestrikerClient.pm 20 Jun 2008 04:29:36 -0000 1.5
@@ -73,4 +73,28 @@
return $rc ? $1 : undef;
}
+# Retrieve the details of a topic in XML format
+# Filtered based on a bugid
+sub get_topics_xml {
+ my ($self, $bugid, $author, $reviewer, $cc, $text) = @_;
+
+ # Perform the HTTP Post.
+ my $ua = new LWP::UserAgent;
+ my $content = [ action => 'list_topics',
+ format => 'xml',
+ sbugid => $bugid,
+ sauthor => $author,
+ sreviewer => $reviewer,
+ scc => $cc,
+ stext => $text];
+
+ my $response =
+ $ua->request(HTTP::Request::Common::POST($self->{url},
+ Content_Type => 'form-data',
+ Content => $content));
+
+ return $response->content;
+}
+
+
1;
|
|
From: <si...@us...> - 2008-08-20 00:43:35
|
User: sits
Date: 08/08/19 17:43:34
Modified: lib/Codestriker/Http/Method CreateCommentMethod.pm
ViewTopicTextMethod.pm
lib/Codestriker/Http Template.pm
bin CodestrikerClient.pm
Log:
More minor fixes so that a basic system can work again.
Index: CreateCommentMethod.pm
===================================================================
RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/Http/Method/CreateCommentMethod.pm,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- CreateCommentMethod.pm 18 Aug 2008 11:11:29 -0000 1.1
+++ CreateCommentMethod.pm 20 Aug 2008 00:43:33 -0000 1.2
@@ -20,13 +20,13 @@
my ($self, %args) = @_;
confess "Parameter topicid missing" unless defined $args{topicid};
- confess "Parameter projectid missing" unless defined $args{projectid};
if ($self->{cgi_style}) {
return $self->{url_prefix} . "?action=edit&fn=$args{filenumber}&line=$args{line}&new=$args{new}&topic=$args{topicid}" .
(defined $args{anchor} ? "&a=$args{anchor}" : "") .
(defined $args{context} ? "&context=$args{context}" : "");
} else {
+ confess "Parameter projectid missing" unless defined $args{projectid};
return $self->{url_prefix} . "/project/$args{projectid}/topic/$args{topicid}/comment/" .
"$args{filenumber}|$args{line}|$args{new}/create" .
(defined $args{anchor} ? "/anchor/$args{anchor}" : "") .
Index: ViewTopicTextMethod.pm
===================================================================
RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/Http/Method/ViewTopicTextMethod.pm,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- ViewTopicTextMethod.pm 17 Aug 2008 22:25:37 -0000 1.2
+++ ViewTopicTextMethod.pm 20 Aug 2008 00:43:33 -0000 1.3
@@ -21,7 +21,6 @@
my ($self, %args) = @_;
confess "Parameter topicid missing" unless defined $args{topicid};
- confess "Parameter projectid missing" unless defined $args{projectid};
if ($self->{cgi_style}) {
return $self->{url_prefix} . "?action=view&topic=$args{topicid}" .
@@ -31,6 +30,7 @@
(defined $args{fview} ? "&fview=$args{fview}" : "") .
(defined $args{filenumber} ? "#" . "$args{filenumber}|$args{line}|$args{new}" : "");
} else {
+ confess "Parameter projectid missing" unless defined $args{projectid};
return $self->{url_prefix} . "/project/$args{projectid}/topic/$args{topicid}/text" .
(defined $args{fview} ? "/filenumber/$args{filenumber}" : "") .
(defined $args{mode} ? "/mode/$args{mode}" : "") .
Index: Template.pm
===================================================================
RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/Http/Template.pm,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- Template.pm 20 Jun 2008 04:27:15 -0000 1.18
+++ Template.pm 20 Aug 2008 00:43:34 -0000 1.19
@@ -122,8 +122,7 @@
# Handle the links and parameters in the main title bar.
$vars->{'list_url'} =
- $url_builder->list_topics_url("", "", "", "", "", "", "",
- "", "", "", [ 0 ], undef);
+ $url_builder->list_topics_url(sstate => [0]);
$vars->{'create_topic_url'} = $url_builder->create_topic_url();
$vars->{'search_url'} = $url_builder->search_url();
$vars->{'doc_url'} = $url_builder->doc_url();
Index: CodestrikerClient.pm
===================================================================
RCS file: /cvsroot/codestriker/codestriker/bin/CodestrikerClient.pm,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- CodestrikerClient.pm 20 Jun 2008 04:29:36 -0000 1.5
+++ CodestrikerClient.pm 20 Aug 2008 00:43:34 -0000 1.6
@@ -57,6 +57,7 @@
email => $params->{email},
reviewers => $params->{reviewers},
cc => $params->{cc},
+ topic_state => $params->{topic_state},
topic_file => [$tempfile_filename]];
my $response =
$ua->request(HTTP::Request::Common::POST($self->{url},
|