<?php
include_once( ROOT . 'lib/html.function.php' );
include_once( ROOT . 'meta/dict.meta.php' );
?>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<HTML>
<HEAD>
<TITLE> share_add </TITLE>
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
<link href="res/css/douya.css" rel="stylesheet" type="text/css">
<script src="res/js/prototype.js"></script>
<script src="res/js/core.js"></script>
<script src="res/js/vf.js"></script>
</HEAD>
<BODY style="padding:5px" class="my"><br/><p class="m">管理页面 &gt; <a href="?a=admin_share_list" class="m">共享模块管理</a> &gt; 修改共享数据格式  </p>
<form action="?a=admin_module_database_update" method="POST" name="admin_module_database_update_form">

<div style="padding: 10px">
1 <a href="?a=admin_module_modify&id=<?php echo $module['id'] ?>" target="main">修改基本信息</a>&nbsp;&nbsp;&nbsp; 2 <a href="?a=admin_module_database_modify&id=<?php echo $module['id'] ?>" target="main">更新数据表结构</a>&nbsp;&nbsp;&nbsp; 3 <a href="?a=admin_module_template_modify&id=<?php echo $module['id'] ?>" target="main">修改呈现模版</a>&nbsp;&nbsp;&nbsp; 4 <a href="?a=admin_module_build_script&id=<?php echo $module['id'] ?>" target="main">更新应用程序</a>&nbsp;&nbsp;&nbsp;

<h3>共享数据格式设定</h3>
<table border="0" cellspacing="5" cellpadding="5" width="90%">
	<tr style="background-color:#F7F7FB">
		<td>
		英文名称
		</td>
		<td>
		中文名称
		</td>
		<td>
		类型
		</td>
		<td>
		启用
		</td>
		<td>
		唯一
		</td>
		<td>
		必填
		</td>
		<td>
		搜索
		</td>
		<td>
		不可改
		</td>
		<!--<td>
		贡献
		</td>-->
		<td>
		操作
		</td>
	</tr>
	<?php foreach( $f as $line ): ?>
	<tr id="line_1">
		<td>
		<input name="fields[dy_en_name][]" onmouseover="this.focus()" value="<?php echo $line['dy_en_name'] ?>">
		</td>
		<td>
		<input name="fields[dy_cn_name][]" onmouseover="this.focus()" value="<?php echo $line['dy_cn_name'] ?>">
		</td>
		<td>
		<select name="fields[dy_type][]" onmouseover="this.focus()">
		<?php echo get_html_options( get_field_type_list() , 'type' , 'desc' , $line['dy_type'] ); ?>	
		</select>
		</td>
		<td>
			<select name="fields[dy_is_active][]" onmouseover="this.focus()">
			<?php echo get_html_options( get_active_list() , 'value' , 'desc' , $line['dy_is_active'] ) ?>
			</select>
		</td>
		<td>
			<select name="fields[dy_is_unique][]" onmouseover="this.focus()">
			<?php echo get_html_options( get_unique_list() , 'value' , 'desc' , $line['dy_is_unique'] ) ?>
			</select>
		</td>
		<td>
			<select name="fields[dy_not_null][]" onmouseover="this.focus()">
			<?php echo get_html_options( get_not_null_list() , 'value' , 'desc' , $line['dy_not_null'] ) ?>
			</select>
		</td>
		<td>
			<select name="fields[dy_in_search][]" onmouseover="this.focus()">
			<?php echo get_html_options( get_in_search_list() , 'value' , 'desc' , $line['dy_in_search'] ) ?>
			</select>
		</td>
		<td>
			<select name="fields[dy_cannot_modify][]" onmouseover="this.focus()">
			<?php echo get_html_options( get_cannot_modify_list() , 'value' , 'desc' , $line['dy_cannot_modify'] ) ?>
			</select>
		</td>
		<!--<td>
			<select name="fields[dy_can_share][]" onmouseover="this.focus()">
			<?php echo get_html_options( get_can_share_list() , 'value' , 'desc' , $line['dy_can_share'] ) ?>
			</select>
		</td>-->
		<td >
		<input type="button" onclick="removeThisRow(this)" style="cursor:pointer" value="删除">&nbsp;
		<input type="button" onclick="insertUnderThisRow(this)" style="cursor:pointer" value="追加">&nbsp;
		<input type="button" onclick="moveThisRowUp(this)" style="cursor:pointer" value="上移">&nbsp;
		<input type="button" onclick="moveThisRowDown(this)" style="cursor:pointer" value="下移">&nbsp;
		</td>
	</tr>
	<?php endforeach; ?>
</table>
<br/><br/><input type="button" value="保存我的设置" onclick="if(vf_check_field_unique('fields[dy_en_name][]' , '英文名')){ submit();}"  class="dbutton">
<?php if( is_numeric( $_REQUEST['id'] ) ): ?>
<INPUT TYPE="hidden" name="id" value="<?php echo  $_REQUEST['id'] ?>">
<?php endif; ?>
</div>
</form><?php echo $vf_js; ?>
<br/>
</BODY>
</HTML>