Ejemplo n.º 1
0
 $hid = $holding['holdings_id'];
 $tradeType = $holding['holdings_tradetype'];
 if ($tradeType == REVERSAL_TRADE) {
     continue;
 }
 $hitT1 = $holding['holdings_t1_marked'];
 $hitT2 = $holding['holdings_t2_marked'];
 $hitT3 = $holding['holdings_t3_marked'];
 $t1 = floatval($holding['holdings_t1']);
 $t2 = floatval($holding['holdings_t2']);
 $t3 = floatval($holding['holdings_t3']);
 $start = $holding['holdings_orig_price'];
 $abandon = $holding['holdings_stop_price'];
 $return_percent = holdings::GetReturnPercent($tradeType, 0, $start, $t1, $t2, $t3, $hitT1, $hitT2, $hitT3, $abandon);
 $tradeClass = strtolower(GetTradeTypeConstantNameSingular($tradeType));
 $tradeString = GetTradeTypeConstantNameSingular($tradeType);
 $ti = GetTradeIndex($tradeType);
 $valuation = 5000 * $return_percent / 100;
 // process months into array for select
 $abandonMonth = date("F Y", strtotime($holding['holdings_abandon_date']));
 if ($abandonMonth != $prevMonth) {
     $prevMonth = $abandonMonth;
     $allMonths[] = $abandonMonth;
     if (!$first) {
         //echo "</tbody>";
         $first = false;
     }
     //echo "<tbody id=\"month_".str_replace(" ", "", $abandonMonth) ."\" class=\"monthTable\">";
 }
 $monthKey = str_replace(" ", "", $abandonMonth);
 $monthArray = array();
Ejemplo n.º 2
0
    } else {
        $tablestate = 'row_odd';
    }
}
?>
					
				</tbody>
			</table>
		</div>
	</div>
</div>
<div id="actions" class = "newwrap">
	<div class="section n4">
		<div class="title1">
			<?php 
echo GetTradeTypeConstantNameSingular($tradeType);
?>
 Actions
		</div >
		<div class="desc">
			<ul class="ruleslist">
				<?php 
echo $typeStrings->actionList;
?>
			</ul>
		</div>
<!-- BEGIN: Constant Contact Archive Homepage link -->
<div class="cc_archive">
<div align="center">
<table border="0" cellspacing="0" cellpadding="1" bgcolor="#999999"><tr><td>
<table border="0" cellpadding="0" cellspacing="0">
Ejemplo n.º 3
0
						<th class="center"> Orig Price </th>
						<th class="center"> Orig Date </th>
						<th class="center"> Return </th>
						<th></th>
					</tr>
				</thead>
				<tbody>
<?php 
$holdings = ticker_group_info::retrieveHoldingsArray(LONG_TRADE, true);
$tablestate = "row_odd";
$borderTop = "borderTop";
foreach ($holdings as $holding) {
    $tt = intval($holding['holdings_tradetype']);
    //if ($tt == BREAKDOWN_TRADE) continue;
    $last = $holding['last'];
    $ttStr = GetTradeTypeConstantNameSingular($tt);
    $tablerowtype = strtolower($ttStr);
    $start = $holding['holdings_orig_price'];
    $return_percent = holdings::GetReturnPercent($tt, $last, $start, 0, 0, 0, 0, 0, 0);
    echo '<tr class="table_row2 ' . $tablestate . ' ' . $tablerowtype . '">';
    echo '<td class="left borderLeft ' . $borderTop . '">' . strtoupper($holding['ticker_symbol']) . '</td>';
    echo '<td class="center ' . $borderTop . '">' . $ttStr . '</td>';
    echo '<td class="center ' . $borderTop . '">' . number_format($holding['last'], 2) . '</td>';
    echo '<td class="center ' . $borderTop . '">' . number_format($start, 2) . '</td>';
    echo '<td class="center ' . $borderTop . '">' . date("m-d-Y", strtotime($holding['holdings_orig_date'])) . '</td>';
    echo '<td class="center borderRight ' . $borderTop . '">' . number_format($return_percent, 2) . '%</td>';
    echo '</tr>';
    $borderTop = "";
}
?>