Add project files.
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Elsa.Common.Models;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace Caspian.WorkflowFramework.Models
|
||||
{
|
||||
[PublicAPI]
|
||||
public class CreateAndExecuteWorkflowModel
|
||||
{
|
||||
/// <summary>
|
||||
/// Workflow name
|
||||
/// </summary>
|
||||
[Required]
|
||||
public string? Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Workflow version
|
||||
/// </summary>
|
||||
[Required]
|
||||
public VersionOptions Version { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Current user's id
|
||||
/// </summary>
|
||||
[Required]
|
||||
public long? UserId { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Caspian.WorkflowFramework.Models
|
||||
{
|
||||
public class InquiryStateModel
|
||||
{
|
||||
[Required]
|
||||
public string WorkflowInstanceId { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace Caspian.WorkflowFramework.Models
|
||||
{
|
||||
[PublicAPI]
|
||||
public class PublishEventModel
|
||||
{
|
||||
[Required]
|
||||
public string WorkflowInstanceId { get; set; }
|
||||
|
||||
[Required]
|
||||
public string EventName { get; set; }
|
||||
|
||||
[Required]
|
||||
public string? EventData { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace Caspian.WorkflowFramework.Models
|
||||
{
|
||||
[PublicAPI]
|
||||
public class WorkflowModel
|
||||
{
|
||||
/// <summary>
|
||||
/// شناسه گردش کار
|
||||
/// </summary>
|
||||
public string? InstanceId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// نام گردش کار
|
||||
/// </summary>
|
||||
public string? Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// اتمام گردش کار؟
|
||||
/// </summary>
|
||||
public bool IsComplete { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// برای کدام کاربر؟
|
||||
/// </summary>
|
||||
public long? UserId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// داده صفحه جاری
|
||||
/// </summary>
|
||||
public string? CurrentPageData { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// داده صفحه بعد
|
||||
/// <remark>
|
||||
/// فعلا استفاده ای نداریم
|
||||
/// </remark>
|
||||
/// </summary>
|
||||
public string? NextPageData { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// آدرس صفحه بعدی
|
||||
/// </summary>
|
||||
public string? NextPageUrl { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// رویدادی که باید پس از سابمیت صفحه بعدی منتشر شود
|
||||
/// </summary>
|
||||
public string? NextPageEventName { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace Caspian.WorkflowFramework.Models
|
||||
{
|
||||
[PublicAPI]
|
||||
public class WorkflowResponse<T> : WorkflowResponseBase where T : class, new()
|
||||
{
|
||||
public WorkflowResponse()
|
||||
{
|
||||
Data = new T();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// پاسخ
|
||||
/// </summary>
|
||||
public T? Data { get; set; }
|
||||
}
|
||||
|
||||
[PublicAPI]
|
||||
public class WorkflowResponseBase
|
||||
{
|
||||
/// <summary>
|
||||
/// وضعیت پاسخ
|
||||
/// </summary>
|
||||
public int? Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// پیام پاسخ
|
||||
/// </summary>
|
||||
public string? Message { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user