-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add qr code management #1046
base: develop
Are you sure you want to change the base?
Add qr code management #1046
Conversation
e723f9b
to
1440d1d
Compare
c45dd5e
to
18a6991
Compare
a62fc6f
to
29599e6
Compare
admin/qrcode.php
Outdated
@@ -0,0 +1,219 @@ | |||
<?php | |||
/* Copyright (C) 2021-2023 EVARISK |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2024
admin/qrcode.php
Outdated
/** | ||
* \file admin/redirections.php | ||
* \ingroup saturne | ||
* \brief Saturne redirections page |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
est-ce que j'aurais copié mon fichier et fais des erreurs ? ça m'étonnerait
admin/qrcode.php
Outdated
require_once DOL_DOCUMENT_ROOT . '/core/lib/files.lib.php'; | ||
require_once DOL_DOCUMENT_ROOT . '/includes/tecnickcom/tcpdf/tcpdf_barcodes_2d.php'; | ||
|
||
// Load Module libraries |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Saturne Libraries
admin/qrcode.php
Outdated
|
||
// Get parameters | ||
$action = GETPOST('action', 'alpha'); | ||
$url = GETPOST('url', 'alpha'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
psr12
admin/qrcode.php
Outdated
$saturneQRCode->url = $url; | ||
$saturneQRCode->encoded_qr_code = $saturneQRCode->getQRCodeBase64($url); | ||
$saturneQRCode->module_name = 'saturne'; | ||
$saturneQRCode->status = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
psr12
-- along with this program. If not, see https://www.gnu.org/licenses/. | ||
|
||
ALTER TABLE llx_saturne_qrcode ADD INDEX idx_saturne_object_qrcode_rowid (rowid); | ||
ALTER TABLE llx_saturne_qrcode ADD INDEX idx_saturne_object_qrcode_ref (ref); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
toujours pas de ref
|
||
ALTER TABLE llx_saturne_qrcode ADD INDEX idx_saturne_object_qrcode_rowid (rowid); | ||
ALTER TABLE llx_saturne_qrcode ADD INDEX idx_saturne_object_qrcode_ref (ref); | ||
ALTER TABLE llx_saturne_qrcode ADD INDEX idx_saturne_object_qrcode_status (status); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pas de status non plus
class/saturneqrcode.class.php
Outdated
'date_creation' => ['type' => 'datetime', 'label' => 'DateCreation', 'enabled' => 1, 'position' => 40, 'notnull' => 1, 'visible' => 0], | ||
'tms' => ['type' => 'timestamp', 'label' => 'DateModification', 'enabled' => 1, 'position' => 50, 'notnull' => 1, 'visible' => 0], | ||
'import_key' => ['type' => 'varchar(14)', 'label' => 'ImportId', 'enabled' => 1, 'position' => 60, 'notnull' => 0, 'visible' => 0, 'index' => 0], | ||
'status' => ['type' => 'smallint', 'label' => 'Status', 'enabled' => 1, 'position' => 70, 'notnull' => 1, 'visible' => 2, 'default' => 0, 'index' => 1, 'validate' => 1, 'arrayofkeyval' => [0 => 'StatusDraft', 1 => 'ValidatePendingSignature', 2 => 'Expired', 3 => 'Archived']], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mauvais arrayofkeyval + si tu hard delete pas besoin de status
sql/qrcode/llx_saturne_qrcode.sql
Outdated
date_creation datetime NOT NULL, | ||
tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
import_key varchar(14), | ||
status integer DEFAULT 1 NOT NULL, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Soit y'a un status mais il sert soit on l'enlève
sql/qrcode/llx_saturne_qrcode.sql
Outdated
@@ -0,0 +1,27 @@ | |||
-- Copyright (C) 2021-2023 EVARISK <[email protected]> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2024
No description provided.