From fc1d3c074f9ab9020364b6a0894d39f82614f79b Mon Sep 17 00:00:00 2001 From: lyf666 Date: Fri, 3 Mar 2017 10:27:24 +0800 Subject: [PATCH] . --- pom.xml | 2 +- src/main/webapp/doc/api.txt | 55 +++++++++++++++++++++++++------------ 2 files changed, 38 insertions(+), 19 deletions(-) diff --git a/pom.xml b/pom.xml index f815d0c..360d3b3 100644 --- a/pom.xml +++ b/pom.xml @@ -94,7 +94,7 @@ cn.cloudowr sdk - 1.3.4 + 1.3.6 \ No newline at end of file diff --git a/src/main/webapp/doc/api.txt b/src/main/webapp/doc/api.txt index fa46d0a..6b18fa6 100644 --- a/src/main/webapp/doc/api.txt +++ b/src/main/webapp/doc/api.txt @@ -10,24 +10,43 @@ upload (json optional, file) { download (String id required) { return attach's oss url } -attach (key-value pairs) { - return attach list json -} -attAchList (int pageNum default 0, int pageSize default 20) { - return attach list json -} -addAttach (String name required, key-value pairs) { - return attach json -} -updateAttach (String id required, String action optional, String[] keys optional) { - if (actions === 'unset') { - 删除指定id的attach的指定key - return {result: true or false} - } else { - 覆盖指定id的attach的指定key的对应value - return {result: true or false} +index ( + pageSize optional default 20, + pageNum optional default 1, + json optional, + proj optional, + sort optional + ) { + special json: { + key: $ex //exists + key: $nex //not exists + key: $revalue //模糊查询,例:$re^te te开头的value + }, + proj json: { + key1: 1, + key2:0 + //必须全是1或者全是0,id除外 + }, + sort: { + key1: 'desc', + key2: 'asc' } + return dict list json } -deleteAttach (String id required) { - return return {result: true or false} +show (id required) { + return dict json +} +save (json required) { + return saved dict json with id +} +update (id required, json required) { + json { + $set: {k,v...}, + $unset: [k1,k2...], + $rename: {k,newK...} + } + return {result : true or false} +} +delete (id required) { + return {result: true or false} } \ No newline at end of file