更新时间:2023-02-25 09:35:31
You need to use the OutputCacheAttribute
or something similar. This action filter "represents an attribute that is used to mark an action method whose output will be cached." When an action updates the database, the resulting view should be cached, because it is overwriting the previously cached data.