master
xy 2 years ago
parent 58f407fa5c
commit 90b059bc6e

@ -5,6 +5,9 @@
<!--清除浏览器中的缓存 -->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta http-equiv="pragram" content="no-cache">
<meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="expires" content="0">
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<title><%= webpackConfig.name %></title>
</head>

@ -130,6 +130,24 @@
</div>
</div>
</template>
<template v-slot:is_framework>
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red; font-weight: 600; padding-right: 4px"
>*</span
>是否框架协议
</div>
<div class="xy-table-item-content">
<el-switch
v-model="form.is_framework"
active-text="是"
inactive-text="否"
:active-value="1"
:inactive-value="0"
/>
</div>
</div>
</template>
</xy-dialog>
</div>
</template>
@ -164,6 +182,7 @@ export default {
guarantee_year: "",
date: this.$moment().format('YYYY-MM-DD'),
is_contract: 1,
is_framework: "",
purchase_status: 3,
join_status: 3,
invite_status: 3

@ -224,7 +224,7 @@
<div slot="tip" class="el-upload__tip">
支持文件格式.rar .zip .doc .docx .pdf .jpg .png .gif .mp4 .xls
.xlsx
<br />单个文件不能超过2M
<br />单个文件不能超过20M
</div>
</el-upload>
</div>
@ -395,7 +395,7 @@ export default {
},
uploadBefore(file) {
console.log(file);
if (file.size / 1000 > 2 * 1024) {
if ((file.size / 1000) > (20 * 1024)) {
this.$message({
type: "warning",
message: "上传图片大小超过2M",

@ -1102,7 +1102,7 @@ import { getparameter } from "@/api/system/dictionary";
import { listdeptNoAuth } from "@/api/system/department";
import { getBudget } from "@/api/budget/budget";
import { getOatoken } from "@/api/oatoken";
import { deepCopy, parseTime, resetSelect } from '@/utils'
import { deepCopy, parseTime, resetSelect,moneyFormatter } from '@/utils'
import { Message } from "element-ui";
import { getInfo } from "@/api/user.js";
import { getToken } from "@/utils/auth";
@ -1330,6 +1330,38 @@ export default {
.replace(/(\d)(?=(\d{3})+\.)/g, "$1,");
},
},
{
label: "支付占比",
width: 140,
customFn: (row) => {
let per =
((row.fund_log_total / row.money || 0) * 100)?.toFixed(2) || 0;
return (
<div
style={{
color: per > 110 ? "red" : "green",
}}
>
{" "}
{per} %
</div>
);
},
},
{
label: "付款计划",
prop: "sign_plan_count",
width: 120,
formatter: (cell, data, value) => {
if (value == 0) return "暂无";
return value + "期";
},
customFn:row => {
let text = "暂无";
if (row.sign_plan_count && row.sign_plan_count != 0) text = row.sign_plan_count + '期';
return (<a style="text-decoration: underline;">{text}</a>)
}
},
{
label: "供应商/服务商",
width: 220,
@ -1363,6 +1395,35 @@ export default {
}
},
},
{
label: '费用年占比',
width: 160,
customFn: row => {
const { start_date, end_date, money } = row
if (!start_date || !end_date) {
return (<span>/</span>)
}
const startYear = new Date(start_date).getFullYear()
const endYear = new Date(end_date).getFullYear()
if (startYear === endYear) {
return (<p><span style="font-weight: 600;">[{startYear}]</span><span>{moneyFormatter(money)}</span></p>)
} else {
const startMonths = 12 - new Date(start_date).getMonth()
const endMonths = new Date(end_date).getMonth() + 1
return(
<div>
<p>
<span style="font-weight: 600;">[{startYear}]</span><span>{moneyFormatter(money*startMonths/(startMonths+endMonths))}</span>
</p>
<p>
<span style="font-weight: 600;">[{endYear}]</span><span>{moneyFormatter(money*endMonths/(startMonths+endMonths))}</span>
</p>
</div>
)
}
}
},
{
label: "签订日期",
width: 160,

@ -75,7 +75,7 @@
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>申请付款金额
</div>
<div class="xy-table-item-content xy-table-item-price">
<el-input readonly clearable placeholder="请填写付款金额" v-model="paymentRegistrationForm.applyMoney"
<el-input clearable placeholder="请填写付款金额" v-model="paymentRegistrationForm.applyMoney"
style="width: 300px;" />
</div>
</div>
@ -86,7 +86,7 @@
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>本期扣款金额
</div>
<div class="xy-table-item-content xy-table-item-price">
<el-input readonly clearable placeholder="请填写扣款金额" v-model="paymentRegistrationForm.discountMoney"
<el-input clearable placeholder="请填写扣款金额" v-model="paymentRegistrationForm.deductionMoney"
style="width: 300px;" />
</div>
</div>
@ -98,7 +98,7 @@
</div>
<div class="xy-table-item-content">
<!-- <el-input readonly clearable placeholder="选择款项类型或直接填写其他类型" v-model="paymentRegistrationForm.type" style="width: 300px;"/>-->
<el-select placeholder="选择款项类型或直接填写其他类型" v-model="paymentRegistrationForm.type" style="width: 200px;"
<el-select placeholder="选择款项类型或直接填写其他类型" v-model="paymentRegistrationForm.type" style="width: 300px;"
disabled filterable allow-create clearable>
<el-option v-for="item in paymentType" :key="item" :label="item" :value="item">
</el-option>
@ -132,10 +132,26 @@
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>资金列支渠道
</div>
<div class="xy-table-item-content">
<el-select multiple style="width: 300px;" v-model="paymentRegistrationForm.moneyWay" placeholder="请选择资金列支渠道"
@change="moneyWayChange">
<el-option v-for="item in planTypes" :value="item.id" :label="item.value"></el-option>
</el-select>
<el-cascader
:show-all-levels="false"
:options="planTypes"
:props="{
emitPath: false,
multiple: true,
checkStrictly: false,
label: 'name',
value: 'id',
}"
:value="paymentRegistrationForm.moneyWay"
clearable
size="small"
style="width: 300px"
@change="moneyWayChange"
/>
<!-- <el-select multiple style="width: 300px;" v-model="paymentRegistrationForm.moneyWay" placeholder="请选择资金列支渠道"-->
<!-- @change="moneyWayChange">-->
<!-- <el-option v-for="item in planTypes" :value="item.id" :label="item.value"></el-option>-->
<!-- </el-select>-->
</div>
</div>
</template>
@ -186,9 +202,9 @@
</template>
<script>
import {
getparameter
} from "@/api/system/dictionary"
import {
getparameter, getparameterTree
} from '@/api/system/dictionary'
import {
getFundLog,
detailFundLog,
@ -312,13 +328,7 @@
{
label: "分类",
width: 136,
prop: 'type',
formatter: (cell, data, value) => {
let res = this.planTypes.filter(item => {
return item.id === value
})
return res[0]?.value || '未知'
}
prop: 'type_detail.value',
},
{
label: "科室",
@ -376,7 +386,9 @@
return total.toFixed(2)
},
//
moneyWayChange() {
moneyWayChange(e) {
this.paymentRegistrationForm.moneyWay = e;
let page = 1
let pageSize = this.plansSelect.page_size
let name = this.plansSelect.name
@ -404,10 +416,23 @@
})
},
async getPlanTypes() {
const res = await getparameter({
number: 'money_way'
})
this.planTypes = res.detail
const res = await getparameterTree({
id: 3
});
const dataHandler = (data) => {
data.forEach(i => {
if (i.hasOwnProperty('detail')) {
i.children = i.detail.map(j => {
j.name = j.value
return j;
})
} else {
dataHandler(i['children'])
}
})
return data;
}
this.planTypes = dataHandler(res?.children) || []
},
//
pageChange(e) {
@ -456,7 +481,7 @@
})
this.paymentRegistrationForm.type = res.type
this.paymentRegistrationForm.isLast = res.is_end === 1
this.paymentRegistrationForm.deductionMoney = res.apply_money
this.paymentRegistrationForm.deductionMoney = res.discount_money
this.paymentRegistrationForm.applyMoney = res.apply_money
this.paymentRegistrationForm.remark = res.remark
for (var m of res.plan_link) {
@ -464,7 +489,6 @@
}
this.paymentRegistrationForm.plan = res.plan_link
this.paymentRegistrationForm.discountMoney = res.discount_money
this.paymentRegistrationForm.actMoney = res.apply_money
this.paymentRegistrationForm.moneyWay = res.money_way_id?.split(',').map(item => Number(item))
@ -513,6 +537,8 @@
contract_id: this.contract.id,
act_money: this.paymentRegistrationForm.actMoney,
status: 1,
apply_money: this.paymentRegistrationForm.applyMoney,
discount_money: this.paymentRegistrationForm.deductionMoney,
money_way_id: this.paymentRegistrationForm.moneyWay.toString(),
contract_plan_act_links: this.paymentRegistrationForm.plan
}).then(res => {
@ -658,4 +684,11 @@
z-index: 2;
}
}
</style>
<style>
.el-cascader-panel li[aria-haspopup] .el-checkbox{
display:none;
}
</style>

@ -312,7 +312,18 @@ export default {
else return "已审核";
},
},
{
prop: 'flow_status',
label: '流程状态',
formatter: (cell, data, value) => {
let map = new Map([
[1,'待申请'],
[2,'流转中'],
[3,'已完成']
])
return map.get(value)
}
},
{
label: "次数",
prop: "pay_count",

@ -8,7 +8,7 @@ function resolve(dir) {
}
const name = defaultSettings.title || '内控管理系统' // page title
const timeStamp = new Date().getTime()
// If your port is set to 80,
// use administrator privileges to execute the command line.
// For example, Mac: sudo npm run
@ -26,7 +26,7 @@ module.exports = {
* Detail: https://cli.vuejs.org/config/#publicpath
*/
publicPath: '/admin/',
outputDir: '/Users/mac/Documents/Work/s-苏州环境监测中心/code/hjjc-workbench-service/public/admin',
outputDir: './dist',
assetsDir: 'static',
lintOnSave: false,
productionSourceMap: false,
@ -38,6 +38,10 @@ module.exports = {
sass:{
prependData: '@import "@/styles/index.scss";'
}
},
extract: { // 打包后css文件名称添加时间戳
filename: `static/css/[name].${timeStamp}.css`,
chunkFilename: `static/css/chunk.[id].${timeStamp}.css`
}
},
devServer: {
@ -80,6 +84,10 @@ module.exports = {
alias: {
'@': resolve('src')
}
},
output: {
filename: `static/js/[name]-${timeStamp}.js`,
chunkFilename: `static/js/[name]-${timeStamp}.js`
}
},
chainWebpack(config) {

Loading…
Cancel
Save