parent
70d985ccca
commit
98f6e6652d
@ -0,0 +1,70 @@
|
||||
package com.ruoyi.web.controller.carrier.issued;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.system.domain.carrier.TdCarrierIssued;
|
||||
import com.ruoyi.web.controller.manager.CarrierIssuedManager;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 保存Controller
|
||||
* @author Administrator
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("system/saveIssued")
|
||||
public class SaveIssuedController extends BaseController {
|
||||
private String prefix = "system/saveIssued";
|
||||
|
||||
@Resource
|
||||
private CarrierIssuedManager carrierIssuedManager;
|
||||
|
||||
@RequiresPermissions("system:saveIssued:view")
|
||||
@GetMapping()
|
||||
public String saveIssued() {
|
||||
return prefix + "/saveIssued";
|
||||
}
|
||||
|
||||
/**
|
||||
* 载体列表
|
||||
*/
|
||||
@RequiresPermissions("system:saveIssued:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(TdCarrierIssued tdCarrierIssued) {
|
||||
startPage();
|
||||
List<TdCarrierIssued> carriers = carrierIssuedManager.selectTdCarrierList(tdCarrierIssued);
|
||||
return getDataTable(carriers);
|
||||
}
|
||||
|
||||
/**
|
||||
* 国家秘密载体保存
|
||||
*/
|
||||
@RequiresPermissions("system:saveIssued:edit")
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") String id, ModelMap mmap) {
|
||||
TdCarrierIssued tdCarrierIssued = carrierIssuedManager.selectTdCarrier(id);
|
||||
mmap.put("tdCarrierIssued", tdCarrierIssued);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 国家秘密载体保存
|
||||
*/
|
||||
@RequiresPermissions("system:saveIssued:edit")
|
||||
@Log(title = "国家秘密载体保存", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(TdCarrierIssued tdCarrierIssued) {
|
||||
return toAjax(carrierIssuedManager.saveOrUpdate(tdCarrierIssued));
|
||||
}
|
||||
}
|
@ -0,0 +1,83 @@
|
||||
package com.ruoyi.web.controller.carrier.issued;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.system.domain.carrier.TdCarrierIssued;
|
||||
import com.ruoyi.web.controller.manager.CarrierIssuedManager;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 使用Controller
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/system/useIssued")
|
||||
public class UseIssuedController extends BaseController {
|
||||
private String prefix = "system/useIssued";
|
||||
|
||||
@Resource
|
||||
private CarrierIssuedManager carrierIssuedManager;
|
||||
|
||||
@RequiresPermissions("system:useIssued:view")
|
||||
@GetMapping()
|
||||
public String useIssued() {
|
||||
return prefix + "/useIssued";
|
||||
}
|
||||
|
||||
/**
|
||||
* 载体列表
|
||||
*/
|
||||
@RequiresPermissions("system:useIssued:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(TdCarrierIssued tdCarrierIssued) {
|
||||
startPage();
|
||||
List<TdCarrierIssued> carriers = carrierIssuedManager.selectTdCarrierList(tdCarrierIssued);
|
||||
return getDataTable(carriers);
|
||||
}
|
||||
|
||||
/**
|
||||
* 国家秘密载体使用
|
||||
*/
|
||||
@RequiresPermissions("system:useIssued:edit")
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") String id, ModelMap mmap) {
|
||||
TdCarrierIssued tdCarrierIssued = carrierIssuedManager.selectTdCarrier(id);
|
||||
mmap.put("tdCarrierIssued", tdCarrierIssued);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 国家秘密载体使用
|
||||
*/
|
||||
@RequiresPermissions("system:useIssued:edit")
|
||||
@Log(title = "国家秘密载体使用", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(TdCarrierIssued tdCarrierIssued) {
|
||||
return toAjax(carrierIssuedManager.saveOrUpdate(tdCarrierIssued));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 回收
|
||||
*/
|
||||
@GetMapping("/updateStatus/{id}")
|
||||
@ResponseBody
|
||||
public AjaxResult updateStatus(@PathVariable("id") String id) {
|
||||
return toAjax(carrierIssuedManager.updateStatus(id));
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
Loading…
Reference in new issue