| GET | /document-template/search |
|---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class SearchTemplateRequest extends PagingRequest
{
public String title = null;
public Boolean isActive = null;
public String getTitle() { return title; }
public SearchTemplateRequest setTitle(String value) { this.title = value; return this; }
public Boolean getIsActive() { return isActive; }
public SearchTemplateRequest setIsActive(Boolean value) { this.isActive = value; return this; }
}
public static class PagingRequest
{
public Integer page = null;
public Integer limit = null;
public Integer getPage() { return page; }
public PagingRequest setPage(Integer value) { this.page = value; return this; }
public Integer getLimit() { return limit; }
public PagingRequest setLimit(Integer value) { this.limit = value; return this; }
}
public static class SearchDocumentTemplateResponse implements IResponseRequest
{
public Integer code = null;
public String message = null;
public ArrayList<DocumentTemplate> data = null;
public Long totalCount = null;
public Integer getCode() { return code; }
public SearchDocumentTemplateResponse setCode(Integer value) { this.code = value; return this; }
public String getMessage() { return message; }
public SearchDocumentTemplateResponse setMessage(String value) { this.message = value; return this; }
public ArrayList<DocumentTemplate> getData() { return data; }
public SearchDocumentTemplateResponse setData(ArrayList<DocumentTemplate> value) { this.data = value; return this; }
public Long getTotalCount() { return totalCount; }
public SearchDocumentTemplateResponse setTotalCount(Long value) { this.totalCount = value; return this; }
}
public static class DocumentTemplate
{
public Integer id = null;
@Required()
public String title = null;
public String description = null;
public Boolean isActive = null;
public String fileKey = null;
public String fileUrl = null;
public String fileName = null;
public Long fileSize = null;
public Integer getId() { return id; }
public DocumentTemplate setId(Integer value) { this.id = value; return this; }
public String getTitle() { return title; }
public DocumentTemplate setTitle(String value) { this.title = value; return this; }
public String getDescription() { return description; }
public DocumentTemplate setDescription(String value) { this.description = value; return this; }
public Boolean getIsActive() { return isActive; }
public DocumentTemplate setIsActive(Boolean value) { this.isActive = value; return this; }
public String getFileKey() { return fileKey; }
public DocumentTemplate setFileKey(String value) { this.fileKey = value; return this; }
public String getFileUrl() { return fileUrl; }
public DocumentTemplate setFileUrl(String value) { this.fileUrl = value; return this; }
public String getFileName() { return fileName; }
public DocumentTemplate setFileName(String value) { this.fileName = value; return this; }
public Long getFileSize() { return fileSize; }
public DocumentTemplate setFileSize(Long value) { this.fileSize = value; return this; }
}
}
Java SearchTemplateRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /document-template/search HTTP/1.1 Host: qlcn-api.vsmlab.vn Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
code: 0,
message: String,
data:
[
{
id: 0,
title: String,
description: String,
isActive: False,
fileKey: String,
fileUrl: String,
fileName: String,
fileSize: 0
}
],
totalCount: 0
}