Skip to content
This repository has been archived by the owner on May 28, 2019. It is now read-only.

Commit

Permalink
Remplacement des po gagné par le prix auquel ça a été acheté sur les …
Browse files Browse the repository at this point in the history
…pages des items vendu.
  • Loading branch information
bulton-fr committed Dec 30, 2013
1 parent abd940e commit 142f0fd
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 16 deletions.
3 changes: 2 additions & 1 deletion controlers/perso/vendu.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@

foreach($items as $item)
{
$item['poGagne'] = get_po($item['poGagne']);
if($item['typeVente'] == 'rachat') {$item['po'] = get_po($item['rachat']);}
else {$item['po'] = get_po($item['enchere']);}

$dateVendu = new \BFW\CKernel\Date($item['dateVendu']);
$item['date'] = $dateVendu->aff_simple();
Expand Down
4 changes: 3 additions & 1 deletion controlers/vendu/allHisto.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@

foreach($items as $item)
{
$item['poGagne'] = get_po($item['poGagne']);
if($item['typeVente'] == 'rachat') {$item['po'] = get_po($item['rachat']);}
else {$item['po'] = get_po($item['enchere']);}

$dateVendu = new \BFW\CKernel\Date($item['dateVendu']);
$item['dateVendu'] = $dateVendu->aff_simple();
$item['color'] = get_color_item($item['color']);
Expand Down
4 changes: 3 additions & 1 deletion controlers/vendu/histo.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@

foreach($items as $item)
{
$item['poGagne'] = get_po($item['poGagne']);
if($item['typeVente'] == 'rachat') {$item['po'] = get_po($item['rachat']);}
else {$item['po'] = get_po($item['enchere']);}

$dateVendu = new \BFW\CKernel\Date($item['dateVendu']);
$item['dateVendu'] = $dateVendu->aff_simple();
$item['color'] = get_color_item($item['color']);
Expand Down
4 changes: 3 additions & 1 deletion controlers/vendu/semaine.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,9 @@

foreach($items as $item)
{
$item['poGagne'] = get_po($item['poGagne']);
if($item['typeVente'] == 'rachat') {$item['po'] = get_po($item['rachat']);}
else {$item['po'] = get_po($item['enchere']);}

$dateVendu = new \BFW\CKernel\Date($item['dateVendu']);
$item['dateVendu'] = $dateVendu->aff_simple();
$item['color'] = get_color_item($item['color']);
Expand Down
8 changes: 4 additions & 4 deletions modeles/PersoItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ public function getVenduSemaineAllPerso($idUser, $dateDeb, $dateFin, $limit, $or
);

$req = $this->select()
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'poGagne', 'notes'))
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'enchere', 'rachat', 'notes'))
->joinLeft(array('i' => 'item'), 'i.id=pi.idItem', array('nomItem' => 'text', 'color' => 'color'))
->joinLeft(array('s' => 'stat'), 's.idStat=pi.idItem', array('nomStat' => 'nom'))
->joinLeft(array('p' => 'perso'), 'p.idPerso=pi.idPerso', array('nomPerso' => 'nom'))
Expand Down Expand Up @@ -272,7 +272,7 @@ public function getVenduAllPerso($idUser, $limit, $order)
);

$req = $this->select()
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'poGagne', 'notes'))
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'enchere', 'rachat', 'notes'))
->joinLeft(array('i' => 'item'), 'i.id=pi.idItem', array('nomItem' => 'text', 'color' => 'color'))
->joinLeft(array('s' => 'stat'), 's.idStat=pi.idItem', array('nomStat' => 'nom'))
->joinLeft(array('p' => 'perso'), 'p.idPerso=pi.idPerso', array('nomPerso' => 'nom'))
Expand Down Expand Up @@ -340,7 +340,7 @@ public function getVenduAll($limit, $order)
);

$req = $this->select()
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'poGagne', 'notes'))
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'enchere', 'rachat', 'notes'))
->joinLeft(array('i' => 'item'), 'i.id=pi.idItem', array('nomItem' => 'text', 'color' => 'color'))
->joinLeft(array('s' => 'stat'), 's.idStat=pi.idItem', array('nomStat' => 'nom'))
->joinLeft(array('p' => 'perso'), 'p.idPerso=pi.idPerso', array('nomPerso' => 'nom'))
Expand Down Expand Up @@ -741,7 +741,7 @@ public function getVenduPerso($idPerso, $limit, $order)
);

$req = $this->select()
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'poGagne', 'notes'))
->from(array('pi' => $this->_name), array('ref', 'typeVente', 'dateVendu', 'enchere', 'rachat', 'notes'))
->joinLeft(array('i' => 'item'), 'i.id=pi.idItem', array('nomItem' => 'text', 'color' => 'color'))
->joinLeft(array('s' => 'stat'), 's.idStat=pi.idItem', array('nomStat' => 'nom'))
->joinLeft(array('p' => 'perso'), 'p.idPerso=pi.idPerso', array('nomPerso' => 'nom'))
Expand Down
4 changes: 2 additions & 2 deletions view/perso/vendu.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<td class="persoVenduItem">Item<div class="triPosition<var name='triItem' />"></div></td>
<td class="persoDate">Date<div class="triPosition<var name='triDate' />"></div></td>
<td class="persoVenduAchat">Type d'achat<div class="triPosition<var name='triAchat' />"></div></td>
<td class="persoPo">Po obtenu<div class="triPosition<var name='triPo' />"></div></td>
<td class="persoPo">Vendu à<div class="triPosition<var name='triPo' />"></div></td>
</tr>
</thead>
<tbody id="ViewPersoTbody">
Expand All @@ -21,7 +21,7 @@
</td>
<td class="center"><var name="date" /></td>
<td class="center"><var name="typeVente" /></td>
<td class="po"><var name="poGagne" /></td>
<td class="po"><var name="po" /></td>
</tr>
</block>
<block name="start">
Expand Down
4 changes: 2 additions & 2 deletions view/vendu/allHisto.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<td class="venduPerso">Personnage<div class="triPosition<var name='triPerso' />"></div></td>
<td class="venduDate">Date<div class="triPosition<var name='triDate' />"></div></td>
<td class="venduAchat">Type d'achat<div class="triPosition<var name='triAchat' />"></div></td>
<td class="venduPo">Po obtenu<div class="triPosition<var name='triPo' />"></div></td>
<td class="venduPo">Vendu à<div class="triPosition<var name='triPo' />"></div></td>
</tr>
</thead>
<tbody id="VenduTbody">
Expand All @@ -23,7 +23,7 @@
<td class="center" title="<var name="nomUser" />"><var name="nomPerso" /></td>
<td class="center"><var name="dateVendu" /></td>
<td class="center"><var name="typeVente" /></td>
<td class="po"><var name="poGagne" /></td>
<td class="po"><var name="po" /></td>
</tr>
</block>
<block name="start">
Expand Down
4 changes: 2 additions & 2 deletions view/vendu/histo.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<td class="venduPerso">Personnage<div class="triPosition<var name='triPerso' />"></div></td>
<td class="venduDate">Date<div class="triPosition<var name='triDate' />"></div></td>
<td class="venduAchat">Type d'achat<div class="triPosition<var name='triAchat' />"></div></td>
<td class="venduPo">Po obtenu<div class="triPosition<var name='triPo' />"></div></td>
<td class="venduPo">Vendu à<div class="triPosition<var name='triPo' />"></div></td>
</tr>
</thead>
<tbody id="VenduTbody">
Expand All @@ -23,7 +23,7 @@
<td class="center"><var name="nomPerso" /></td>
<td class="center"><var name="dateVendu" /></td>
<td class="center"><var name="typeVente" /></td>
<td class="po"><var name="poGagne" /></td>
<td class="po"><var name="po" /></td>
</tr>
</block>
<block name="start">
Expand Down
4 changes: 2 additions & 2 deletions view/vendu/semaine.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<td class="venduPerso">Personnage<div class="triPosition<var name='triPerso' />"></div></td>
<td class="venduDate">Date<div class="triPosition<var name='triDate' />"></div></td>
<td class="venduAchat">Type d'achat<div class="triPosition<var name='triAchat' />"></div></td>
<td class="venduPo">Po obtenu<div class="triPosition<var name='triPo' />"></div></td>
<td class="venduPo">Vendu à<div class="triPosition<var name='triPo' />"></div></td>
</tr>
</thead>
<tbody id="VenduTbody">
Expand All @@ -23,7 +23,7 @@
<td class="center"><var name="nomPerso" /></td>
<td class="center"><var name="dateVendu" /></td>
<td class="center"><var name="typeVente" /></td>
<td class="po"><var name="poGagne" /></td>
<td class="po"><var name="po" /></td>
</tr>
</block>
<block name="start">
Expand Down

0 comments on commit 142f0fd

Please sign in to comment.