分支-特殊字符

This commit is contained in:
caishi 2021-12-23 14:07:12 +08:00
parent 2f25643fcc
commit b0088a24ae
1 changed files with 3 additions and 3 deletions

View File

@ -257,7 +257,7 @@ export function turnbar(str){
let s = str; let s = str;
if(s && s.length>0){ if(s && s.length>0){
if(s.indexOf("%")>-1){ if(s.indexOf("%")>-1){
s = s.replaceAll('%','55'); s = s.replaceAll('%','_25');
} }
if(s.indexOf("#")>-1){ if(s.indexOf("#")>-1){
s = s.replaceAll('#','%23'); s = s.replaceAll('#','%23');
@ -271,8 +271,8 @@ export function turnbar(str){
export function returnbar(str){ export function returnbar(str){
let s = str; let s = str;
if(s && s.length>0){ if(s && s.length>0){
if(str.indexOf("55")>-1){ if(str.indexOf("_25")>-1){
s = s.replaceAll('55','%'); s = s.replaceAll('_25','%');
} }
if(s.indexOf("%23")>-1){ if(s.indexOf("%23")>-1){
s = s.replaceAll('%23','#'); s = s.replaceAll('%23','#');