Feature #288
Updated by Trịnh Thế Định about 1 year ago
<pre><code class="shell"> user_roles > > id integer autoincrement > > user_id integer > > role varchar(255) Enum [Affiliate admin, 'XXX'] > > status, is_aff_active > > created_at datetime > > updated_at datetime </code></pre> <pre><code class="sql"> aff_reward_histories > > id > > affiliate_user_id > > paid_amount biginteger > > receipt_image nullable > > rewarded_by integer ?? relate to user ? > > created_at datetime > > updated_at datetime </code></pre> <pre><code class="sql"> aff_reward_history_details > > id > > reward_history ?? relate to reward_histories > > affiliate_user_id > > invited_user_id invited_account_id > > reward_amount > > rewarded_by integer ?? relate to user ? > > created_at datetime > > updated_at datetime </code></pre> <pre><code class="sql"> aff_achievements id affiliate_user_id integer invited_account_id integer reward_amount biginteger reward_paid tinyint ??true/false created_at datetime updated_at datetime </code></pre> <pre><code class="shell"> aff_user_settings > > id > > affiliate_user_id > > invitation_code > > reward_percentage //set mặc định là 1 giá trị cài từ biến môi trường > > payment_info > > ... > > last_rewarded_at > > agree_tos tinyint > > created_at datetime > > updated_at datetime </code></pre>