Beispiel #1
0
     } else {
         include tpl('fields_add');
     }
     break;
 case 'edit':
     $itemid or msg();
     $do->itemid = $itemid;
     if ($submit) {
         if ($do->pass($post)) {
             $do->edit($post);
             dmsg('修改成功', $this_forward);
         } else {
             msg($do->errmsg);
         }
     } else {
         extract($do->get_one());
         include tpl('fields_edit');
     }
     break;
 case 'delete':
     $itemid or msg();
     $do->delete($itemid);
     dmsg('删除成功', $this_forward);
     break;
 case 'order':
     $do->order($listorder);
     dmsg('更新成功', $this_forward);
     break;
 case 'delete':
     $itemid or msg();
     $do->delete($itemid);