diff --git a/lib/LIMS2/WebApp/Controller/User/PlateEdit.pm b/lib/LIMS2/WebApp/Controller/User/PlateEdit.pm
index 9fa09e52ee..9d3ac5a836 100644
--- a/lib/LIMS2/WebApp/Controller/User/PlateEdit.pm
+++ b/lib/LIMS2/WebApp/Controller/User/PlateEdit.pm
@@ -56,7 +56,7 @@ sub delete_plate :Path( '/user/delete_plate' ) :Args(0) {
catch {
$c->flash->{error_msg} = 'Error encountered while deleting plate: ' . $_;
$c->model('Golgi')->txn_rollback;
- $c->res->redirect( $c->uri_for('/user/edit_plate', { id => $params->{id} }) );
+ $c->res->redirect( $c->uri_for('/user/view_plate', { id => $params->{id} }) );
};
}
);
@@ -69,7 +69,7 @@ sub rename_plate :Path( '/user/rename_plate' ) :Args(0) {
unless ( $params->{new_name} ) {
$c->flash->{error_msg} = 'You must specify a new plate name';
- $c->res->redirect( $c->uri_for('/user/edit_plate', { id => $params->{id} }) );
+ $c->res->redirect( $c->uri_for('/user/view_plate', { id => $params->{id} }) );
return;
}
@@ -92,7 +92,7 @@ sub rename_plate :Path( '/user/rename_plate' ) :Args(0) {
}
);
- $c->res->redirect( $c->uri_for('/user/edit_plate', { id => $params->{id} }) );
+ $c->res->redirect( $c->uri_for('/user/view_plate', { id => $params->{id} }) );
}
=head1 AUTHOR
diff --git a/root/site/user/browseplates/index.tt b/root/site/user/browseplates/index.tt
index 1ab0078d4a..c68e5078ca 100644
--- a/root/site/user/browseplates/index.tt
+++ b/root/site/user/browseplates/index.tt
@@ -36,11 +36,6 @@
[% plate.name %]
|
-
-
- Edit
-
- |
[% plate.type_id %] |
[% plate.description %] |
[% plate.created_by.name %] |
diff --git a/root/site/user/browseplates/view.tt b/root/site/user/browseplates/view.tt
index 839b5e0523..40ac0f018c 100644
--- a/root/site/user/browseplates/view.tt
+++ b/root/site/user/browseplates/view.tt
@@ -1,47 +1,145 @@
-[%- META title="View Plate"; META tab_name = "Browse" %]
+[%- META title="View Plate"; META tab_name = "Plates" %]
-
-
-
- Plate Name |
- Plate Type |
- Description |
- Created By |
- Created At |
-
-
-
-
- [% plate.name %] |
- [% plate.type.id %] ([% plate.type.description %]) |
- [% plate.description %] |
- [% plate.created_by.name %] |
- [% plate.created_at.ymd %] |
-
-
-
-
-Comments
-[% IF plate.plate_comments.size %]
-
- [% FOR comment IN plate.plate_comments %]
- - [% comment.created_by.name %], [% comment.created_at.ymd %]
- -
-
[% comment.comment_text %]
-
- [% END %]
-
-[% ELSE %]
-No comments for this plate.
-[% END %]
+
+
+
+
+
+
+ Name
+ |
+
+ [% plate.name %]
+ |
+
+
+ Rename
+
+ |
+
+
+
+
+ Type
+ |
+
+ [% plate.type.id %] ([% plate.type.description %])
+ |
+ |
+
+
+
+
+ Description
+ |
+
+ [% plate.description %]
+ |
+ |
+
+
+
+
+ Created By
+ |
+
+ [% plate.created_by.name %]
+ |
+ |
+
+
+
+
+ Created At
+ |
+
+ [% plate.created_at.ymd %]
+ |
+ |
+
+
+
+
+
+
+
+
+
Comments
+ [% IF plate.plate_comments.size %]
+
+ [% FOR comment IN plate.plate_comments %]
+ - [% comment.created_by.name %], [% comment.created_at.ymd %]
+ -
+
[% comment.comment_text %]
+
+ [% END %]
+
+ [% ELSE %]
+
No comments for this plate.
+ [% END %]
+
+
+
-
- Edit Plate
-
+
+
+
+[% UNLESS plate.has_child_wells %]
+
+
+
+
+[% END %]
Wells
Well Details
diff --git a/root/site/user/plateedit/index.tt b/root/site/user/plateedit/index.tt
deleted file mode 100644
index 24e96d3ae6..0000000000
--- a/root/site/user/plateedit/index.tt
+++ /dev/null
@@ -1,143 +0,0 @@
-[%- META title="Edit Plate"; META tab_name = "Plates" %]
-
-
-
-
-
-
-
-
-
-
- Name
- |
-
- [% plate.name %]
- |
-
-
- Rename
-
- |
-
-
-
-
- Type
- |
-
- [% plate.type.id %] ([% plate.type.description %])
- |
- |
-
-
-
-
- Description
- |
-
- [% plate.description %]
- |
- |
-
-
-
-
- Created By
- |
-
- [% plate.created_by.name %]
- |
- |
-
-
-
-
- Created At
- |
-
- [% plate.created_at.ymd %]
- |
- |
-
-
-
-
-
-
-
-
-
Comments
- [% IF plate.plate_comments.size %]
-
- [% FOR comment IN plate.plate_comments %]
- - [% comment.created_by.name %], [% comment.created_at.ymd %]
- -
-
[% comment.comment_text %]
-
- [% END %]
-
- [% ELSE %]
-
No comments for this plate.
- [% END %]
-
-
-
-
-
-
-[% UNLESS plate.has_child_wells %]
-
-
-
-
-[% END %]
-
diff --git a/t/80-plate_edit.t b/t/80-plate_edit.t
index 0451e806d6..4dfbe3b21a 100644
--- a/t/80-plate_edit.t
+++ b/t/80-plate_edit.t
@@ -21,12 +21,12 @@ my $plate_with_children = model->retrieve_plate( { name => 'PCS00097_A' } );
{
note( "Visit plate edit page" );
- $mech->get_ok( '/user/edit_plate?id=' . $plate_without_children->id );
- $mech->title_is('Edit Plate');
+ $mech->get_ok( '/user/view_plate?id=' . $plate_without_children->id );
+ $mech->title_is('View Plate');
$mech->content_like( qr/delete_plate_button/, '..has delete plate button');
- $mech->get_ok( '/user/edit_plate?id=' . $plate_with_children->id );
- $mech->title_is('Edit Plate');
+ $mech->get_ok( '/user/view_plate?id=' . $plate_with_children->id );
+ $mech->title_is('View Plate');
$mech->content_unlike( qr/delete_plate_button/, '..has no delete plate button');
}
@@ -35,11 +35,11 @@ my $plate_with_children = model->retrieve_plate( { name => 'PCS00097_A' } );
my $plate = model->retrieve_plate( { name => 'SEP0006' } );
$mech->get_ok( '/user/rename_plate?id=' . $plate->id . '&name=' . $plate->name . '&new_name=' . $plate_with_children->name );
- $mech->base_like( qr{user/edit_plate},'...moves to edit_plates page');
+ $mech->base_like( qr{user/view_plate},'...moves to view_plates page');
$mech->content_like( qr/Error encountered while renaming plate: .* already exists/, '...correct plate rename error message');
$mech->get_ok( '/user/rename_plate?id=' . $plate->id . '&name=' . $plate->name . '&new_name=FOOBAR' );
- $mech->base_like( qr{user/edit_plate},'...moves to browse_plates page');
+ $mech->base_like( qr{user/view_plate},'...moves to view_plate page');
$mech->content_like( qr/Renamed plate from SEP0006 to FOOBAR/, '...correct plate rename message');
}
@@ -51,7 +51,7 @@ my $plate_with_children = model->retrieve_plate( { name => 'PCS00097_A' } );
$mech->content_like( qr/Deleted plate FFP0001/, '...correct plate delete message');
$mech->get_ok( '/user/delete_plate?id=' . $plate_with_children->id . '&name=' . $plate_with_children->name );
- $mech->base_like( qr{user/edit_plate},'...moves to edit_plate page');
+ $mech->base_like( qr{user/view_plate},'...moves to view_plate page');
$mech->content_like( qr/Error encountered while deleting plate: .* has child plates/, '...correct delete plate error message');
}