<?php

$_G['module']['vote'] = array();

//模块名称
$_G['module']['vote']['name']	=	"投票";

//模块类型
$_G['module']['vote']['model']	=	"module";

//模块版本
$_G['module']['vote']['version']	=	"3.0";

//模块作者
$_G['module']['vote']['author']	=	"VeryIDE";

//模块网站
$_G['module']['vote']['support']	=	"http://www.veryide.com/";

//模块网站
$_G['module']['vote']["describe"]	=	"图片投票十分钟搞定";

/***************************/

//表单状态
$_G['module']['vote']['state']	=	array('<span class="text-no">已停用</a>','<span class="text-yes">使用中</a>','<span class="text-no">已过期</a>');

//操作菜单
$_G['module']['vote']['tool']	=	'<a href="javascript:Mo(\'#table tbody tr input[type=checkbox]\').checked( true ); void(0);">全选</a> / <a href="javascript:Mo(\'#table td input[type=checkbox]\').checked( false ); void(0);">不选</a> / <a href="javascript:Mo(\'#table td input[type=checkbox]\').checked(); void(0);">反选</a> - <a href="javascript:if(confirm(\'确定要启用所选吗?\')){ Mo(\'#formPost input[name=state]\').value(1); Mo(\'#formPost input[name=action]\').value(\'state\'); Mo(\'#formPost\').submit();}void(0);">启用所选</a> - <a href="javascript:if(confirm(\'确定要停用所选吗?\')){ Mo(\'#formPost input[name=state]\').value(0); Mo(\'#formPost input[name=action]\').value(\'state\'); Mo(\'#formPost\').submit(); }void(0);">停用所选</a> - <a href="javascript:if(confirm(\'确定要删除所选吗?\')){ Mo(\'#formPost input[name=action]\').value(\'delete\'); Mo(\'#formPost\').submit(); }void(0);">删除所选</a>';

//用户标识
$_G['module']['vote']['sign']	=	array('<span class="text-no">未确认</a>','<span class="text-yes">已确认</a>');

//搜索配置
$_G['module']['vote']['search']	=	array(
	"table"=>"{TableModPre}form",
	"title"=>"投票",
	"where"=>" and appid='".$appid."' ",
	"keyword"=>"name",
	"private"=>" aid = ".$_SESSION['Manager']['id'],
	"order"=>"id",
	"cache"=>"html/",
	"fieds"=>array("id"=>"ID","name"=>"选票名称","account"=>"创建者","f_view"=>"点击量"),
	"extra"=>array("name"=>"<a onclick='parent.Mo.Window(\"window\",\"搜索结果预览\" , \"poll.edit.php?fid={id}&action=edit\" , 900, 500 ,{});void(0);'>{name}</a>")
);

//权限配置
$_G['module']['vote']['func'] = array(
							  "vote-add"=>"添加表单",
							  "vote-mod"=>"修改表单",
							  "vote-del"=>"删除表单",
							  "vote-data-dow"=>"下载用户数据",
							  "vote-data-del"=>"删除用户数据",
							  "vote-other"=>"<span class='text-yes'>包含他人表单</span>"
							);
		
//选项风格
$_G['module']['vote']["style"] = array(
							  "0"=>"",
							  "1"=>"{INPUT} {LABEL}",
							  "2"=>"{INPUT} {LABEL} <span>{DESC}</span>",
							  "3"=>'<a href="{LINK}" target="_blank"><img _src="{IMAGE}" alt="{LABEL}" /></a> <br /> {INPUT}',
							  "4"=>'<a href="{LINK}" target="_blank"><img _src="{IMAGE}" alt="{LABEL}" /> <br /> {LABEL} </a><br /> {INPUT}',
							  "5"=>'<a href="{LINK}" target="_blank"><img _src="{IMAGE}" alt="{LABEL}" /> <br /> {LABEL} </a><br /> <span>{DESC}</span> <br /> {INPUT}',
							  "6"=>'<a href="{LINK}" target="_blank"><img _src="{IMAGE}" alt="{LABEL}" /> <br /> {LABEL} </a><br /> <strong>{COUNT}</strong> <br /> {INPUT}'
							);

//选项组类型
$_G['module']['vote']["group"]	=	array(
	"radio"=>"单选",
	"button"=>"按钮",
	"checkbox"=>"复选"
);

//模块菜单
$_G['module']['vote']['menu'] = array(
							  "新增投票"=>"vote.edit.php",
							  "管理投票"=>"vote.list.php"
							);