diff options
| -rw-r--r-- | .github/workflows/release.yml | 1 | ||||
| -rw-r--r-- | web/assets/css/custom.css | 4 | ||||
| -rw-r--r-- | web/html/xui/inbounds.html | 4 | ||||
| -rw-r--r-- | web/html/xui/xray.html | 4 | ||||
| -rw-r--r-- | web/html/xui/xray_balancer_modal.html | 16 | ||||
| -rw-r--r-- | web/service/inbound.go | 7 |
6 files changed, 26 insertions, 10 deletions
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f13462eb..67329344 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -124,4 +124,3 @@ jobs: file: x-ui-linux-${{ matrix.platform }}.tar.gz asset_name: x-ui-linux-${{ matrix.platform }}.tar.gz prerelease: true - draft: true diff --git a/web/assets/css/custom.css b/web/assets/css/custom.css index f4a13b51..53c1168a 100644 --- a/web/assets/css/custom.css +++ b/web/assets/css/custom.css @@ -1171,3 +1171,7 @@ b, strong { background-color: var(--dark-color-btn-danger-hover); border-color: var(--dark-color-btn-danger-hover); } + +.dark .ant-alert-close-icon .anticon-close:hover { + color: rgb(255 255 255); +}
\ No newline at end of file diff --git a/web/html/xui/inbounds.html b/web/html/xui/inbounds.html index a2365cde..117cbffb 100644 --- a/web/html/xui/inbounds.html +++ b/web/html/xui/inbounds.html @@ -186,7 +186,7 @@ </a-radio-group> </div> <a-back-top></a-back-top> - <a-table :columns="isMobile ? mobileColums : columns" :row-key="dbInbound => dbInbound.id" + <a-table :columns="isMobile ? mobileColumns : columns" :row-key="dbInbound => dbInbound.id" :data-source="searchedInbounds" :scroll="isMobile ? {} : { x: 1000 }" :pagination=pagination(searchedInbounds) @@ -508,7 +508,7 @@ scopedSlots: { customRender: 'expiryTime' }, }]; - const mobileColums = [{ + const mobileColumns = [{ title: "ID", align: 'right', dataIndex: "id", diff --git a/web/html/xui/xray.html b/web/html/xui/xray.html index 2ddba224..572d8b6a 100644 --- a/web/html/xui/xray.html +++ b/web/html/xui/xray.html @@ -393,6 +393,10 @@ <td>Port</td> <td><a-tag color="green" v-for="r in rule.port.split(',')">[[ r ]]</a-tag></td> </tr> + <tr v-if="rule.balancerTag"> + <td>Balancer Tag</td> + <td><a-tag color="blue">[[ rule.balancerTag ]]</a-tag></td> + </tr> </table> </template> <a-button shape="round" size="small" style="font-size: 14px; padding: 0 10px;"> diff --git a/web/html/xui/xray_balancer_modal.html b/web/html/xui/xray_balancer_modal.html index 627aecf6..78b15fda 100644 --- a/web/html/xui/xray_balancer_modal.html +++ b/web/html/xui/xray_balancer_modal.html @@ -23,7 +23,8 @@ <a-select-option value="roundRobin">Round Robin</a-select-option> </a-select> </a-form-item> - <a-form-item label='{{ i18n "pages.xray.balancer.balancerSelectors" }}' has-feedback :validate-status="balancerModal.emptySelector? 'warning' : 'success'"> + <a-form-item label='{{ i18n "pages.xray.balancer.balancerSelectors" }}' has-feedback + :validate-status="balancerModal.emptySelector? 'warning' : 'success'"> <a-select v-model="balancerModal.balancer.selector" mode="tags" @change="balancerModal.checkSelector()" :dropdown-class-name="themeSwitcher.currentTheme"> <a-select-option v-for="tag in balancerModal.outboundTags" :value="tag">[[ tag ]]</a-select-option> @@ -74,17 +75,18 @@ this.balancerTags = balancerTags.filter((tag) => tag != balancer.tag); this.outboundTags = app.templateSettings.outbounds.filter((o) => !ObjectUtil.isEmpty(o.tag)).map(obj => obj.tag); this.isEdit = isEdit; - this.check() + this.check(); + this.checkSelector(); }, close() { - balancerModal.visible = false; - balancerModal.loading(false); + this.visible = false; + this.loading(false); }, loading(loading=true) { - balancerModal.confirmLoading = loading; + this.confirmLoading = loading; }, check() { - if (balancerModal.balancer.tag == '' || balancerModal.balancerTags.includes(balancerModal.balancer.tag)) { + if (this.balancer.tag == '' || this.balancerTags.includes(this.balancer.tag)) { this.duplicateTag = true; this.isValid = false; } else { @@ -93,7 +95,7 @@ } }, checkSelector() { - balancerModal.emptySelector = balancerModal.balancer.selector.length == 0; + this.emptySelector = this.balancer.selector.length == 0; } }; diff --git a/web/service/inbound.go b/web/service/inbound.go index 6a3dac5d..f637c0b2 100644 --- a/web/service/inbound.go +++ b/web/service/inbound.go @@ -1900,6 +1900,13 @@ func (s *InboundService) MigrationRequirements() { newStream, _ := json.MarshalIndent(stream, " ", " ") tx.Model(model.Inbound{}).Where("id = ?", ep.Id).Update("stream_settings", newStream) } + + err = tx.Raw(`UPDATE inbounds + SET tag = REPLACE(tag, '0.0.0.0:', '') + WHERE INSTR(tag, '0.0.0.0:') > 0;`).Error + if err != nil { + return + } } func (s *InboundService) MigrateDB() { |
