ip limit + export links

This commit is contained in:
MHSanaei
2023-02-28 23:24:29 +03:30
parent 1a4ba4afd6
commit 5317df21f3
20 changed files with 604 additions and 14 deletions

View File

@@ -43,6 +43,11 @@ type Inbound struct {
Tag string `json:"tag" form:"tag" gorm:"unique"`
Sniffing string `json:"sniffing" form:"sniffing"`
}
type InboundClientIps struct {
Id int `json:"id" gorm:"primaryKey;autoIncrement"`
ClientEmail string `json:"clientEmail" form:"clientEmail" gorm:"unique"`
Ips string `json:"ips" form:"ips"`
}
func (i *Inbound) GenXrayInboundConfig() *xray.InboundConfig {
listen := i.Listen
@@ -70,6 +75,7 @@ type Client struct {
ID string `json:"id"`
AlterIds uint16 `json:"alterId"`
Email string `json:"email"`
LimitIP int `json:"limitIp"`
Security string `json:"security"`
TotalGB int64 `json:"totalGB" form:"totalGB"`
ExpiryTime int64 `json:"expiryTime" form:"expiryTime"`