///// <summary> ///// 查询子科目_返回DataSet ///// </summary> ///// <param name="Mcode"></param> ///// <returns></returns> //public static DataSet GetZcodeItems(string Mcode) //{ // return SqlHelper.ExecuteDataset(SetString.SQLConn, Sql_Select_UfCode + string.Format(Sql_Where_Zcode, Mcode)); //} #endregion 检索指定科目的信息 #region 获得辅助ID public static object GetFzId(string where, codefuzhu fz) { string SelectSql = ""; switch (fz) { case codefuzhu.bcus: //客户 SelectSql = Sql_Select_GetCustomerID; break; case codefuzhu.bdept: //部门 SelectSql = Sql_Select_GetDepartmentID; break; //case codefuzhu.bitem: // Tbname="Customer"; // break; case codefuzhu.bperson: //个人 SelectSql = Sql_Select_GetPersonID; break; case codefuzhu.bsup: //供应商 SelectSql = Sql_Select_GetVendorID; break; } return(SqlHelper.ExecuteScalar(SetString.SQLConn, CommandType.Text, SelectSql + where, null)); }
/// <summary> /// 更改欲改为核算方式 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void FzRDbt_CheckedChanged(object sender, EventArgs e) { RadioButton temprb = (RadioButton)sender; switch (temprb.Name) { case "RB_bdept": codefz = codefuzhu.bdept; break; case "RB_bperson": codefz = codefuzhu.bperson; break; case "RB_bcus": codefz = codefuzhu.bcus; break; case "RB_bsup": codefz = codefuzhu.bsup; break; case "RB_bitem": codefz = codefuzhu.bitem; MessageBox.Show("请选择项目大类编码!"); break; } }