编程语言
首页 > 编程语言> > 钉钉C#发起审批实例demo

钉钉C#发起审批实例demo

作者:互联网

原文:钉钉C#发起审批实例demo

钉钉上只有JAVA的demo,虽然也提供了.net的SDK,但是那资料又臭又长,看的头都大了,

这是c#的服务端发起审批的demo,亲测有效

 

复制代码
IDingTalkClient client = new DefaultDingTalkClient("https://eco.taobao.com/router/rest");
SmartworkBpmsProcessinstanceCreateRequest req = new SmartworkBpmsProcessinstanceCreateRequest();
req.AgentId = 41605932L;
req.ProcessCode = "PROC-EF6YJL35P2-SCKICSB7P750S0YISYKV3-17IBLGZI-1";
req.OriginatorUserId = "manager432";
req.DeptId = 100L;
req.Approvers = "zhangsan,lisi";
req.CcList = "zhangsan,lisi";
req.CcPosition = "START";
List<SmartworkBpmsProcessinstanceCreateRequest.FormComponentValueVoDomain> list2 = new List<SmartworkBpmsProcessinstanceCreateRequest.FormComponentValueVoDomain>();
SmartworkBpmsProcessinstanceCreateRequest.FormComponentValueVoDomain obj3 = new SmartworkBpmsProcessinstanceCreateRequest.FormComponentValueVoDomain();
list2.Add(obj3);
obj3.Name = "请假类型";
obj3.Value = "事假";
obj3.ExtValue = "总天数:1";
req.FormComponentValues_ = list2;
SmartworkBpmsProcessinstanceCreateResponse rsp = client.Execute(req, access_token);
Console.WriteLine(rsp.Body);
复制代码

 

 

c#获取钉钉审批信息demo

http://www.zixun119.com/article/459.cshtml

标签:obj3,C#,demo,req,list2,实例,SmartworkBpmsProcessinstanceCreateRequest,new
来源: https://www.cnblogs.com/lonelyxmas/p/12409034.html