using System; using System.Xml.Serialization; using System.Collections.Generic; using Top.Api.Util; using Top.Api; using Top.Api.DingTalk; namespace DingTalk.Api.Request { /// /// TOP API: dingtalk.oapi.process.save /// public class OapiProcessSaveRequest : BaseDingTalkRequest { /// /// 入参 /// public string SaveProcessRequest { get; set; } public SaveProcessRequestDomain SaveProcessRequest_ { set { this.SaveProcessRequest = TopUtils.ObjectToJson(value); } } #region IDingTalkRequest Members public override string GetApiName() { return "dingtalk.oapi.process.save"; } public override string GetApiCallType() { return DingTalkConstants.CALL_TYPE_OAPI; } public override IDictionary GetParameters() { TopDictionary parameters = new TopDictionary(); parameters.Add("saveProcessRequest", this.SaveProcessRequest); if (this.otherParams != null) { parameters.AddAll(this.otherParams); } return parameters; } public override void Validate() { } /// /// FormComponentStatVoDomain Data Structure. /// [Serializable] public class FormComponentStatVoDomain : TopObject { /// /// 组件id /// [XmlElement("id")] public string Id { get; set; } /// /// 组件名称 /// [XmlElement("label")] public string Label { get; set; } /// /// 单元 /// [XmlElement("unit")] public string Unit { get; set; } /// /// 统计总和是否大写 /// [XmlElement("upper")] public Nullable Upper { get; set; } } /// /// FormComponentPropVoDomain Data Structure. /// [Serializable] public class FormComponentPropVoDomain : TopObject { /// /// 增加明细动作名称 /// [XmlElement("action_name")] public string ActionName { get; set; } /// /// 套件是否开启异步获取分条件规则 /// [XmlElement("async_condition")] public Nullable AsyncCondition { get; set; } /// /// 套件别名 /// [XmlElement("biz_alias")] public string BizAlias { get; set; } /// /// 套件类型 /// [XmlElement("biz_type")] public string BizType { get; set; } /// /// 内部联系人choice,1表示多选,0表示单选 /// [XmlElement("choice")] public Nullable Choice { get; set; } /// /// 说明文字 /// [XmlElement("content")] public string Content { get; set; } /// /// 是否自动计算时长 /// [XmlElement("duration")] public Nullable Duration { get; set; } /// /// 时间格式 /// [XmlElement("format")] public string Format { get; set; } /// /// 暂不需要 /// [XmlElement("formula")] public string Formula { get; set; } /// /// 表单id /// [XmlElement("id")] public string Id { get; set; } /// /// 表单名称 /// [XmlElement("label")] public string Label { get; set; } /// /// 说明文案的链接地址 /// [XmlElement("link")] public string Link { get; set; } /// /// 是否参与打印(1表示不打印, 0表示打印) /// [XmlElement("not_print")] public string NotPrint { get; set; } /// /// 是否需要大写 默认是需要; 1:不需要大写, 空或者0:需要大写 /// [XmlElement("not_upper")] public string NotUpper { get; set; } /// /// 单选框或者多选框的选项 /// [XmlArray("options")] [XmlArrayItem("string")] public List Options { get; set; } /// /// 占位提示(仅输入类组件) /// [XmlElement("placeholder")] public string Placeholder { get; set; } /// /// 是否必填 /// [XmlElement("required")] public Nullable Required { get; set; } /// /// 需要计算总和的明细组件 /// [XmlArray("stat_field")] [XmlArrayItem("form_component_stat_vo")] public List StatField { get; set; } /// /// 数字组件/日期区间组件单位属性 /// [XmlElement("unit")] public string Unit { get; set; } } /// /// FormComponentPropVo2Domain Data Structure. /// [Serializable] public class FormComponentPropVo2Domain : TopObject { /// /// 套件是否开启异步获取分条件规则 /// [XmlElement("async_condition")] public Nullable AsyncCondition { get; set; } /// /// 控件别名 /// [XmlElement("biz_alias")] public string BizAlias { get; set; } /// /// 控件类型 /// [XmlElement("biz_type")] public string BizType { get; set; } /// /// 内部联系人choice,1表示多选,0表示单选 /// [XmlElement("choice")] public Nullable Choice { get; set; } /// /// 自定义控件渲染类型 /// [XmlElement("common_biz_type")] public string CommonBizType { get; set; } /// /// 说明文字 /// [XmlElement("content")] public string Content { get; set; } /// /// 是否自动计算时长 /// [XmlElement("duration")] public Nullable Duration { get; set; } /// /// 时间格式 /// [XmlElement("format")] public string Format { get; set; } /// /// 暂不需要 /// [XmlElement("formula")] public string Formula { get; set; } /// /// 表单id /// [XmlElement("id")] public string Id { get; set; } /// /// 表单名称 /// [XmlElement("label")] public string Label { get; set; } /// /// 说明文案的链接地址 /// [XmlElement("link")] public string Link { get; set; } /// /// 是否参与打印(1表示不打印, 0表示打印) /// [XmlElement("not_print")] public string NotPrint { get; set; } /// /// 是否需要大写 默认是需要; 1:不需要大写, 空或者0:需要大写 /// [XmlElement("not_upper")] public string NotUpper { get; set; } /// /// 单选框或者多选框的选项 /// [XmlArray("options")] [XmlArrayItem("string")] public List Options { get; set; } /// /// 占位提示(仅输入类组件) /// [XmlElement("placeholder")] public string Placeholder { get; set; } /// /// 是否必填 /// [XmlElement("required")] public Nullable Required { get; set; } /// /// 明细展示方式:表格 table、列表list /// [XmlElement("table_view_mode")] public string TableViewMode { get; set; } /// /// 数字组件/日期区间组件单位属性 /// [XmlElement("unit")] public string Unit { get; set; } } /// /// FormComponentPropVo3Domain Data Structure. /// [Serializable] public class FormComponentPropVo3Domain : TopObject { /// /// 套件是否开启异步获取分条件规则 /// [XmlElement("async_condition")] public Nullable AsyncCondition { get; set; } /// /// 控件别名 /// [XmlElement("biz_alias")] public string BizAlias { get; set; } /// /// 内部联系人choice,1表示多选,0表示单选 /// [XmlElement("choice")] public Nullable Choice { get; set; } /// /// 是否自动计算时长 /// [XmlElement("duration")] public Nullable Duration { get; set; } /// /// 时间格式 /// [XmlElement("format")] public string Format { get; set; } /// /// 计算公式 /// [XmlElement("formula")] public string Formula { get; set; } /// /// 控件id /// [XmlElement("id")] public string Id { get; set; } /// /// 控件名称 /// [XmlElement("label")] public string Label { get; set; } /// /// 是否参与打印(1表示不打印, 0表示打印) /// [XmlElement("not_print")] public string NotPrint { get; set; } /// /// 是否需要大写 默认是需要; 1:不需要大写, 空或者0:需要大写 /// [XmlElement("not_upper")] public string NotUpper { get; set; } /// /// 选项 /// [XmlArray("options")] [XmlArrayItem("string")] public List Options { get; set; } /// /// 占位提示(仅输入类组件) /// [XmlElement("placeholder")] public string Placeholder { get; set; } /// /// 是否必填 /// [XmlElement("required")] public Nullable Required { get; set; } /// /// 数字组件/日期区间组件单位属性 /// [XmlElement("unit")] public string Unit { get; set; } } /// /// FormComponentVo3Domain Data Structure. /// [Serializable] public class FormComponentVo3Domain : TopObject { /// /// 控件类型 /// [XmlElement("component_name")] public string ComponentName { get; set; } /// /// 控件属性 /// [XmlElement("props")] public FormComponentPropVo3Domain Props { get; set; } } /// /// FormComponentVo2Domain Data Structure. /// [Serializable] public class FormComponentVo2Domain : TopObject { /// /// 子控件 /// [XmlArray("children")] [XmlArrayItem("form_component_vo3")] public List Children { get; set; } /// /// 控件类型 /// [XmlElement("component_name")] public string ComponentName { get; set; } /// /// 子表单属性 /// [XmlElement("props")] public FormComponentPropVo2Domain Props { get; set; } } /// /// FormComponentVoDomain Data Structure. /// [Serializable] public class FormComponentVoDomain : TopObject { /// /// 子表单列表 /// [XmlArray("children")] [XmlArrayItem("form_component_vo2")] public List Children { get; set; } /// /// 控件类型 /// [XmlElement("component_name")] public string ComponentName { get; set; } /// /// 表单属性 /// [XmlElement("props")] public FormComponentPropVoDomain Props { get; set; } } /// /// ProcessConfigDomain Data Structure. /// [Serializable] public class ProcessConfigDomain : TopObject { /// /// 是否在审批后台禁用删除操作 /// [XmlElement("disable_delete_process")] public Nullable DisableDeleteProcess { get; set; } /// /// 是否允许表单在审批管理后台可编辑。true表示不可以 /// [XmlElement("disable_form_edit")] public Nullable DisableFormEdit { get; set; } /// /// 是否在审批首页/工作台屏蔽模板 /// [XmlElement("disable_homepage")] public Nullable DisableHomepage { get; set; } /// /// 是否在审批详情页禁用再次提交操作 /// [XmlElement("disable_resubmit")] public Nullable DisableResubmit { get; set; } /// /// 是否在审批后台禁用停用操作 /// [XmlElement("disable_stop_process_button")] public Nullable DisableStopProcessButton { get; set; } /// /// 假流程模板编辑url /// [XmlElement("fake_template_edit_url")] public string FakeTemplateEditUrl { get; set; } /// /// 设置模板是否隐藏,true表示隐藏 /// [XmlElement("hidden")] public Nullable Hidden { get; set; } /// /// 审批模板编辑跳转页。当fake_mode为true时,此参数失效。 /// [XmlElement("template_edit_url")] public string TemplateEditUrl { get; set; } } /// /// SaveProcessRequestDomain Data Structure. /// [Serializable] public class SaveProcessRequestDomain : TopObject { /// /// 企业应用id /// [XmlElement("agentid")] public Nullable Agentid { get; set; } /// /// 发起审批移动端链接 /// [XmlElement("create_instance_mobile_url")] public string CreateInstanceMobileUrl { get; set; } /// /// 发起审批pc链接 /// [XmlElement("create_instance_pc_url")] public string CreateInstancePcUrl { get; set; } /// /// 审批模板描述 /// [XmlElement("description")] public string Description { get; set; } /// /// 分组id /// [XmlElement("dir_id")] public string DirId { get; set; } /// /// 废弃,请使用process_config.disable_form_edit字段 /// [XmlElement("disable_form_edit")] public Nullable DisableFormEdit { get; set; } /// /// true /// [XmlElement("disable_stop_process_button")] public Nullable DisableStopProcessButton { get; set; } /// /// true表示不带流程的模板 /// [XmlElement("fake_mode")] public Nullable FakeMode { get; set; } /// /// 表单列表 /// [XmlArray("form_component_list")] [XmlArrayItem("form_component_vo")] public List FormComponentList { get; set; } /// /// 废弃,请使用process_config.hidden字段 /// [XmlElement("hidden")] public Nullable Hidden { get; set; } /// /// icon /// [XmlElement("icon")] public string Icon { get; set; } /// /// 审批模板名称 /// [XmlElement("name")] public string Name { get; set; } /// /// 原分组id /// [XmlElement("origin_dir_id")] public string OriginDirId { get; set; } /// /// 审批模板唯一码 /// [XmlElement("process_code")] public string ProcessCode { get; set; } /// /// 模板配置属性 /// [XmlElement("process_config")] public ProcessConfigDomain ProcessConfig { get; set; } /// /// 废弃,请使用process_config.template_edit_url字段 /// [XmlElement("template_edit_url")] public string TemplateEditUrl { get; set; } } #endregion } }