Exemplo n.º 1
0
        public XtYhbModel GetModel(XtYhbModel model)
        {
            string sql = "SELECT top 1 * FROM dbo.xt_yhb WHERE dh=@dh AND yybh=@yybh AND mm=@mm AND xm=@xm";

            using (IDbConnection conn = new DapperConnection().DbConnection)
            {
                return(conn.QueryFirstOrDefault <XtYhbModel>(sql, model));
            }
        }
Exemplo n.º 2
0
        public void Add(XtYhbModel model)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.Append("insert into xt_yhb(");
            strSql.Append("zh,xm,dh,mm,cjsj,yybh)");
            strSql.Append(" values (");
            strSql.Append("@zh,@xm,@dh,@mm,@cjsj,@yybh)");
            using (IDbConnection conn = new DapperConnection().DbConnection)
            {
                conn.Execute(strSql.ToString(), model);
            }
        }
Exemplo n.º 3
0
        public void Login(XtYhbModel model)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.AppendLine("");
        }