<?


function IF_FORM_CAN_WRITE($ID,$FIELD) {
	global $thiss;
	SEF('A_ADM_COMPANY_CHECK');

//	DEBUG_S(-3,'perm',$_SESSION[$thiss->DETECT_TABLE_COLUMN]['PERMEDIT'][$FIELD]);
	if(
	strstr($_SESSION[$thiss->DETECT_TABLE_COLUMN]['PERMEDIT'][$FIELD],'W')
	&&(A_ADM_COMPANY_CHECK($ID))
	) return true;

	
	if(strstr($_SESSION[$thiss->DETECT_TABLE_COLUMN]['PERMEDIT'][$FIELD],'S'))
		return true;

	if(
	strstr($_SESSION[$thiss->DETECT_TABLE_COLUMN]['PERMEDIT'][$FIELD],'O')
	&&(A_ADM_COMPANY_CHECK($ID))
	) return true;
	
	
	return false;
	
	

}



?>
