本文整理汇总了C#中LiquiForce.LFSLive.DA.Projects.Projects.ProjectGateway.GetDeleted方法的典型用法代码示例。如果您正苦于以下问题:C# ProjectGateway.GetDeleted方法的具体用法?C# ProjectGateway.GetDeleted怎么用?C# ProjectGateway.GetDeleted使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LiquiForce.LFSLive.DA.Projects.Projects.ProjectGateway
的用法示例。
在下文中一共展示了ProjectGateway.GetDeleted方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: PostPageChanges
private void PostPageChanges()
{
ProjectGateway projectGateway = new ProjectGateway(projectTDS);
int projectId = int.Parse(hdfProjectId.Value);
// General Data
Int64 countryId = projectGateway.GetCountryID(projectId);
int officeId = projectGateway.GetOfficeID(projectId);
Int64? provinceId = projectGateway.GetProvinceID(projectId);
Int64? cityId = projectGateway.GetCityID(projectId);
Int64? countyId = projectGateway.GetCountyID(projectId);
int? projectLeadId = null; if ((ddlProjectLeadId.SelectedValue != "-1") && (ddlProjectLeadId.SelectedIndex > -1)) projectLeadId = int.Parse(ddlProjectLeadId.SelectedValue);
int salesmanId = int.Parse(ddlSalesmanId.SelectedValue);
string projectType = projectGateway.GetProjectType(projectId);
string projectState = projectGateway.GetProjectState(projectId);
string name = tbxName.Text.Trim();
string description = tbxDescription.Text.Trim();
DateTime? proposalDate = null; if (tkrdpProposalDate.SelectedDate.HasValue) proposalDate = tkrdpProposalDate.SelectedDate.Value;
DateTime? startDate = null; if (tkrdpStartDate.SelectedDate.HasValue) startDate = tkrdpStartDate.SelectedDate.Value;
DateTime? endDate = null; if (tkrdpEndDate.SelectedDate.HasValue) endDate = tkrdpEndDate.SelectedDate.Value;
int clientId = projectGateway.GetClientID(projectId);
string clientProjectNumber = tbxClientProjectNumber.Text.Trim();
int? clientPrimaryContactId = null; if ((ddlClientPrimaryContactId.SelectedValue != "-1") && (ddlClientPrimaryContactId.SelectedIndex > -1)) clientPrimaryContactId = int.Parse(ddlClientPrimaryContactId.SelectedValue);
int? clientSecondaryContactId = null; if ((ddlClientSecondaryContactId.SelectedValue != "-1") && (ddlClientSecondaryContactId.SelectedIndex > -1)) clientSecondaryContactId = int.Parse(ddlClientSecondaryContactId.SelectedValue);
bool deleted = projectGateway.GetDeleted(projectId);
int? libraryCategoriesId = null; if (projectGateway.GetLibraryCategoriesId(projectId).HasValue) libraryCategoriesId = (int)projectGateway.GetLibraryCategoriesId(projectId);
bool fairWageApplies = cbxFairWageApplies.Checked;
// ... Update Project Number
Project project = new Project(projectTDS);
string projectNumber;
if (projectGateway.GetOriginalProjectID(projectId) == null)
{
projectNumber = project.UpdateProjectNumber(projectId, salesmanId);
}
else
{
projectNumber = projectGateway.GetProjectNumber(projectId);
}
// ... Update Project
project.Update(projectId, countryId, officeId, projectLeadId, salesmanId, projectNumber, projectType, projectState, name, description, proposalDate, startDate, endDate, clientId, clientProjectNumber, clientPrimaryContactId, clientSecondaryContactId, deleted, libraryCategoriesId, provinceId, cityId, Int32.Parse(hdfCompanyId.Value.Trim()), countyId, fairWageApplies);
// ... If project type is Ballpark update Bill Price and Bill Money
if (projectType == "Ballpark")
{
ProjectSaleBillingPricing projectSaleBillingPricingForGeneralData = new ProjectSaleBillingPricing(projectTDS);
decimal? billPrice = null; if (tbxBillPrice.Text != "") billPrice = Convert.ToDecimal(tbxBillPrice.Text);
string billMoney = ddlBillMoney.SelectedValue;
projectSaleBillingPricingForGeneralData.UpdateBillPrice(projectId, billPrice, billMoney);
}
if ((projectType != "Ballpark") && (projectType != "Internal"))
{
// Sale/Billing/Pricing
//bool saleBidProject = cbxSaleBidProject.Checked;
//bool saleRFP = cbxSaleRFP.Checked;
//bool saleSoleSource = cbxSaleSoleSource.Checked;
//bool saleTermContract = cbxSaleTermContract.Checked;
//string saleTermContractDetail = tbxSaleTermContractDetail.Text.Trim();
//bool saleOther = cbxSaleOther.Checked;
//string saleOtherDetail = tbxSaleOtherDetail.Text.Trim();
//int? saleGettingJob = null; if (tbxSaleGettingJob.Text.Trim() != "") saleGettingJob = int.Parse(tbxSaleGettingJob.Text.Trim());
decimal? billPriceSaleBillingPricing = null; if (tbxBillPriceSaleBillingPricing.Text.Trim() != "") billPriceSaleBillingPricing = decimal.Parse(tbxBillPriceSaleBillingPricing.Text.Trim());
string billMoneySaleBillingPricing = ddlBillMoneySaleBillingPricing.SelectedValue;
decimal? billSubcontractorAmount = null; if (tbxBillSubcontractorAmount.Text.Trim() != "") billSubcontractorAmount = decimal.Parse(tbxBillSubcontractorAmount.Text.Trim());
//string billBidHardDollar = tbxBillBidHardDollar.Text.Trim();
//bool billPerUnit = cbxBillPerUnit.Checked;
//bool billHourly = cbxBillHourly.Checked;
//string billExpectExtras = tbxBillExpectExtras.Text.Trim();
//bool chargesWater = cbxChargesWater.Checked;
//decimal? chargesWaterAmount = null; if (tbxChargesWaterAmount.Text.Trim() != "") chargesWaterAmount = decimal.Parse(tbxChargesWaterAmount.Text.Trim());
//bool chargesDisposal = cbxChargesDisposal.Checked;
//decimal? chargesDisposalAmount = null; if (tbxChargesDisposalAmount.Text.Trim() != "") chargesDisposalAmount = decimal.Parse(tbxChargesDisposalAmount.Text.Trim());
// ... Update Sale/Billing/Pricing
ProjectSaleBillingPricing projectSaleBillingPricing = new ProjectSaleBillingPricing(projectTDS);
//projectSaleBillingPricing.Update(projectId, saleBidProject, saleRFP, saleSoleSource, saleTermContract, saleTermContractDetail, saleOther, saleOtherDetail, saleGettingJob, billPriceSaleBillingPricing, billMoneySaleBillingPricing, billBidHardDollar, billPerUnit, billHourly, billExpectExtras, billSubcontractorAmount, chargesWater, chargesWaterAmount, chargesDisposal, chargesDisposalAmount, Int32.Parse(hdfCompanyId.Value.Trim()));
projectSaleBillingPricing.Update(projectId, billPriceSaleBillingPricing, billMoneySaleBillingPricing, billSubcontractorAmount, Int32.Parse(hdfCompanyId.Value.Trim()));
// ... Update job info
bool typeOfWorkMhRehab = ckbxMhRehab.Checked;
bool typeOfWorkJunctionLining = ckbxJunctionLining.Checked;
bool typeOfWorkProjectManagement = ckbxProjectManagement.Checked;
bool typeOfWorkFullLenghtLining = ckbxFullLengthLining.Checked;
bool typeOfWorkPointRepairs = ckbxPointRepairs.Checked;
bool typeOfWorkRehabAssessment = ckbxRehabAssessment.Checked;
bool typeOfWorkGrout = ckbxGrout.Checked;
bool typeOfWorkOther = ckbxOther.Checked;
bool agreement = cbxSubcontractorAgreement.Checked;
bool writtenQuote = cbxSubcontractorWrittenQuote.Checked;
string role = tbxSubcontractorRole.Text;
ProjectNavigatorProjectJobInfo projectNavigatorProjectJobInfo = new ProjectNavigatorProjectJobInfo(projectNavigatorTDS);
projectNavigatorProjectJobInfo.Update(projectId, typeOfWorkMhRehab, typeOfWorkJunctionLining, typeOfWorkProjectManagement, typeOfWorkFullLenghtLining, typeOfWorkPointRepairs, typeOfWorkRehabAssessment, typeOfWorkGrout, typeOfWorkOther, agreement, writtenQuote, role);
// Costing Updates
//.........这里部分代码省略.........
示例2: UpdateState
//.........这里部分代码省略.........
projectState = "Waiting";
break;
case "project_activate":
projectState = "Active";
break;
case "project_inactivate":
projectState = "Inactive";
break;
case "project_complete":
projectState = "Complete";
break;
case "project_cancel":
projectState = "Canceled";
break;
case "project_unpromote_to_ballpark":
projectState = "Active";
projectType = "Ballpark";
break;
case "project_unpromote_to_proposal":
projectState = "Awarded";
projectType = "Proposal";
break;
case "project_tagAsInternal":
projectState = "Active";
projectType = "Internal";
break;
//Internal Project
case "internalProject_activate":
projectState = "Active";
break;
case "internalProject_complete":
projectState = "Complete";
break;
case "internalProject_cancel":
projectState = "Canceled";
break;
case "internalProject_promote_to_proposal":
projectState = "Awarded";
projectType = "Proposal";
break;
case "internalProject_promote_to_project":
projectState = "Active";
projectType = "Project";
break;
//Ballpark
case "ballparkProject_activate":
projectState = "Active";
break;
case "ballparkProject_cancel":
projectState = "Canceled";
break;
case "ballparkProject_promote_to_proposal":
projectState = "Bidding";
projectType = "Proposal";
break;
case "ballparkProject_promote_to_project":
projectState = "Active";
projectType = "Project";
break;
}
string name = projectGateway.GetName(projectId);
string description = projectGateway.GetDescription(projectId);
DateTime? proposalDate = projectGateway.GetProposalDate(projectId);
DateTime? startDate = projectGateway.GetStartDate(projectId);
DateTime? endDate = projectGateway.GetEndDate(projectId);
int clientId = projectGateway.GetClientID(projectId);
string clientProjectNumber = projectGateway.GetClientProjectNumber(projectId);
int? clientPrimaryContactId = projectGateway.GetClientPrimaryContactID(projectId);
int? clientSecondaryContactId = projectGateway.GetClientSecondaryContactID(projectId);
bool deleted = projectGateway.GetDeleted(projectId);
int? libraryCategoriesId = projectGateway.GetLibraryCategoriesId(projectId);
bool fairWageApplies = projectGateway.GetFairWageApplies(projectId);
// Update project
Project project = new Project(projectTDS);
string projectNumber = project.UpdateProjectNumber(projectId, salesmanId);
project.Update(projectId, countryId, officeId, projectLeadId, salesmanId, projectNumber, projectType, projectState, name, description, proposalDate, startDate, endDate, clientId, clientProjectNumber, clientPrimaryContactId, clientSecondaryContactId, deleted, libraryCategoriesId, provinceId, cityId, Int32.Parse(hdfCompanyId.Value.Trim()), countyId, fairWageApplies);
//Insert in history
ProjectHistory projectHistory = new ProjectHistory(projectTDS);
int newRefId = projectHistory.GetNewRefId();
projectHistory.Insert(projectId, newRefId, projectState, DateTime.Now, Convert.ToInt32(Session["loginID"]), Int32.Parse(hdfCompanyId.Value.Trim()));
}