⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 10157777.sff

📁 使用flex和bison
💻 SFF
字号:
string menukey;
string songkey;
string menufile;
string songfile;
string dialnum;
string sql;
int menutime = 50;
int songtime = 50;
string linkfile ;
int sysconnid = 1;
int connid = 5;
string newfile;
string userid ;
string flag ;
string companyid = "1";
#测试是不是联通号码
state m_mainproc
{
	init
	{
		int len = strlen($sys_caller);
		if(len != 11)
		{
			hangup(); 
		}
		string phonetype =  getsubstring($sys_caller,0,3);
		int phonenum = stoi(phonetype);
		if(phonenum>=130)
		{
			if(phonenum<=133)
			{
				goto m_start;	
			}
			else
			{
				hangup();
			}
		}
		else
		{
			hangup();
		}
	}
}
state m_start
{
	init
	{
		playfile("d:\trasin\myvoc\sdmenu.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "0":
				gotosubflow(companyid,"flowshengdandiange");
			break;
			default:
				goto m_shengdanmenu;
			break;
		}
	}
}
state m_shengdandiange
{
	init
	{
		playfile("d:\trasin\myvoc\song_jieshao.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "1":
				gotosubflow(companyid,"flowsendsong");
			break;
			case "2":
				goto m_shengdanfuwa;
			break;
			case "*":
				goto m_shengdanmenu;
			break;
			default:
				gotosubflow(companyid,"flowsendsong");
			break;
		}
	}
}

state m_shengdanmenu
{
	init
	{
		playfile("d:\trasin\myvoc\shengdanwel.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "*":
				goto m_start;
			break;
			default:
				goto m_shengdandiange;
			break;
		}
	}
}

state m_shengdanfuwa
{
	init
	{
		playfile("d:\trasin\myvoc\fuwa_jieshao.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "1":
				gotosubflow(companyid,"flowfuwa");
			break;
			case "2":
				goto m_shengdantuling;
			break;
			case "*":
				goto m_shengdandiange;
			break;
			default:
				gotosubflow(companyid,"flowfuwa");
			break;
		}
	}
}

state m_shengdantuling
{
	init
	{
		playfile("d:\trasin\myvoc\tuling_jieshao.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "1":
				gotosubflow(companyid,"flowtpls");
			break;
			case "2":
				goto m_shengdansex;
			break;
			case "*":
				goto m_shengdanfuwa;
			break;
			default:
				gotosubflow(companyid,"flowtpls");
			break;
		}
	}
}
state m_shengdansex
{
	init
	{
		playfile("d:\trasin\myvoc\sex_jieshao.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "1":
				gotosubflow(companyid,"flowdiantai");
			break;
			case "2":
				goto m_shengdanshengse;
			break;
			case "*":
				goto m_shengdantuling;
			break;
			default:
				gotosubflow(companyid,"flowdiantai");
			break;
		}
	}
}

state m_shengdanshengse
{
	init
	{
		playfile("d:\trasin\myvoc\shengse_jieshao.pcm",2);	
		readdigits(1);
		setchantimer(menutime);
	}
	proc
	{
		switch($sys_dtmf)
		{
			case "1":
				gotosubflow(companyid,"flowshengse");
			break;
			case "2":
				goto m_shengdandiange;
			break;
			case "*":
				goto m_shengdansex;
			break;
			default:
				gotosubflow(companyid,"flowshengse");
			break;
		}
	}
}


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -