Skip to content
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

Dev #53

Merged
merged 5 commits into from
Dec 13, 2024
Merged

Dev #53

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion classes/privacy/provider.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public static function get_metadata(collection $collection): collection {
'paygw_cryptocloud',
[
'invoiceid' => 'privacy:metadata:paygw_cryptocloud:invoiceid',
'courceid' => 'privacy:metadata:paygw_cryptocloud:courceid',
'courseid' => 'privacy:metadata:paygw_cryptocloud:courseid',
'groupnames' => 'privacy:metadata:paygw_cryptocloud:groupnames',
'success' => 'privacy:metadata:paygw_cryptocloud:success',
],
Expand Down
3 changes: 3 additions & 0 deletions lang/en/paygw_cryptocloud.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,6 @@
Please send me some <a href="https://yoomoney.ru/fundraise/143H2JO3LLE.240720">donate</a>😊</div>
<iframe src="https://yoomoney.ru/quickpay/fundraise/button?billNumber=143H2JO3LLE.240720"
width="330" height="50" frameborder="0" allowtransparency="true" scrolling="no"></iframe>';
$string['error_txdatabase'] = 'Error write TX data to database';
$string['error_notvalidtxid'] = 'FAIL. Not a valid transaction id';
$string['error_notvalidpayment'] = 'FAIL. Not a valid payment';
4 changes: 2 additions & 2 deletions return.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@
$id = required_param('order_id', PARAM_INT);

if (!$cryptocloudtx = $DB->get_record('paygw_cryptocloud', ['paymentid' => $id])) {
throw new Error('FAIL. Not a valid transaction id');
throw new \moodle_exception(get_string('error_notvalidtxid', 'paygw_cryptocloud'), 'paygw_cryptocloud');
}

if (!$payment = $DB->get_record('payments', ['id' => $cryptocloudtx->paymentid])) {
throw new Error('FAIL. Not a valid payment.');
throw new \moodle_exception(get_string('error_notvalidpayment', 'paygw_cryptocloud'), 'paygw_cryptocloud');
}

$paymentarea = $payment->paymentarea;
Expand Down
5 changes: 4 additions & 1 deletion settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,10 @@
defined('MOODLE_INTERNAL') || die();

if ($ADMIN->fulltree) {
$settings->add(new admin_setting_heading('paygw_cryptocloud_settings', '', get_string('pluginname_desc', 'paygw_cryptocloud')));
$plugininfo = \core_plugin_manager::instance()->get_plugin_info('paygw_cryptocloud');
$donate = get_string('donate', 'paygw_cryptocloud', $plugininfo);

$settings->add(new admin_setting_heading('paygw_cryptocloud_settings', $donate, get_string('pluginname_desc', 'paygw_cryptocloud')));

\core_payment\helper::add_common_gateway_settings($settings, 'paygw_cryptocloud');
}
4 changes: 2 additions & 2 deletions version.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@

defined('MOODLE_INTERNAL') || die();

$plugin->version = 2024111000;
$plugin->version = 2024121300;
$plugin->requires = 2023100900;
$plugin->component = 'paygw_cryptocloud';
$plugin->release = '0.15';
$plugin->release = '0.16';
$plugin->maturity = MATURITY_STABLE;
Loading