商戶模塊
數(shù)據(jù)庫(kù)設(shè)計(jì)
商戶模塊數(shù)據(jù)設(shè)計(jì).PNG
后臺(tái)form表單和RESTful
REST ful與SpringMVC
form表單要有_method這個(gè)隱藏域,配合Spring的過(guò)濾器HiddenHttpMethodFilter
提交參數(shù)為中文,在web.xml中的URLencodeing為utf-8
如何解決RESTful應(yīng)用中的問(wèn)題
問(wèn)題一:
class path resource [mybatis.xml] cannot be opened because it does not exist:看評(píng)論第一條
問(wèn)題二:?jiǎn)?dòng)時(shí)localhost:8081/comment出現(xiàn)404
tomcat的配置出錯(cuò),在deployment中將路徑修改一下,另外補(bǔ)充一點(diǎn),Server中的On ‘Update’ action和On frame deactivation有什么用
問(wèn)題三:web.xml中攔截器、監(jiān)聽器名字下面報(bào)紅線
檢查pom.xml中工程名是否和自己的工程名一致
問(wèn)題四:訪問(wèn)comment-test/login一直404,無(wú)法在LoginController中完成路徑映射
檢查是否在LoginController類上加上了@Controller注解
SpringMVC 的工作流程:
springmvc工作流程.PNG
Mybatis知識(shí)點(diǎn)補(bǔ)充:
- 如果只有一個(gè)參數(shù),那么_parameter 就代表該參數(shù),如果有多個(gè)參數(shù),那么_parameter 可以get(0)得到第一個(gè)參數(shù)
Git基本操作
為什么每次服務(wù)器重啟后,頁(yè)面的信息丟失:session失效
關(guān)于redirectAttributes
完成:
- 廣告模塊的增刪改查
- 商戶模塊的增刪改查
遇到的問(wèn)題:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'desc='hello',
顯然,desc是mysql中的一個(gè)關(guān)鍵字,應(yīng)該用表名.desc代替