Exemplo n.º 1
0
        /// <summary>
        /// Returns update query for capmaign participants synchronization.
        /// </summary>
        /// <param name="userConnection">An instance of <see cref="UserConnection"/>.</param>
        /// <returns>Update query for capmaign participants synchronization.</returns>
        protected virtual UpdateSelect GetUpdateInProgressParticipantsQuery(UserConnection userConnection)
        {
            var update = new UpdateSelect(userConnection, CampaignParticipantTableName, "cp")
                         .Set("CampaignItemId", Column.SourceColumn(CampaignParticipantOpTableName, "CampaignItemId"))
                         .Set("StatusId", Column.SourceColumn(CampaignParticipantOpTableName, "StatusId"))
                         .Set("StepCompleted", Column.SourceColumn(CampaignParticipantOpTableName, "StepCompleted"))
                         .Set("StepModifiedOn", Column.SourceColumn(CampaignParticipantOpTableName, "StepModifiedOn"))
                         .Set("StepCompletedOn", Column.SourceColumn(CampaignParticipantOpTableName, "StepCompletedOn"))
                         .From(CampaignParticipantOpTableName, null)
                         .Where(ParticipantsToSyncSelect.Condition)
                         .And("cp", "Id").IsEqual(CampaignParticipantOpTableName, "CampaignParticipantId")
                         .And("cp", "CampaignItemId").IsEqual(CampaignParticipantOpTableName, "InitialCampaignItemId")
                         .And("cp", "StatusId").IsEqual(
                Column.Parameter(CoreCampaignConsts.CampaignParticipantInProgressStatusId)) as UpdateSelect;

            update.WithHints(new RowLockHint());
            update.SpecifyNoLockHints();
            return(update);
        }
Exemplo n.º 2
0
 //Pasa productos insertados a la ventana ImportacionToProductWindow
 private void EventoImportacion()
 {
     UpdateSelect?.Invoke(this, EventArgs.Empty);
 }