inbound.html 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. {{define "form/inbound"}}
  2. <!-- base -->
  3. <a-form layout="inline">
  4. <a-form-item label='{{ i18n "remark" }}'>
  5. <a-input v-model.trim="dbInbound.remark"></a-input>
  6. </a-form-item>
  7. <a-form-item label='{{ i18n "enable" }}'>
  8. <a-switch v-model="dbInbound.enable"></a-switch>
  9. </a-form-item>
  10. <a-form-item label='{{ i18n "protocol" }}'>
  11. <a-select v-model="inbound.protocol" style="width: 160px;">
  12. <a-select-option v-for="p in Protocols" :key="p" :value="p">[[ p ]]</a-select-option>
  13. </a-select>
  14. </a-form-item>
  15. <a-form-item>
  16. <span slot="label">
  17. {{ i18n "monitor" }}
  18. <a-tooltip>
  19. <template slot="title">
  20. <span>{{ i18n "pages.inbounds.monitorDesc" }}</span>
  21. </template>
  22. <a-icon type="question-circle" theme="filled"></a-icon>
  23. </a-tooltip>
  24. </span>
  25. <a-input v-model.trim="inbound.listen"></a-input>
  26. </a-form-item>
  27. <a-form-item label='{{ i18n "pages.inbounds.port" }}'>
  28. <a-input type="number" v-model.number="inbound.port"></a-input>
  29. </a-form-item>
  30. <a-form-item>
  31. <span slot="label">
  32. <span >{{ i18n "pages.inbounds.totalFlow" }}</span>(GB)
  33. <a-tooltip>
  34. <template slot="title">
  35. 0 <span>{{ i18n "pages.inbounds.meansNoLimit" }}</span>
  36. </template>
  37. <a-icon type="question-circle" theme="filled"></a-icon>
  38. </a-tooltip>
  39. </span>
  40. <a-input-number v-model="dbInbound.totalGB" :min="0"></a-input-number>
  41. </a-form-item>
  42. <a-form-item>
  43. <span slot="label">
  44. <span >{{ i18n "pages.inbounds.expireDate" }}</span>
  45. <a-tooltip>
  46. <template slot="title">
  47. <span>{{ i18n "pages.inbounds.leaveBlankToNeverExpire" }}</span>
  48. </template>
  49. <a-icon type="question-circle" theme="filled"></a-icon>
  50. </a-tooltip>
  51. </span>
  52. <a-date-picker :show-time="{ format: 'HH:mm' }" format="YYYY-MM-DD HH:mm"
  53. v-model="dbInbound._expiryTime" style="width: 300px;"></a-date-picker>
  54. </a-form-item>
  55. </a-form>
  56. <!-- vmess settings -->
  57. <template v-if="inbound.protocol === Protocols.VMESS">
  58. {{template "form/vmess"}}
  59. </template>
  60. <!-- vless settings -->
  61. <template v-if="inbound.protocol === Protocols.VLESS">
  62. {{template "form/vless"}}
  63. </template>
  64. <!-- trojan settings -->
  65. <template v-if="inbound.protocol === Protocols.TROJAN">
  66. {{template "form/trojan"}}
  67. </template>
  68. <!-- shadowsocks -->
  69. <template v-if="inbound.protocol === Protocols.SHADOWSOCKS">
  70. {{template "form/shadowsocks"}}
  71. </template>
  72. <!-- dokodemo-door -->
  73. <template v-if="inbound.protocol === Protocols.DOKODEMO">
  74. {{template "form/dokodemo"}}
  75. </template>
  76. <!-- socks -->
  77. <template v-if="inbound.protocol === Protocols.SOCKS">
  78. {{template "form/socks"}}
  79. </template>
  80. <!-- http -->
  81. <template v-if="inbound.protocol === Protocols.HTTP">
  82. {{template "form/http"}}
  83. </template>
  84. <!-- stream settings -->
  85. <template v-if="inbound.canEnableStream()">
  86. {{template "form/streamSettings"}}
  87. </template>
  88. <!-- tls settings -->
  89. <template v-if="inbound.canEnableTls()">
  90. {{template "form/tlsSettings"}}
  91. </template>
  92. <!-- sniffing -->
  93. <template v-if="inbound.canSniffing()">
  94. {{template "form/sniffing"}}
  95. </template>
  96. {{end}}