View ProjeQtOr On SourceForge.net
ProjeQtOr - Project Management Tool
Support us on Capterra
OIN - Open Invention Network
ProjeQtOr free project management software - New loop in dawObject - ProjeQtOr
 

New loop in dawObject

More
15 May 2017 15:55 #1 by antonio.grr
Hi.
Could you please explain me the meaning of the following loop added to drawOrigin function in objectDetail.php ?

foreach ( $list as $origin ) {
//$origObj=null;
$origObjClass=null;
$origObjId=null;
if ($list->originType == get_class($obj) and $list->originId == $obj->id) {
//$origObj=new $list->refType($list->refId);
$origObjClass=$list->refType;
$origObjId=$list->refId;
} else {
//$origObj=new $list->originType($list->originId);
$origObjClass=$list->originType;
$origObjId=$list->originId;
}
$gotoE=' onClick="gotoElement(' . "'" . $origObjClass . "','" . htmlEncode($origObjId) . "'" . ');" style="cursor: pointer;" ';
echo '</td><td xclass="noteData" '.$gotoE.' style="height: 15px">';
}
It seems that you loop through attributes of object $list ( $obj->Origin), then ,regardless attribute, you test $list->originType and $list->originId (that seem to be a copy of arguments refType, $refId) and echo an onClick action gotoElement to the same object once for each attribute.
I'm missing something.
Thank you for your attention

Please Log in or Create an account to join the conversation.

More
15 May 2017 18:32 #2 by babynus
Replied by babynus on topic New loop in dawObject
Target is to set Origin (that you can view on Ticket or Activity) as Clickable, so that just just can click on, item to go to it.
Alos, new feature is to be able to define several Origins for single item.
Not finished yet and not used yet.

Babynus
Administrator of ProjeQtOr web site

Please Log in or Create an account to join the conversation.

Moderators: babynusprotion
Time to create page: 0.030 seconds

Cookies settings

×

Functional Cookies

Ce site utilise des cookies pour assurer son bon fonctionnement et ne peuvent pas être désactivés de nos systèmes. Nous ne les utilisons pas à des fins publicitaires. Si ces cookies sont bloqués, certaines parties du site ne pourront pas fonctionner.

Session

Please login to see yours activities!

Other cookies

Ce site web utilise un certain nombre de cookies pour gérer, par exemple, les sessions utilisateurs.