Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: mantisbt/mantisbt
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: df7782a
Choose a base ref
...
head repository: mantisbt/mantisbt
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 4974921
Choose a head ref
  • 2 commits
  • 3 files changed
  • 1 contributor

Commits on Jan 6, 2012

  1. Add a dedicated SOAP logger

    Bug: #8657 ( custom filters )
    rombert committed Jan 6, 2012
    Copy the full SHA
    253c988 View commit details
  2. Extract mci_issue_data_as_header_array utility function

    Bug: #8657 ( custom filters )
    rombert committed Jan 6, 2012
    Copy the full SHA
    4974921 View commit details
Showing with 37 additions and 1 deletion.
  1. +35 −1 api/soap/mc_issue_api.php
  2. +1 −0 core/constant_inc.php
  3. +1 −0 core/logging_api.php
36 changes: 35 additions & 1 deletion api/soap/mc_issue_api.php
Original file line number Diff line number Diff line change
@@ -1301,7 +1301,6 @@ function mci_iso8601_to_timestamp( $p_date ) {

}


/**
* Returns an array for SOAP encoding from a BugData object
*
@@ -1383,3 +1382,38 @@ function mci_issue_get_tags_for_bug_id( $p_bug_id, $p_user_id ) {

return $t_result;
}

/**
* Returns an array for SOAP encoding from a BugData object
*
* @param BugData $p_issue_data
* @return array The issue header data as an array
*/
function mci_issue_data_as_header_array( $p_issue_data ) {

$t_issue = array();

$t_id = $p_issue_data->id;

$t_issue['id'] = $t_id;
$t_issue['view_state'] = $p_issue_data->view_state;
$t_issue['last_updated'] = timestamp_to_iso8601( $p_issue_data->last_updated );

$t_issue['project'] = $p_issue_data->project_id;
$t_issue['category'] = mci_get_category( $p_issue_data->category_id );
$t_issue['priority'] = $p_issue_data->priority;
$t_issue['severity'] = $p_issue_data->severity;
$t_issue['status'] = $p_issue_data->status;

$t_issue['reporter'] = $p_issue_data->reporter_id;
$t_issue['summary'] = $p_issue_data->summary;
if( !empty( $p_issue_data->handler_id ) ) {
$t_issue['handler'] = $p_issue_data->handler_id;
}
$t_issue['resolution'] = $p_issue_data->resolution;

$t_issue['attachments_count'] = count( mci_issue_get_attachments( $p_issue_data->id ) );
$t_issue['notes_count'] = count( mci_issue_get_notes( $p_issue_data->id ) );

return $t_issue;
}
1 change: 1 addition & 0 deletions core/constant_inc.php
Original file line number Diff line number Diff line change
@@ -494,6 +494,7 @@
define( 'LOG_AJAX', 8 ); # logging for AJAX / XmlHttpRequests
define( 'LOG_LDAP', 16 ); # logging for ldap
define( 'LOG_DATABASE', 32 ); # logging for ldap
define( 'LOG_SOAP', 64 ); # logging for SOAP

# COLUMNS_TARGET_*
define( 'COLUMNS_TARGET_VIEW_PAGE', 1 );
1 change: 1 addition & 0 deletions core/logging_api.php
Original file line number Diff line number Diff line change
@@ -31,6 +31,7 @@
LOG_AJAX => 'ajax',
LOG_LDAP => 'ldap',
LOG_DATABASE => 'database',
LOG_SOAP => 'soap'
);

/**