$art_cat_info = $art_cat_info[0];
     if ($art_cat_info['art_cat_pid'] > 0) {
         $art_cat_obj->setArt_cat_pid($slt_cat_id);
     }
 } else {
     $art_cat_obj->setArt_cat_pid($slt_cat_id);
 }
 $art_cat_obj->setCat_name(kekezu::escape($txt_cat_name));
 $art_cat_obj->setListorder($txt_listorder ? $txt_listorder : 0);
 $art_cat_obj->setIs_show(intval($chk_is_show));
 $art_cat_obj->setSeo_title($seo_title);
 $art_cat_obj->setSeo_keyword($seo_keyword);
 $art_cat_obj->setSeo_desc($seo_desc);
 $art_cat_obj->setOn_time(time());
 if ($type == "art") {
     $art_cat_obj->setCat_type("article");
     $top_index = '{1}';
 } else {
     if ($type == "help") {
         $art_cat_obj->setCat_type("help");
         $top_index = '{100}';
     } else {
         if ($type == "single") {
             $art_cat_obj->setCat_type("single");
         }
     }
 }
 if ($slt_cat_id == 0) {
     $art_index = $top_index;
 } else {
     $art_index = $art_cat_arr[$slt_cat_id]['art_index'];
        foreach ($add_cat_name_arr as $k => $aindarr) {
            foreach ($aindarr as $kk => $v) {
                if (!$v) {
                    continue;
                }
                $cat_obj->_art_cat_id = null;
                $cat_obj->setCat_name($v);
                $cat_obj->setArt_cat_pid($k);
                $cat_obj->setListorder($add_cat_name_listarr[$k][$kk] ? $add_cat_name_listarr[$k][$kk] : 0);
                $cat_obj->setOn_time(time());
                if ($type == 'art') {
                    $cat_type = 'article';
                } else {
                    $cat_type = 'help';
                }
                $cat_obj->setCat_type($cat_type);
                $res = $cat_obj->create_keke_witkey_article_category();
                $res and db_factory::execute(sprintf("update %switkey_article_category set art_index = '%s' where art_cat_id = {$res} ", TABLEPRE, $cat_all_arr[$k]['art_index'] . '{' . $res . '}'));
            }
        }
        kekezu::admin_system_log($_lang['delete_article_cat']);
    }
    $file_obj->delete_files(S_ROOT . "./data/data_cache/");
    $file_obj->delete_files(S_ROOT . './data/tpl_c/');
    kekezu::admin_show_msg($_lang['operate_success'], 'index.php?do=' . $do . '&view=' . $view . '&type=' . $type, 3, '', 'success');
} elseif ($ac === 'editlistorder') {
    if ($iid) {
        $cat_obj->setWhere('art_cat_id=' . $iid);
        $cat_obj->setListorder($val);
        $cat_obj->edit_keke_witkey_article_category();
    }