CRM自定义
<h3><strong>简要描述:</strong></h3>
<h1>- 条件查询接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/grid</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>status</td>
<td>否</td>
<td>int</td>
<td></td>
<td>状态: 0 禁用; 1 启用</td>
</tr>
<tr>
<td>page</td>
<td>是</td>
<td>int</td>
<td>1</td>
<td>起始页</td>
</tr>
<tr>
<td>limit</td>
<td>是</td>
<td>int</td>
<td>10</td>
<td>显示条数</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;msg&quot;: &quot;success&quot;,
&quot;code&quot;: 0,
&quot;data&quot;: [{
&quot;id&quot;: 1,
&quot;name&quot;: &quot;test&quot;,
&quot;stamp&quot;: &quot;2021-08-26 19:44:40&quot;,
&quot;issue&quot;: true,
&quot;inspections&quot;: &quot;[\&quot;未质检\&quot;, \&quot;质检合格\&quot;, \&quot;质检不合格\&quot;]&quot;,
&quot;admin_id&quot;: 1,
&quot;status&quot;: 1
}],
&quot;count&quot;: 1
}</code></pre>
<p><strong>返回参数说明</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>id</td>
<td>int</td>
<td>crm编号</td>
</tr>
<tr>
<td>name</td>
<td>string</td>
<td>名称</td>
</tr>
<tr>
<td>admin_id</td>
<td>int</td>
<td>用户编号</td>
</tr>
<tr>
<td>issue</td>
<td>Boolean</td>
<td>问卷跳转</td>
</tr>
<tr>
<td>stamp</td>
<td>datetime</td>
<td>创建日期</td>
</tr>
<tr>
<td>inspections</td>
<td>string</td>
<td>质检字段</td>
</tr>
<tr>
<td>status</td>
<td>int</td>
<td>状态,1:启用,0:禁用</td>
</tr>
</tbody>
</table>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 添加crm接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/add</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>name</td>
<td>是</td>
<td>string</td>
<td></td>
<td>名称 ; 不可修改,添加请注意</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 启用 | 禁用 crm 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/enable</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>ids</td>
<td>是</td>
<td>string</td>
<td></td>
<td>crm编号 ,多个逗号分割</td>
</tr>
<tr>
<td>status</td>
<td>是</td>
<td>int</td>
<td></td>
<td>状态: 0 禁用; 1 启用</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 开启,关闭问卷 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/editIssue</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>id</td>
<td>是</td>
<td>string</td>
<td></td>
<td>crm编号</td>
</tr>
<tr>
<td>status</td>
<td>是</td>
<td>int</td>
<td></td>
<td>状态: 0 禁用; 1 启用</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 质检字段编辑 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/editInsp</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>id</td>
<td>是</td>
<td>string</td>
<td>crm编号</td>
</tr>
<tr>
<td>inspections</td>
<td>是</td>
<td>数组</td>
<td>[“未质检”,”质检合格”,”质检不合格”]</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 编辑字段 : 查询 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://xx.com/admin/crm_field/grid</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>method</td>
<td>是</td>
<td>string</td>
<td>grid</td>
<td>方法参数</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;msg&quot;: &quot;success&quot;,
&quot;code&quot;: 0,
&quot;data&quot;: [{
&quot;id&quot;: 1,
&quot;issue&quot;: &quot;&quot;,
&quot;field_name&quot;: &quot;客户姓名&quot;,
&quot;field_type&quot;: 1,
&quot;input_type&quot;: 1,
&quot;is_display&quot;: 1,
&quot;is_edit&quot;: 1,
&quot;is_empty&quot;: 1,
&quot;is_search&quot;: 0,
&quot;jump&quot;: 1,
&quot;field_json&quot;: null,
&quot;status&quot;: 1,
&quot;crm_id&quot;: 1
}],
&quot;count&quot;: 1
}</code></pre>
<p><strong>返回参数说明</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>id</td>
<td>int</td>
<td>编号</td>
</tr>
<tr>
<td>field_name</td>
<td>string</td>
<td>名称</td>
</tr>
<tr>
<td>is_search</td>
<td>int</td>
<td>是否高级查询,1:允许,0,不允许</td>
</tr>
<tr>
<td>issue</td>
<td>string</td>
<td>话术(问卷)</td>
</tr>
<tr>
<td>is_display</td>
<td>int</td>
<td>是否显示 : 0 否; 1 是</td>
</tr>
<tr>
<td>is_edit</td>
<td>int</td>
<td>允许修改:0 否; 1 是</td>
</tr>
<tr>
<td>input_type</td>
<td>string</td>
<td>输入类型 1:短文本,4:长文本,2:单选,3:多选</td>
</tr>
<tr>
<td>field_json</td>
<td>json</td>
<td>字段数据</td>
</tr>
<tr>
<td>jump</td>
<td>int</td>
<td>数据跳转</td>
</tr>
</tbody>
</table>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 编辑字段 : 上移 | 下移 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm_field/displacement</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>id</td>
<td>是</td>
<td>int</td>
<td></td>
<td>编号</td>
</tr>
<tr>
<td>value</td>
<td>是</td>
<td>string</td>
<td></td>
<td>值: 1 上移; -1 下移</td>
</tr>
<tr>
<td>jump</td>
<td>是</td>
<td>int</td>
<td></td>
<td>数据跳转</td>
</tr>
<tr>
<td>crm_id</td>
<td>是</td>
<td>int</td>
<td></td>
<td>crm编号</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 添加字段 | 修改字段 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/field</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>id</td>
<td>是</td>
<td>int</td>
<td></td>
<td>依据字段, 添加:0; 修改; 字段id</td>
</tr>
<tr>
<td>field_name</td>
<td>是</td>
<td>string</td>
<td></td>
<td>字段名称</td>
</tr>
<tr>
<td>issue</td>
<td>否</td>
<td>string</td>
<td></td>
<td>话术(问卷)内容</td>
</tr>
<tr>
<td>is_display</td>
<td>是</td>
<td>int</td>
<td></td>
<td>是否显示: 0 否; 1 是</td>
</tr>
<tr>
<td>is_edit</td>
<td>是</td>
<td>int</td>
<td></td>
<td>允许修改: 0 否; 1 是</td>
</tr>
<tr>
<td>is_search</td>
<td>是</td>
<td>int</td>
<td></td>
<td>允许高级查询: 0 否; 1 是</td>
</tr>
<tr>
<td>input_type</td>
<td>是</td>
<td>string</td>
<td></td>
<td>输入类型 1:短文本,4:长文本,2:单选,3:多选</td>
</tr>
<tr>
<td>crm_id</td>
<td>是</td>
<td>int</td>
<td></td>
<td>crm编号</td>
</tr>
<tr>
<td>field_json</td>
<td>否</td>
<td>数组,例:[]</td>
<td></td>
<td>信息数据,类型为单选,多选时:[{“name”:”史蒂夫”,”next”:”1”}],name时名称,next单选时跳转的字段id,多选时为空</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 编辑字段 : 删除 接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm_field/remove</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>ids</td>
<td>是</td>
<td>string</td>
<td></td>
<td>信息字段编号,多个逗号分割</td>
</tr>
<tr>
<td>crm_id</td>
<td>是</td>
<td>int</td>
<td></td>
<td>crm编号</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<pre><code> {
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;&quot;,
&quot;data&quot;: 1
}</code></pre>
<hr />
<h3><strong>简要描述:</strong></h3>
<h1>- 验证名称接口</h1>
<p><strong>请求URL:</strong></p>
<ul>
<li><code>http://../admin/crm/exist</code></li>
</ul>
<p><strong>请求方式:</strong></p>
<ul>
<li>POST</li>
</ul>
<p><strong>参数:</strong></p>
<table>
<thead>
<tr>
<th>参数名</th>
<th>必选</th>
<th>类型</th>
<th>参数</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>name</td>
<td>是</td>
<td>string</td>
<td></td>
<td>名称</td>
</tr>
</tbody>
</table>
<p><strong>返回示例</strong></p>
<p>复制 <code>{ &quot;code&quot;:0, &quot;msg&quot;:&quot;&quot;, &quot;data&quot;:false://重复,不可用,true:可用 }</code></p>