Skip to main content
1-Visitor
February 14, 2007
Question

get approvers with trigger

  • February 14, 2007
  • 2 replies
  • 927 views
hi all,
i'm writing a post release level change to get the two approvers that
vote for the change of a release level of a piv and the date of both
approvation.

using PDMReviewHistoryGetLastModificationStamp i can get the last
approver, but i'm not able to find the first approver.


the portion of code that i wrote and work for the last approver is:

for ( i=0; i<argc; i++=" )=" {<br="/> part = *((HPDMPROMOTIONPARTICIPANT *)argv[i]);

err = PDMPromotionParticipantGetPIV( part, &piv );

err = PDMPromotionParticipantGetPromotionForm( part, &pf );

// get REVIEW HISTORY
err = PDMPromotionFormGetReviewHistory ( pf, &revisionHistoryCursor );

for ( PDMCursorGetNext( revisionHistoryCursor, &ReviewHistoryHandle );
!PDM_HANDLE_IS_NULL( ReviewHistoryHandle );
PDMCursorGetNext( revisionHistoryCursor, &ReviewHistoryHandle ))
{
// get the last modification stamp of REVIEW HISTORY
err = PDMReviewHistoryGetLastModificationStamp(
ReviewHistoryHandle, &dataOraReviewHistory, &reviewer );

// reviewer is the last approver

// get date of last modification
err = PDMDateTimeGetInfo ( dataOraReviewHistory, &DateTimeInfo );
PDM_STATUS(funcName, "PDMDateTimeGetInfo()",err);
}
err = PDMCursorDelete ( revisionHistoryCursor );
PDM_STATUS(funcName, "PDMCursorDelete()",err);

any help is appreciated.

thanks,

michele giudici



[]


Cad.I.Tech. - Cad Integration Technology s.r.l.

Via Montevideo 7/11, 16129 Genova (Italy)

    2 replies

    13-Aquamarine
    February 14, 2007
    I have never tried to get this data but I would try this:



    PDMReviewHistoryGetOriginalVoter

    (



    HPDMREVIEWHISTORY ReviewHistoryHandle





    /* (In)



    The handle to the review history



    */



    HPDMUSER* UserHandle





    /* (Out)



    The handle to the original voter



    */





    Patrick Williams | Sr. Application Engineer | CAM Systems | Steelcase
    Inc. | 616.698.4078






    1-Visitor
    February 23, 2007
    thanks for the suggestion,
    i will tray and get a feedback.
    michele

    >I have never tried to get this data but I would try this:
    >
    >PDMReviewHistoryGetOriginalVoter
    >(
    >
    >HPDMREVIEWHISTORY ReviewHistoryHandle
    >
    >
    >/* (In)
    >
    >The handle to the review history
    >
    >*/
    >
    >HPDMUSER* UserHandle
    >
    >
    >/* (Out)
    >
    >The handle to the original voter
    >
    >*/
    >
    >
    >Patrick Williams | Sr. Application Engineer | CAM Systems |
    >Steelcase Inc. | 616.698.4078
    >
    >[]
    >
    >
    >
    >----------