Closed AlexTr closed 3 years ago
It would be better to update currently available Payments app that it can be used in two modes:
Some things to take into account:
Execute during the next update:
ALTER TABLE `bx_payment_subscriptions` ADD `status` varchar(32) NOT NULL default 'unpaid';
UPDATE `bx_payment_subscriptions` SET `status`='active' WHERE `paid` <> 0;
ALTER TABLE `bx_payment_subscriptions` DROP `paid`;
ALTER TABLE `bx_payment_subscriptions_deleted` ADD `status` varchar(32) NOT NULL default 'unpaid';
UPDATE `bx_payment_subscriptions_deleted` SET `status`='active' WHERE `paid` <> 0;
ALTER TABLE `bx_payment_subscriptions_deleted` DROP `paid`;
Add setting in payment module to enable "single transaction mode for multiple purchases from different vendors" (or it maybe it's better to implement it as separate Payment module instead of setting in existing module).
It has many benefits:
In this mode we need to pass vendor ID for every purchased product, so we'll be able to track whom item is sold. When vendor's product is purchases, vendor receives credits according to specified credits conversion rate. Later vendor can exchange received credits to real money using different exchange rate or using the same rate but with some commission deducted.
Master user payment tools need to be updated to include sub-vendor ID field. Vendors payment tools will have limited functionality in this mode, most tools should be read-only, however variant where vendor adds transaction without affecting any balance can be also considered.
Some things to take into account: