Se pueden exportar las planillas de un barrio a pdf

This commit is contained in:
Ale 2022-09-06 21:43:56 -03:00
parent 25d5830462
commit 4939dbbd83
8 changed files with 67 additions and 3 deletions

BIN
.docker-compose.yml.swp Normal file

Binary file not shown.

1
.gitignore vendored
View File

@ -10,3 +10,4 @@ Homestead.json
Homestead.yaml
npm-debug.log
yarn-error.log
.idea

View File

@ -78,6 +78,11 @@
<excludeFolder url="file://$MODULE_DIR$/vendor/dragonmantank/cron-expression" />
<excludeFolder url="file://$MODULE_DIR$/vendor/psr/http-message" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/polyfill-php80" />
<excludeFolder url="file://$MODULE_DIR$/vendor/setasign/fpdi" />
<excludeFolder url="file://$MODULE_DIR$/vendor/paragonie/random_compat" />
<excludeFolder url="file://$MODULE_DIR$/vendor/mpdf/mpdf" />
<excludeFolder url="file://$MODULE_DIR$/vendor/php-http/message-factory" />
<excludeFolder url="file://$MODULE_DIR$/vendor/myclabs/deep-copy" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />

View File

@ -75,6 +75,13 @@
<path value="$PROJECT_DIR$/vendor/dragonmantank/cron-expression" />
<path value="$PROJECT_DIR$/vendor/psr/http-message" />
<path value="$PROJECT_DIR$/vendor/symfony/polyfill-php80" />
<path value="$PROJECT_DIR$/vendor/rmccue/requests" />
<path value="$PROJECT_DIR$/vendor/prexview/prexview" />
<path value="$PROJECT_DIR$/vendor/setasign/fpdi" />
<path value="$PROJECT_DIR$/vendor/paragonie/random_compat" />
<path value="$PROJECT_DIR$/vendor/mpdf/mpdf" />
<path value="$PROJECT_DIR$/vendor/php-http/message-factory" />
<path value="$PROJECT_DIR$/vendor/myclabs/deep-copy" />
</include_path>
</component>
<component name="PhpProjectSharedConfiguration" php_language_level="7.2">

View File

@ -7,7 +7,7 @@
</template>
<script>
import BotonAdminSubpedidoRow from "./BotonAdminSubpedidoRow";
import BotonAdminSubpedidoRow from "./SubpedidoRowBotonAdmin";
export default {
name: "SubpedidoRow",
components: {BotonAdminSubpedidoRow},

View File

@ -1,5 +1,15 @@
<template>
<div class="container is-max-widescreen is-max-desktop animate__animated" :class="animation" v-show="!init">
<div class="buttons is-right">
<a class="button is-info" :href="'/admin/exportar-planillas-a-pdf/'+gdc">
<span>
Imprimir Planillas
</span>
<span class="icon is-small">
<i class="fas fa-print"></i>
</span>
</a>
</div>
<table v-show="this.subpedidos.length !== 0" class="table is-fullwidth is-striped is-bordered">
<thead>
<tr>

View File

@ -1 +1,40 @@
<?php
<!doctype html>
<style>
tr:nth-child(even) {
background: #CCC
}
</style>
<h3>{{$subpedido->nombre}}</h3>
<table style="width: 100%">
<tr>
<th>
Producto
</th>
<th>
Cantidad
</th>
<th>
Control 1
</th>
<th>
Control 2
</th>
<th>
Control 3
</th>
</tr>
@foreach($subpedido->productos as $producto)
@if(!$producto->bono)
<tr>
<td>
{{ $producto->nombre }}
</td>
<td style="text-align: center">
{{ $producto->pivot->cantidad }}
</td>
</tr>
@endif
@endforeach
</table>

View File

@ -34,8 +34,10 @@ Route::get('/admin/obtener_sesion', function() {
return $sesion;
})->name('admin_obtener_sesion');
Route::middleware(['auth', 'admin'])->group( function () {
Route::get('/admin/exportar-planillas-a-pdf/{gdc}', 'AdminController@exportarPlanillasAPdf');
Route::middleware(['auth', 'admin'])->group( function () {
//Route::get('/admin/exportar-planillas-a-pdf/{gdc}', 'AdminController@exportarPlanillasAPdf');
});
Route::middleware('auth')->group( function() {