add link to quote website

This commit is contained in:
2023-05-03 17:00:28 +02:00
parent b714c6138a
commit 7e73994acf
4 changed files with 14 additions and 9 deletions

View File

@@ -56,8 +56,13 @@
<div class="form-group">
<label class="required-field" for="website">{{form.website.label}}</label>
<div class="input-group">
<div class="input-group-addon">
<a href="{{ item.website }}" target="_blank"><span class="glyphicon glyphicon-globe"></span></a>
</div>
{{form.website(class_='form-control')}}
</div>
</div>
<div class="form-group">
<p class="form-control-static"><b>Dernière modif. :</b> {{ item.modif_le }}</p>

View File

@@ -46,17 +46,17 @@
<tbody>
<tr>
<td>Valorisation</td>
<td class="text-right">{{ '{0:0.2f} €'.format(total_valeur) }}</td>
<td class="text-right">{{ '{0:0.2f} €'.format(total_valeur).replace(',',' ') }}</td>
<td></td>
</tr>
<tr>
<td>Plus value</td>
<td class="text-right">{{ '{0:0.2f} €'.format(total_pv) }}</td>
<td class="text-right">{{ '{0:0,.0f} €'.format(total_pv).replace(',',' ') }}</td>
<td class="text-right">{{ '{0:0.1f} %'.format(total_pc_value) }}</td>
</tr>
<tr>
<td>Safe Withdrawal Rate</td>
<td class="text-right text-success"><b>{{ '{0:0.1f} %'.format(swr_amount) }}</b></td>
<td class="text-right text-success"><b>{{ '{0:0,.0f} '.format(swr_amount) }}</b></td>
<td class="text-right text-success"><b>{{ '{0:0.1f} %'.format(swr_rate) }}</b></td>
</tr>
</tbody>

View File

@@ -58,7 +58,7 @@ def portfolio(request):
ticker = yf.Ticker(symbole)
# ticker delisted ?
if symbole == 'SHLDQ':
cours = 0
cours = 0.1
else:
cours = round(ticker.fast_info.get('lastPrice'), 3)