@@ -281,11 +281,7 @@ public function delete() {
281281$ this ->content_check_db = pc_base::load_model ('content_check_model ' );
282282$ this ->position_data_db = pc_base::load_model ('position_data_model ' );
283283$ this ->search_db = pc_base::load_model ('search_model ' );
284- //判断视频模块是否安装
285- if (module_exists ('video ' ) && file_exists (PC_PATH .'model ' .DIRECTORY_SEPARATOR .'video_content_model.class.php ' )) {
286- $ video_content_db = pc_base::load_model ('video_content_model ' );
287- $ video_install = 1 ;
288- }
284+
289285$ this ->comment = pc_base::load_app_class ('comment ' , 'comment ' );
290286$ search_model = getcache ('search_model_ ' .$ this ->siteid ,'search ' );
291287$ typeid = $ search_model [$ modelid ]['typeid ' ];
@@ -329,10 +325,6 @@ public function delete() {
329325$ this ->position_data_db ->delete (array ('id ' =>$ id ,'catid ' =>$ catid ,'module ' =>'content ' ));
330326//删除全站搜索中数据
331327$ this ->search_db ->delete_search ($ typeid ,$ id );
332- //删除视频库与内容对应关系数据
333- if ($ video_install ==1 ) {
334- $ video_content_db ->delete (array ('contentid ' =>$ id , 'modelid ' =>$ modelid ));
335- }
336328
337329//删除相关的评论,删除前应该判断是否还存在此模块
338330if (module_exists ('comment ' )){
@@ -1013,7 +1005,7 @@ public function clear_data() {
10131005
10141006if ($ _POST ['dosubmit ' ]) {
10151007set_time_limit (0 );
1016- $ models = array ('category ' , 'content ' , 'hits ' , 'search ' , 'position_data ' , 'video_content ' , ' video_store ' , ' comment ' );
1008+ $ models = array ('category ' , 'content ' , 'hits ' , 'search ' , 'position_data ' , 'comment ' );
10171009$ tables = $ _POST ['tables ' ];
10181010if (is_array ($ tables )) {
10191011foreach ($ tables as $ t ) {
@@ -1063,16 +1055,6 @@ public function clear_data() {
10631055$ this ->create_sql_file ($ result , $ position_db ->db_tablepre .'position_data ' , $ sql_file );
10641056}
10651057$ position_db ->delete ('`modelid`= ' .$ modelid .' AND `module`= \'content \'' );
1066- //清理视频库与内容对应关系表
1067- if (module_exists ('video ' )) {
1068- $ video_content_db = pc_base::load_model ('video_content_model ' );
1069- $ result = $ video_content_db ->select ('`modelid`= \'' .$ modelid .'\'' );
1070- if (is_array ($ result )) {
1071- $ sql_file = CACHE_PATH .'bakup ' .DIRECTORY_SEPARATOR .'default ' .DIRECTORY_SEPARATOR .'video_content- ' .$ modelid .'.sql ' ;
1072- $ this ->create_sql_file ($ result , $ video_content_db ->db_tablepre .'video_content ' , $ sql_file );
1073- }
1074- $ video_content_db ->delete ('`modelid`= \'' .$ modelid .'\'' );
1075- }
10761058//清理评论表及附件表,附件的清理为不可逆操作。
10771059//附件初始化
10781060//$attachment = pc_base::load_model('attachment_model');
0 commit comments