mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
新增 运营商财务管理页面
This commit is contained in:
@@ -144,4 +144,6 @@ public class OrderBasicInfoController extends BaseController {
|
||||
public AjaxResult manualSettlementOrder(@RequestBody ManualSettlementDTO dto) {
|
||||
return toAjax(orderService.manualSettlementOrder(dto));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,11 +1,15 @@
|
||||
package com.jsowell.web.controller.pile;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
import com.jsowell.common.annotation.Log;
|
||||
import com.jsowell.common.core.controller.BaseController;
|
||||
import com.jsowell.common.core.domain.AjaxResult;
|
||||
import com.jsowell.common.core.domain.vo.AuthorizedDeptVO;
|
||||
import com.jsowell.common.core.page.TableDataInfo;
|
||||
import com.jsowell.common.enums.BusinessType;
|
||||
import com.jsowell.common.exception.BusinessException;
|
||||
import com.jsowell.common.util.SecurityUtils;
|
||||
import com.jsowell.common.util.StringUtils;
|
||||
import com.jsowell.common.util.poi.ExcelUtil;
|
||||
import com.jsowell.pile.domain.PileMerchantInfo;
|
||||
import com.jsowell.pile.dto.CreateMerchantDTO;
|
||||
@@ -15,6 +19,7 @@ import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -109,4 +114,20 @@ public class PileMerchantInfoController extends BaseController {
|
||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
||||
return toAjax(pileMerchantInfoService.deletePileMerchantInfoByIds(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 财务管理页面获取运营商列表
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('pile:merchant:query')")
|
||||
@GetMapping("/getFinancialMerchantList")
|
||||
public TableDataInfo getFinancialMerchantList() {
|
||||
// 权限过滤
|
||||
AuthorizedDeptVO authorizedMap = SecurityUtils.getAuthorizedMap();
|
||||
if (authorizedMap == null) {
|
||||
// 为空表示没有权限,返回空数组
|
||||
return new TableDataInfo();
|
||||
}
|
||||
return getDataTable(pileMerchantInfoService.queryInfoListByIds(authorizedMap));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,4 +23,7 @@ public class AuthorizedDeptVO {
|
||||
|
||||
// 运营商id
|
||||
private List<String> merchantIds;
|
||||
|
||||
// 父级id
|
||||
private String parentId;
|
||||
}
|
||||
|
||||
@@ -132,6 +132,7 @@ public class SecurityUtils {
|
||||
// 登录用户角色
|
||||
List<SysRole> roles = user.getRoles();
|
||||
Long parentId = dept.getParentId();
|
||||
resultVO.setParentId(String.valueOf(parentId));
|
||||
List<String> merchantDeptIds = Lists.newArrayList();
|
||||
List<String> stationDeptIds = Lists.newArrayList();
|
||||
if (parentId == 0L) {
|
||||
|
||||
@@ -77,4 +77,11 @@ public interface PileMerchantInfoMapper {
|
||||
* @return
|
||||
*/
|
||||
PileMerchantInfo queryInfoByDeptId(@Param("deptId") String deptId);
|
||||
|
||||
/**
|
||||
* 通过ids查询信息列表
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
List<PileMerchantInfo> queryInfoListByIds(@Param("deptIds") List<String> deptIds);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.jsowell.pile.service;
|
||||
|
||||
import com.jsowell.common.core.domain.vo.AuthorizedDeptVO;
|
||||
import com.jsowell.pile.domain.PileMerchantInfo;
|
||||
import com.jsowell.pile.dto.CreateMerchantDTO;
|
||||
import com.jsowell.pile.vo.base.MerchantInfoVO;
|
||||
@@ -73,4 +74,11 @@ public interface IPileMerchantInfoService {
|
||||
List<String> queryByMerchantDeptIds(List<String> merchantDeptIds);
|
||||
|
||||
PileMerchantInfo queryInfoByDeptId(String deptId);
|
||||
|
||||
/**
|
||||
* 通过ids查询信息列表
|
||||
* @param authorizedMap
|
||||
* @return
|
||||
*/
|
||||
List<PileMerchantInfo> queryInfoListByIds(AuthorizedDeptVO authorizedMap);
|
||||
}
|
||||
|
||||
@@ -6,10 +6,7 @@ import com.jsowell.common.core.domain.entity.SysDept;
|
||||
import com.jsowell.common.core.domain.entity.SysUser;
|
||||
import com.jsowell.common.core.domain.vo.AuthorizedDeptVO;
|
||||
import com.jsowell.common.exception.BusinessException;
|
||||
import com.jsowell.common.util.DateUtils;
|
||||
import com.jsowell.common.util.DictUtils;
|
||||
import com.jsowell.common.util.SecurityUtils;
|
||||
import com.jsowell.common.util.StringUtils;
|
||||
import com.jsowell.common.util.*;
|
||||
import com.jsowell.pile.domain.PileMerchantInfo;
|
||||
import com.jsowell.pile.dto.CreateMerchantDTO;
|
||||
import com.jsowell.pile.mapper.PileMerchantInfoMapper;
|
||||
@@ -250,4 +247,22 @@ public class PileMerchantInfoServiceImpl implements IPileMerchantInfoService {
|
||||
public PileMerchantInfo queryInfoByDeptId(String deptId) {
|
||||
return pileMerchantInfoMapper.queryInfoByDeptId(deptId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过ids查询信息列表
|
||||
* @param authorizedMap
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<PileMerchantInfo> queryInfoListByIds(AuthorizedDeptVO authorizedMap) {
|
||||
String parentId = authorizedMap.getParentId();
|
||||
List<String> deptIds = Lists.newArrayList();
|
||||
// 父级id为100表示为 thinkgem 账号, 0为 jskf 账号
|
||||
if (!StringUtils.equals("100", parentId) && !StringUtils.equals("0", parentId)) {
|
||||
String deptId = authorizedMap.getDeptId();
|
||||
deptIds.add(deptId);
|
||||
}
|
||||
PageUtils.startPage();
|
||||
return pileMerchantInfoMapper.queryInfoListByIds(deptIds);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -286,4 +286,18 @@
|
||||
where
|
||||
dept_id = #{deptId,jdbcType=VARCHAR}
|
||||
</select>
|
||||
|
||||
<select id="queryInfoListByIds" resultMap="PileMerchantInfoResult">
|
||||
select
|
||||
<include refid="Base_Column_List"/>
|
||||
from
|
||||
pile_merchant_info
|
||||
where del_flag = '0'
|
||||
<if test="deptIds != null and deptIds.size() != 0">
|
||||
and dept_id in
|
||||
<foreach collection="deptIds" item="deptId" open="(" separator="," close=")">
|
||||
#{deptId,jdbcType=VARCHAR}
|
||||
</foreach>
|
||||
</if>
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -1528,7 +1528,7 @@ public class LianLianServiceImpl implements LianLianService {
|
||||
List<EquipmentInfo> resultList = new ArrayList<>();
|
||||
// 通过站点id查询桩基本信息
|
||||
List<PileBasicInfo> list = pileBasicInfoService.getPileListByStationId(String.valueOf(pileStationInfo.getId()));
|
||||
MerchantInfoVO merchantInfo = pileMerchantInfoService.getMerchantInfo(String.valueOf(pileStationInfo.getMerchantId()));
|
||||
// MerchantInfoVO merchantInfo = pileMerchantInfoService.getMerchantInfo(String.valueOf(pileStationInfo.getMerchantId()));
|
||||
// 封装成联联平台对象
|
||||
for (PileBasicInfo pileBasicInfo : list) {
|
||||
EquipmentInfo equipmentInfo = new EquipmentInfo();
|
||||
|
||||
@@ -51,3 +51,11 @@ export function getMerchantList(query) {
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 财务管理页面获取运营商列表
|
||||
export function getFinancialMerchantList() {
|
||||
return request({
|
||||
url: '/pile/merchant/getFinancialMerchantList',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
@@ -26,32 +26,32 @@
|
||||
/>
|
||||
</el-form-item>
|
||||
<div v-if="buttonBoolean">
|
||||
<el-form-item label="订单编号" prop="orderCode">
|
||||
<el-input
|
||||
v-model="queryParams.orderCode"
|
||||
placeholder="请输入订单编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="订单编号" prop="orderCode">
|
||||
<el-input
|
||||
v-model="queryParams.orderCode"
|
||||
placeholder="请输入订单编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="订单编号" prop="orderCode">
|
||||
<el-input
|
||||
v-model="queryParams.orderCode"
|
||||
placeholder="请输入订单编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="订单编号" prop="orderCode">
|
||||
<el-input
|
||||
v-model="queryParams.orderCode"
|
||||
placeholder="请输入订单编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="订单编号" prop="orderCode">
|
||||
<el-input
|
||||
v-model="queryParams.orderCode"
|
||||
placeholder="请输入订单编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="订单编号" prop="orderCode">
|
||||
<el-input
|
||||
v-model="queryParams.orderCode"
|
||||
placeholder="请输入订单编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
</div>
|
||||
<el-button
|
||||
@click="showOrHide()"
|
||||
@@ -66,7 +66,7 @@
|
||||
margin-bottom: 15px;
|
||||
"
|
||||
:icon="icon"
|
||||
>{{ showOrHideText }}
|
||||
>{{ showOrHideText }}
|
||||
</el-button>
|
||||
</el-form>
|
||||
|
||||
@@ -77,7 +77,8 @@
|
||||
icon="el-icon-search"
|
||||
size="mini"
|
||||
@click="handleQuery"
|
||||
>搜索</el-button
|
||||
>搜索
|
||||
</el-button
|
||||
>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
@@ -85,7 +86,8 @@
|
||||
icon="el-icon-refresh"
|
||||
size="mini"
|
||||
@click="resetQuery"
|
||||
>重置</el-button
|
||||
>重置
|
||||
</el-button
|
||||
>
|
||||
</el-col>
|
||||
<el-button
|
||||
@@ -95,89 +97,137 @@
|
||||
size="mini"
|
||||
@click="handleExport"
|
||||
v-hasPermi="['order:order:export']"
|
||||
>导出</el-button
|
||||
>导出
|
||||
</el-button
|
||||
>
|
||||
</el-row>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
stripe
|
||||
border
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="date"
|
||||
label="运营商"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="组织机构代码"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="联系人">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="联系方式">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="入驻时间">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="操作">
|
||||
<template slot-scope="scope">
|
||||
<!-- :to="'/merchant/detail/index/' + scope.row.id" -->
|
||||
:data="merchantList"
|
||||
stripe
|
||||
border
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="merchantName"
|
||||
label="运营商"
|
||||
align="center"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="organizationCode"
|
||||
label="组织机构代码"
|
||||
align="center"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="status"
|
||||
label="状态"
|
||||
align="center"
|
||||
width="130"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<dict-tag
|
||||
:options="dict.type.merchant_status"
|
||||
:value="scope.row.status"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="managerName"
|
||||
label="联系人"
|
||||
align="center"
|
||||
width="130"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="managerPhone"
|
||||
label="联系方式"
|
||||
align="center"
|
||||
width="300"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="createTime"
|
||||
label="入驻时间"
|
||||
align="center"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="操作"
|
||||
align="center">
|
||||
<template slot-scope="scope">
|
||||
<!-- :to="'/merchant/detail/index/' + scope.row.id" -->
|
||||
<router-link
|
||||
to="/financial/merchant/merchantVirtual"
|
||||
class="link-type"
|
||||
>
|
||||
<span>虚拟财务</span>
|
||||
</router-link>
|
||||
<router-link
|
||||
<router-link
|
||||
to="/financial/merchant/cleanFinancical"
|
||||
class="link-type"
|
||||
>
|
||||
<span style="margin-left:10px;color: darkblue;">清分财务</span>
|
||||
</router-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getFinancialMerchantList"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import {getFinancialMerchantList} from "@/api/pile/merchant";
|
||||
|
||||
export default {
|
||||
dicts: ["merchant_status"],
|
||||
data() {
|
||||
return {
|
||||
// 运营商列表
|
||||
merchantList: [],
|
||||
|
||||
showOrHideText: "显示更多查询条件",
|
||||
buttonBoolean: false,
|
||||
//图标,可根据自己的需求匹配
|
||||
icon: "el-icon-caret-bottom",
|
||||
queryParams:{},
|
||||
tableData: [{
|
||||
date: '2016-05-02',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1518 弄'
|
||||
}, {
|
||||
date: '2016-05-04',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1517 弄'
|
||||
}, {
|
||||
date: '2016-05-01',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1519 弄'
|
||||
}, {
|
||||
date: '2016-05-03',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1516 弄'
|
||||
}]
|
||||
|
||||
total: 0,
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
merchantName: null,
|
||||
address: null,
|
||||
status: null,
|
||||
organizationCode: null,
|
||||
managerName: null,
|
||||
managerPhone: null,
|
||||
servicePhone: null,
|
||||
logoUrl: null,
|
||||
},
|
||||
tableData: [{
|
||||
date: '2016-05-02',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1518 弄'
|
||||
}, {
|
||||
date: '2016-05-04',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1517 弄'
|
||||
}, {
|
||||
date: '2016-05-01',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1519 弄'
|
||||
}, {
|
||||
date: '2016-05-03',
|
||||
name: '王小虎',
|
||||
address: '上海市普陀区金沙江路 1516 弄'
|
||||
}]
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getFinancialMerchantList();
|
||||
},
|
||||
methods: {
|
||||
showOrHide() {
|
||||
@@ -191,6 +241,13 @@ export default {
|
||||
this.buttonBoolean = !this.buttonBoolean;
|
||||
}
|
||||
},
|
||||
// 获取运营商列表
|
||||
getFinancialMerchantList() {
|
||||
getFinancialMerchantList().then((response) => {
|
||||
console.log("merchantList", response)
|
||||
this.merchantList = response.rows;
|
||||
})
|
||||
},
|
||||
// 取消按钮
|
||||
cancel() {
|
||||
this.open = false;
|
||||
@@ -224,13 +281,15 @@ export default {
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
::v-deep
|
||||
.el-descriptions--medium:not(.is-bordered)
|
||||
.el-descriptions-item__cell {
|
||||
.el-descriptions--medium:not(.is-bordered)
|
||||
.el-descriptions-item__cell {
|
||||
padding-bottom: 4px;
|
||||
}
|
||||
|
||||
::v-deep .el-descriptions__header {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.cardview-box {
|
||||
width: 100%;
|
||||
margin-bottom: 12px;
|
||||
@@ -238,6 +297,7 @@ export default {
|
||||
color: #4a4a4a;
|
||||
border: 1px solid #f0f0f0;
|
||||
}
|
||||
|
||||
.cardview-static {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
@@ -249,6 +309,7 @@ export default {
|
||||
line-height: 46px;
|
||||
background-color: #f0f0f0;
|
||||
}
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
||||
Reference in New Issue
Block a user