46 lines
597 B
C++
Executable File
46 lines
597 B
C++
Executable File
/*
|
|
* This file is a part of Winix
|
|
* and is not publicly distributed
|
|
*
|
|
* Copyright (c) 2008-2010, Tomasz Sowa
|
|
* All rights reserved.
|
|
*
|
|
*/
|
|
|
|
#include "content.h"
|
|
#include "../core/request.h"
|
|
#include "../core/db.h"
|
|
|
|
|
|
|
|
void Content::FunLs()
|
|
{
|
|
if( !request.is_item )
|
|
{
|
|
Db::ItemQuery iq;
|
|
|
|
iq.sel_content = false;
|
|
|
|
iq.WhereParentId(request.dir_table.back()->id);
|
|
iq.WhereType(Item::file);
|
|
|
|
if( request.IsParam("ckeditor_browse") )
|
|
{
|
|
iq.WhereAuth(Item::auth_image);
|
|
db.GetItems(request.item_table, iq);
|
|
}
|
|
else
|
|
{
|
|
db.GetItems(request.item_table, iq);
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|