1 line
61 KiB
JavaScript
1 line
61 KiB
JavaScript
"use strict";(self["webpackChunkvue_antd_pro"]=self["webpackChunkvue_antd_pro"]||[]).push([[140],{2140:function(e,t,a){a.r(t),a.d(t,{default:function(){return v}});var i=function(){var e=this,t=e._self._c;return t("div",{staticClass:"profile-page",class:{"theme-dark":e.isDarkTheme}},[t("div",{staticClass:"page-header"},[t("h2",{staticClass:"page-title"},[t("a-icon",{attrs:{type:"user"}}),t("span",[e._v(e._s(e.$t("profile.title")||"My Profile"))])],1),t("p",{staticClass:"page-desc"},[e._v(e._s(e.$t("profile.description")||"Manage your account settings and preferences"))])]),t("a-row",{staticClass:"profile-cards-row",attrs:{gutter:24}},[t("a-col",{staticClass:"profile-card-col",attrs:{xs:24,md:8}},[t("a-card",{staticClass:"profile-card",attrs:{bordered:!1}},[t("div",{staticClass:"avatar-section"},[t("a-avatar",{attrs:{size:100,src:e.profile.avatar||"/avatar2.jpg"}}),t("h3",{staticClass:"username"},[e._v(e._s(e.profile.nickname||e.profile.username))]),t("p",{staticClass:"user-role"},[t("a-tag",{attrs:{color:e.getRoleColor(e.profile.role)}},[e._v(" "+e._s(e.getRoleLabel(e.profile.role))+" ")]),e.isVip?t("a-tag",{attrs:{color:"gold"}},[t("a-icon",{attrs:{type:"crown"}}),e._v(" VIP ")],1):e._e()],1)],1),t("a-divider"),t("div",{staticClass:"profile-info"},[t("div",{staticClass:"info-item"},[t("a-icon",{attrs:{type:"user"}}),t("span",{staticClass:"label"},[e._v(e._s(e.$t("profile.username")||"Username")+":")]),t("span",{staticClass:"value"},[e._v(e._s(e.profile.username))])],1),t("div",{staticClass:"info-item"},[t("a-icon",{attrs:{type:"mail"}}),t("span",{staticClass:"label"},[e._v(e._s(e.$t("profile.email")||"Email")+":")]),t("span",{staticClass:"value"},[e._v(e._s(e.profile.email||"-"))])],1),t("div",{staticClass:"info-item"},[t("a-icon",{attrs:{type:"calendar"}}),t("span",{staticClass:"label"},[e._v(e._s(e.$t("profile.lastLogin")||"Last Login")+":")]),t("span",{staticClass:"value"},[e._v(e._s(e.formatTime(e.profile.last_login_at)||"-"))])],1)])],1)],1),t("a-col",{staticClass:"right-cards-col",attrs:{xs:24,md:16}},[t("a-row",{staticClass:"right-cards-row",attrs:{gutter:16}},[t("a-col",{attrs:{xs:24,md:12}},[t("a-card",{staticClass:"credits-card",attrs:{bordered:!1}},[t("div",{staticClass:"credits-header"},[t("h3",{staticClass:"credits-title"},[t("a-icon",{attrs:{type:"wallet"}}),e._v(" "+e._s(e.$t("profile.credits.title")||"我的积分")+" ")],1)]),t("div",{staticClass:"credits-body"},[t("div",{staticClass:"credits-amount"},[t("span",{staticClass:"amount-value"},[e._v(e._s(e.formatCredits(e.billing.credits)))]),t("span",{staticClass:"amount-label"},[e._v(e._s(e.$t("profile.credits.unit")||"积分"))])]),e.billing.vip_expires_at?t("div",{staticClass:"vip-status"},[t("a-icon",{style:{color:e.isVip?"#faad14":"#999"},attrs:{type:"crown"}}),e.isVip?t("span",{staticClass:"vip-active"},[e._v(" "+e._s(e.$t("profile.credits.vipExpires")||"VIP有效期至")+": "+e._s(e.formatDate(e.billing.vip_expires_at))+" ")]):t("span",{staticClass:"vip-expired"},[e._v(" "+e._s(e.$t("profile.credits.vipExpired")||"VIP已过期")+" ")])],1):e.billing.is_vip?e._e():t("div",{staticClass:"vip-status"},[t("span",{staticClass:"no-vip"},[e._v(e._s(e.$t("profile.credits.noVip")||"非VIP用户"))])])]),t("a-divider"),t("div",{staticClass:"credits-actions"},[t("a-button",{attrs:{type:"primary",icon:"shopping"},on:{click:e.handleRecharge}},[e._v(" "+e._s(e.$t("profile.credits.recharge")||"开通/充值")+" ")])],1),e.billing.billing_enabled?t("div",{staticClass:"credits-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.credits.hint")||"使用AI分析/回测/监控等功能会消耗积分;VIP仅可免费使用VIP免费指标。"))])],1):e._e()],1)],1),t("a-col",{attrs:{xs:24,md:12}},[t("a-card",{staticClass:"referral-card",attrs:{bordered:!1}},[t("div",{staticClass:"referral-header"},[t("h3",{staticClass:"referral-title"},[t("a-icon",{attrs:{type:"team"}}),e._v(" "+e._s(e.$t("profile.referral.title")||"邀请好友")+" ")],1)]),t("div",{staticClass:"referral-body"},[t("div",{staticClass:"referral-stats"},[t("div",{staticClass:"stat-item"},[t("span",{staticClass:"stat-value"},[e._v(e._s(e.referralData.total||0))]),t("span",{staticClass:"stat-label"},[e._v(e._s(e.$t("profile.referral.totalInvited")||"已邀请"))])]),e.referralData.referral_bonus>0?t("div",{staticClass:"stat-item"},[t("span",{staticClass:"stat-value"},[e._v("+"+e._s(e.referralData.referral_bonus))]),t("span",{staticClass:"stat-label"},[e._v(e._s(e.$t("profile.referral.bonusPerInvite")||"每邀请获得"))])]):e._e()]),t("a-divider",{staticStyle:{margin:"12px 0"}}),t("div",{staticClass:"referral-link-section"},[t("div",{staticClass:"link-label"},[e._v(e._s(e.$t("profile.referral.yourLink")||"您的邀请链接"))]),t("div",{staticClass:"link-box"},[t("a-input",{attrs:{value:e.referralLink,readonly:"",size:"small"}},[t("a-tooltip",{attrs:{slot:"suffix",title:e.$t("profile.referral.copyLink")||"复制链接"},slot:"suffix"},[t("a-icon",{staticStyle:{cursor:"pointer"},attrs:{type:"copy"},on:{click:e.copyReferralLink}})],1)],1)],1)]),e.referralData.register_bonus>0?t("div",{staticClass:"referral-hint"},[t("a-icon",{attrs:{type:"gift"}}),t("span",[e._v(e._s(e.$t("profile.referral.newUserBonus")||"新用户注册获得")+" "+e._s(e.referralData.register_bonus)+" "+e._s(e.$t("profile.credits.unit")||"积分"))])],1):e._e()],1)])],1)],1)],1)],1),t("a-row",{staticStyle:{"margin-top":"24px"},attrs:{gutter:24}},[t("a-col",{attrs:{xs:24}},[t("a-card",{staticClass:"edit-card",attrs:{bordered:!1}},[t("a-tabs",{model:{value:e.activeTab,callback:function(t){e.activeTab=t},expression:"activeTab"}},[t("a-tab-pane",{key:"basic",attrs:{tab:e.$t("profile.basicInfo")||"Basic Info"}},[t("a-form",{staticClass:"profile-form",attrs:{form:e.profileForm,layout:"vertical"}},[t("a-form-item",{attrs:{label:e.$t("profile.nickname")||"Nickname"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["nickname",{initialValue:e.profile.nickname}],expression:"['nickname', { initialValue: profile.nickname }]"}],attrs:{placeholder:e.$t("profile.nicknamePlaceholder")||"Enter your nickname"}},[t("a-icon",{attrs:{slot:"prefix",type:"smile"},slot:"prefix"})],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.email")||"Email"}},[t("a-input",{attrs:{value:e.profile.email||"-",disabled:""}},[t("a-icon",{attrs:{slot:"prefix",type:"mail"},slot:"prefix"}),t("a-tooltip",{attrs:{slot:"suffix",title:e.$t("profile.emailCannotChange")||"Email cannot be changed after registration"},slot:"suffix"},[t("a-icon",{staticStyle:{color:"rgba(0,0,0,.45)"},attrs:{type:"info-circle"}})],1)],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.timezone")||"时区"}},[t("a-select",{directives:[{name:"decorator",rawName:"v-decorator",value:["timezone",{initialValue:e.profile.timezone||""}],expression:"['timezone', { initialValue: profile.timezone || '' }]"}],attrs:{placeholder:e.$t("profile.timezonePlaceholder")||"跟随浏览器/系统","show-search":"","allow-clear":"","option-filter-prop":"children"}},[t("a-select-option",{attrs:{value:""}},[e._v(" "+e._s(e.$t("profile.timezoneBrowser")||"跟随浏览器")+" ")]),e._l(e.timezoneIanaList,function(a){return t("a-select-option",{key:a,attrs:{value:a}},[e._v(" "+e._s(a)+" ")])})],2)],1),t("a-form-item",[t("a-button",{attrs:{type:"primary",loading:e.saving},on:{click:e.handleSaveProfile}},[t("a-icon",{attrs:{type:"save"}}),e._v(" "+e._s(e.$t("common.save")||"Save")+" ")],1)],1)],1)],1),t("a-tab-pane",{key:"password",attrs:{tab:e.$t("profile.changePassword")||"Change Password"}},[t("a-form",{staticClass:"password-form",attrs:{form:e.passwordForm,layout:"vertical"}},[t("a-alert",{staticStyle:{"margin-bottom":"24px"},attrs:{message:e.$t("profile.passwordHintNew")||"For security, email verification is required to change password. Password must be at least 8 characters with uppercase, lowercase, and number.",type:"info",showIcon:""}}),t("a-form-item",{attrs:{label:e.$t("profile.verificationCode")||"Verification Code"}},[t("a-row",{attrs:{gutter:12}},[t("a-col",{attrs:{span:16}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["code",{rules:[{required:!0,message:e.$t("profile.codeRequired")||"Please enter verification code"}]}],expression:"['code', {\n rules: [{ required: true, message: $t('profile.codeRequired') || 'Please enter verification code' }]\n }]"}],attrs:{placeholder:e.$t("profile.codePlaceholder")||"Enter verification code"}},[t("a-icon",{attrs:{slot:"prefix",type:"safety-certificate"},slot:"prefix"})],1)],1),t("a-col",{attrs:{span:8}},[t("a-button",{attrs:{block:"",loading:e.sendingPwdCode,disabled:e.sendingPwdCode||e.pwdCodeCountdown>0||!e.profile.email},on:{click:e.handleSendPwdCode}},[e._v(" "+e._s(e.pwdCodeCountdown>0?"".concat(e.pwdCodeCountdown,"s"):e.$t("profile.sendCode")||"Send Code")+" ")])],1)],1),e.profile.email?t("div",{staticClass:"email-hint"},[e._v(" "+e._s(e.$t("profile.codeWillSendTo")||"Code will be sent to")+": "+e._s(e.profile.email)+" ")]):t("div",{staticClass:"email-hint email-warning"},[e._v(" "+e._s(e.$t("profile.noEmailWarning")||"Please set your email first in Basic Info tab")+" ")])],1),t("a-form-item",{attrs:{label:e.$t("profile.newPassword")||"New Password"}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["new_password",{rules:[{required:!0,message:e.$t("profile.newPasswordRequired")||"Please enter new password"},{validator:e.validateNewPassword}]}],expression:"['new_password', {\n rules: [\n { required: true, message: $t('profile.newPasswordRequired') || 'Please enter new password' },\n { validator: validateNewPassword }\n ]\n }]"}],attrs:{placeholder:e.$t("profile.newPasswordPlaceholder")||"Enter new password"}},[t("a-icon",{attrs:{slot:"prefix",type:"lock"},slot:"prefix"})],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.confirmPassword")||"Confirm Password"}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["confirm_password",{rules:[{required:!0,message:e.$t("profile.confirmPasswordRequired")||"Please confirm password"},{validator:e.validateConfirmPassword}]}],expression:"['confirm_password', {\n rules: [\n { required: true, message: $t('profile.confirmPasswordRequired') || 'Please confirm password' },\n { validator: validateConfirmPassword }\n ]\n }]"}],attrs:{placeholder:e.$t("profile.confirmPasswordPlaceholder")||"Confirm new password"}},[t("a-icon",{attrs:{slot:"prefix",type:"lock"},slot:"prefix"})],1)],1),t("a-form-item",[t("a-button",{attrs:{type:"primary",loading:e.changingPassword,disabled:!e.profile.email},on:{click:e.handleChangePassword}},[t("a-icon",{attrs:{type:"key"}}),e._v(" "+e._s(e.$t("profile.changePassword")||"Change Password")+" ")],1)],1)],1)],1),t("a-tab-pane",{key:"credits",attrs:{tab:e.$t("profile.creditsLog")||"消费记录"}},[t("a-table",{attrs:{columns:e.creditsLogColumns,dataSource:e.creditsLog,loading:e.creditsLogLoading,pagination:e.creditsLogPagination,rowKey:function(e){return e.id},size:"small"},on:{change:e.handleCreditsLogChange},scopedSlots:e._u([{key:"action",fn:function(a){return[t("a-tag",{attrs:{color:e.getActionColor(a)}},[e._v(" "+e._s(e.getActionLabel(a))+" ")])]}},{key:"amount",fn:function(a){return[t("span",{class:a>=0?"amount-positive":"amount-negative"},[e._v(" "+e._s(a>=0?"+":"")+e._s(a)+" ")])]}},{key:"created_at",fn:function(t){return[e._v(" "+e._s(e.formatCreditsLogTime(t))+" ")]}}])})],1),t("a-tab-pane",{key:"notifications",attrs:{tab:e.$t("profile.notifications.title")||"通知设置"}},[t("div",{staticClass:"notification-settings-form"},[t("a-alert",{staticStyle:{"margin-bottom":"24px"},attrs:{message:e.$t("profile.notifications.hint")||"配置您的默认通知方式,在创建资产监控和预警时将自动使用这些设置",type:"info",showIcon:""}}),t("a-form",{staticStyle:{"max-width":"600px"},attrs:{form:e.notificationForm,layout:"vertical"}},[t("a-form-item",{attrs:{label:e.$t("profile.notifications.defaultChannels")||"默认通知渠道"}},[t("a-checkbox-group",{directives:[{name:"decorator",rawName:"v-decorator",value:["default_channels",{initialValue:e.notificationSettings.default_channels||["browser"]}],expression:"['default_channels', { initialValue: notificationSettings.default_channels || ['browser'] }]"}]},[t("a-row",{attrs:{gutter:16}},[t("a-col",{attrs:{span:8}},[t("a-checkbox",{attrs:{value:"browser"}},[t("a-icon",{attrs:{type:"bell"}}),e._v(" "+e._s(e.$t("profile.notifications.browser")||"站内通知")+" ")],1)],1),t("a-col",{attrs:{span:8}},[t("a-checkbox",{attrs:{value:"telegram"}},[t("a-icon",{attrs:{type:"send"}}),e._v(" Telegram ")],1)],1),t("a-col",{attrs:{span:8}},[t("a-checkbox",{attrs:{value:"email"}},[t("a-icon",{attrs:{type:"mail"}}),e._v(" "+e._s(e.$t("profile.notifications.email")||"邮件")+" ")],1)],1)],1),t("a-row",{staticStyle:{"margin-top":"8px"},attrs:{gutter:16}},[t("a-col",{attrs:{span:8}},[t("a-checkbox",{attrs:{value:"phone"}},[t("a-icon",{attrs:{type:"phone"}}),e._v(" "+e._s(e.$t("profile.notifications.phone")||"短信")+" ")],1)],1),t("a-col",{attrs:{span:8}},[t("a-checkbox",{attrs:{value:"discord"}},[t("a-icon",{attrs:{type:"message"}}),e._v(" Discord ")],1)],1),t("a-col",{attrs:{span:8}},[t("a-checkbox",{attrs:{value:"webhook"}},[t("a-icon",{attrs:{type:"api"}}),e._v(" Webhook ")],1)],1)],1)],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.telegramBotToken")||"Telegram Bot Token"}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["telegram_bot_token",{initialValue:e.notificationSettings.telegram_bot_token}],expression:"['telegram_bot_token', { initialValue: notificationSettings.telegram_bot_token }]"}],attrs:{placeholder:e.$t("profile.notifications.telegramBotTokenPlaceholder")||"请输入您的 Telegram Bot Token"}},[t("a-icon",{attrs:{slot:"prefix",type:"robot"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(" "+e._s(e.$t("profile.notifications.telegramBotTokenHint")||"通过 @BotFather 创建机器人获取 Token")+" "),t("a",{attrs:{href:"https://t.me/BotFather",target:"_blank",rel:"noopener noreferrer"}},[e._v("@BotFather")])])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.telegramChatId")||"Telegram Chat ID"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["telegram_chat_id",{initialValue:e.notificationSettings.telegram_chat_id}],expression:"['telegram_chat_id', { initialValue: notificationSettings.telegram_chat_id }]"}],attrs:{placeholder:e.$t("profile.notifications.telegramPlaceholder")||"请输入您的 Telegram Chat ID(如 123456789)"}},[t("a-icon",{attrs:{slot:"prefix",type:"message"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.notifications.telegramHint")||"发送 /start 给 @userinfobot 可获取您的 Chat ID"))])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.notifyEmail")||"通知邮箱"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["email",{initialValue:e.notificationSettings.email||e.profile.email}],expression:"['email', { initialValue: notificationSettings.email || profile.email }]"}],attrs:{placeholder:e.$t("profile.notifications.emailPlaceholder")||"接收通知的邮箱地址"}},[t("a-icon",{attrs:{slot:"prefix",type:"mail"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.notifications.emailHint")||"默认使用账户邮箱,可设置其他邮箱接收通知"))])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.phone")||"手机号(短信通知)"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["phone",{initialValue:e.notificationSettings.phone}],expression:"['phone', { initialValue: notificationSettings.phone }]"}],attrs:{placeholder:e.$t("profile.notifications.phonePlaceholder")||"请输入手机号(如 +8613800138000)"}},[t("a-icon",{attrs:{slot:"prefix",type:"phone"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.notifications.phoneHint")||"需要管理员配置 Twilio 服务后才能使用短信通知"))])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.discordWebhook")||"Discord Webhook"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["discord_webhook",{initialValue:e.notificationSettings.discord_webhook}],expression:"['discord_webhook', { initialValue: notificationSettings.discord_webhook }]"}],attrs:{placeholder:e.$t("profile.notifications.discordPlaceholder")||"https://discord.com/api/webhooks/..."}},[t("a-icon",{attrs:{slot:"prefix",type:"message"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.notifications.discordHint")||"在 Discord 服务器设置中创建 Webhook"))])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.webhookUrl")||"Webhook URL"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["webhook_url",{initialValue:e.notificationSettings.webhook_url}],expression:"['webhook_url', { initialValue: notificationSettings.webhook_url }]"}],attrs:{placeholder:e.$t("profile.notifications.webhookPlaceholder")||"https://your-server.com/webhook"}},[t("a-icon",{attrs:{slot:"prefix",type:"api"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.notifications.webhookHint")||"自定义 Webhook 地址,将以 POST JSON 方式推送通知"))])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.notifications.webhookToken")||"Webhook Token(可选)"}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["webhook_token",{initialValue:e.notificationSettings.webhook_token}],expression:"['webhook_token', { initialValue: notificationSettings.webhook_token }]"}],attrs:{placeholder:e.$t("profile.notifications.webhookTokenPlaceholder")||"用于验证请求的 Bearer Token"}},[t("a-icon",{attrs:{slot:"prefix",type:"key"},slot:"prefix"})],1),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.notifications.webhookTokenHint")||"将作为 Authorization: Bearer Token 发送到 Webhook"))])],1)],1),t("a-form-item",[t("a-button",{attrs:{type:"primary",loading:e.savingNotifications},on:{click:e.handleSaveNotifications}},[t("a-icon",{attrs:{type:"save"}}),e._v(" "+e._s(e.$t("common.save")||"保存")+" ")],1),t("a-button",{staticStyle:{"margin-left":"12px"},attrs:{loading:e.testingNotification},on:{click:e.handleTestNotification}},[t("a-icon",{attrs:{type:"experiment"}}),e._v(" "+e._s(e.$t("profile.notifications.testBtn")||"发送测试通知")+" ")],1)],1)],1)],1)]),t("a-tab-pane",{key:"exchange",attrs:{tab:e.$t("profile.exchange.title")||"交易所配置"}},[t("div",{staticClass:"exchange-config-section"},[t("a-alert",{staticStyle:{"margin-bottom":"16px"},attrs:{message:e.$t("profile.exchange.hint"),type:"info",showIcon:""}}),t("div",{staticStyle:{"margin-bottom":"16px","text-align":"right"}},[t("a-button",{staticStyle:{"margin-right":"12px"},on:{click:e.openExchangeSignupModal}},[t("a-icon",{attrs:{type:"rocket"}}),e._v(" "+e._s(e.$t("profile.exchange.openAccount"))+" ")],1),t("a-button",{attrs:{type:"primary",icon:"plus"},on:{click:e.openAddExchangeModal}},[e._v(" "+e._s(e.$t("profile.exchange.addAccount"))+" ")])],1),t("a-table",{attrs:{columns:e.exchangeColumns,dataSource:e.exchangeCredentials,loading:e.exchangeLoading,rowKey:function(e){return e.id},locale:{emptyText:e.$t("profile.exchange.noAccounts")||"暂无交易所账户,请点击上方按钮添加"},size:"small"},scopedSlots:e._u([{key:"exchange_id",fn:function(a,i){return[t("span",{staticStyle:{"text-transform":"capitalize","font-weight":"500"}},[e._v(e._s(e.getExchangeDisplayName(a)))]),i.enable_demo_trading?t("a-tag",{staticStyle:{"margin-left":"6px"},attrs:{color:"orange",size:"small"}},[e._v(" "+e._s(e.$t("profile.exchange.demoTag"))+" ")]):e._e()]}},{key:"api_key_hint",fn:function(a,i){return[t("span",{staticClass:"credential-hint"},[e._v(e._s(a||i.name||"-"))])]}},{key:"created_at",fn:function(t){return[e._v(" "+e._s(e.formatTime(t))+" ")]}},{key:"action",fn:function(a,i){return[t("a-popconfirm",{attrs:{title:e.$t("profile.exchange.deleteConfirm"),okText:e.$t("common.confirm"),cancelText:e.$t("common.cancel")},on:{confirm:function(t){return e.handleDeleteCredential(i.id)}}},[t("a-button",{attrs:{type:"danger",size:"small",ghost:"",icon:"delete"}},[e._v(" "+e._s(e.$t("common.delete"))+" ")])],1)]}}])})],1)]),t("a-tab-pane",{key:"referrals",attrs:{tab:e.$t("profile.referral.listTab")||"邀请列表"}},[t("a-table",{attrs:{columns:e.referralColumns,dataSource:e.referralData.list||[],loading:e.referralLoading,pagination:e.referralPagination,rowKey:function(e){return e.id},locale:{emptyText:e.$t("profile.referral.noReferrals")||"暂无邀请记录"},size:"small"},on:{change:e.handleReferralChange},scopedSlots:e._u([{key:"user",fn:function(a,i){return[t("div",{staticClass:"referral-user-cell"},[t("a-avatar",{attrs:{size:32,src:i.avatar||"/avatar2.jpg"}}),t("div",{staticClass:"user-info"},[t("span",{staticClass:"nickname"},[e._v(e._s(i.nickname||i.username))]),t("span",{staticClass:"username"},[e._v("@"+e._s(i.username))])])],1)]}},{key:"created_at",fn:function(t){return[e._v(" "+e._s(e.formatTime(t))+" ")]}}])})],1)],1)],1)],1)],1),t("a-modal",{attrs:{title:e.$t("profile.exchange.addTitle"),visible:e.showAddExchangeModal,"wrap-class-name":e.exchangeModalWrapClass,confirmLoading:e.savingExchange,okText:e.$t("common.save"),cancelText:e.$t("common.cancel"),maskClosable:!1,width:"520px"},on:{ok:e.handleSaveExchange,cancel:function(t){e.showAddExchangeModal=!1}}},[t("a-form",{staticClass:"exchange-account-form",attrs:{form:e.exchangeForm,layout:"vertical"}},[t("a-form-item",{attrs:{label:e.$t("profile.exchange.selectExchange")}},[t("a-select",{directives:[{name:"decorator",rawName:"v-decorator",value:["exchange_id",{rules:[{required:!0,message:e.$t("profile.exchange.selectExchange")}]}],expression:"['exchange_id', { rules: [{ required: true, message: $t('profile.exchange.selectExchange') }] }]"}],attrs:{placeholder:e.$t("profile.exchange.selectExchange"),"dropdown-class-name":e.isDarkTheme?"profile-exchange-select-dropdown-dark":"","get-popup-container":e.getExchangeSelectPopupContainer},on:{change:e.handleExchangeTypeChange}},[t("a-select-opt-group",{attrs:{label:e.$t("profile.exchange.typeCrypto")}},e._l(e.cryptoExchangeList,function(a){return t("a-select-option",{key:a.id,attrs:{value:a.id}},[e._v(" "+e._s(a.name)+" ")])}),1),t("a-select-opt-group",{attrs:{label:e.$t("profile.exchange.typeIBKR")}},[t("a-select-option",{attrs:{value:"ibkr"}},[e._v("Interactive Brokers (IBKR)")])],1),t("a-select-opt-group",{attrs:{label:e.$t("profile.exchange.typeMT5")}},[t("a-select-option",{attrs:{value:"mt5"}},[e._v("MetaTrader 5")])],1)],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.accountName")}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["name"],expression:"['name']"}],attrs:{placeholder:e.$t("profile.exchange.accountNamePlaceholder")}})],1),"crypto"===e.addExchangeType?t("a-form-item",{attrs:{label:e.$t("profile.exchange.whitelistIpLabel")}},[t("div",{staticClass:"egress-ip-block"},[e.egressIpLoading?t("a-spin",{attrs:{size:"small"}}):[t("div",{staticClass:"egress-ip-line"},[t("span",{staticClass:"egress-ip-kind"},[e._v(e._s(e.$t("profile.exchange.whitelistIpv4")))]),t("code",{staticClass:"egress-ip-value"},[e._v(e._s(e.egressServerIpv4||"—"))]),t("a-button",{staticClass:"egress-ip-action",attrs:{type:"link",size:"small",disabled:!e.egressServerIpv4},on:{click:function(t){return e.copyEgressIp("v4")}}},[e._v(" "+e._s(e.$t("profile.exchange.whitelistIpCopy"))+" ")])],1),t("div",{staticClass:"egress-ip-line"},[t("span",{staticClass:"egress-ip-kind"},[e._v(e._s(e.$t("profile.exchange.whitelistIpv6")))]),t("code",{staticClass:"egress-ip-value"},[e._v(e._s(e.egressServerIpv6||"—"))]),t("a-button",{staticClass:"egress-ip-action",attrs:{type:"link",size:"small",disabled:!e.egressServerIpv6},on:{click:function(t){return e.copyEgressIp("v6")}}},[e._v(" "+e._s(e.$t("profile.exchange.whitelistIpCopy"))+" ")])],1),t("div",{staticClass:"egress-ip-row egress-ip-refresh-row"},[t("a-button",{staticClass:"egress-ip-action",attrs:{type:"link",size:"small"},on:{click:e.fetchEgressIp}},[e._v(" "+e._s(e.$t("profile.exchange.whitelistIpRefresh"))+" ")])],1)]],2),t("div",{staticClass:"field-hint egress-ip-hint"},[e._v(e._s(e.$t("profile.exchange.whitelistIpHint")))])]):e._e(),"crypto"===e.addExchangeType?[e.selectedExchangeApiDocUrl?t("div",{staticClass:"exchange-api-doc-callout"},[t("div",{staticClass:"exchange-api-doc-callout__content"},[t("div",{staticClass:"exchange-api-doc-callout__icon"},[t("a-icon",{attrs:{type:"link"}})],1),t("div",{staticClass:"exchange-api-doc-callout__text"},[t("div",{staticClass:"exchange-api-doc-callout__title"},[e._v(" "+e._s(e.selectedCryptoExchangeName)+" "+e._s(e.$t("profile.exchange.apiDocTitleSuffix"))+" ")]),t("div",{staticClass:"exchange-api-doc-callout__hint"},[e._v(" "+e._s(e.$t("profile.exchange.apiDocHint"))+" ")])])]),t("a-button",{staticClass:"exchange-api-doc-callout__action",attrs:{type:"link",size:"small"},on:{click:e.openSelectedExchangeApiDoc}},[e._v(" "+e._s(e.$t("profile.exchange.apiDocAction"))+" "),t("a-icon",{attrs:{type:"arrow-right"}})],1)],1):e._e(),t("a-form-item",{attrs:{label:e.$t("profile.exchange.apiKey")}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["api_key",{rules:[{required:!0,message:"API Key is required"}]}],expression:"['api_key', { rules: [{ required: true, message: 'API Key is required' }] }]"}],attrs:{placeholder:"API Key",autocomplete:"new-password"}})],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.secretKey")}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["secret_key",{rules:[{required:!0,message:"Secret Key is required"}]}],expression:"['secret_key', { rules: [{ required: true, message: 'Secret Key is required' }] }]"}],attrs:{placeholder:"Secret Key",autocomplete:"new-password"}})],1),e.addExchangeNeedsPassphrase?t("a-form-item",{attrs:{label:e.$t("profile.exchange.passphrase")}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["passphrase"],expression:"['passphrase']"}],attrs:{placeholder:"Passphrase",autocomplete:"new-password"}})],1):e._e(),e.addExchangeShowDemo?t("a-form-item",[t("a-checkbox",{directives:[{name:"decorator",rawName:"v-decorator",value:["enable_demo_trading",{valuePropName:"checked",initialValue:!1}],expression:"['enable_demo_trading', { valuePropName: 'checked', initialValue: false }]"}],staticClass:"exchange-demo-checkbox"},[t("span",{staticClass:"exchange-demo-checkbox-label"},[e._v(e._s(e.$t("profile.exchange.demoTrading")))])]),t("div",{staticClass:"field-hint exchange-demo-hint"},[e._v(e._s(e.$t("profile.exchange.demoTradingHint")))])],1):e._e()]:e._e(),"ibkr"===e.addExchangeType?[t("a-alert",{staticStyle:{"margin-bottom":"16px"},attrs:{type:"warning",showIcon:"",message:e.$t("profile.exchange.localDeploymentRequired"),description:e.$t("profile.exchange.localDeploymentHint")}}),t("a-form-item",{attrs:{label:e.$t("profile.exchange.ibkrHost")}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["ibkr_host",{initialValue:"127.0.0.1"}],expression:"['ibkr_host', { initialValue: '127.0.0.1' }]"}],attrs:{placeholder:"127.0.0.1"}})],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.ibkrPort")}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["ibkr_port",{initialValue:7497}],expression:"['ibkr_port', { initialValue: 7497 }]"}],staticStyle:{width:"100%"},attrs:{min:1,max:65535}}),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.exchange.ibkrPortHint")))])],1)],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.ibkrClientId")}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["ibkr_client_id",{initialValue:1}],expression:"['ibkr_client_id', { initialValue: 1 }]"}],staticStyle:{width:"100%"},attrs:{min:1,max:999}})],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.ibkrAccount")}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["ibkr_account"],expression:"['ibkr_account']"}],attrs:{placeholder:"DU123456"}})],1)]:e._e(),"mt5"===e.addExchangeType?[t("a-alert",{staticStyle:{"margin-bottom":"16px"},attrs:{type:"warning",showIcon:"",message:e.$t("profile.exchange.localDeploymentRequired"),description:e.$t("profile.exchange.localDeploymentHint")}}),t("a-form-item",{attrs:{label:e.$t("profile.exchange.mt5Server")}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["mt5_server",{rules:[{required:!0,message:"Server is required"}]}],expression:"['mt5_server', { rules: [{ required: true, message: 'Server is required' }] }]"}],attrs:{placeholder:"MetaQuotes-Demo"}})],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.mt5Login")}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["mt5_login",{rules:[{required:!0,message:"Login is required"}]}],expression:"['mt5_login', { rules: [{ required: true, message: 'Login is required' }] }]"}],staticStyle:{width:"100%"},attrs:{min:1,placeholder:"12345678"}})],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.mt5Password")}},[t("a-input-password",{directives:[{name:"decorator",rawName:"v-decorator",value:["mt5_password",{rules:[{required:!0,message:"Password is required"}]}],expression:"['mt5_password', { rules: [{ required: true, message: 'Password is required' }] }]"}],attrs:{placeholder:"Password",autocomplete:"new-password"}})],1),t("a-form-item",{attrs:{label:e.$t("profile.exchange.mt5TerminalPath")}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["mt5_terminal_path"],expression:"['mt5_terminal_path']"}],attrs:{placeholder:"C:\\Program Files\\MetaTrader 5\\terminal64.exe"}}),t("div",{staticClass:"field-hint"},[t("a-icon",{attrs:{type:"info-circle"}}),t("span",[e._v(e._s(e.$t("profile.exchange.mt5TerminalPathHint")))])],1)],1)]:e._e(),e.addExchangeType?t("a-form-item",[t("a-button",{attrs:{block:"",loading:e.testingExchange},on:{click:e.handleTestExchangeConnection}},[t("a-icon",{attrs:{type:"api"}}),e._v(" "+e._s(e.$t("profile.exchange.testConnection"))+" ")],1),e.exchangeTestResult?t("div",{staticClass:"test-result-msg",class:e.exchangeTestResult.success?"success":"error"},[t("a-icon",{attrs:{type:e.exchangeTestResult.success?"check-circle":"close-circle"}}),e._v(" "+e._s(e.exchangeTestResult.message)+" ")],1):e._e()],1):e._e()],2)],1),t("a-modal",{attrs:{title:e.$t("profile.exchange.openAccountTitle"),visible:e.showExchangeSignupModal,"wrap-class-name":e.exchangeModalWrapClass,footer:null,width:"860px"},on:{cancel:function(t){e.showExchangeSignupModal=!1}}},[t("div",{staticClass:"exchange-signup-modal"},[t("div",{staticClass:"exchange-signup-promo"},[e._v(e._s(e.$t("profile.exchange.openAccountPromo")))]),t("div",{staticClass:"exchange-signup-grid"},e._l(e.exchangeSignupCards,function(a){return t("div",{key:a.id,staticClass:"exchange-signup-card"},[t("div",{staticClass:"exchange-signup-card__header"},[t("div",{staticClass:"exchange-signup-logo",style:{background:a.brandBg,color:a.brandColor}},[e._v(" "+e._s(a.short)+" ")]),t("div",{staticClass:"exchange-signup-meta"},[t("div",{staticClass:"exchange-signup-name"},[e._v(e._s(a.name))])])]),t("div",{staticClass:"exchange-signup-actions"},[t("a-button",{attrs:{type:"primary",block:"",disabled:!a.signupUrl},on:{click:function(t){return e.openExchangeSignupLink(a.signupUrl)}}},[e._v(" "+e._s(e.$t("profile.exchange.openAccountButton"))+" ")])],1)])}),0)])])],1)},r=[],n=a(76338),o=a(81127),s=a(56252),c=(a(74423),a(84841)),l=a(53003),d=a(42430),p=a(36911),u=a(55434),f={name:"Profile",mixins:[u.t],data:function(){return{loading:!1,saving:!1,changingPassword:!1,sendingPwdCode:!1,pwdCodeCountdown:0,pwdCodeTimer:null,activeTab:"basic",profile:{id:null,username:"",nickname:"",email:"",avatar:"",timezone:"",role:"user",last_login_at:null},timezoneIanaList:["UTC","Etc/UTC","Asia/Shanghai","Asia/Hong_Kong","Asia/Taipei","Asia/Tokyo","Asia/Seoul","Asia/Singapore","Asia/Dubai","Asia/Kolkata","Europe/London","Europe/Paris","Europe/Berlin","America/New_York","America/Chicago","America/Denver","America/Los_Angeles","America/Toronto","America/Sao_Paulo","Australia/Sydney","Pacific/Auckland"],creditsLog:[],creditsLogLoading:!1,creditsLogPagination:{current:1,pageSize:10,total:0},referralData:{list:[],total:0,referral_code:"",referral_bonus:0,register_bonus:0},referralLoading:!1,referralPagination:{current:1,pageSize:10,total:0},billing:{credits:0,is_vip:!1,vip_expires_at:null,billing_enabled:!1,feature_costs:{}},rechargeTelegramUrl:"https://t.me/your_support_bot",notificationSettings:{default_channels:["browser"],telegram_bot_token:"",telegram_chat_id:"",email:"",phone:"",discord_webhook:"",webhook_url:"",webhook_token:""},savingNotifications:!1,testingNotification:!1,exchangeCredentials:[],exchangeLoading:!1,showAddExchangeModal:!1,showExchangeSignupModal:!1,savingExchange:!1,testingExchange:!1,exchangeTestResult:null,addExchangeType:"",selectedExchangeId:"",egressServerIpv4:"",egressServerIpv6:"",egressIpLoading:!1,cryptoExchangeList:[{id:"binance",name:"Binance",docsUrl:"https://www.binance.com/en/support/faq/api-faq-360027369792"},{id:"okx",name:"OKX",docsUrl:"https://www.okx.com/help/how-do-i-create-my-api-key"},{id:"bitget",name:"Bitget",docsUrl:"https://www.bitget.com/api-doc/common/introduction"},{id:"bybit",name:"Bybit",docsUrl:"https://www.bybit.com/en/help-center/article/How-to-create-your-API-key/"},{id:"coinbaseexchange",name:"Coinbase",docsUrl:"https://docs.cdp.coinbase.com/exchange/rest-api/authentication"},{id:"kraken",name:"Kraken",docsUrl:"https://support.kraken.com/articles/360000919966-how-to-create-an-api-key"},{id:"kucoin",name:"KuCoin",docsUrl:"https://www.kucoin.com/docs-new/authentication"},{id:"gate",name:"Gate.io",docsUrl:"https://www.gate.com/docs/developers/apiv4/"},{id:"bitfinex",name:"Bitfinex",docsUrl:"https://docs.bitfinex.com/docs/create-an-api-key"},{id:"deepcoin",name:"Deepcoin",docsUrl:"https://www.deepcoin.com/docs/deepcoinApiDocs/"},{id:"htx",name:"HTX",docsUrl:"https://www.htx.com/support/en-us/detail/360000188081"}],exchangeSignupCards:[{id:"binance",name:"Binance",short:"BN",brandBg:"rgba(243, 186, 47, 0.16)",brandColor:"#f0b90b",signupUrl:"https://www.bsmkweb.cc/register?ref=QUANTDINGER"},{id:"bitget",name:"Bitget",short:"BG",brandBg:"rgba(0, 193, 255, 0.14)",brandColor:"#00c1ff",signupUrl:"https://partner.hdmune.cn/bg/7r4xz8kd"},{id:"bybit",name:"Bybit",short:"BY",brandBg:"rgba(247, 166, 0, 0.14)",brandColor:"#f7a600",signupUrl:"https://partner.bybit.com/b/DINGER"},{id:"okx",name:"OKX",short:"OK",brandBg:"rgba(17, 24, 39, 0.08)",brandColor:"#111827",signupUrl:"https://www.xqmnobxky.com/join/QUANTDINGER"},{id:"gate",name:"Gate.io",short:"GT",brandBg:"rgba(42, 93, 255, 0.12)",brandColor:"#2a5dff",signupUrl:"https://www.gateport.company/share/DINGER"},{id:"htx",name:"HTX",short:"HX",brandBg:"rgba(22, 119, 255, 0.12)",brandColor:"#1677ff",signupUrl:"https://www.htx.com/invite/zh-cn/1f?invite_code=dinger"}]}},computed:{isDarkTheme:function(){return"dark"===this.navTheme||"realdark"===this.navTheme},exchangeModalWrapClass:function(){var e="profile-exchange-modal";return this.isDarkTheme?"".concat(e," ").concat(e,"--dark"):e},isVip:function(){if(!this.billing.vip_expires_at)return!1;var e=new Date(this.billing.vip_expires_at);return e>new Date},creditsLogColumns:function(){return[{title:this.$t("profile.creditsLog.time")||"时间",dataIndex:"created_at",width:160,scopedSlots:{customRender:"created_at"}},{title:this.$t("profile.creditsLog.action")||"类型",dataIndex:"action",width:100,scopedSlots:{customRender:"action"}},{title:this.$t("profile.creditsLog.amount")||"变动",dataIndex:"amount",width:100,scopedSlots:{customRender:"amount"}},{title:this.$t("profile.creditsLog.balance")||"余额",dataIndex:"balance_after",width:100},{title:this.$t("profile.creditsLog.remark")||"备注",dataIndex:"remark",ellipsis:!0}]},referralColumns:function(){return[{title:this.$t("profile.referral.user")||"用户",dataIndex:"username",scopedSlots:{customRender:"user"}},{title:this.$t("profile.referral.registerTime")||"注册时间",dataIndex:"created_at",width:180,scopedSlots:{customRender:"created_at"}}]},referralLink:function(){var e=window.location.origin+window.location.pathname,t=this.referralData.referral_code||this.profile.id;return"".concat(e,"#/user/login?ref=").concat(t)},exchangeColumns:function(){return[{title:this.$t("profile.exchange.colExchange")||"Exchange",dataIndex:"exchange_id",width:140,scopedSlots:{customRender:"exchange_id"}},{title:this.$t("profile.exchange.colName")||"Name",dataIndex:"name",width:140,customRender:function(e){return e||"-"}},{title:this.$t("profile.exchange.colHint")||"Connection Info",dataIndex:"api_key_hint",scopedSlots:{customRender:"api_key_hint"}},{title:this.$t("profile.exchange.colCreatedAt")||"Created At",dataIndex:"created_at",width:180,scopedSlots:{customRender:"created_at"}},{title:this.$t("profile.exchange.colActions")||"Actions",width:120,scopedSlots:{customRender:"action"}}]},addExchangeNeedsPassphrase:function(){var e=["okx","bitget","kucoin"];return e.includes(this.selectedExchangeId)},addExchangeShowDemo:function(){return"crypto"===this.addExchangeType&&!!this.selectedExchangeId},selectedCryptoExchangeMeta:function(){var e=this;return this.cryptoExchangeList.find(function(t){return t.id===e.selectedExchangeId})||null},selectedCryptoExchangeName:function(){return this.selectedCryptoExchangeMeta?this.selectedCryptoExchangeMeta.name:this.getExchangeDisplayName(this.selectedExchangeId)},selectedExchangeApiDocUrl:function(){return this.selectedCryptoExchangeMeta?this.selectedCryptoExchangeMeta.docsUrl:""}},watch:{showAddExchangeModal:function(e){e&&this.fetchEgressIp()},activeTab:function(e){"credits"===e&&0===this.creditsLog.length&&this.loadCreditsLog(),"referrals"!==e||this.referralData.list&&0!==this.referralData.list.length||this.loadReferrals(),"notifications"!==e||this.notificationSettings.telegram_chat_id||this.notificationSettings.discord_webhook||this.loadNotificationSettings(),"exchange"===e&&0===this.exchangeCredentials.length&&this.loadExchangeCredentials()}},beforeCreate:function(){this.profileForm=this.$form.createForm(this,{name:"profile"}),this.passwordForm=this.$form.createForm(this,{name:"password"}),this.notificationForm=this.$form.createForm(this,{name:"notification"}),this.exchangeForm=this.$form.createForm(this,{name:"exchange"})},mounted:function(){this.loadProfile(),this.loadReferrals()},beforeDestroy:function(){this.pwdCodeTimer&&clearInterval(this.pwdCodeTimer)},methods:{loadProfile:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:return e.loading=!0,t.p=1,t.n=2,(0,c.E$)();case 2:a=t.v,1===a.code?(e.profile=a.data,a.data.billing&&(e.billing=a.data.billing),a.data.notification_settings&&(e.notificationSettings={default_channels:a.data.notification_settings.default_channels||["browser"],telegram_bot_token:a.data.notification_settings.telegram_bot_token||"",telegram_chat_id:a.data.notification_settings.telegram_chat_id||"",email:a.data.notification_settings.email||a.data.email||"",phone:a.data.notification_settings.phone||"",discord_webhook:a.data.notification_settings.discord_webhook||"",webhook_url:a.data.notification_settings.webhook_url||"",webhook_token:a.data.notification_settings.webhook_token||""}),e.$nextTick(function(){e.profileForm.setFieldsValue({nickname:e.profile.nickname,email:e.profile.email,timezone:e.profile.timezone||""})})):e.$message.error(a.msg||"Failed to load profile"),t.n=4;break;case 3:t.p=3,t.v,e.$message.error("Failed to load profile");case 4:return t.p=4,e.loading=!1,t.f(4);case 5:return t.a(2)}},t,null,[[1,3,4,5]])}))()},loadRechargeUrl:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if("admin"!==e.profile.role){t.n=4;break}return t.p=1,t.n=2,(0,l.YT)();case 2:a=t.v,1===a.code&&a.data&&a.data.billing&&(e.rechargeTelegramUrl=a.data.billing.RECHARGE_TELEGRAM_URL||e.rechargeTelegramUrl),t.n=4;break;case 3:t.p=3,t.v;case 4:return t.a(2)}},t,null,[[1,3]])}))()},handleRecharge:function(){this.$router.push("/billing")},formatCredits:function(e){return e||0===e?Number(e).toLocaleString("en-US",{minimumFractionDigits:0,maximumFractionDigits:2}):"0"},formatDate:function(e){if(!e)return"";var t=new Date(e);return t.toLocaleDateString()},handleSaveProfile:function(){var e=this;this.profileForm.validateFields(function(){var t=(0,s.A)((0,o.A)().m(function t(a,i){var r;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(!a){t.n=1;break}return t.a(2);case 1:return e.saving=!0,t.p=2,t.n=3,(0,c.r7)({nickname:i.nickname,timezone:null!=i.timezone?i.timezone:""});case 3:r=t.v,1===r.code?(e.$message.success(r.msg||"Profile updated successfully"),e.loadProfile(),e.$store.dispatch("FetchUserInfo").catch(function(){})):e.$message.error(r.msg||"Update failed"),t.n=5;break;case 4:t.p=4,t.v,e.$message.error("Update failed");case 5:return t.p=5,e.saving=!1,t.f(5);case 6:return t.a(2)}},t,null,[[2,4,5,6]])}));return function(e,a){return t.apply(this,arguments)}}())},validateConfirmPassword:function(e,t,a){var i=this.passwordForm.getFieldValue("new_password");t&&t!==i?a(this.$t("profile.passwordMismatch")||"Passwords do not match"):a()},handleSendPwdCode:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var i,r,n,s,c;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(e.profile.email){t.n=1;break}return e.$message.error(e.$t("profile.noEmailWarning")||"Please set your email first"),t.a(2);case 1:return e.sendingPwdCode=!0,t.p=2,t.n=3,a.e(824).then(a.bind(a,95824));case 3:return i=t.v,r=i.sendVerificationCode,t.n=4,r({email:e.profile.email,type:"change_password"});case 4:n=t.v,1===n.code?(e.$message.success(e.$t("profile.codeSent")||"Verification code sent"),e.startPwdCodeCountdown()):e.$message.error(n.msg||"Failed to send code"),t.n=6;break;case 5:t.p=5,c=t.v,e.$message.error((null===(s=c.response)||void 0===s||null===(s=s.data)||void 0===s?void 0:s.msg)||"Failed to send code");case 6:return t.p=6,e.sendingPwdCode=!1,t.f(6);case 7:return t.a(2)}},t,null,[[2,5,6,7]])}))()},startPwdCodeCountdown:function(){var e=this;this.pwdCodeCountdown=60,this.pwdCodeTimer=setInterval(function(){e.pwdCodeCountdown--,e.pwdCodeCountdown<=0&&(clearInterval(e.pwdCodeTimer),e.pwdCodeTimer=null)},1e3)},validateNewPassword:function(e,t,a){t?t.length<8?a(new Error(this.$t("user.register.pwdMinLength")||"At least 8 characters")):/[A-Z]/.test(t)?/[a-z]/.test(t)?/[0-9]/.test(t)?a():a(new Error(this.$t("user.register.pwdNumber")||"At least one number")):a(new Error(this.$t("user.register.pwdLowercase")||"At least one lowercase letter")):a(new Error(this.$t("user.register.pwdUppercase")||"At least one uppercase letter")):a()},handleChangePassword:function(){var e=this;this.passwordForm.validateFields(function(){var t=(0,s.A)((0,o.A)().m(function t(i,r){var n,s,c,l,d;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(!i){t.n=1;break}return t.a(2);case 1:return e.changingPassword=!0,t.p=2,t.n=3,a.e(824).then(a.bind(a,95824));case 3:return n=t.v,s=n.changePassword,t.n=4,s({code:r.code,new_password:r.new_password});case 4:c=t.v,1===c.code?(e.$message.success(c.msg||"Password changed successfully"),e.passwordForm.resetFields()):e.$message.error(c.msg||"Change password failed"),t.n=6;break;case 5:t.p=5,d=t.v,e.$message.error((null===(l=d.response)||void 0===l||null===(l=l.data)||void 0===l?void 0:l.msg)||"Change password failed");case 6:return t.p=6,e.changingPassword=!1,t.f(6);case 7:return t.a(2)}},t,null,[[2,5,6,7]])}));return function(e,a){return t.apply(this,arguments)}}())},getRoleColor:function(e){var t={admin:"red",manager:"orange",user:"blue",viewer:"default"};return t[e]||"default"},getRoleLabel:function(e){var t={admin:this.$t("userManage.roleAdmin")||"Admin",manager:this.$t("userManage.roleManager")||"Manager",user:this.$t("userManage.roleUser")||"User",viewer:this.$t("userManage.roleViewer")||"Viewer"};return t[e]||e},_profileDateTimeLocaleOptions:function(){var e=String(this.profile&&this.profile.timezone||"").trim();if(!e)return{};try{return Intl.DateTimeFormat(void 0,{timeZone:e}).format(new Date),{timeZone:e}}catch(t){return{}}},formatTime:function(e){if(!e)return"";var t=new Date("number"===typeof e?1e3*e:e);return Number.isNaN(t.getTime())?"":t.toLocaleString(void 0,this._profileDateTimeLocaleOptions())},formatCreditsLogTime:function(e){if(!e)return"";if("string"===typeof e){var t=e.trim();if(t.endsWith("Z")&&t.includes("T"))return t.replace("T"," ").replace("Z","")}return this.formatTime(e)},loadCreditsLog:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:return e.creditsLogLoading=!0,t.p=1,t.n=2,(0,c.v9)({page:e.creditsLogPagination.current,page_size:e.creditsLogPagination.pageSize});case 2:a=t.v,1===a.code&&(e.creditsLog=a.data.items||[],e.creditsLogPagination.total=a.data.total||0),t.n=4;break;case 3:t.p=3,t.v,e.$message.error("Failed to load credits log");case 4:return t.p=4,e.creditsLogLoading=!1,t.f(4);case 5:return t.a(2)}},t,null,[[1,3,4,5]])}))()},handleCreditsLogChange:function(e){this.creditsLogPagination.current=e.current,this.loadCreditsLog()},loadReferrals:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:return e.referralLoading=!0,t.p=1,t.n=2,(0,c.rx)({page:e.referralPagination.current,page_size:e.referralPagination.pageSize});case 2:a=t.v,1===a.code&&(e.referralData={list:a.data.list||[],total:a.data.total||0,referral_code:a.data.referral_code||"",referral_bonus:a.data.referral_bonus||0,register_bonus:a.data.register_bonus||0},e.referralPagination.total=a.data.total||0),t.n=4;break;case 3:t.p=3,t.v,e.$message.error("Failed to load referral data");case 4:return t.p=4,e.referralLoading=!1,t.f(4);case 5:return t.a(2)}},t,null,[[1,3,4,5]])}))()},handleReferralChange:function(e){this.referralPagination.current=e.current,this.loadReferrals()},copyReferralLink:function(){var e=this,t=this.referralLink;navigator.clipboard?navigator.clipboard.writeText(t).then(function(){e.$message.success(e.$t("profile.referral.linkCopied")||"邀请链接已复制")}).catch(function(){e.fallbackCopy(t)}):this.fallbackCopy(t)},fallbackCopy:function(e){var t=document.createElement("textarea");t.value=e,document.body.appendChild(t),t.select();try{document.execCommand("copy"),this.$message.success(this.$t("profile.referral.linkCopied")||"邀请链接已复制")}catch(a){this.$message.error("Copy failed")}document.body.removeChild(t)},getActionColor:function(e){var t={consume:"red",recharge:"green",admin_adjust:"blue",refund:"orange",vip_grant:"gold",vip_revoke:"default",register_bonus:"cyan",referral_bonus:"purple",indicator_purchase:"volcano",indicator_sale:"lime"};return t[e]||"default"},getActionLabel:function(e){var t={consume:this.$t("profile.creditsLog.actionConsume")||"消费",recharge:this.$t("profile.creditsLog.actionRecharge")||"充值",admin_adjust:this.$t("profile.creditsLog.actionAdjust")||"调整",refund:this.$t("profile.creditsLog.actionRefund")||"退款",vip_grant:this.$t("profile.creditsLog.actionVipGrant")||"VIP授予",vip_revoke:this.$t("profile.creditsLog.actionVipRevoke")||"VIP取消",register_bonus:this.$t("profile.creditsLog.actionRegisterBonus")||"注册奖励",referral_bonus:this.$t("profile.creditsLog.actionReferralBonus")||"邀请奖励",indicator_purchase:this.$t("profile.creditsLog.actionIndicatorPurchase")||"购买指标",indicator_sale:this.$t("profile.creditsLog.actionIndicatorSale")||"出售指标"};return t[e]||e},loadExchangeCredentials:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:return e.exchangeLoading=!0,t.p=1,t.n=2,(0,d.IA)();case 2:a=t.v,1===a.code&&a.data&&(e.exchangeCredentials=a.data.items||[]),t.n=4;break;case 3:t.p=3,t.v,e.$message.error("Failed to load exchange accounts");case 4:return t.p=4,e.exchangeLoading=!1,t.f(4);case 5:return t.a(2)}},t,null,[[1,3,4,5]])}))()},getExchangeSelectPopupContainer:function(){return document.body},openAddExchangeModal:function(){this.showAddExchangeModal=!0},openExchangeSignupModal:function(){this.showExchangeSignupModal=!0},openExternalLink:function(e){e&&window.open(e,"_blank")},openExchangeSignupLink:function(e){this.openExternalLink(e)},openSelectedExchangeApiDoc:function(){this.openExternalLink(this.selectedExchangeApiDocUrl)},fetchEgressIp:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a,i,r,n;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:return e.egressIpLoading=!0,e.egressServerIpv4="",e.egressServerIpv6="",t.p=1,t.n=2,(0,d.N6)();case 2:a=t.v,1===a.code&&a.data&&(i=null!=a.data.ipv4?String(a.data.ipv4).trim():"",r=null!=a.data.ipv6?String(a.data.ipv6).trim():"",e.egressServerIpv4=i,e.egressServerIpv6=r,i||r||!a.data.ip||(n=String(a.data.ip).trim(),n.includes(":")?e.egressServerIpv6=n:e.egressServerIpv4=n)),t.n=4;break;case 3:t.p=3,t.v,e.egressServerIpv4="",e.egressServerIpv6="";case 4:return t.p=4,e.egressIpLoading=!1,t.f(4);case 5:return t.a(2)}},t,null,[[1,3,4,5]])}))()},copyEgressIp:function(e){var t=this,a="v6"===e?this.egressServerIpv6:this.egressServerIpv4;if(a){var i=function(){return t.$message.success(t.$t("profile.exchange.whitelistIpCopied"))};navigator.clipboard&&navigator.clipboard.writeText?navigator.clipboard.writeText(a).then(i).catch(function(){return t._fallbackCopyText(a,i)}):this._fallbackCopyText(a,i)}},_fallbackCopyText:function(e,t){try{var a=document.createElement("textarea");a.value=e,a.style.position="fixed",a.style.left="-9999px",document.body.appendChild(a),a.select(),document.execCommand("copy"),document.body.removeChild(a),t&&t()}catch(i){this.$message.error(this.$t("profile.exchange.whitelistIpCopyFail"))}},handleExchangeTypeChange:function(e){this.selectedExchangeId=e,this.exchangeTestResult=null;var t=this.cryptoExchangeList.map(function(e){return e.id});t.includes(e)?this.addExchangeType="crypto":this.addExchangeType="ibkr"===e?"ibkr":"mt5"===e?"mt5":""},getExchangeDisplayName:function(e){var t={binance:"Binance",okx:"OKX",bitget:"Bitget",bybit:"Bybit",coinbaseexchange:"Coinbase",kraken:"Kraken",kucoin:"KuCoin",gate:"Gate.io",bitfinex:"Bitfinex",deepcoin:"Deepcoin",htx:"HTX",ibkr:"IBKR",mt5:"MetaTrader 5"};return t[e]||e},handleSaveExchange:function(){var e=this;this.exchangeForm.validateFields(function(){var t=(0,s.A)((0,o.A)().m(function t(a,i){var r,s,c;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(!a){t.n=1;break}return t.a(2);case 1:return e.savingExchange=!0,t.p=2,r=(0,n.A)({},i),t.n=3,(0,d.PR)(r);case 3:s=t.v,1===s.code?(e.$message.success(e.$t("profile.exchange.saveSuccess")),e.showAddExchangeModal=!1,e.exchangeForm.resetFields(),e.addExchangeType="",e.selectedExchangeId="",e.exchangeTestResult=null,e.loadExchangeCredentials()):e.$message.error(s.msg||e.$t("profile.exchange.saveFailed")),t.n=5;break;case 4:t.p=4,c=t.v,e.$message.error(c.message||e.$t("profile.exchange.saveFailed"));case 5:return t.p=5,e.savingExchange=!1,t.f(5);case 6:return t.a(2)}},t,null,[[2,4,5,6]])}));return function(e,a){return t.apply(this,arguments)}}())},handleDeleteCredential:function(e){var t=this;return(0,s.A)((0,o.A)().m(function a(){var i;return(0,o.A)().w(function(a){while(1)switch(a.p=a.n){case 0:return a.p=0,a.n=1,(0,d.kI)(e);case 1:i=a.v,1===i.code?(t.$message.success(t.$t("profile.exchange.deleteSuccess")),t.loadExchangeCredentials()):t.$message.error(i.msg||"Delete failed"),a.n=3;break;case 2:a.p=2,a.v,t.$message.error("Delete failed");case 3:return a.a(2)}},a,null,[[0,2]])}))()},handleTestExchangeConnection:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a,i,r,s,c;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(a=e.exchangeForm.getFieldsValue(),i=a.exchange_id,i){t.n=1;break}return t.a(2);case 1:return e.testingExchange=!0,e.exchangeTestResult=null,t.p=2,r=(0,n.A)({},a),t.n=3,(0,p.kv)(r);case 3:s=t.v,1===s.code?e.exchangeTestResult={success:!0,message:e.$t("profile.exchange.testSuccess")}:e.exchangeTestResult={success:!1,message:"".concat(e.$t("profile.exchange.testFailed"),": ").concat(s.msg||"Unknown error")},t.n=5;break;case 4:t.p=4,c=t.v,e.exchangeTestResult={success:!1,message:"".concat(e.$t("profile.exchange.testFailed"),": ").concat(c.message||"Network error")};case 5:return t.p=5,e.testingExchange=!1,t.f(5);case 6:return t.a(2)}},t,null,[[2,4,5,6]])}))()},loadNotificationSettings:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:return t.p=0,t.n=1,(0,c.vF)();case 1:a=t.v,1===a.code&&a.data&&(e.notificationSettings={default_channels:a.data.default_channels||["browser"],telegram_bot_token:a.data.telegram_bot_token||"",telegram_chat_id:a.data.telegram_chat_id||"",email:a.data.email||e.profile.email||"",phone:a.data.phone||"",discord_webhook:a.data.discord_webhook||"",webhook_url:a.data.webhook_url||"",webhook_token:a.data.webhook_token||""},e.$nextTick(function(){e.notificationForm.setFieldsValue({default_channels:e.notificationSettings.default_channels,telegram_bot_token:e.notificationSettings.telegram_bot_token,telegram_chat_id:e.notificationSettings.telegram_chat_id,email:e.notificationSettings.email,phone:e.notificationSettings.phone,discord_webhook:e.notificationSettings.discord_webhook,webhook_url:e.notificationSettings.webhook_url,webhook_token:e.notificationSettings.webhook_token})})),t.n=3;break;case 2:t.p=2,t.v;case 3:return t.a(2)}},t,null,[[0,2]])}))()},_mapNotifyTestError:function(e,t){var a=(t||"").trim();if("email"===e){if("missing_SMTP_HOST"===a)return this.$t("profile.notifications.errSmtpHost")||"email:服务器未配置发信 SMTP(管理员在「系统设置 → 邮件」或环境变量 SMTP_HOST/SMTP_USER 等)";if("missing_SMTP_FROM"===a)return this.$t("profile.notifications.errSmtpFrom")||"email:未配置发件人 SMTP_FROM(或 SMTP_USER)";if("missing_email_target"===a)return this.$t("profile.notifications.errEmailTarget")||"email:未填写通知邮箱且账号无邮箱"}return a?"".concat(e,": ").concat(a):""},handleSaveNotifications:function(){var e=this;this.notificationForm.validateFields(function(){var t=(0,s.A)((0,o.A)().m(function t(a,i){var r;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(!a){t.n=1;break}return t.a(2);case 1:return e.savingNotifications=!0,t.p=2,t.n=3,(0,c.Gl)({default_channels:i.default_channels||["browser"],telegram_bot_token:i.telegram_bot_token||"",telegram_chat_id:i.telegram_chat_id||"",email:i.email||"",phone:i.phone||"",discord_webhook:i.discord_webhook||"",webhook_url:i.webhook_url||"",webhook_token:i.webhook_token||""});case 3:r=t.v,1===r.code?(e.$message.success(e.$t("profile.notifications.saveSuccess")||"通知设置保存成功"),e.notificationSettings=r.data||e.notificationSettings):e.$message.error(r.msg||"保存失败"),t.n=5;break;case 4:t.p=4,t.v,e.$message.error("保存失败");case 5:return t.p=5,e.savingNotifications=!1,t.f(5);case 6:return t.a(2)}},t,null,[[2,4,5,6]])}));return function(e,a){return t.apply(this,arguments)}}())},handleTestNotification:function(){var e=this;return(0,s.A)((0,o.A)().m(function t(){var a,i,r,n,s,l,d;return(0,o.A)().w(function(t){while(1)switch(t.p=t.n){case 0:if(a=e.notificationForm.getFieldsValue(),i=a.default_channels||[],0!==i.length){t.n=1;break}return e.$message.warning(e.$t("profile.notifications.selectChannel")||"请至少选择一个通知渠道"),t.a(2);case 1:if(!i.includes("telegram")){t.n=3;break}if(a.telegram_bot_token){t.n=2;break}return e.$message.warning(e.$t("profile.notifications.fillTelegramToken")||"请填写 Telegram Bot Token"),t.a(2);case 2:if(a.telegram_chat_id){t.n=3;break}return e.$message.warning(e.$t("profile.notifications.fillTelegram")||"请填写 Telegram Chat ID"),t.a(2);case 3:if(!i.includes("email")||a.email){t.n=4;break}return e.$message.warning(e.$t("profile.notifications.fillEmail")||"请填写通知邮箱"),t.a(2);case 4:if(!i.includes("phone")||a.phone){t.n=5;break}return e.$message.warning(e.$t("profile.notifications.fillPhone")||"请填写手机号"),t.a(2);case 5:if(!i.includes("discord")||a.discord_webhook){t.n=6;break}return e.$message.warning(e.$t("profile.notifications.fillDiscord")||"请填写 Discord Webhook URL"),t.a(2);case 6:if(!i.includes("webhook")||a.webhook_url){t.n=7;break}return e.$message.warning(e.$t("profile.notifications.fillWebhook")||"请填写 Webhook URL"),t.a(2);case 7:return e.testingNotification=!0,t.p=8,t.n=9,(0,c.Gl)({default_channels:i,telegram_bot_token:a.telegram_bot_token||"",telegram_chat_id:a.telegram_chat_id||"",email:a.email||"",phone:a.phone||"",discord_webhook:a.discord_webhook||"",webhook_url:a.webhook_url||"",webhook_token:a.webhook_token||""});case 9:if(r=t.v,1===r.code){t.n=10;break}return e.$message.error(r.msg||"保存设置失败"),t.a(2);case 10:return t.n=11,(0,c.hl)();case 11:if(n=t.v,1===n.code){t.n=12;break}return e.$message.error(n.msg||e.$t("profile.notifications.testFailed")||"测试通知发送失败"),t.a(2);case 12:s=n.data&&n.data.results||{},l=Object.keys(s).filter(function(e){return!s[e].ok}),0===l.length?e.$message.success(e.$t("profile.notifications.testSent")||"测试通知已发送,请检查各渠道"):(d=l.map(function(t){var a=s[t]&&s[t].error||"",i=e._mapNotifyTestError(t,a);return i||(a?"".concat(t,": ").concat(a):t)}).join(";"),e.$message.warning((e.$t("profile.notifications.testPartial")||"部分渠道发送失败")+" — ".concat(d),8)),t.n=14;break;case 13:t.p=13,t.v,e.$message.error(e.$t("profile.notifications.testFailed")||"发送测试通知失败");case 14:return t.p=14,e.testingNotification=!1,t.f(14);case 15:return t.a(2)}},t,null,[[8,13,14,15]])}))()}}},g=f,h=a(845),m=(0,h.A)(g,i,r,!1,null,"06c79ed5",null),v=m.exports},42430:function(e,t,a){a.d(t,{IA:function(){return o},N6:function(){return l},PR:function(){return s},kI:function(){return c}});var i=a(76338),r=a(75769),n={list:"/api/credentials/list",get:"/api/credentials/get",create:"/api/credentials/create",delete:"/api/credentials/delete",egressIp:"/api/credentials/egress-ip"};function o(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,r.Ay)({url:n.list,method:"get",params:e})}function s(e){return(0,r.Ay)({url:n.create,method:"post",data:e})}function c(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(0,r.Ay)({url:n.delete,method:"delete",params:(0,i.A)({id:e},t)})}function l(){return(0,r.Ay)({url:n.egressIp,method:"get"})}},53003:function(e,t,a){a.d(t,{DZ:function(){return o},YT:function(){return n},_d:function(){return s},lo:function(){return r}});var i=a(75769);function r(){return(0,i.Ay)({url:"/api/settings/schema",method:"get"})}function n(){return(0,i.Ay)({url:"/api/settings/values",method:"get"})}function o(e){return(0,i.Ay)({url:"/api/settings/save",method:"post",data:e})}function s(){return(0,i.Ay)({url:"/api/settings/openrouter-balance",method:"get"})}},84841:function(e,t,a){a.d(t,{DK:function(){return w},E$:function(){return d},Gl:function(){return f},O0:function(){return l},TK:function(){return o},aU:function(){return r},cw:function(){return c},d$:function(){return x},hG:function(){return s},hl:function(){return g},kg:function(){return n},nY:function(){return _},r7:function(){return p},rx:function(){return m},v9:function(){return h},vF:function(){return u},vi:function(){return b},wq:function(){return v}});var i=a(75769);function r(e){return(0,i.Ay)({url:"/api/users/list",method:"get",params:e})}function n(e){return(0,i.Ay)({url:"/api/users/create",method:"post",data:e})}function o(e,t){return(0,i.Ay)({url:"/api/users/update",method:"put",params:{id:e},data:t})}function s(e){return(0,i.Ay)({url:"/api/users/delete",method:"delete",params:{id:e}})}function c(e){return(0,i.Ay)({url:"/api/users/reset-password",method:"post",data:e})}function l(){return(0,i.Ay)({url:"/api/users/roles",method:"get"})}function d(){return(0,i.Ay)({url:"/api/users/profile",method:"get"})}function p(e){return(0,i.Ay)({url:"/api/users/profile/update",method:"put",data:e})}function u(){return(0,i.Ay)({url:"/api/users/notification-settings",method:"get"})}function f(e){return(0,i.Ay)({url:"/api/users/notification-settings",method:"put",data:e})}function g(){return(0,i.Ay)({url:"/api/users/notification-settings/test",method:"post",data:{}})}function h(e){return(0,i.Ay)({url:"/api/users/my-credits-log",method:"get",params:e})}function m(e){return(0,i.Ay)({url:"/api/users/my-referrals",method:"get",params:e})}function v(e){return(0,i.Ay)({url:"/api/users/set-credits",method:"post",data:e})}function _(e){return(0,i.Ay)({url:"/api/users/set-vip",method:"post",data:e})}function w(e){return(0,i.Ay)({url:"/api/users/system-strategies",method:"get",params:e})}function b(e){return(0,i.Ay)({url:"/api/users/admin-orders",method:"get",params:e})}function x(e){return(0,i.Ay)({url:"/api/users/admin-ai-stats",method:"get",params:e})}}}]); |