//有C6账户且不等于董事长、总经理时,则对应列只读。
function SetRead()
{
//alert(12);
if((txtBaoXiaoRen.value!='FR010002###')&&(txtBaoXiaoRen.value!='FR010001##')&&(labelC6.value=='1'))
{
sys_SetGridColReadOnly(grid2,1);
sys_SetGridColReadOnly(grid2,2);
sys_SetGridColReadOnly(grid2,5);
// sys_SetGridColReadOnly(grid2,6);//alert(123);
}
}
//检测含编号姓名的报销人是否有C6账户。
function checkhaveC6()
{
var S11 = txtBaoXiaoRen.value;
S11=S11.substr(8);
var sql = "select count(*) as icount from users where username='"+ S11 +"' ";
var icount = SqlToField(sql);
//alert(icount);
if (icount ==0 )
{
//alert("无C6账户");
labelC6.value=0;
SetRead();
}
if (icount ==1 )
{
// alert("有C6账户");
labelC6.value=1;
SetRead();
}
}