Files
EasySoft-ZenTaoPMS/test/model/webhook/bind.php
2022-05-09 10:39:04 +08:00

59 lines
2.3 KiB
PHP
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env php
<?php
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
include dirname(dirname(dirname(__FILE__))) . '/class/webhook.class.php';
su('admin');
/**
title=测试 webhookModel->bind();
cid=1
pid=1
绑定admin账号给飞书账号的白袁李创建了测试用户飞书管理端然后通过create方法创建了一条数据关联飞书里的一个用户页面验证成功绑定 >> 1
*/
$webhook = new webhookTest();
$post = array();
$post['type'] = 'feishuuser';
$post['name'] = '测试绑定的webhook';
$post['url'] = '';
$post['secret'] = '';
$post['agentId'] = '';
$post['appKey'] = '';
$post['appSecret'] = '';
$post['wechatCorpId'] = '';
$post['wechatCorpSecret'] = '';
$post['wechatAgentId'] = '';
$post['feishuAppId'] = 'cli_a2e1f12e6d785013';
$post['feishuAppSecret'] = 'Pk4rYTwtFJveepj4JDfPCciSgUqBJYM5';
$post['domain'] = 'http://www.zentaopms.com';
$post['sendType'] = 'sync';
$post['products'] = array('0' => 93);
$post['executions'] = array('0' => 690);
$post['desc'] = '当你老了~~~';
$bind = array();
$bind['userid'] = array();
$bind['userid']['admin'] = 'ou_584a4988c0cf7aa997ccd71b57d740ab';
$bind['userid']['program1whitelist'] = '';
$bind['userid']['program1whitelist'] = '';
$bind['userid']['user3'] = '';
$bind['userid']['user4'] = '';
$bind['userid']['user5'] = '';
$bind['userid']['user6'] = '';
$bind['userid']['user7'] = '';
$bind['userid']['user8'] = '';
$bind['userid']['user9'] = '';
$bind['userid']['user10'] = '';
$bind['userid']['user11'] = '';
$bind['userid']['user12'] = '';
$bind['userid']['user13'] = '';
$bind['userid']['user14'] = '';
$result1 = $webhook->bindTest($post, $bind);
r($result1) && p() && e('1'); //绑定admin账号给飞书账号的白袁李创建了测试用户飞书管理端然后通过create方法创建了一条数据关联飞书里的一个用户页面验证成功绑定
system("./ztest init");