示例#1
0
    protected override void InitPageValue(XYECOM.Web.BasePage.MyDictionary table)
    {
        string type = table["XY"].ToLower();
        if ("BrandPageList".ToLower() == type)
        {
            this.tbpagenum.Text = table["调用数量"];
            this.tbpagetitlenum.Text = table["标题字数"];
            this.ddlpageorder.SelectedValue = table["排序字段"];
            this.ddlpagedesc.SelectedValue = table["排序方式"];
            this.ddlpagedatetype.SelectedValue = table["日期格式"];
            this.tbpageproductnum.Text = table["品牌描述显示字数"];
            this.tbpagecorporationnum.Text = table["公司名称字数"];

            ClientScript.RegisterStartupScript(GetType(), "page", "myclick(\"li_page\",\"click\");", true);
        }
        if ("BrandList".ToLower() == type)
        {
            this.hidptid.Value = table["信息类别"];
            this.tbnum.Text = table["调用数量"];
            this.tbtitlenum.Text = table["标题字数"];
            this.tbclicknum.Text = table["点击次数"];
            this.ddlorderColumuName.SelectedValue = table["排序字段"];
            this.ddlorder.SelectedValue = table["排序方式"];
            this.chkUserGradeOrder.Checked = (table["优先以会员等级排序"] == "1");
            this.ddldatetype.SelectedValue = table["日期格式"];
            this.tbinfonum.Text = table["品牌描述显示字数"];
            this.tbcorporationNum.Text = table["公司名称字数"];
            this.ddlCommend.SelectedValue = table["是否推荐"];
            this.ddlimg.SelectedValue = table["是否显示缩略图"];

            ClientScript.RegisterStartupScript(GetType(), "page", "myclick(\"li_base\",\"click\");", true);
        }
    }
示例#2
0
文件: Attachment.cs 项目: xyecom/AMS
        /// <summary>
        /// ��ȡ������ı�ʶ����
        /// </summary>
        /// <returns>������ı�ʾ����</returns>
        public static string GetDescTableName(XYECOM.Model.AttachmentItem item)
        {
            if (item == XYECOM.Model.AttachmentItem.Exhibition) return "i_showinfo";
            if (item == XYECOM.Model.AttachmentItem.Individual) return "u_individual";
            if (item == XYECOM.Model.AttachmentItem.Investment) return "i_invitebusinessmaninfo";
            if (item == XYECOM.Model.AttachmentItem.Venture) return "i_demand";
            if (item == XYECOM.Model.AttachmentItem.News) return "n_news";
            if (item == XYECOM.Model.AttachmentItem.Service) return "i_serviceinfo";
            if (item == XYECOM.Model.AttachmentItem.Supply) return "i_supply";
            if (item == XYECOM.Model.AttachmentItem.Topic) return "xy_topic";
            if (item == XYECOM.Model.AttachmentItem.User) return "u_user";
            if (item == XYECOM.Model.AttachmentItem.Certificate) return "U_Certificate";
            if (item == XYECOM.Model.AttachmentItem.FriendLink) return "b_FriendLink";
            if (item == XYECOM.Model.AttachmentItem.Banner) return "u_banner";
            if (item == XYECOM.Model.AttachmentItem.Logo) return "u_logo";
            if (item == XYECOM.Model.AttachmentItem.PartLabel) return "xy_partlabel";
            if (item == XYECOM.Model.AttachmentItem.BaikeImg) return "baike";
            if (item == XYECOM.Model.AttachmentItem.Gift) return "xy_gift";
            if (item == XYECOM.Model.AttachmentItem.ClassAds) return "XY_ClassAds";
            if (item == XYECOM.Model.AttachmentItem.CustomRanking) return "xy_rankinguserinfo";
            if (item == XYECOM.Model.AttachmentItem.xy_userbrand) return "xy_userbrand";
            if (item == XYECOM.Model.AttachmentItem.XY_Brand) return "xy_brand";
            if (item == XYECOM.Model.AttachmentItem.UserVideo) return "Video";
            if (item == XYECOM.Model.AttachmentItem.Slides) return "Slides";
            if (item == XYECOM.Model.AttachmentItem.TeamBuy) return "TeamBuy";
            if (item == XYECOM.Model.AttachmentItem.ForeclosedInfo) return "ForeclosedInfo";
            if (item == XYECOM.Model.AttachmentItem.CreditInfo) return "CreditInfo";

            return "";
        }
示例#3
0
        protected override void InitPageValue(XYECOM.Web.BasePage.MyDictionary table)
        {
            string type = table["XY"].ToLower();
            if ("UserNewsList".ToLower() == type)
            {
                this.hdgetid.Value = table["资讯栏目"];
                this.tbnum.Text = table["调用数量"];
                this.tbtitlenum.Text = table["标题字数"];
                this.tbclicknum.Text = table["点击次数"];
                this.ddlorderColumuName.SelectedValue = table["排序字段"];
                this.ddlorder.SelectedValue = table["排序方式"];
                this.ddldatetype.SelectedValue = table["日期格式"];
                this.ddlCommend.SelectedValue = table["是否推荐"];
                this.tbcontentnum.Text = table["导读显示字数"];
                //this.ddlimg.SelectedValue = table["是否为图片资讯"];
                //this.rbtcobyes.Checked

                ClientScript.RegisterStartupScript(GetType(), "base", "myclick(\"li_base\",\"click\");", true);

            }
            if ("UserNewsPageList".ToLower() == type)
            {
                this.tbpagenum.Text = table["调用数量"];
                tbpagetitlenum.Text = table["标题字数"];
                ddlpagedatetype.SelectedValue = table["日期格式"];
                ddlpageorder.SelectedValue = table["排序字段"];
                ddlpagedesc.SelectedValue = table["排序方式"];
                tbpageproductnum.Text = table["导读显示字数"];
                ClientScript.RegisterStartupScript(GetType(), "page", "myclick(\"li_page\",\"click\");", true);
            }
        }
示例#4
0
文件: Certificate.cs 项目: xyecom/AMS
        /// <summary>
        /// ����֤����Ϣ
        /// </summary>
        /// <param name="Cet"></param>
        /// <param name="CE_ID">id</param>
        /// <returns></returns>
        public int Insert(XYECOM.Model.CertificateInfo info, out long ceInfoid)
        {
            SqlParameter[] Parame = new SqlParameter[]
            {
                new SqlParameter("@CE_ID",SqlDbType.BigInt),
                new SqlParameter("@U_ID",info.U_ID),
                new SqlParameter("@CE_Name",info.CE_Name),
                new SqlParameter("@CE_Organ",info.CE_Organ),
                new SqlParameter("@CE_Begin",info.CE_Begin),
                new SqlParameter("@CE_Upto",info.CE_Upto),
                new SqlParameter("@CE_Type",info.CE_Type),
                new SqlParameter("@CE_Isopen",info.CE_Isopen)

            };
               Parame[0].Direction = ParameterDirection.Output;

               int rowAffected = XYECOM.Core.Data.SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure,"XYP_InsertCertificate", Parame);

               if (rowAffected >= 0)
               {
               if (Parame[0].Value != null && Parame[0].Value.ToString() != "")
                   ceInfoid = (long)Parame[0].Value;
               else
                   ceInfoid = 0;
               }
               else
               {
               ceInfoid = -1;
               }

               return rowAffected;
        }
示例#5
0
文件: TmpLemma.cs 项目: ZhaiQuan/Zhai
        /// <summary>
        /// 审核临时词条
        /// </summary>
        /// <param name="tmpInfo">待审核的临时词条</param>
        /// <returns>返回影响行数</returns>
        public int CheckUpLemma(XYECOM.Model.TmpLemmaInfo tmpInfo)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                    new SqlParameter("@LemmaTmpId",tmpInfo.LemmaTmpId),
                    new SqlParameter("@LemmaId",tmpInfo.LemmaId),
                    new SqlParameter("@LemmaName",tmpInfo.LemmaName),
                    new SqlParameter("@Reference",tmpInfo.Reference),
                    new SqlParameter("@LemmaCategory",tmpInfo.LemmaCategory),
                    new SqlParameter("@ExtendRead",tmpInfo.ExtendRead),
                    new SqlParameter("@LemmaStatus",tmpInfo.LemmaStatus),
                    new SqlParameter("@Creator",tmpInfo.Creator),
                    new SqlParameter("@CreateTime",tmpInfo.CreateTime),
                    new SqlParameter("@Synonyms",tmpInfo.Synonyms),
                    new SqlParameter("@EnName",tmpInfo.EnName),
                    new SqlParameter("@FailReason",tmpInfo.FailReason),
                    new SqlParameter("@FailTime",tmpInfo.FailTime),
                    new SqlParameter("@PassTime",tmpInfo.PassTime),
                    new SqlParameter("@ModiyDate",tmpInfo.ModiyDate),
                    new SqlParameter("@Content",tmpInfo.Content),
                    new SqlParameter("@Modifier",tmpInfo.Modifier),
                    new SqlParameter("@ModifyReason",tmpInfo.ModifyReason),
                    new SqlParameter("@BrowseTimes",tmpInfo.BrowseTimes),
                    new SqlParameter("@EditTimes",tmpInfo.EditTimes)
            };

            return XYECOM.Core.Data.SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_CheckUpLemma", param);
        }
示例#6
0
 /// <summary>
 /// ���
 /// </summary>
 /// <param name="ei">ʵ�����</param>
 /// <returns>-3��ʾ�����Ѿ������</returns>
 public int Insert(XYECOM.Model.UserInputMoneyInfo ei)
 {
     if (!DAL.CheckOrder(ei.OrderID,ei.U_ID))
         return DAL.Insert(ei);
     else
         return -3;
 }
示例#7
0
        protected override void InitPageValue(XYECOM.Web.BasePage.MyDictionary table)
        {
            string type = table["XY"].ToLower();
            if ("TeamBuyList".ToLower() == type)
            {
                tbnum.Text = table["调用数量"];
                tbtitlenum.Text = table["标题字数"];
                ddlOrderColumuName.SelectedValue = table["排序字段"];
                ddlOrderType.SelectedValue = table["排序方式"];
                ddldatetype.SelectedValue = table["日期格式"];
                tbinfonum.Text = table["信息描述字数"];
                ddlIsPlat.SelectedValue = table["是否是平台团购"];
                this.ddlCommend.SelectedValue = table["是否推荐"];
                this.ddlUserCommend.SelectedValue = table["是否用户推荐"];

                ClientScript.RegisterStartupScript(GetType(), "base", "myclick(\"li_base\",\"click\");", true);
            }
            if ("TeamBuyPageList".ToLower() == type)
            {
                this.tbpagenum.Text = table["调用数量"];
                tbpagetitlenum.Text = table["标题字数"];
                ddlPageOrderColumnName.SelectedValue = table["排序字段"];
                ddlPageOrderType.SelectedValue = table["排序方式"];
                ddlIsPlat1.SelectedValue = table["是否是平台团购"];
                ddlpagedatetype.SelectedValue = table["日期格式"];
                tbpageproductnum.Text = table["信息描述字数"];
                ClientScript.RegisterStartupScript(GetType(), "page", "myclick(\"li_page\",\"click\");", true);
            }
        }
示例#8
0
文件: UserData.cs 项目: ZhaiQuan/Zhai
 /// <summary>
 /// ���¾�·
 /// </summary>
 /// <param name="userdata">���ݶ���</param>
 /// <returns>Ӱ������</returns>
 public int Update(XYECOM.Model.UserData userdata)
 {
     SqlParameter[] parm = new SqlParameter[]
     {
         new SqlParameter("@uid",userdata.Uid),
         new SqlParameter("@companyids",userdata.Companyids)
     };
     return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_UpdateUserData", parm);
 }
示例#9
0
 /// <summary>
 /// ����һ�����߸���һ����վ���������
 /// </summary>
 /// <param name="info"></param>
 /// <returns></returns>
 public int InsertAndUpdate(XYECOM.Model.UserAnnounceInfo info)
 {
     SqlParameter[] parm = new SqlParameter[]
     {
         new SqlParameter("@Centent",info.Centent),
         new SqlParameter("@UserID",info.UserID)
     };
     return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertAndUpdateUserAnnounce", parm);
 }
示例#10
0
        /// <summary>
        /// 插入记录
        /// </summary>
        /// <param name="et">数据对象</param>
        /// <returns>受影响行数</returns>
        public int Insert(XYECOM.Model.FinanceTypeInfo et)
        {
            SqlParameter[] parm = new SqlParameter[]
            {
                new  SqlParameter ("@FT_Type",et .FT_Type )
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertFinanceType", parm);
        }
示例#11
0
文件: Demand.cs 项目: ZhaiQuan/Zhai
 /// <summary>
 /// ��Ӽӹ���Ϣ
 /// </summary>
 /// <param name="info">ʵ����</param>
 /// <returns>��Ӱ�������</returns>
 public int Insert(XYECOM.Model.DemandInfo info, out int infoId)
 {
     infoId = 0;
     if (info == null)
     {
         return 0;
     }
     return DAL.Insert(info, out infoId);
 }
示例#12
0
文件: Role.cs 项目: ZhaiQuan/Zhai
        /// <summary>
        /// ��ӽ�ɫ
        /// </summary>
        /// <param name="er">ʵ����</param>
        /// <returns>��Ӱ�������</returns>
        public int Insert(XYECOM.Model.RoleInfo er)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@value",er.UR_Name),
                new SqlParameter("@TableName","b_Role")
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertRole", param);
        }
示例#13
0
        /// <summary>
        ///  添加新闻栏目信息
        /// </summary>
        /// <param name="nt">实体类NewsTitles</param>
        /// <param name="nt_id">所添加的新闻栏目的ID值</param>
        /// <returns>数字,大于或等于0表示添加成功</returns>
        public int Insert(XYECOM.Model.User.UserNewsTitleInfo info, out int nt_id)
        {
            if (info == null)
            {
                nt_id = 0;
                return 0;
            }

            return DAL.Insert(info, out nt_id);
        }
示例#14
0
        /// <summary>
        /// �޸�ָ����������Դ��Ϣ
        /// </summary>
        /// <param name="no">Ҫ�޸ĵ�������Դ��Ϣ����</param>
        /// <returns>���֣����ڻ����0���޸ijɹ�</returns>
        public int Update(XYECOM.Model.NewsOriginInfo no)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@NO_ID",no.NO_ID),
                new SqlParameter("@NO_Name",no.NO_Name)
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_UpdateNewsOrigin", param);
        }
示例#15
0
文件: SupplyBuy.cs 项目: xyecom/AMS
 /// <summary>
 /// 插入信息
 /// </summary>
 /// <param name="info"></param>
 /// <returns></returns>
 public int Insert(XYECOM.Model.SupplyBuyInfo info)
 {
     int num = 0;
     string sql =string.Format(@"insert into i_SupplyBuy
                             (Uid,Title,KeyWord,Contetns,[Name],Tel,AuditingState,Emergency,BuyNum,Area_ID)
                              values ({0},'{1}','{2}','{3}','{4}','{5}',{6},{7},{8},{9})"
                             , info.Uid,info.Title,info.KeyWord,info.Contents,info.U_name,info.Tel,info.State,info.Emergency,info.BuyNum,info.Area_id);
     num = XYECOM.Core.Data.SqlHelper.ExecuteNonQuery(sql);
     return num;
 }
示例#16
0
        public int Insert(XYECOM.Model.LemmaFavoriteInfo info)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@LemmaId",info.LemmaId),
                new SqlParameter("@UserId",info.UserId),
                new SqlParameter("@Tags",info.Tags)
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertLemmaFavorite", param);
        }
示例#17
0
        /// <summary>
        /// �����¼
        /// </summary>
        /// <param name="efc">���ݶ���</param>
        /// <returns>Ӱ������</returns>
        public int Insert(XYECOM.Model.UserFictitiouCountInfo efc)
        {
            SqlParameter[] parm = new SqlParameter[]
            {
                new SqlParameter ("@U_ID",efc.U_ID ),
                new SqlParameter ("@C_SumMoney",efc.C_SumMoney ),
                new SqlParameter ("@C_LeftMoney",efc .C_LeftMoney )
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure,"XYP_InsertFictitiouCount", parm);
        }
示例#18
0
文件: Mode.cs 项目: ZhaiQuan/Zhai
        /// <summary>
        /// 插入记录
        /// </summary>
        /// <param name="info">数据对象</param>
        /// <returns>受影响行数</returns>
        public int Insert(XYECOM.Model.ModeInfo info)
        {
            SqlParameter[] parm = new SqlParameter[]
            {
                new SqlParameter ("@M_Type",info.M_Type )
            };

            int result =  SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertMode", parm);

            UpdateCache();

            return result;
        }
示例#19
0
文件: Finance.cs 项目: xyecom/AMS
        /// <summary>
        /// 插入记录
        /// </summary>
        /// <param name="ef">数据对象</param>
        /// <returns>受影响行数</returns>
        public int Insert(XYECOM.Model.FinanceInfo ef)
        {
            SqlParameter[] parm = new SqlParameter[]
            {
                new SqlParameter ("@U_Name",ef.U_Name ),
                new  SqlParameter ("@UM_ID",ef.UM_ID ),
                new SqlParameter ("@M_Money",ef .M_Money ),
                new  SqlParameter ("@FT_ID",ef.FT_ID ),
                new SqlParameter ("@F_Remark",ef .F_Remark )
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertFinance", parm);
        }
示例#20
0
文件: AdPlace.cs 项目: ZhaiQuan/Zhai
        /// <summary>
        /// �޸�ָ���Ĺ��λ��Ϣ
        /// </summary>
        /// <param name="ap">�ù��λ����</param>
        /// <returns>���֣����ڻ����0��ʾ�޸ijɹ�</returns>
        public int Update(XYECOM.Model.AdPlaceInfo ap)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@AP_ID",ap.AP_ID),
                new SqlParameter("@AP_Name",ap.AP_Name),
                new SqlParameter("@AP_Alt",ap.AP_Alt),
                new SqlParameter("@AT_ID",ap.AT_ID),
                new SqlParameter("@AP_IsUse",ap.AP_IsUse)
            };

            return SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_UpdateAdPlace", param);
        }
示例#21
0
 private void AddChild(XYECOM.Model.XYClassInfo info, string str, String ename)
 {
     this.pnlSuperClass.Controls.Add(new LiteralControl("<li id=\"li_" + info.ClassId + "\" style=\"display:block;\"><ul>"));
     foreach (XYECOM.Model.XYClassInfo info2 in info.childList)
     {
         AddInfoHtml(info2, info.ClassId.ToString(), str, ename);
         if (info2.HasSub)
         {
             AddChild(info2, str + "&nbsp;&nbsp;&nbsp;&nbsp;", ename);
         }
     }
     this.pnlSuperClass.Controls.Add(new LiteralControl("</ul></li>"));
 }
示例#22
0
文件: AdPlace.cs 项目: ZhaiQuan/Zhai
        /// <summary>
        /// ��ӹ��λ
        /// </summary>
        /// <param name="ap">��������</param>
        /// <returns>��Ӱ������</returns>
        public int Insert(XYECOM.Model.AdPlaceInfo ap)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@AP_Name",ap.AP_Name),
                new SqlParameter("@AP_Alt",ap.AP_Alt),
                new SqlParameter("@AT_ID",ap.AT_ID),
                new SqlParameter("@AP_IsUse",ap.AP_IsUse)
            };

            int RowAfferent = SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertAdPlace", param);

            return RowAfferent;
        }
示例#23
0
        /// <summary>
        /// 插入百科分类
        /// </summary>
        /// <param name="info">实体对象</param>
        /// <returns>受影响的行数</returns>
        public int Insert(XYECOM.Model.LemmaCategoryInfo info)
        {
            string fullId = Core.Utils.AppendComma(GetFullID(info.ParentId));
            SqlParameter[] param = new SqlParameter[]
            {
                    new SqlParameter("@CategoryId",info.CategoryId),
                    new SqlParameter("@CategoryName",info.CategoryName),
                    new SqlParameter("@ParentId",info.ParentId),
                    new SqlParameter("@Description",info.Description),
                    new SqlParameter("@FullId",fullId),
                    new SqlParameter("@OrderId",info.OrderId),
            };

            return XYECOM.Core.Data.SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertLemmaCategory", param);
        }
示例#24
0
文件: ExGift.cs 项目: ZhaiQuan/Zhai
        /// <summary>
        /// 
        /// </summary>
        /// <param name="exGiftInfo"></param>
        /// <param name="giftInfo"></param>
        /// <returns></returns>
        public int ExchangeGift(XYECOM.Model.ExGiftInfo exGiftInfo, XYECOM.Model.GiftInfo giftInfo)
        {
            SqlParameter[] spArray =
            {
               new SqlParameter("@UserId",exGiftInfo.UserId),
               new SqlParameter("@GId",giftInfo.GId),
               new SqlParameter("@Name",giftInfo.Name),
               new SqlParameter("@Amount",giftInfo.Amount),
               new SqlParameter("@Number",exGiftInfo.Number),
               new SqlParameter("@ReturnValue",SqlDbType.Int)
            };
            spArray[5].Direction=ParameterDirection.ReturnValue;

            SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_ExchangeGift", spArray);

            return XYECOM.Core.MyConvert.GetInt32(spArray[5].Value.ToString());
        }
示例#25
0
        /// <summary>
        ///  添加用户输入错误支付密码
        /// </summary>
        /// <param name="PInfo">支付密码错误信息对象</param>
        /// <returns>数字,大于或等于0表示添加成功</returns>
        public int Insert(XYECOM.Model.PaymentPassWordMistake PInfo)
        {
            string sql = "";

            SqlParameter[] prarm = new SqlParameter[]
            {
                new SqlParameter("@UserId",PInfo.UserId),
                new SqlParameter("@LockTime",PInfo.LockTime),
                new SqlParameter("@MistakeNum",PInfo.MistakeNum)

            };

            sql += "INSERT INTO XY_PaymentPassWordMistake (UserId,LockTime,MistakeNum) ";
            sql += "VALUES (@UserId,@LockTime,@MistakeNum)";

            int rowAffected = Core.Data.SqlHelper.ExecuteNonQuery(CommandType.Text, sql, prarm);

            return rowAffected;
        }
示例#26
0
        /// <summary>
        /// ���������Դ��Ϣ
        /// </summary>
        /// <param name="no">Ҫ��ӵ�������Դ����</param>
        /// <param name="no_id">��ӳɹ����������Դ�����ڱ��е�IDֵ</param>
        /// <returns>���֣����ڻ����0����ӳɹ�</returns>
        public int Insert(XYECOM.Model.NewsOriginInfo no, out int no_id)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@NO_ID",SqlDbType.Int),
                new SqlParameter("@NO_Name",no.NO_Name)
            };

            param[0].Direction = ParameterDirection.Output;
            int rowAffected = SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertNewsOrigin", param);

            if (param[0].Value.ToString() != "" && param[0].Value.ToString() != null)
            {
                no_id = Convert.ToInt32(param[0].Value);
            }
            else
            {
                no_id = -1;
            }
            return rowAffected;
        }
示例#27
0
文件: HTMLPageSet.cs 项目: xyecom/AMS
        /// <summary>
        /// ��Ӿ�̬ҳ��������Ϣ
        /// </summary>
        /// <param name="ehps">��̬ҳ��������Ϣ���������</param>
        /// <returns>���֡�����0��ʾ���óɹ�</returns>
        public int Insert(XYECOM.Model.HtmlPageSetInfo ehps)
        {
            SqlParameter[] parm = new SqlParameter[]{
                new SqlParameter("@HPS_Index",ehps.HPS_Index),
                new SqlParameter("@HPS_Indextime",ehps.HPS_Indextime),
                new SqlParameter("@HPS_Supply",ehps.HPS_Supply ),
                new SqlParameter("@HPS_Supplytime",ehps.HPS_Supplytime),
                new SqlParameter("@HPS_Demand",ehps.HPS_Demand),
                new SqlParameter("@HPS_Demandtime",ehps.HPS_Demandtime),
                new SqlParameter("@HPS_Business",ehps.HPS_Bussiness),
                new SqlParameter("@HPS_Businesstime",ehps.HPS_Bussinesstime),
                new SqlParameter("@HPS_Engage",ehps.HPS_Engage),
                new SqlParameter("@HPS_Engagetime",ehps.HPS_Engagetime),
                new SqlParameter("@HPS_Corporation",ehps.HPS_Corporation),
                new SqlParameter("@HPS_Corporationtime",ehps.HPS_Corporationtime),
                new SqlParameter("@HPS_Address",ehps.HPS_Address),
                new SqlParameter("@HPS_Addresstime",ehps.HPS_Addresstime)
            };
            int err = SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "[XYP_InsertHTMLPageSet]", parm);

            return err;
        }
示例#28
0
        /// <summary>
        ///  添加新闻栏目信息
        /// </summary>
        /// <param name="info">栏目信息对象</param>
        /// <param name="nt_id">所添加的新闻栏目的ID值</param>
        /// <returns>数字,大于或等于0表示添加成功</returns>
        public int Insert(XYECOM.Model.User.UserNewsTitleInfo info, out int nt_id)
        {
            SqlParameter[] prarm = new SqlParameter[]
            {
                new SqlParameter("@Id",info.Id),
                new SqlParameter("@Name",info.Name),
                new SqlParameter("@UserId",info.UserId),
                new SqlParameter("@ParentId",info.ParentId),
                new SqlParameter("@OrderId",info.OrderId)
            };

            prarm[0].Direction = ParameterDirection.Output;
            string sql = "INSERT INTO XY_UserNewsTitleInfo (";
            sql += "Name,";
            sql += "UserId,";
            sql += "ParentId,";
            sql += "OrderId)";
            sql += "values (";
            sql += "@Name,";
            sql += "@UserId,";
            sql += "@ParentId,";
            sql += "@OrderId)";

            int rowAffected = SqlHelper.ExecuteNonQuery(CommandType.Text, sql, prarm);
            if (rowAffected >= 0)
            {
                if (prarm[0].Value != null && prarm[0].Value.ToString() != "")
                    nt_id = Core.MyConvert.GetInt32(prarm[0].Value.ToString());
                else
                    nt_id = 0;
            }
            else
            {
                nt_id = -1;
            }

            return rowAffected;
        }
示例#29
0
文件: Ad.cs 项目: xyecom/AMS
        /// <summary>
        /// ��ӹ������Ϣ
        /// </summary>
        /// <param name="ad">Ҫ��ӵĹ��������</param>
        /// <returns>���֣����ڻ����0����ӳɹ�</returns>
        public int Insert(XYECOM.Model.AdInfo ad, out int AD_ID)
        {
            SqlParameter[] param = new SqlParameter[]
            {
                new SqlParameter("@AD_ID",SqlDbType.BigInt),
                new SqlParameter("@AD_Name",ad.AD_Name),
                new SqlParameter("@AP_ID",ad.AP_ID),
                new SqlParameter("@AD_LinkURL",ad.AD_LinkURL),
                new SqlParameter("@AD_Type",ad.AD_Type),
                new SqlParameter("@AD_OpenType",ad.AD_OpenType),
                new SqlParameter("@AD_NoteText",ad.AD_NoteText),
                new SqlParameter("@AD_PicURL",ad.AD_PicURL),
                new SqlParameter("@AD_Alt",ad.AD_Alt),
                new SqlParameter("@AD_Width",ad.AD_Width),
                new SqlParameter("@AD_High",ad.AD_High),
                new SqlParameter("@AD_Letter",ad.AD_Letter),
                new SqlParameter("@AD_Font",ad.AD_Font),
                new SqlParameter("@AD_Size",ad.AD_Size),
                new SqlParameter("@AD_Color",ad.AD_Color),
                new SqlParameter("@AD_JSname",ad.AD_JSname),
                new SqlParameter("@AD_CodeContent",ad.AD_CodeContent),
                new SqlParameter("@Ad_StartDate",ad.Ad_StartDate),
                new SqlParameter("@Ad_EndDate",ad.Ad_EndDate)
            };

            param[0].Direction = ParameterDirection.Output;
            int row = SqlHelper.ExecuteNonQuery(CommandType.StoredProcedure, "XYP_InsertAdInfo", param);

            if (param[0].Value != null && param[0].Value.ToString() != "")
            {
                AD_ID = Convert.ToInt32(param[0].Value);
            }
            else
                AD_ID = -1;

            return row;
        }
示例#30
0
        protected override void InitPageValue(XYECOM.Web.BasePage.MyDictionary table)
        {
            string type = table["XY"].ToLower();
            #region 分页
            if ("SupplyBuyPageList".ToLower() == type)
            {
                this.tbpagenum.Text = table["调用数量"];
                this.tbpagetitlenum.Text = table["标题字数"];
                this.ddlpageorder.SelectedValue = table["排序字段"];
                this.ddlpagedesc.SelectedValue = table["排序方式"];
                this.ddlpagedatetype.SelectedValue = table["日期格式"];
                this.tbpageproductnum.Text = table["信息描述字数"];
                this.tbpagecorporationnum.Text = table["公司名称字数"];
                this.areatypeid2.Value = table["求购所属地区"];
                ClientScript.RegisterStartupScript(GetType(), "page", "myclick(\"li_page\",\"click\");", true);
            }
            #endregion
            #region 基本
            if ("SupplyBuyList".ToLower() == type)
            {

                this.tbnum.Text = table["调用数量"];
                this.tbtitlenum.Text = table["标题字数"];

                this.ddlorderColumuName.SelectedValue = table["排序字段"];
                this.ddlorder.SelectedValue = table["排序方式"];

                this.ddldatetype.SelectedValue = table["日期格式"];
                this.tbinfonum.Text = table["信息描述字数"];
                this.tbcorporationNum.Text = table["公司名称字数"];
                this.areatypeid.Value = table["求购所属地区"];

                ClientScript.RegisterStartupScript(GetType(), "page", "myclick(\"li_base\",\"click\");", true);
            }
            #endregion
        }