示例#1
0
 private void Add_Click(string Name)
 {
     try
     {
         char[] trimChars = new char[] { ',' };
         this.type = this.type.TrimEnd(trimChars);
         MESSAGE message = new MESSAGE();
         if (string.IsNullOrEmpty(this.type))
         {
             OpenWindows.Prompt(message.FeedbackTypeIsNull);
         }
         else if (string.IsNullOrEmpty(this.Description.Text))
         {
             OpenWindows.Prompt(message.DescriptionNotNull);
         }
         else
         {
             this.model.Type        = this.type;
             this.model.Description = this.Description.Text;
             if (UserActionUtils.WriteFeedback(this.model))
             {
                 base.Close();
             }
         }
     }
     catch
     {
     }
 }
示例#2
0
 public void Statistics()
 {
     try
     {
         UserActionUtils.WriteHotSpot(this.users.UserId, 0, this.model);
         this.history = new List <Model.History>(); //new LocalHistoryUtils().GetHistory();
         if (this.history == null)
         {
             this.ForWard.IsEnabled       = false;
             this.ForWard.Icon.Visibility = Visibility.Hidden;
         }
         if (this.index == 0)
         {
             this.BackWard.IsEnabled       = false;
             this.BackWard.Icon.Visibility = Visibility.Hidden;
         }
         else if (this.index == (this.history.Count - 1))
         {
             this.ForWard.IsEnabled       = false;
             this.ForWard.Icon.Visibility = Visibility.Hidden;
         }
     }
     catch
     {
     }
 }
示例#3
0
        private void This_Click(object sender, MouseButtonEventArgs e)
        {
            int num = UserActionUtils.WriteGood(this.GoodCount.Text.ToString(), this.UserId, this.model);

            if (num != 0)
            {
                this.GoodCount.Text = num.ToString();
            }
        }
示例#4
0
 public void Statistics()
 {
     UserActionUtils.WriteHotSpot(this.users.UserId, 1, this.model);
     //List<BACAClient.Model.History> history = new LocalHistoryUtils().GetHistory();
     //if (!new LocalHistoryUtils().IsExists(history, this.model))
     //{
     //    new LocalHistoryUtils().SetHistory(this.model);
     //}
 }
示例#5
0
 private void DownLoad_Click(string Name)
 {
     try
     {
         this.IsGood = true;
         UserActionUtils.DownLoad(this.model.PDFPath, this.model.PDFName, this.model.TypeName, this.model.Key1);
     }
     catch
     {
     }
 }
示例#6
0
 private void Collection_Click(string Name)
 {
     if (string.IsNullOrEmpty(this.users.UserId))
     {
         OpenWindows.Prompt(new MESSAGE().NotLogin);
     }
     else
     {
         UserActionUtils.WriteCollection(this.users.UserId, this.model);
     }
 }
示例#7
0
 private void Good_Click(string Name)
 {
     try
     {
         this.IsGood = true;
         int num = UserActionUtils.WriteGood(this.Count.Text, this.UserID, this.model);
         if (num != 0)
         {
             this.Count.Text    = num.ToString();
             this.Count.ToolTip = num.ToString();
         }
     }
     catch
     {
     }
 }
示例#8
0
        private void Icon_Click(string Name)
        {
            string str = Name.ToLower();

            if (!(str == "up"))
            {
                if (str == "download")
                {
                    string typename = string.Empty;
                    if (this.TypeId == 7)
                    {
                        typename = "引文文献";
                    }
                    else
                    {
                        typename = this.model.TypeName;
                    }
                    UserActionUtils.DownLoad(this.PDFPath, this.PDFName, typename, this.Knowledge);
                }
                else if (str == "close")
                {
                    base.Close();
                    ShowEvent.ShowOrHideWindow(new Flash().Title);
                }
                else if (str == "down")
                {
                    this.page++;
                    this.BindFullImages();
                }
            }
            else
            {
                this.page--;
                this.BindFullImages();
            }
        }
示例#9
0
 public void Statistic()
 {
     UserActionUtils.WriteSearchHistory(0, string.Empty, this.keyword.Text, string.Empty, this.RadioButtonCheck(2), this.returnsearch.UserId);
 }
示例#10
0
 private void This_Click(object sender, MouseButtonEventArgs e)
 {
     UserActionUtils.DownLoad(this.model.PDFPath, this.model.PDFName, this.model.TypeName, this.model.Key1);
 }
示例#11
0
 public void Statistic()
 {
     UserActionUtils.WriteSearchHistory(this.TypeId, ((ComboxItem)this.Type.SelectedItem).Text, this.keyword.Text, this.category, "全部资源", this.returnsearch.UserId);
 }