当前位置:网站首页>phpcms小程序接口新增万能接口get_diy.php
phpcms小程序接口新增万能接口get_diy.php
2022-06-26 08:38:00 【cms小程序插件【官方】】
该接口可以调用任意非文章单表:
调用列表信息get_diy.php
小程序调用api:https://***/api.php?op=get_diy&table=keyword[&num=10][&order=desc]
参数:
- ** wxid必填 验证小程序合法性
- ** table 表名 必填
- ** num 调用数量
- ** page 当前页面
- ** pagesize 指定页面大小
- ** order 排序
- ** where where条件,格式:“id <10 AND status = 1”
- ** moreinfo 是否调用副表
小程序实例代码:
- swan.request({
- url: that.globalData.api.api_diy,
- data: {
- table: 'keyword',
- wxid: wxid,
- num:10,
- order:'DESC',//asc或者desc
- moreinfo:1,//调用副表
- where:"videonum = 1 AND id < 120",
- //page:1
- },
- method: 'GET',
- header: {
- 'content-type': 'application/json' // 默认值
- },
- success: function (res) {
- console.log(res)
- }
- })
使用说明
(1)含有admin,sso的表属于敏感信息表,禁止调用,调用会直接返回错误
(2)内容表,包含:news、picture、video、download以及其它用户自定义的内容表以及副表,禁止调用,可以通过其它接口调用
(3)调用任意的表,该表必须有对应的model类,否则会报错
(4)moreinfo 调用副表,如果没有副表该参数无效
(5)where条件,格式:“id <10 AND status = 1” 按照正常sql格式编写即可
(6)该接口需要对phpcms的表有一定了解
版权所有:石头建站,有需要可以留言
边栏推荐
- 在同花顺开户证券安全吗,
- Mongodb分片环境搭建和验证(redis期末大作业)
- Addition of attention function in yolov5
- Drawing with MATLAB (1)
- Koa_ mySQL_ Integration of TS
- Using MySQL and Qt5 to develop takeout management system (I): environment configuration
- HDU - 6225 little boxes (\u int128)
- dedecms小程序插件正式上线,一键安装无需任何php或sql基础
- Performance comparison of unaryexpr's function on matrix elements in eigen Library
- Clion installation + MinGW configuration + opencv installation
猜你喜欢

Solution to the encoding problem encountered by the crawler when requesting get/post

Euler function: find the number of numbers less than or equal to N and coprime with n

Graduation thesis management system based on SSM

【程序的编译和预处理】

pgsql_ UDF01_ jx

Simulation of parallel structure using webots

Computer mall based on SSM

phpcms v9商城模块(修复自带支付宝接口bug)

滑块验证 - 亲测 (京东)

Trimming_ nanyangjx
随机推荐
拦截器与过滤器的实现代码
VS2005 project call free() compiled with static libcurl library reported heap error
Yolov5进阶之五GPU环境搭建
Backward usage
[300+ continuous sharing of selected interview questions from large manufacturers] column on interview questions of big data operation and maintenance (I)
Convert verification code image to tfrecord file
ImportError: ERROR: recursion is detected during loading of “cv2“ binary extensions. Check OpenCV in
Tensor
Summary of common instructions for arm assembly
Speckle denoising method for ultrasonic image
自动化测试中,三种常用的等待方式,强制式(sleep) 、 隐式 ( implicitly_wait ) 、显式(expected_conditions)
小程序首页加载之前加载其他相关资源或配置(小程序的promise应用)
Exploration of webots and ROS joint simulation (II): model import
Sublime Text3 common plug-ins
Euler function: find the number of numbers less than or equal to N and coprime with n
20220623 getting started with Adobe Illustrator
Trimming_ nanyangjx
Reverse crawling verification code identification login (OCR character recognition)
VS2005 compiles libcurl to normaliz Solution of Lib missing
Convex optimization of quadruped