Esempio n. 1
0
        /// <summary>
        /// 审核
        /// </summary>
        /// <param name="oddNum"></param>
        /// <param name="result"></param>
        /// <returns></returns>
        public bool Exanmie(LineProductMesEntityu.LEDNewsHeaderEntity model)
        {
            Dictionary <object, object> SQLString = new Dictionary <object, object> ( );
            StringBuilder strSql = new StringBuilder( );

            strSql.Append("UPDATE MIKLEF SET LEF017=@LEF017 WHERE LEF001=@LEF001");
            SqlParameter [] parameter =
            {
                new SqlParameter("@LEF001", SqlDbType.NVarChar, 20),
                new SqlParameter("@LEF017", SqlDbType.Bit)
            };
            parameter [0].Value = model.LEF001;
            parameter [1].Value = model.LEF017;
            SQLString.Add(strSql, parameter);

            if (model.LEF017)
            {
                strSql = new StringBuilder( );
                strSql.AppendFormat("SELECT LEH002 ANN002,LEH003 ANN003,LEH005 ANN005,LEH009 ANN009,DDA001 FROM MIKLEH A LEFT JOIN TPADEA B ON A.LEH003=B.DEA001 INNER JOIN TPADDA C ON B.DEA008=C.DDA001 WHERE LEH001='{0}'", model.LEF001);

                GenerateSGMRCACB.GenerateSGM(SQLString, strSql, model.LEF001, model.LEF011);
            }

            return(SqlHelper.ExecuteSqlTranDic(SQLString));
        }
Esempio n. 2
0
        /// <summary>
        /// 审核
        /// </summary>
        /// <param name="oddNum"></param>
        /// <param name="result"></param>
        /// <returns></returns>
        public bool Exanmie(string oddNum, bool result, string department)
        {
            Dictionary <object, object> SQLString = new Dictionary <object, object> ( );
            StringBuilder strSql = new StringBuilder( );

            strSql.Append("UPDATE MIKANW SET ANW020=@ANW020 WHERE ANW001=@ANW001");
            SqlParameter [] parameter =
            {
                new SqlParameter("@ANW001", SqlDbType.NVarChar, 20),
                new SqlParameter("@ANW020", SqlDbType.Bit)
            };
            parameter [0].Value = oddNum;
            parameter [1].Value = result;
            SQLString.Add(strSql, parameter);

            if (result)
            {
                strSql = new StringBuilder( );
                strSql.AppendFormat("SELECT ANN002,ANN003,ANN005,ANN009,DDA001 FROM MIKANN A LEFT JOIN TPADEA C ON A.ANN003=C.DEA001 INNER JOIN TPADDA D ON C.DEA008=D.DDA001 WHERE ANN001='{0}'", oddNum);

                GenerateSGMRCACB.GenerateSGM(SQLString, strSql, oddNum, department);
            }

            return(SqlHelper.ExecuteSqlTranDic(SQLString));
        }
Esempio n. 3
0
        /// <summary>
        /// 审核
        /// </summary>
        /// <param name="oddNum"></param>
        /// <param name="result"></param>
        /// <returns></returns>
        public bool Exanmie(LineProductMesEntityu.PaintNewspaperHeaderEntity model)
        {
            Dictionary <object, object> SQLString = new Dictionary <object, object> ( );
            StringBuilder strSql = new StringBuilder( );

            strSql.Append("UPDATE MIKPAN SET PAN009=@PAN009 WHERE PAN001=@PAN001");
            SqlParameter [] parameter =
            {
                new SqlParameter("@PAN001", SqlDbType.NVarChar, 20),
                new SqlParameter("@PAN009", SqlDbType.Bit)
            };
            parameter [0].Value = model.PAN001;
            parameter [1].Value = model.PAN009;
            SQLString.Add(strSql, parameter);

            if (model.PAN009)
            {
                strSql = new StringBuilder( );
                strSql.AppendFormat("SELECT PAO002 ANN002,PAO003 ANN003,PAO008 ANN005,PAO012 ANN009,DDA001 FROM MIKPAO A LEFT JOIN TPADEA B ON A.PAO003=B.DEA001 INNER JOIN TPADDA C ON B.DEA008=C.DDA001 WHERE PAO001='{0}'", model.PAN001);

                GenerateSGMRCACB.GenerateSGM(SQLString, strSql, model.PAN001, model.PAN004);
            }

            return(SqlHelper.ExecuteSqlTranDic(SQLString));
        }