コード例 #1
0
        /// <summary>
        /// 添加新记录
        /// </summary>
        /// <param name="json"></param>
        private void ActionAddNew(ref string json)
        {
            #region
            if (WLOGWeekSummaryBusiness.SessionCheckValid(this.SessionUserId, ref json))
            {
                wlogweeksummary.writeUser = this.SessionUserId;
                wlogweeksummary.writeIp   = this.SessionUserIp;

                if (!this.wlogweeksummaryclass.FindUserWeekSummary(wlogweeksummary, ref json))
                {
                    this.wlogweeksummaryclass.AddRow(ref wlogweeksummarydata, wlogweeksummary);
                    json = this.wlogweeksummaryclass.SaveWLOGWeekSummary(wlogweeksummarydata);
                    this.wlogmissionclass.UpdateMissionSummaryId("", this.wlogmission.missionId, this.wlogweeksummary.summaryId);
                }
            }
            #endregion
        }
コード例 #2
0
 /// <summary>
 /// 编辑指定行的记录
 /// </summary>
 /// <param name="json"></param>
 private void ActionEdit(ref string json)
 {
     #region
     if (WLOGWeekSummaryBusiness.SessionCheckValid(this.SessionUserId, ref json))
     {
         wlogweeksummary.writeUser = this.SessionUserId;
         wlogmission.writeIp       = this.SessionUserIp;
         this.wlogweeksummaryclass.EditRow(ref wlogweeksummarydata, wlogweeksummary);
         json = this.wlogweeksummaryclass.SaveWLOGWeekSummary(wlogweeksummarydata);
         if (this.oldmissionsid != this.wlogmission.missionId)
         {
             this.wlogmissionclass.UpdateMissionSummaryId(this.oldmissionsid,
                                                          this.wlogmission.missionId, this.wlogweeksummary.summaryId);
         }
     }
     #endregion
 }