Skip to content
GitLab
Erkunden
Anmelden
Registrieren
Primärnavigation
Suchen oder aufrufen …
Projekt
invoice
Verwalten
Aktivität
Mitglieder
Labels
Planen
Tickets
Ticketübersichten
Meilensteine
Wiki
Code
Merge Requests
Repository
Branch
Commits
Tags
Repository-Diagramm
Revisionen vergleichen
Build
Pipelines
Aufgaben
Pipeline-Zeitpläne
Artefakte
Bereitstellung
Releases
Modell-Registry
Betreiben
Umgebungen
Überwachen
Vorfälle
Service-Desk
Analysieren
Wertschöpfungskettenanalyse
Mitwirkenden-Analyse
CI/CD-Analyse
Repository-Analysen
Modellexperimente
Hilfe
Hilfe
Support
GitLab-Dokumentation
GitLab-Pläne vergleichen
Community-Forum
Zu GitLab beitragen
Feedback geben
Tastenkürzel
?
Code-Schnipsel
Gruppen
Projekte
Show more breadcrumbs
QUIQQER
invoice
Commits
a3a9b994
Commit
a3a9b994
erstellt
4 years ago
von
Henning Leutz
Dateien durchsuchen
Optionen
Downloads
Patches
Einfaches Diff
fix:
#63
Übergeordneter
cbc9d409
Keine zugehörigen Branchen gefunden
Keine zugehörigen Tags gefunden
Keine zugehörigen Merge Requests gefunden
Änderungen
2
Leerzeichenänderungen ausblenden
Inline
Nebeneinander
2 geänderte Dateien
src/QUI/ERP/Accounting/Invoice/Search/InvoiceSearch.php
+40
-8
40 Ergänzungen, 8 Löschungen
src/QUI/ERP/Accounting/Invoice/Search/InvoiceSearch.php
src/QUI/ERP/Accounting/Invoice/Settings.php
+18
-8
18 Ergänzungen, 8 Löschungen
src/QUI/ERP/Accounting/Invoice/Settings.php
werden angezeigt
mit
58 Ergänzungen
und
16 Löschungen
src/QUI/ERP/Accounting/Invoice/Search/InvoiceSearch.php
+
40
−
8
Zeige Datei @
a3a9b994
...
...
@@ -228,10 +228,13 @@ public function searchForGrid()
$this
->
cache
=
[];
// select display invoices
$invoices
=
$this
->
executeQueryParams
(
$this
->
getQuery
());
$query
=
$this
->
getQuery
();
$countQuery
=
$this
->
getQueryCount
();
$invoices
=
$this
->
executeQueryParams
(
$query
);
// count
$count
=
$this
->
executeQueryParams
(
$
this
->
getQueryCount
()
);
$count
=
$this
->
executeQueryParams
(
$
countQuery
);
$count
=
(
int
)
$count
[
0
][
'count'
];
...
...
@@ -407,7 +410,7 @@ protected function getQuery($count = false)
if
(
!
empty
(
$this
->
search
))
{
$where
[]
=
'(
id LIKE :search OR
id LIKE :search
Id
OR
customer_id LIKE :search OR
hash LIKE :search OR
global_process_id LIKE :search OR
...
...
@@ -438,6 +441,30 @@ protected function getQuery($count = false)
sum LIKE :search
)'
;
$prefix
=
Settings
::
getInstance
()
->
getInvoicePrefix
();
$tempPrefix
=
Settings
::
getInstance
()
->
getTemporaryInvoicePrefix
();
if
(
\strpos
(
$this
->
search
,
$prefix
)
===
0
)
{
$idSearch
=
\substr
(
$this
->
search
,
\strlen
(
$prefix
));
$binds
[
'searchId'
]
=
[
'value'
=>
$idSearch
.
'%'
,
'type'
=>
\PDO
::
PARAM_STR
];
}
elseif
(
\strpos
(
$this
->
search
,
$tempPrefix
)
===
0
)
{
$idSearch
=
\substr
(
$this
->
search
,
\strlen
(
$tempPrefix
));
$binds
[
'searchId'
]
=
[
'value'
=>
$idSearch
.
'%'
,
'type'
=>
\PDO
::
PARAM_STR
];
}
else
{
$binds
[
'searchId'
]
=
[
'value'
=>
'%'
.
$this
->
search
.
'%'
,
'type'
=>
\PDO
::
PARAM_STR
];
}
$binds
[
'search'
]
=
[
'value'
=>
'%'
.
$this
->
search
.
'%'
,
'type'
=>
\PDO
::
PARAM_STR
...
...
@@ -478,8 +505,10 @@ protected function getQuery($count = false)
* @return array
* @throws QUI\Exception
*/
protected
function
executeQueryParams
(
$queryData
=
[])
{
protected
function
executeQueryParams
(
$queryData
=
[]
)
{
$PDO
=
QUI
::
getDataBase
()
->
getPDO
();
$binds
=
$queryData
[
'binds'
];
$query
=
$queryData
[
'query'
];
...
...
@@ -508,8 +537,10 @@ protected function executeQueryParams($queryData = [])
*
* @throws QUI\Exception
*/
protected
function
parseListForGrid
(
$data
)
{
protected
function
parseListForGrid
(
$data
)
{
$Invoices
=
Handler
::
getInstance
();
$Locale
=
QUI
::
getLocale
();
$Payments
=
Payments
::
getInstance
();
...
...
@@ -744,7 +775,8 @@ protected function parseListForGrid($data)
/**
* @return array
*/
protected
function
getAllowedFields
()
protected
function
getAllowedFields
()
{
return
[
'id'
,
...
...
Dieser Diff ist reduziert.
Zum Erweitern klicken.
src/QUI/ERP/Accounting/Invoice/Settings.php
+
18
−
8
Zeige Datei @
a3a9b994
...
...
@@ -101,8 +101,6 @@ public function sendMailAtInvoiceCreation()
* eq: PREFIX-10022 (default = INV-)
*
* @return string
*
* @throws QUI\Exception
*/
public
function
getInvoicePrefix
()
{
...
...
@@ -110,8 +108,15 @@ public function getInvoicePrefix()
return
\strftime
(
$this
->
invoicePrefix
);
}
$Package
=
QUI
::
getPackage
(
'quiqqer/invoice'
);
$Config
=
$Package
->
getConfig
();
try
{
$Package
=
QUI
::
getPackage
(
'quiqqer/invoice'
);
$Config
=
$Package
->
getConfig
();
}
catch
(
QUI\Exception
$Exception
)
{
QUI\System\Log
::
writeException
(
$Exception
);
return
'INV-'
;
}
$setting
=
$Config
->
getValue
(
'invoice'
,
'prefix'
);
$this
->
invoicePrefix
=
'INV-'
;
...
...
@@ -128,8 +133,6 @@ public function getInvoicePrefix()
* eq: PREFIX-10022 (default = EDIT-)
*
* @return string
*
* @throws QUI\Exception
*/
public
function
getTemporaryInvoicePrefix
()
{
...
...
@@ -137,8 +140,15 @@ public function getTemporaryInvoicePrefix()
return
\strftime
(
$this
->
temporaryInvoicePrefix
);
}
$Package
=
QUI
::
getPackage
(
'quiqqer/invoice'
);
$Config
=
$Package
->
getConfig
();
try
{
$Package
=
QUI
::
getPackage
(
'quiqqer/invoice'
);
$Config
=
$Package
->
getConfig
();
}
catch
(
QUI\Exception
$Exception
)
{
QUI\System\Log
::
writeException
(
$Exception
);
return
'EDIT-'
;
}
$setting
=
$Config
->
getValue
(
'temporaryInvoice'
,
'prefix'
);
$this
->
temporaryInvoicePrefix
=
'EDIT-'
;
...
...
Dieser Diff ist reduziert.
Zum Erweitern klicken.
Vorschau
0%
Lade
Wiederholen
oder
Neue Datei anhängen
.
Abbrechen
You are about to add
0
people
to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Kommentar speichern
Abbrechen
Bitte
registrieren
oder
Anmelden
zum Kommentieren