Datenverbund

- Added new Page to Manage missing bPK
- Improved Error Handling on DVB Class
This commit is contained in:
Andreas Österreicher
2018-11-20 17:36:24 +01:00
parent 412c05c7e3
commit 6a26609aef
10 changed files with 718 additions and 129 deletions
+58
View File
@@ -0,0 +1,58 @@
<?php
$filterWidgetArray = array(
'query' => '
SELECT
person_id, vorname, nachname, geschlecht, svnr, ersatzkennzeichen, matr_nr,
staatsbuergerschaft, gebdatum
FROM
public.tbl_person
WHERE
matr_nr is not null
AND bpk is null
AND EXISTS(SELECT 1 FROM public.tbl_benutzer JOIN public.tbl_student ON(uid=student_uid) AND
person_id=tbl_person.person_id AND tbl_benutzer.aktiv=true)
',
'requiredPermissions' => 'admin',
'additionalColumns' => array('Details'),
'columnsAliases' => array(
'PersonID',
ucfirst($this->p->t('person', 'vorname')) ,
ucfirst($this->p->t('person', 'nachname')),
ucfirst($this->p->t('person', 'geschlecht')),
ucfirst($this->p->t('person', 'svnr')),
ucfirst($this->p->t('person', 'ersatzkennzeichen')),
ucfirst($this->p->t('person', 'matrikelnummer')),
ucfirst($this->p->t('person', 'staatsbuergerschaft')),
ucfirst($this->p->t('person', 'geburtsdatum')),
),
'formatRow' => function($datasetRaw) {
/* NOTE: Dont use $this here for PHP Version compatibility */
$datasetRaw->{'Details'} = sprintf(
'<a href="%s?person_id=%s&origin_page=%s&fhc_controller_id=%s">Details</a>',
site_url('person/BPKWartung/showDetails'),
$datasetRaw->{'person_id'},
'index',
(isset($_GET['fhc_controller_id'])?$_GET['fhc_controller_id']:'')
);
if ($datasetRaw->{'ersatzkennzeichen'} == null)
{
$datasetRaw->{'ersatzkennzeichen'} = '-';
}
if ($datasetRaw->{'svnr'} == null)
{
$datasetRaw->{'svnr'} = '-';
}
return $datasetRaw;
}
);
$filterWidgetArray['app'] = 'core';
$filterWidgetArray['datasetName'] = 'overview';
$filterWidgetArray['filterKurzbz'] = 'BPKWartung';
$filterWidgetArray['filter_id'] = $this->input->get('filter_id');
echo $this->widgetlib->widget('FilterWidget', $filterWidgetArray);
?>
+153
View File
@@ -0,0 +1,153 @@
<?php
$this->load->view(
'templates/FHC-Header',
array(
'title' => 'bPK Details',
'jquery' => true,
'bootstrap' => true,
'fontawesome' => true,
'jqueryui' => true,
'ajaxlib' => true,
'tablesorter' => true,
'tinymce' => true,
'sbadmintemplate' => true,
'addons' => true,
'navigationwidget' => true,
'customCSSs' => array(
'public/css/sbadmin2/admintemplate.css',
'public/css/sbadmin2/tablesort_bootstrap.css',
'public/css/infocenter/infocenterDetails.css'
),
'customJSs' => array(
'public/js/bootstrapper.js',
'public/js/tablesort/tablesort.js'
),
'phrases' => array(
'ui' => array(
'gespeichert',
'fehlerBeimSpeichern'
),
'global' => array(
'bis',
'zeilen'
)
)
)
);
?>
<body>
<div id="wrapper">
<?php echo $this->widgetlib->widget('NavigationWidget'); ?>
<div id="page-wrapper">
<div class="container-fluid">
<input type="hidden" id="hiddenpersonid" value="<?php echo $stammdaten->person_id ?>">
<div class="row">
<div class="col-lg-8">
<h3 class="page-header">
bPK Details: <?php echo $stammdaten->vorname.' '.$stammdaten->nachname ?>
</h3>
</div>
</div>
<br/>
<section>
<div class="row">
<div class="col-lg-12">
<div class="panel panel-primary">
<div class="panel-heading text-center">
<h4><?php echo ucfirst($this->p->t('global', 'stammdaten')) ?></h4>
</div>
<div class="panel-body">
<div class="row">
<div class="col-lg-6 table-responsive">
<table class="table">
<?php if (!empty($stammdaten->titelpre)): ?>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','titelpre')) ?></strong></td>
<td><?php echo $stammdaten->titelpre ?></td>
</tr>
<?php endif; ?>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','vorname')) ?></strong></td>
<td><?php echo $stammdaten->vorname ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','nachname')) ?></strong></td>
<td>
<?php echo $stammdaten->nachname ?></td>
</tr>
<?php if (!empty($stammdaten->titelpost)): ?>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','titelpost')) ?></strong></td>
<td><?php echo $stammdaten->titelpost ?></td>
</tr>
<?php endif; ?>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','geburtsdatum')) ?></strong></td>
<td>
<?php echo date_format(date_create($stammdaten->gebdatum), 'd.m.Y') ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','svnr')) ?></strong></td>
<td>
<?php echo $stammdaten->svnr ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','ersatzkennzeichen')) ?></strong></td>
<td>
<?php echo $stammdaten->ersatzkennzeichen ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','staatsbuergerschaft')) ?></strong></td>
<td>
<?php echo $stammdaten->staatsbuergerschaft ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','geschlecht')) ?></strong></td>
<td>
<?php echo $stammdaten->geschlecht ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','bpk')) ?></strong></td>
<td>
<?php echo $stammdaten->bpk ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','postleitzahl')) ?></strong></td>
<td>
<?php echo $adresse->plz ?></td>
</tr>
<tr>
<td><strong><?php echo ucfirst($this->p->t('person','strasse')) ?></strong></td>
<td>
<?php echo $adresse->strasse ?></td>
</tr>
</table>
</div>
<div class="col-lg-4 table-responsive">
<form action="<?php echo base_url('soap/datenverbund_client.php?action=pruefeBPK');?>" method="POST" target="_blank">
<input type="hidden" name="vorname" value="<?php echo $stammdaten->vorname; ?>"/>
<input type="hidden" name="nachname" value="<?php echo $stammdaten->nachname; ?>"/>
<input type="hidden" name="geburtsdatum" value="<?php echo mb_str_replace('-','',$stammdaten->gebdatum); ?>"/>
<input type="hidden" name="geschlecht" value="<?php echo mb_strtoupper($stammdaten->geschlecht); ?>"/>
<input type="submit" value="Namenssuche starten" class="btn btn-default"/>
</form>
<br><br>
<form action="<?php echo site_url('person/BPKWartung/saveBPK');?>" method="POST">
<strong>bPK</strong><input type="text" name="bpk" value="" class="form-control"/>
<input type="hidden" name="person_id" value="<?php echo $stammdaten->person_id;?>"/>
<input type="submit" value="Speichern" class="btn btn-default"/>
</form>
</div>
</div> <!-- ./panel-body -->
</div> <!-- ./panel -->
</div> <!-- ./main column -->
</div> <!-- ./main row -->
</section>
</div> <!-- ./container-fluid-->
</div> <!-- ./page-wrapper-->
</div> <!-- ./wrapper -->
</body>
<?php $this->load->view('templates/FHC-Footer'); ?>
@@ -0,0 +1,51 @@
<?php
$this->load->view(
'templates/FHC-Header',
array(
'title' => 'bPK Wartung',
'jquery' => true,
'jqueryui' => true,
'bootstrap' => true,
'fontawesome' => true,
'sbadmintemplate' => true,
'tablesorter' => true,
'ajaxlib' => true,
'filterwidget' => true,
'navigationwidget' => true,
'phrases' => array(
'ui' => array('bitteEintragWaehlen')
),
'customCSSs' => 'public/css/sbadmin2/tablesort_bootstrap.css',
'customJSs' => array('public/js/bootstrapper.js')
)
);
?>
<body>
<div id="wrapper">
<?php echo $this->widgetlib->widget('NavigationWidget'); ?>
<div id="page-wrapper">
<div class="container-fluid">
<div class="row">
<div class="col-lg-12">
<h3 class="page-header">
bPK <?php echo ucfirst($this->p->t('global', 'uebersicht')); ?>
</h3>
</div>
</div>
<div>
Bei folgenden Personen mit Matrikelnummer konnte kein bPK ermittelt werden.
Es ist die Namensschreibweise zu prüfen und ggf zu korrigieren.
Falls die Person keine Meldeadresse hat, ist eine Eintragung der
Person in das "Ergänzungsregister für natürliche Personen" notwendig.
<br /><br />
<?php $this->load->view('person/bpk/bpkData.php'); ?>
</div>
</div>
</div>
</div>
</body>
<?php $this->load->view('templates/FHC-Footer'); ?>