8 changed files with 125 additions and 2 deletions
@ -0,0 +1,50 @@
|
||||
package org.springblade.system.vo; |
||||
|
||||
import lombok.Data; |
||||
|
||||
/** |
||||
* 通讯录 |
||||
*/ |
||||
@Data |
||||
public class ContactsVO { |
||||
|
||||
/** |
||||
* 姓名 |
||||
*/ |
||||
private String name; |
||||
/** |
||||
* 手机号码 |
||||
*/ |
||||
private String mobile; |
||||
/** |
||||
* 电子邮件地址 |
||||
*/ |
||||
private String email; |
||||
/** |
||||
* 家庭或通信地址 |
||||
*/ |
||||
private String address; |
||||
|
||||
/** |
||||
* 部门 |
||||
* 逗号分割 拼接在一起 |
||||
*/ |
||||
private String deptNames; |
||||
|
||||
|
||||
/** |
||||
* 岗位s |
||||
* 逗号分割 拼接在一起 |
||||
*/ |
||||
private String postNames; |
||||
|
||||
|
||||
/** |
||||
* 备注信息,记录额外的说明或需要注意的事项 |
||||
*/ |
||||
private String remark; |
||||
|
||||
|
||||
|
||||
|
||||
} |
@ -0,0 +1,33 @@
|
||||
package org.springblade.system.controller; |
||||
|
||||
import io.swagger.annotations.Api; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.tenant.annotation.NonDS; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.system.service.IUserService; |
||||
import org.springblade.system.vo.ContactsVO; |
||||
import org.springframework.web.bind.annotation.GetMapping; |
||||
import org.springframework.web.bind.annotation.RequestMapping; |
||||
import org.springframework.web.bind.annotation.RestController; |
||||
import springfox.documentation.annotations.ApiIgnore; |
||||
|
||||
import java.util.List; |
||||
|
||||
@NonDS |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/contacts") |
||||
@ApiIgnore |
||||
@Api(value = "通讯录", tags = "通讯录") |
||||
public class ContactsController extends BladeController { |
||||
|
||||
private final IUserService userService; |
||||
@GetMapping("/list") |
||||
public R<List<ContactsVO>> list() { |
||||
List<ContactsVO> data =userService.listContacts(); |
||||
return R.data(data); |
||||
|
||||
} |
||||
|
||||
} |
Loading…
Reference in new issue