Browse Source

[feat]新增:修改:报销单修改页面,编辑报销单页面修改表单获取为serializeArray对象。

修改:报销管理修改报销管理页面。页面改为报销单页面。

。
dev
zhangsiqi 3 months ago
parent
commit
d351136912
  1. 8
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountController.java
  2. 7
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountServiceImpl.java
  3. 2
      ruoyi-admin/src/main/resources/templates/financial/expense/edit.html
  4. 5
      ruoyi-admin/src/main/resources/templates/financial/expense/expense.html
  5. 4
      ruoyi-admin/src/main/resources/templates/system/baseExpense/baseExpense.html
  6. 6
      ruoyi-admin/src/main/resources/templates/system/baseExpense/detail.html

8
ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountController.java

@ -252,7 +252,13 @@ public class BaseExpenseAccountController extends BaseController
@ResponseBody
public AjaxResult editSave(@RequestBody BaseExpenseAccount baseExpenseAccount)
{
return toAjax(baseExpenseAccountService.updateBaseExpenseAccount(baseExpenseAccount));
baseExpenseAccount.setCreateBy(ShiroUtils.getLoginName());
baseExpenseAccount.setUseStatus("0");
baseExpenseAccount.setAuditStatus("0");
baseExpenseAccount.setFinanceAuditStatus("0");
baseExpenseAccount.setManagerAuditStatus("0");
baseExpenseAccountService.submitApply(baseExpenseAccount);
return AjaxResult.success();
}
/**

7
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountServiceImpl.java

@ -306,6 +306,7 @@ public class BaseExpenseAccountServiceImpl implements IBaseExpenseAccountService
}
/**
* 提交申请
* @param baseExpenseAccount
@ -317,11 +318,15 @@ public class BaseExpenseAccountServiceImpl implements IBaseExpenseAccountService
SysUser user = ShiroUtils.getSysUser();
baseExpenseAccount.setApplyUser(user.getLoginName());
baseExpenseAccount.setApplyTime(DateUtils.getNowDate());
String applyTitle = "";
if (baseExpenseAccount.getExpenseId() == null || baseExpenseAccount.getExpenseId() == 0){
insertBaseExpenseAccount(baseExpenseAccount);
applyTitle = user.getUserName()+"发起了报销单提交审批-"+DateUtils.dateTimeNow();
}else{
updateBaseExpenseAccount(baseExpenseAccount);
applyTitle = user.getUserName()+"发起了报销单修改提交审批-"+DateUtils.dateTimeNow();
}
// 启动流程
String applyTitle = user.getUserName()+"发起了报销单提交审批-"+DateUtils.dateTimeNow();
String instanceType = "submit";
ProcessInstance processInstance = startProcessInstance(applyTitle,instanceType,baseExpenseAccount, user);
String processInstanceId = processInstance.getProcessInstanceId();

2
ruoyi-admin/src/main/resources/templates/financial/expense/edit.html

@ -91,7 +91,7 @@
<script th:inline="javascript">
var prefix = ctx + "system/baseExpense"
var costTypeDatas = [[${@category.getChildByCode('costType')}]];
$("#form-baseExpense-add").validate({focusCleanup: true});
$("#form-baseExpense-edit").validate({focusCleanup: true});
$(function(){
$.ajax({
url: prefix + "/getId",

5
ruoyi-admin/src/main/resources/templates/financial/expense/expense.html

@ -48,7 +48,7 @@
</li>
<li>
<label>财务审核状态:</label>
<select name="financeAuditStatus" th:with="type=${@dict.getType('auditStatus')}">
<select name="financeAuditStatus" th:with="type=${@dict.getType('financial_expense_status')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}"
th:value="${dict.dictValue}"></option>
@ -112,6 +112,7 @@
var loginName = [[${@permission.getPrincipalProperty('loginName')}]];
var auditStatusData = [[${@dict.getType('auditStatus')}]];
var expenseMethodData = [[${@dict.getType('sys_base_expense_method')}]];
var finacialExpenseStatusDatas = [[${@dict.getType('financial_expense_status')}]];
var prefix = ctx + "system/baseExpense";
$(function() {
@ -162,7 +163,7 @@
},
{title: '财务审核状态',field: 'financeAuditStatus',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(auditStatusData, value);
return $.table.selectDictLabel(finacialExpenseStatusDatas, value);
}
},
{title: '报销单编号',field: 'expenseCode',align: 'center',},

4
ruoyi-admin/src/main/resources/templates/system/baseExpense/baseExpense.html

@ -48,7 +48,7 @@
</li>
<li>
<label>财务状态:</label>
<select name="financeAuditStatus" th:with="type=${@dict.getType('auditStatus')}">
<select name="financeAuditStatus" th:with="type=${@dict.getType('financial_expense_status')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}"
th:value="${dict.dictValue}"></option>
@ -112,7 +112,7 @@
var loginName = [[${@permission.getPrincipalProperty('loginName')}]];
var auditStatusData = [[${@dict.getType('auditStatus')}]];
var expenseMethodData = [[${@dict.getType('sys_base_expense_method')}]];
var finacialExpenseStatusDatas = [[${@dict.getType('finacialExpenseStatus')}]];
var finacialExpenseStatusDatas = [[${@dict.getType('financial_expense_status')}]];
var prefix = ctx + "system/baseExpense";
$(function() {

6
ruoyi-admin/src/main/resources/templates/system/baseExpense/detail.html

@ -34,7 +34,11 @@
<div class="form-group">
<label class="col-sm-3 control-label">报销方式:</label>
<div class="col-sm-8">
<input id="detail_expenseMethod" name="expenseMethod" th:field="*{expenseMethod}" class="form-control" type="text" disabled>
<select id="detail_expenseMethod" name="expenseMethod" th:with="type=${@dict.getType('sys_base_expense_method')}" th:field="*{expenseMethod}" disabled>
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}"
th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div id="detail_expenseMethodModal" class="container" style="display: none">

Loading…
Cancel
Save