Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

mantisbt bug_actiongroup.php,1.45,1.46 bug_actiongroup_page.php,1.49,1.50 c: msg#00034

bug-tracking.mantis.cvs

Subject: mantisbt bug_actiongroup.php,1.45,1.46 bug_actiongroup_page.php,1.49,1.50 config_defaults_inc.php,1.269,1.270

Update of /cvsroot/mantisbt/mantisbt
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12486

Modified Files:
bug_actiongroup.php bug_actiongroup_page.php
config_defaults_inc.php
Log Message:
Implemented #5771: Support custom actions in issue group actions.

Index: bug_actiongroup_page.php
===================================================================
RCS file: /cvsroot/mantisbt/mantisbt/bug_actiongroup_page.php,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -d -r1.49 -r1.50
--- bug_actiongroup_page.php 9 Jun 2005 20:35:39 -0000 1.49
+++ bug_actiongroup_page.php 12 Jun 2005 00:20:46 -0000 1.50
@@ -14,6 +14,8 @@

require_once( 'core.php' );

+ require_once( $t_core_path.'bug_group_action_api.php' );
+
auth_ensure_user_authenticated();

$f_action = gpc_get_string( 'action', '' );
@@ -29,6 +31,15 @@
$t_finished = false;
$t_request = '';

+ $t_custom_group_actions = config_get( 'custom_group_actions' );
+
+ foreach( $t_custom_group_actions as $t_custom_group_action ) {
+ if ( $f_action == $t_custom_group_action['action'] ) {
+ require_once( $t_custom_group_action['form_page'] );
+ exit;
+ }
+ }
+
# Check if user selected to update a custom field.
$t_custom_fields_prefix = 'custom_field_';
if ( strpos( $f_action, $t_custom_fields_prefix ) === 0 ) {
@@ -125,8 +136,7 @@
trigger_error( ERROR_GENERIC, ERROR );
}

- html_page_top1();
- html_page_top2();
+ bug_group_action_print_top();
?>

<br />
@@ -135,27 +145,14 @@
<form method="POST" action="bug_actiongroup.php">
<input type="hidden" name="action" value="<?php echo string_attribute(
$f_action ) ?>" />
<?php
+ bug_group_action_print_hidden_fields( $f_bug_arr );
+
if ( $f_action === 'CUSTOM' ) {
echo "<input type=\"hidden\" name=\"custom_field_id\"
value=\"$t_custom_field_id\" />";
}
?>
<table class="width75" cellspacing="1">
<?php
-
-$t_bug_rows = "";
-$t_i = 1;
-
-foreach( $f_bug_arr as $t_bug_id ) {
- $t_class = sprintf( "row-%d", ($t_i++ % 2) + 1 );
- $t_bug_rows .= sprintf( "<tr bgcolor=\"%s\"> <td>%s</td> <td>%s</td>
</tr>\n",
- get_status_color( bug_get_field( $t_bug_id, 'status' ) ),
string_get_bug_view_link( $t_bug_id ),
- string_attribute( bug_get_field( $t_bug_id, 'summary' ) )
- );
- echo '<input type="hidden" name="bug_arr[]" value="' . $t_bug_id . '"
/>' . "\n";
-}
-?>
-
-<?php
if ( !$t_finished ) {
?>
<tr class="row-1">
@@ -252,23 +249,14 @@
</td>
</tr>
</table>
-
<br />

-<table class="width75" cellspacing="1">
-<tr class="row-1">
- <td class="category" colspan="2">
- <?php echo lang_get( 'actiongroup_bugs' ); ?>
- </td>
-</tr>
<?php
- echo $t_bug_rows;
+ bug_group_action_print_bug_list( $f_bug_arr );
?>
-</table>
</form>
</div>

-
<?php
- html_page_bottom1( __FILE__ );
-?>
+ bug_group_action_print_bottom();
+?>
\ No newline at end of file

Index: bug_actiongroup.php
===================================================================
RCS file: /cvsroot/mantisbt/mantisbt/bug_actiongroup.php,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- bug_actiongroup.php 18 May 2005 02:11:39 -0000 1.45
+++ bug_actiongroup.php 12 Jun 2005 00:20:46 -0000 1.46
@@ -27,6 +27,15 @@
$f_custom_field_id = gpc_get_int( 'custom_field_id', 0 );
$f_bug_arr = gpc_get_int_array( 'bug_arr', array() );

+ $t_custom_group_actions = config_get( 'custom_group_actions' );
+
+ foreach( $t_custom_group_actions as $t_custom_group_action ) {
+ if ( $f_action == $t_custom_group_action['action'] ) {
+ require_once( $t_custom_group_action['action_page'] );
+ exit;
+ }
+ }
+
$t_failed_ids = array();

if ( 0 != $f_custom_field_id ) {

Index: config_defaults_inc.php
===================================================================
RCS file: /cvsroot/mantisbt/mantisbt/config_defaults_inc.php,v
retrieving revision 1.269
retrieving revision 1.270
diff -u -d -r1.269 -r1.270
--- config_defaults_inc.php 9 Jun 2005 19:54:25 -0000 1.269
+++ config_defaults_inc.php 12 Jun 2005 00:20:46 -0000 1.270
@@ -1164,7 +1164,7 @@
$g_view_filters = SIMPLE_DEFAULT;

# This switch enables the use of xmlhttprequest protocol to speed up
the filter display.
- # Rather than launching a separate page, the filters are updated
in-line in the
+ # Rather than launching a separate page, the filters are updated
in-line in the
# view_all_bugs_page.
$g_dhtml_filters = ON;

@@ -1573,4 +1573,19 @@
# Number of years in the future that custom date fields will display in
# drop down boxes.
$g_forward_year_count = 4 ;
+
+ # Custom Group Actions
+ # Sample:
+ #
+ # array(
+ # array( 'action' => 'my_custom_action',
+ # 'form_page' => 'my_custom_action_page.php',
+ # 'action_page' => 'my_custom_action.php'
+ # )
+ # array( 'action' => 'my_custom_action2',
+ # 'form_page' => 'my_custom_action2_page.php',
+ # 'action_page' => 'my_custom_action2.php'
+ # )
+ # );
+ $g_custom_group_actions = array();
?>



-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games. How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy.
Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
user-groups.jax...    php.zend.framew...    os.solaris.open...    web.quixote.use...    java.openjdk.ho...    ietf.secmech/20...    gnu.glpk/2004-0...    recreation.cars...    network.smokepi...    linux.drivers.i...    cms.opencms.dev...    fonts.gfontview...    text.xml.soap.u...    voip.nist-sip/2...    debian.ports.hp...    xfree86.interna...    science.biology...    qnx.openqnx.dev...    mail.sylpheed.c...    busybox/bios/20...    emulators.kvm.s...    hardware.openco...    apple.fink.begi...    kde.german/2006...   
Home | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation