如果不从导航栏中添加 rightbuttonitem,导航设置很困难

问题描述

这是我的导航层次结构。

导航控制器 -> Auth Storybard -> TabbarController -> MainViewController,PostViewController

enter image description here

로그인을 하고 메인화면으로 pushViewController를 해주었기 때문에 导航栏 나타납니다。 바로 이렇게 말이죠

enter image description here

但是,因为我不想让它在主屏幕上倒退,所以将它设置为 并没有消失。我想添加 rightBarButton。

SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/Users/nehasingh/.p2/pool/plugins/org.eclipse.m2e.maven.runtime.slf4j.simple_1.16.0.20200610-1735/jars/slf4j-simple-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [file:/Users/nehasingh/eclipse/java-2021-032/Eclipse.app/Contents/Eclipse/configuration/org.eclipse.osgi/5/0/.cp/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.SimpleLoggerFactory]
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/Users/nehasingh/.p2/pool/plugins/org.eclipse.m2e.maven.runtime.slf4j.simple_1.16.0.20200610-1735/jars/slf4j-simple-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [file:/Users/nehasingh/eclipse/java-2021-032/Eclipse.app/Contents/Eclipse/configuration/org.eclipse.osgi/5/0/.cp/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.SimpleLoggerFactory]
[INFO] Scanning for projects...
[INFO] 
[INFO] ---------------------------< UI:Automation >----------------------------
[INFO] Building Automation 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ Automation ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/nehasingh/Downloads/AutomationUI-main/src/main/resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.5.1:compile (default-compile) @ Automation ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 3 source files to /Users/nehasingh/Downloads/AutomationUI-main/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[10,29] package UI.Automation.stepdfn does not exist
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[14,31] cannot find symbol
  symbol: class Hooks
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/loginPage.java:[3,29] package UI.Automation.stepdfn does not exist
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/loginPage.java:[5,32] cannot find symbol
  symbol: class Hooks
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[19,49] cannot find symbol
  symbol:   variable driver
  location: class UI.Automation.pageobjects.HomePage
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[32,35] cannot find symbol
  symbol:   variable driver
  location: class UI.Automation.pageobjects.HomePage
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/loginPage.java:[11,17] cannot find symbol
  symbol:   variable driver
  location: class UI.Automation.pageobjects.loginPage
[INFO] 7 errors 
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  2.837 s
[INFO] Finished at: 2021-04-17T00:03:28-03:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile (default-compile) on project Automation: Compilation failure: Compilation failure: 
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[10,31] cannot find symbol
[ERROR]   symbol: class Hooks
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/loginPage.java:[3,32] cannot find symbol
[ERROR]   symbol: class Hooks
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[19,49] cannot find symbol
[ERROR]   symbol:   variable driver
[ERROR]   location: class UI.Automation.pageobjects.HomePage
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/HomePage.java:[32,35] cannot find symbol
[ERROR]   symbol:   variable driver
[ERROR]   location: class UI.Automation.pageobjects.HomePage
[ERROR] /Users/nehasingh/Downloads/AutomationUI-main/src/main/java/UI/Automation/pageobjects/loginPage.java:[11,17] cannot find symbol
[ERROR]   symbol:   variable driver
[ERROR]   location: class UI.Automation.pageobjects.loginPage
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors,re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions,please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

我现在想做的就是......

  1. 登录,来到主界面,登录,,,,, 1.登录,来到主界面,使导航栏没有backButton。
  2. 添加 rightBarButton

可能是tabbar控制器的原因,但是和导航有冲突。我不知道。请帮帮我。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)