tvpl.api

<back to all web services

UserUpdateProfileRequest

Requires Authentication
The following routes are available for this service:
POST/users/update-profile
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
import com.google.gson.annotations.*;
import com.google.gson.reflect.*;

public class dtos
{

    public static class UserUpdateProfileRequest
    {
        public String fullName = null;
        public String phone = null;
        public Date birthday = null;
        public String avatar = null;
        
        public String getFullName() { return fullName; }
        public UserUpdateProfileRequest setFullName(String value) { this.fullName = value; return this; }
        public String getPhone() { return phone; }
        public UserUpdateProfileRequest setPhone(String value) { this.phone = value; return this; }
        public Date getBirthday() { return birthday; }
        public UserUpdateProfileRequest setBirthday(Date value) { this.birthday = value; return this; }
        public String getAvatar() { return avatar; }
        public UserUpdateProfileRequest setAvatar(String value) { this.avatar = value; return this; }
    }

    public static class BaseResponse<List> implements IResponseRequest
    {
        public Integer code = null;
        public String message = null;
        public ArrayList<Category> data = null;
        
        public Integer getCode() { return code; }
        public BaseResponse<List> setCode(Integer value) { this.code = value; return this; }
        public String getMessage() { return message; }
        public BaseResponse<List> setMessage(String value) { this.message = value; return this; }
        public ArrayList<Category> getData() { return data; }
        public BaseResponse<List> setData(ArrayList<Category> value) { this.data = value; return this; }
    }

    public static class Category extends CreateCategoryModel
    {
        public Integer id = null;
        public Integer level = null;
        public Integer sortOrder = null;
        public Date lastUpdate = null;
        @Ignore()
        public ArrayList<Category> children = null;
        
        public Integer getId() { return id; }
        public Category setId(Integer value) { this.id = value; return this; }
        public Integer getLevel() { return level; }
        public Category setLevel(Integer value) { this.level = value; return this; }
        public Integer getSortOrder() { return sortOrder; }
        public Category setSortOrder(Integer value) { this.sortOrder = value; return this; }
        public Date getLastUpdate() { return lastUpdate; }
        public Category setLastUpdate(Date value) { this.lastUpdate = value; return this; }
        public ArrayList<Category> getChildren() { return children; }
        public Category setChildren(ArrayList<Category> value) { this.children = value; return this; }
    }

    public static class CreateCategoryModel
    {
        public String name = null;
        public String description = null;
        public CategoryTypes type = null;
        public Boolean isParty = null;
        @Ignore()
        public ArrayList<Integer> childList = null;
        
        public String getName() { return name; }
        public CreateCategoryModel setName(String value) { this.name = value; return this; }
        public String getDescription() { return description; }
        public CreateCategoryModel setDescription(String value) { this.description = value; return this; }
        public CategoryTypes getType() { return type; }
        public CreateCategoryModel setType(CategoryTypes value) { this.type = value; return this; }
        public Boolean getIsParty() { return isParty; }
        public CreateCategoryModel setIsParty(Boolean value) { this.isParty = value; return this; }
        public ArrayList<Integer> getChildList() { return childList; }
        public CreateCategoryModel setChildList(ArrayList<Integer> value) { this.childList = value; return this; }
    }

    public static enum CategoryTypes
    {
        Department,
        PartyGroup,
        DocGroup,
        DocType,
        IssuingAgency,
        Status,
        Subjects,
        Workflow;
    }

}

Java UserUpdateProfileRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /users/update-profile HTTP/1.1 
Host: etc-api.vsmlab.vn 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"fullName":"String","phone":"String","birthday":"0001-01-01T00:00:00.0000000+07:06","avatar":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"code":0,"message":"String","data":{"id":0,"userName":"String","fullName":"String","name":"String","email":"String","departmentId":0,"phoneNumber":"String","partyGroupId":0,"hrmsId":0,"avatar":"String","birthday":"0001-01-01T00:00:00.0000000+07:06","isDelete":0}}