This commit is contained in:
2022-06-13 21:36:11 -04:00
parent d7d671fb51
commit 119cdd2b95
16 changed files with 628 additions and 156 deletions

View File

@ -5,10 +5,24 @@
<h3>Precios</h3>
</div>
<table class="table">
@foreach ($proyectos as $proyecto)
<tr>
<td><a href="{{nUrl('precios', 'list', ['proyecto' => $proyecto->id])}}">{{$proyecto->descripcion}}</a>
</tr>
@endforeach
<tbody id="proyectos"></tbody>
</table>
@endsection
@push('scripts')
<script type="text/javascript">
$(document).ready(() => {
sendGet('/proyectos').then(response => {
response.proyectos.forEach(el => {
$('#proyectos').append(
$('<tr></tr>').append(
$('<td></td>').append(
$('<a></a>').attr('href', '{{$urls->base}}/proyecto/' + el.id + '/precios').html(el.descripcion)
)
)
)
})
})
})
</script>
@endpush