首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > Web前端 >

radio绑定后盾数据

2012-09-19 
radio绑定后台数据,//////////////////////////客户端单选按钮radio绑定后台数据,修改过后将值存到隐藏域

radio绑定后台数据,

//////////////////////////
客户端单选按钮radio绑定后台数据,修改过后将值存到隐藏域中,然后form提交修改过的数据
注:dt为cs文件的全局变量dataTable
//////////////////////////

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="C2-1100-02_OffLineTaskAutoAssignModifyInitAct_T01.aspx.cs"

?? ?Inherits="OLCC_zh_CN_pages_sysManagement_OffLineTaskAutoAssign_C2_1100_02_OffLineTaskAutoAssignModifyInitAct_T01" %>

?

<%@ Register Assembly="Ebf.Core.View" Namespace="Ebf.Core.View" TagPrefix="ebf" %>

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

?? ?<title>离线任务自动分配管理修改页面</title>

?? ?<script type="text/javascript" src="<%=JsfilePath %>/jquery-1.4.1.js"></script>

?? ?<script type="text/javascript" src="<%=JsfilePath %>/TableViewToolbarScript.js"></script>

?? ?<link rel="Stylesheet" type="text/css" href="<%=CssfilePath %>/PageStyle.css" />

?? ?<script type="text/javascript">

?? ? ? ?function SubmitConfirmForm() {

?? ? ? ? ? ?SubmitConfirm("您将改变离线任务的分配方式,确认请点击“确定”按钮", OffLineTaskAutoAssignForm);

?? ? ? ?};

?? ?</script>

?? ?<style type="text/css">

?? ? ? ?.tableborder table tr { height: 50px; }

?? ? ? ?.tableborder table td { width: 150px; }

?? ?</style>

</head>

·

<body>

?? ?<div id="TableTool">

?? ? ? ?<div id="TableToolTop" style="width: 100%">

?? ? ? ? ? ?<span>离线任务自动分配管理修改</span>

?? ? ? ?</div>

?? ? ? ?<div id="TableToolbar" style="width: 100%" runat="server">

?? ? ? ? ? ?<form id="OffLineTaskAutoAssignForm" action="OffLineTaskAutoAssignModifySubmitAct.do">

?? ? ? ? ? ?<div style="padding: 20px 100px;">

?? ? ? ? ? ? ? ?<table>

?? ? ? ? ? ? ? ? ? ?<tr>

?? ? ? ? ? ? ? ? ? ? ? ?<td>

?? ? ? ? ? ? ? ? ? ? ? ? ? ?离线任务自动分配

?? ? ? ? ? ? ? ? ? ? ? ? ? ?<input type="hidden" id="Hidden1" name="ID" value='<%=dt.Rows[0]["ID"].ToString()%>' />

?? ? ? ? ? ? ? ? ? ? ? ? ? ?<input type="hidden" id="stateValue" name="OLTA_STATE" value='<%=dt.Rows[0]["OLTA_STATE"].ToString()%>' />

?? ? ? ? ? ? ? ? ? ? ? ?</td>

?? ? ? ? ? ? ? ? ? ? ? ?<td>

?? ? ? ? ? ? ? ? ? ? ? ? ? ?<input type="radio" id="open" name="stateRadio" style="width: 20px; height: 20px"

?? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?value="开启" onclick="show(this)" />开启自动分配

?? ? ? ? ? ? ? ? ? ? ? ?</td>

?? ? ? ? ? ? ? ? ? ? ? ?<td>

?? ? ? ? ? ? ? ? ? ? ? ? ? ?<input type="radio" style="width: 20px; height: 20px" id="close" name="stateRadio"

?? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?value="关闭" onclick="show(this)" />关闭自动分配

?? ? ? ? ? ? ? ? ? ? ? ?</td>

?? ? ? ? ? ? ? ? ? ?</tr>

?? ? ? ? ? ? ? ? ? ?<tr>

?? ? ? ? ? ? ? ? ? ? ? ?<td colspan="3" style=" width:100%">

?? ? ? ? ? ? ? ? ? ? ? ? ? ?<center><input id="OK" type="button" onclick="SubmitConfirmForm()" value="确定" style="width: auto" />

?? ? ? ? ? ? ? ? ? ? ? ? ? ?<input id="Button1" type="button" runat="server" value="返回" style="width: auto;"

?? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?onclick="location.href='javascript:history.back(-1)'" /></center>

?? ? ? ? ? ? ? ? ? ? ? ?</td>

?? ? ? ? ? ? ? ? ? ?</tr>

?? ? ? ? ? ? ? ?</table>

?? ? ? ? ? ?</div>

?? ? ? ? ? ?</form>

?? ? ? ?</div>

?? ?</div>

?? ?<script type="text/javascript">

?? ? ? ?(function () {

?? ? ? ? ? ?var state = document.getElementById("stateValue");

?? ? ? ? ? ?if (state.value == "开启") {

?? ? ? ? ? ? ? ?document.getElementById("open").checked = "checked";

?? ? ? ? ? ?} else {

?? ? ? ? ? ? ? ?document.getElementById("close").checked = "chedked";

?? ? ? ? ? ?}

?? ? ? ?})();

?? ? ? ?function show(obj) {

?? ? ? ? ? ?if (obj.value == '开启') {

?? ? ? ? ? ? ? ?document.getElementById('stateValue').value = "开启";


?? ? ? ? ? ?} else {

?? ? ? ? ? ? ? ?document.getElementById('stateValue').value = "关闭";

?? ? ? ? ? ?}

?? ? ? ?}?

?? ?</script>

</body>

</html>


?

热点排行