ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
# 12. 卸载删除演示数据 ## 卸载删除演示数据 用于删除导入的演示数据,如果开发者提供了演示数据就必须提供一份删除演示数据的sql文件 在模板主题根目录命名为:undemodata.sql 数据库里面的表前缀使用`@prefix@` 代替,如下 ``` <pre class="calibre16">``` insert into `@prefix@archives`<span class="token1">(</span>`id`<span class="token1">,</span>`category_id`<span class="token1">,</span>`model_id`<span class="token1">,</span>`admin_id`<span class="token1">,</span>`title`<span class="token1">,</span>`thumb`<span class="token1">,</span>`seotitle`<span class="token1">,</span>`keywords`<span class="token1">,</span>`description`<span class="token1">,</span>`tags`<span class="token1">,</span>`show_tpl`<span class="token1">,</span>`publish_time`<span class="token1">,</span>`create_time`<span class="token1">,</span>`update_time`<span class="token1">,</span>`delete_time`<span class="token1">,</span>`weigh`<span class="token1">,</span>`author`<span class="token1">,</span>`url`<span class="token1">,</span>`views`<span class="token1">,</span>`lang`<span class="token1">,</span>`status`<span class="token1">,</span>`flags`<span class="token1">)</span> values <span class="token1">(</span><span class="token2">null</span><span class="token1">,</span><span class="token3">6</span><span class="token1">,</span><span class="token3">1</span><span class="token1">,</span><span class="token3">1</span><span class="token1">,</span><span class="token4">'Honor certificate'</span><span class="token1">,</span><span class="token4">'/static/module/index/default/img/honor.jpg'</span><span class="token1">,</span><span class="token4">''</span><span class="token1">,</span><span class="token4">''</span><span class="token1">,</span><span class="token4">''</span><span class="token1">,</span><span class="token4">''</span><span class="token1">,</span><span class="token4">'show.html'</span><span class="token1">,</span><span class="token3">1636988345</span><span class="token1">,</span><span class="token3">1636988345</span><span class="token1">,</span><span class="token3">1636988345</span><span class="token1">,</span>NULL<span class="token1">,</span><span class="token3">0</span><span class="token1">,</span><span class="token4">'小编'</span><span class="token1">,</span><span class="token4">''</span><span class="token1">,</span><span class="token3">0</span><span class="token1">,</span><span class="token4">'en'</span><span class="token1">,</span><span class="token4">'normal'</span><span class="token1">,</span><span class="token4">''</span><span class="token1">)</span><span class="token1">;</span> ``` ``` 将在卸载模板时执行undemodata.sql文件