This commit is contained in:
愉快的大福 2024-07-23 10:06:41 +08:00
commit 8ab846f633
12 changed files with 216 additions and 136 deletions

View File

@ -3,7 +3,8 @@ export default {
name: "afterff",
data() {
return {
dialogVisible:false,
dialogVisible2:false,
tableData: [{
price:2000,
yprice:2500,
@ -15,6 +16,9 @@ export default {
}, ],
}
},
props: {
deptId: String
},
methods: {
onSubmit() {
console.log('表单提交', this.form);
@ -24,6 +28,12 @@ export default {
console.log('取消操作');
//
},
submitForm(){
},
resetForm(){
},
}
}
</script>
@ -35,37 +45,42 @@ export default {
border
style="width: 100%;margin-left: 55px ">
<el-table-column
prop="price"
prop="deductionRate"
align="center"
label="预付金额(元)">
label="扣点税率(元)">
</el-table-column>
<el-table-column
prop="yprice"
prop="likelyTransactionVolume"
align="center"
label="扣点费率(‱">
label="易发生交易流量(元">
</el-table-column>
<el-table-column
prop="address"
prop="serviceFeeStatistics"
align="center"
label="预估交易流量(万)">
label="系统服务费统计">
</el-table-column>
<el-table-column
prop="serviceFeeLimit"
align="center"
label="系统服务费限制(元)">
</el-table-column>
<el-table-column
prop="paymentAmount"
align="center"
label="收款金额">
</el-table-column>
<el-table-column
prop="status"
align="center"
label="剩余交易流量(万)">
</el-table-column>
<el-table-column
prop="upadate"
align="center"
label="状态">
</el-table-column>
<el-table-column
prop="name"
prop="createTime"
align="center"
label="创建时间">
</el-table-column>
<el-table-column
prop="name"
prop="createName"
align="center"
label="创建人">
</el-table-column>
@ -81,7 +96,6 @@ export default {
<el-button
size="mini"
@click="handleEdit(scope.$index, scope.row)">修改</el-button>
</template>
</el-table-column>
</el-table>
@ -89,25 +103,58 @@ export default {
title="新增"
:visible.sync="dialogVisible"
width="30%">
<el-form :model="form" label-width="150px">
<el-form-item label="预付金额">
<el-input v-model="form.prepaidAmount" placeholder="请输入预付金额"></el-input>
</el-form-item>
<!-- 表头插入按钮 -->
<el-form :model="form" label-width="120px">
<el-form-item label="扣点费率">
<el-input v-model="form.deductionRate" placeholder="请输入扣点费率" suffix-icon="el-icon-percent"></el-input>
<el-input v-model="form.deductionRate" placeholder="请输入扣点费率" suffix="%"></el-input>
</el-form-item>
<el-form-item label="预估交易流量">
<el-input v-model="form.estimatedTraffic" placeholder="请输入预估交易流量" suffix-icon="el-icon-percent"></el-input>
<el-form-item label="已发生交易流量">
<el-input v-model="form.transactionFlow" placeholder="请输入已发生交易流量" suffix="万元"></el-input>
</el-form-item>
<el-form-item label="剩余交易流量">
<el-input v-model="form.remainingTraffic" placeholder="请输入剩余交易流量" suffix-icon="el-icon-percent" readonly></el-input>
<el-form-item label="系统服务费">
<el-input v-model="form.systemFee" placeholder="请输入系统服务费" suffix="万元"></el-input>
</el-form-item>
<el-form-item label="系统服务费限制">
<el-input v-model="form.systemFeeLimit" placeholder="请输入系统服务费限制" suffix="万元"></el-input>
</el-form-item>
</el-form>
<div class="button-group">
<el-button type="danger" @click="onCancel">取消</el-button>
<el-button type="primary" @click="onSubmit">保存</el-button>
</div>
</el-dialog
>
<el-dialog
title="新增"
:visible.sync="dialogVisible2"
width="30%">
<el-form :model="form" label-width="120px">
<el-form-item label="扣点费率">
<!-- 假设扣点费率是固定的这里仅显示 -->
<span>{{ form.deductionRate }}%</span>
</el-form-item>
<el-form-item label="已发生交易流量">
<el-input v-model="form.transactionVolume" placeholder="请输入交易流量"></el-input>
</el-form-item>
<el-form-item label="系统服务费统计">
<!-- 假设这是计算得出的这里仅显示 -->
<span>{{ form.systemServiceFee }}万元</span>
</el-form-item>
<el-form-item label="系统服务费限制">
<!-- 假设这是固定的这里仅显示 -->
<span>{{ form.serviceFeeLimit }}万元</span>
</el-form-item>
<el-form-item label="收款金额">
<el-input v-model="form.paymentAmount" placeholder="请输入收款金额"></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit">保存</el-button>
<el-button @click="onCancel">取消</el-button>
<el-button type="primary" @click="submitForm('form')">保存</el-button>
<el-button @click="resetForm('form')">取消</el-button>
</el-form-item>
</el-form>
</el-dialog>
</div>
</template>

View File

@ -14,10 +14,10 @@ export default {
upadate: '2016-05-02',
}, ],
form: {
deductionRate: '',
transactionFlow: '',
systemFee: '',
systemFeeLimit: ''
prepaidAmount:'',
deductionRate:'',
estimatedTransactionVolume:'',
remainingTransactionVolume:'',
},
form2: {
form: {
@ -30,63 +30,70 @@ export default {
}
}
},
props: {
deptId: String
},
methods: {
cancel() {
onCancel() {
//
console.log('取消操作');
},
save() {
onSubmit() {
//
console.log('保存操作', this.form);
}
},
handleUpdate1(){
},
handleEdit(){
},
}
}
</script>
<template>
<div>
<el-table
:data="tableData"
border
style="width: 100%;margin-left: 55px ">
<el-table-column
prop="price"
prop="prepaidAmount"
align="center"
label="扣点税率(元)">
label="预付金额(元)">
</el-table-column>
<el-table-column
prop="yprice"
prop="deductionRate"
align="center"
label="易发生交易流量(元">
label="扣点费率(‱">
</el-table-column>
<el-table-column
prop="address"
prop="estimatedTransactionVolume"
align="center"
label="系统服务费统计">
label="预估交易流量(万)">
</el-table-column>
<el-table-column
prop="remainingTransactionVolume"
align="center"
label="剩余交易流量(万)">
</el-table-column>
<el-table-column
prop="status"
align="center"
label="系统服务费限制(元)">
</el-table-column>
<el-table-column
prop="upadate"
align="center"
label="收款金额">
</el-table-column>
<el-table-column
prop="name"
align="center"
label="状态">
</el-table-column>
<el-table-column
prop="name"
prop="createTime"
align="center"
label="创建时间">
</el-table-column>
<el-table-column
prop="name"
prop="createName"
align="center"
label="创建人">
</el-table-column>
@ -102,7 +109,6 @@ export default {
<el-button
size="mini"
@click="handleEdit(scope.$index, scope.row)">修改</el-button>
</template>
</el-table-column>
</el-table>
@ -110,53 +116,22 @@ export default {
title="新增"
:visible.sync="dialogVisible"
width="30%">
<!-- 表头插入按钮 -->
<el-form :model="form" label-width="120px">
<el-form :model="form" label-width="150px">
<el-form-item label="预付金额">
<el-input v-model="form.prepaidAmount" placeholder="请输入预付金额"></el-input>
</el-form-item>
<el-form-item label="扣点费率">
<el-input v-model="form.deductionRate" placeholder="请输入扣点费率" suffix="%"></el-input>
<el-input v-model="form.deductionRate" placeholder="请输入扣点费率" suffix-icon="el-icon-percent"></el-input>
</el-form-item>
<el-form-item label="已发生交易流量">
<el-input v-model="form.transactionFlow" placeholder="请输入已发生交易流量" suffix="万元"></el-input>
<el-form-item label="预估交易流量">
<el-input v-model="form.estimatedTransactionVolume" placeholder="请输入预估交易流量" suffix-icon="el-icon-percent"></el-input>
</el-form-item>
<el-form-item label="系统服务费">
<el-input v-model="form.systemFee" placeholder="请输入系统服务费" suffix="万元"></el-input>
</el-form-item>
<el-form-item label="系统服务费限制">
<el-input v-model="form.systemFeeLimit" placeholder="请输入系统服务费限制" suffix="万元"></el-input>
</el-form-item>
</el-form>
<div class="button-group">
<el-button type="danger" @click="cancel">取消</el-button>
<el-button type="primary" @click="save">保存</el-button>
</div>
</el-dialog
>
<el-dialog
title="新增"
:visible.sync="dialogVisible2"
width="30%">
<el-form :model="form" label-width="120px">
<el-form-item label="扣点费率">
<!-- 假设扣点费率是固定的这里仅显示 -->
<span>{{ form.deductionRate }}%</span>
</el-form-item>
<el-form-item label="已发生交易流量">
<el-input v-model="form.transactionVolume" placeholder="请输入交易流量"></el-input>
</el-form-item>
<el-form-item label="系统服务费统计">
<!-- 假设这是计算得出的这里仅显示 -->
<span>{{ form.systemServiceFee }}万元</span>
</el-form-item>
<el-form-item label="系统服务费限制">
<!-- 假设这是固定的这里仅显示 -->
<span>{{ form.serviceFeeLimit }}万元</span>
</el-form-item>
<el-form-item label="收款金额">
<el-input v-model="form.receiptAmount" placeholder="请输入收款金额"></el-input>
<el-form-item label="剩余交易流量">
<el-input v-model="form.remainingTransactionVolume" placeholder="请输入剩余交易流量" suffix-icon="el-icon-percent" readonly></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="submitForm('form')">保存</el-button>
<el-button @click="resetForm('form')">取消</el-button>
<el-button type="primary" @click="onSubmit">保存</el-button>
<el-button @click="onCancel">取消</el-button>
</el-form-item>
</el-form>
</el-dialog>

View File

@ -1,39 +1,79 @@
<script>
import {addYearApi, getYearListApi, updateYearApi} from "@/api/system/Site/compant";
export default {
name: "yearff",
data() {
return {
dialogVisible:false,
tableData: [{
price:2000,
yprice:2500,
date: '2016-05-02',
name: '王小虎',
address: '上海市普陀区金沙江路 1518 弄',
status:'进行中',
upadate: '2016-05-02',
}, ],
tableData: [ ],
form: {
id: '',
price: '',
paymentAmount: '',
prepaidAmount: '',
validDate: [],
systemValidityPeriodStart:'',
systemValidityPeriodEnd:'',
deptId:this.deptId,
},
}
},
props: {
deptId: Number
},
created() {
console.log("deptId",this.deptId)
this.getList()
},
methods: {
getList() {
getYearListApi({deptId : this.deptId}).then(res => {
this.tableData = res.data.records
})
},
onSubmit() {
console.log('表单提交', this.form);
if (this.form.validDate) {
this.form.systemValidityPeriodStart = this.form.validDate[0]
this.form.systemValidityPeriodEnd = this.form.validDate[1]
}
console.log("123123")
if (this.form.id) {
updateYearApi(this.form).then(res => {
this.getList();
this.dialogVisible = false;
})
}else {
addYearApi(this.form).then(res => {
this.getList();
this.dialogVisible
})
}
//
},
onCancel() {
console.log('取消操作');
this.dialogVisible=false
//
},
handleEdit(data) {
this.form = data
this.dialogVisible=false
},
cal() {
this.form= {
id: '',
price: '',
prepaidAmount: '',
validDate: [],
systemValidityPeriodStart:'',
systemValidityPeriodEnd:'',
deptId:this.deptId,
}
}
}
}
@ -51,7 +91,7 @@ export default {
label="价格(元)">
</el-table-column>
<el-table-column
prop="yprice"
prop="prepaidAmount"
align="center"
label="付款金额(元)">
</el-table-column>
@ -66,12 +106,12 @@ export default {
label="状态">
</el-table-column>
<el-table-column
prop="upadate"
prop="createTime"
align="center"
label="创建时间">
</el-table-column>
<el-table-column
prop="name"
prop="createName"
align="center"
label="创建人">
</el-table-column>
@ -101,7 +141,7 @@ export default {
<el-input v-model="form.price" placeholder="请输入价格"></el-input>
</el-form-item>
<el-form-item label="付款金额">
<el-input v-model="form.paymentAmount" placeholder="请输入付款金额"></el-input>
<el-input v-model="form.prepaidAmount" placeholder="请输入付款金额"></el-input>
</el-form-item>
<el-form-item label="系统有效日期">
<el-date-picker

View File

@ -322,14 +322,14 @@
</el-row>
<el-row>
<template v-if="ruleForm.turnoverType === '3'">
<beforeff></beforeff>
<beforeff :deptId="queryParams.deptId"></beforeff>
</template>
<template v-if="ruleForm.turnoverType === '4'">
<afterff></afterff>
<afterff :deptId="queryParams.deptId"></afterff>
</template>
<template v-if="ruleForm.turnoverType === '5'">
<yearff></yearff>
<yearff :deptId="queryParams.deptId"></yearff>
</template>
<template v-if="ruleForm.turnoverType === '6'">
<el-col :span="10">

View File

@ -1,8 +1,12 @@
package com.fuint.business.deptPay.entity;
import cn.hutool.core.date.DateTime;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fuint.repository.model.base.BaseEntity;
import lombok.Data;
import java.util.Date;
/**
* 存储年付费的表(DeptPriceInfo)实体类
*
@ -27,11 +31,15 @@ public class DeptPriceInfo extends BaseEntity {
/**
* 系统有效期整数表示天数不能为空
*/
private Integer systemValidityPeriod;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
private Date systemValidityPeriodStart;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
private Date systemValidityPeriodEnd;
/**
* 状态布尔类型不能为空
*/
private Integer status;
private Integer deptId;

View File

@ -1,5 +1,6 @@
package com.fuint.business.deptPay.entity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fuint.repository.model.base.BaseEntity;
import lombok.Data;
@ -40,6 +41,9 @@ public class DeptServiceFeeInfo extends BaseEntity {
* 状态布尔类型不能为空
*/
private Integer status;
private Integer deptId;
@TableField(exist = false)
private String createName;

View File

@ -36,6 +36,7 @@ public class DeptTransactionInfo extends BaseEntity {
* 状态布尔类型不能为空
*/
private Integer status;
private Integer deptId;

View File

@ -30,7 +30,7 @@ public interface DeptPriceInfoMapper {
* @param page 分页对象
* @return 对象列表
*/
IPage<DeptPriceInfo> queryAllByLimit(@Param("page") Page page, DeptPriceInfo deptPriceInfo);
IPage<DeptPriceInfo> queryAllByLimit(@Param("page") Page page,@Param("info") DeptPriceInfo deptPriceInfo);
/**
* 统计总行数

View File

@ -21,23 +21,21 @@ id,price,prepaid_amount,system_validity_period,status
<!--查询指定行数据-->
<select id="queryAllByLimit" resultMap="DeptPriceInfoMap">
select
id,price,prepaid_amount,system_validity_period,status
id,price,prepaid_amount,system_validity_period_start,system_validity_period_end,status
from dept_price_info
<where>
<if test="id != null">
and id = #{id}
<if test="info.id != null">
and id = #{info.id}
</if>
<if test="price != null">
and price = #{price}
<if test="info.price != null">
and price = #{info.price}
</if>
<if test="prepaidAmount != null">
and prepaid_amount = #{prepaidAmount}
<if test="info.prepaidAmount != null">
and prepaid_amount = #{info.prepaidAmount}
</if>
<if test="systemValidityPeriod != null">
and system_validity_period = #{systemValidityPeriod}
</if>
<if test="status != null">
and status = #{status}
<if test="info.status != null">
and status = #{info.status}
</if>
</where>
</select>
@ -67,9 +65,9 @@ id,price,prepaid_amount,system_validity_period,status
<!--新增所有列-->
<insert id="insert" keyProperty="id" useGeneratedKeys="true">
insert into dept_price_info(price,prepaid_amount,system_validity_period,status
insert into dept_price_info(price,prepaid_amount,system_validity_period_start,system_validity_period_end,status,dept_id
)
values (#{price}#{prepaidAmount}#{systemValidityPeriod}#{status})
values (#{price},#{prepaidAmount},#{systemValidityPeriodStart},#{systemValidityPeriodEnd},#{status},#{deptId})
</insert>
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
@ -102,12 +100,19 @@ price = values(price)prepaid_amount = values(prepaid_amount)system_validity_peri
<if test="prepaidAmount != null">
prepaid_amount = #{prepaidAmount},
</if>
<if test="systemValidityPeriod != null">
system_validity_period = #{systemValidityPeriod},
<if test="systemValidityPeriodStart != null">
system_validity_period_start = #{systemValidityPeriodStart},
</if>
<if test="systemValidityPeriodEnd != null">
system_validity_period_end = #{systemValidityPeriodEnd},
</if>
<if test="status != null">
status = #{status},
</if>
<if test="deptId != null">
dept_id = #{deptId},
</if>
</set>
where id = #{id}
</update>

View File

@ -46,7 +46,7 @@ public class DeptPriceInfoServiceImpl implements DeptPriceInfoService {
@Override
public IPage<DeptPriceInfo> queryByPage(@Param("page") Page page, DeptPriceInfo deptPriceInfo) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
deptPriceInfo.setStoreId(nowAccountInfo.getStoreId());
// deptPriceInfo.setStoreId(nowAccountInfo.getStoreId());
return this.deptPriceInfoMapper.queryAllByLimit(page, deptPriceInfo);
}
@ -59,7 +59,7 @@ public class DeptPriceInfoServiceImpl implements DeptPriceInfoService {
@Override
public DeptPriceInfo insert(DeptPriceInfo deptPriceInfo) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
deptPriceInfo.setStoreId(nowAccountInfo.getStoreId());
// deptPriceInfo.setStoreId(nowAccountInfo.getStoreId());
this.deptPriceInfoMapper.insert(deptPriceInfo);
return deptPriceInfo;
}

View File

@ -46,7 +46,7 @@ public class DeptServiceFeeInfoServiceImpl implements DeptServiceFeeInfoService
@Override
public IPage<DeptServiceFeeInfo> queryByPage(@Param("page") Page page, DeptServiceFeeInfo deptServiceFeeInfo) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
deptServiceFeeInfo.setStoreId(nowAccountInfo.getStoreId());
// deptServiceFeeInfo.setStoreId(nowAccountInfo.getStoreId());
return this.deptServiceFeeInfoMapper.queryAllByLimit(page, deptServiceFeeInfo);
}
@ -59,7 +59,7 @@ public class DeptServiceFeeInfoServiceImpl implements DeptServiceFeeInfoService
@Override
public DeptServiceFeeInfo insert(DeptServiceFeeInfo deptServiceFeeInfo) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
deptServiceFeeInfo.setStoreId(nowAccountInfo.getStoreId());
// deptServiceFeeInfo.setStoreId(nowAccountInfo.getStoreId());
this.deptServiceFeeInfoMapper.insert(deptServiceFeeInfo);
return deptServiceFeeInfo;
}

View File

@ -46,7 +46,7 @@ public class DeptTransactionInfoServiceImpl implements DeptTransactionInfoServic
@Override
public IPage<DeptTransactionInfo> queryByPage(@Param("page") Page page, DeptTransactionInfo deptTransactionInfo) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
deptTransactionInfo.setStoreId(nowAccountInfo.getStoreId());
// deptTransactionInfo.setStoreId(nowAccountInfo.getStoreId());
return this.deptTransactionInfoMapper.queryAllByLimit(page, deptTransactionInfo);
}
@ -59,7 +59,7 @@ public class DeptTransactionInfoServiceImpl implements DeptTransactionInfoServic
@Override
public DeptTransactionInfo insert(DeptTransactionInfo deptTransactionInfo) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
deptTransactionInfo.setStoreId(nowAccountInfo.getStoreId());
// deptTransactionInfo.setStoreId(nowAccountInfo.getStoreId());
this.deptTransactionInfoMapper.insert(deptTransactionInfo);
return deptTransactionInfo;
}