Commit 104f548c authored by 罗成兵's avatar 罗成兵

需求更新

parent dfd7a171
NODE_ENV = dev NODE_ENV = dev
VUE_APP_BASE_URL111 = https://beta-ysservice.yiboshi.com VUE_APP_BASE_URL22 = https://beta-ysservice.yiboshi.com
VUE_APP_BASE_URL1 = https://ys-service.yiboshi.com VUE_APP_BASE_URL1 = https://ys-service.yiboshi.com
VUE_APP_BASE_URL111 = http://59.230.237.90:8115 VUE_APP_BASE_URL111 = http://59.230.237.90:8115
VUE_APP_BASE_URL = http://127.0.0.1:8083 VUE_APP_BASE_URL = http://127.0.0.1:8083
......
...@@ -46,8 +46,8 @@ export default { ...@@ -46,8 +46,8 @@ export default {
fetchAllEnum(params) {//获取所有枚举值 fetchAllEnum(params) {//获取所有枚举值
return fetch(`/basic-info/v1/basic-info/basic-sys-enum/all-enum`, params) return fetch(`/basic-info/v1/basic-info/basic-sys-enum/all-enum`, params)
}, },
fetchAreaByCode(params) {//根据区域编码获取下级地区 fetchAreaByCode(areaCode) {//根据区域编码获取下级地区
return fetch(`/v1/folacin-admin/sys-dict-area/child-area/${params.areaCode}`) return fetch(`/v1/folacin-admin/sys-dict-area/child-area/${areaCode}`)
}, },
//知情同意书 //知情同意书
fetchConsentInfo(params) {//查询单位的知情同意书 fetchConsentInfo(params) {//查询单位的知情同意书
...@@ -199,6 +199,9 @@ export default { ...@@ -199,6 +199,9 @@ export default {
fetchAddFolviteDistribution(params) {//叶酸发放 fetchAddFolviteDistribution(params) {//叶酸发放
return fetch('/v1/folacin-admin/folacin-resident-info/direct-grant', params, 'post', 'json') return fetch('/v1/folacin-admin/folacin-resident-info/direct-grant', params, 'post', 'json')
}, },
fetchApplyDetail(id) {//申请详情
return fetch(`/v1/folacin-admin/folacin-apply-info/${id}`)
},
fetchFolviteDistributionDetail(params) {//叶酸发放查看详情 fetchFolviteDistributionDetail(params) {//叶酸发放查看详情
return fetch(`/v1/folacin-admin/folacin-resident-info/grant-details/${params.residentId}`) return fetch(`/v1/folacin-admin/folacin-resident-info/grant-details/${params.residentId}`)
}, },
...@@ -254,13 +257,16 @@ export default { ...@@ -254,13 +257,16 @@ export default {
}, },
folviteApplyManage: { folviteApplyManage: {
fetchFolviteApplyList(params) {//叶酸申请列表 fetchFolviteApplyList(params) {//叶酸申请列表
return fetch('/v1/folacin-admin/folacin-resident-info/apply', params) return fetch('/v1/folacin-admin/folacin-apply-info/apply', params)
}, },
delFolviteApplyById(params) {//删除叶酸申请 delFolviteApplyById(params) {//删除叶酸申请
return fetch(`/v1/folacin-admin/folacin-resident-info/delete/${params.id}`, params, 'delete', 'json'); return fetch(`/v1/folacin-admin/folacin-apply-info/delete/${params.id}`, params, 'delete', 'json');
},
addFolviteDistributionByApply(params) {
return fetch(`/v1/folacin-admin/folacin-resident-info/apply-grant/${params.id}`, params, "post", 'json');
}, },
addFolviteDistributionByApply(params) {//对申请记录进行发放 addApplyGrant(params) {//对申请记录进行发放
return fetch(`/v1/folacin-admin/folacin-resident-info/apply-grant/${params.applyId}`, params, "post", 'json'); return fetch(`/v1/folacin-admin/folacin-apply-info/apply-grant`, params, "post", 'json');
} }
}, },
fyManage: { fyManage: {
......
<template>
<div>
<a-cascader v-model="areaCode"
:style="{width:width}"
change-on-select
:disabled="disabled"
:options="options"
:fieldNames="fieldNames"
:load-data="loadAreaData"
@change="areaChange"
placeholder="请选择">
</a-cascader>
</div>
</template>
<!--
全国地区级联选择控件,包括回显数据
-->
<script>
export default {
name: "allAreaCascader",
props: ["disabled", "value","width"],
created() {
this.loadAreaData([{areaCode: 0}]);
},
mounted() {
this.handleAreaCode(this.value);
},
data() {
return {
areaCode: undefined,
options: [],
fieldNames: {
label: 'areaName',
value: 'areaCode',
children: 'children'
},
areaData: {},
optionsObj: {},
number3: 0,
number4: 0,
};
},
watch: {
//子组件中直接使用prop1
value(newValue, oldValue) {
this.handleAreaCode(newValue);
//this.$emit( 'propChange', newValue )
}
},
methods: {
handleAreaCode(areaCode) {
if (this.$api.utils.isBlank(areaCode)) {
this.areaCode=[];
return;
}
let level = 1;
if (areaCode.length == 2) {
this.areaCode = [areaCode];
return;
}
let provinceCode = areaCode.substring(0, 2);
let cityCodeFull = areaCode.substring(0, 4) + "00000000";
let countyCode, townshipCode, villageCode;
let countyCodeFull, townshipCodeFull;
level = 2;
if (areaCode.substring(2, 4) != '00') {
level = 3
countyCode = areaCode.substring(0, 6);
countyCodeFull = areaCode.substring(0, 6) + "000000";
if (areaCode.substring(4, 6) != '00') {
level = 4;
townshipCode = areaCode.substring(0, 9);
townshipCodeFull = areaCode.substring(0, 9) + "000";
if (areaCode.substring(6, 9) != '000') {
level = 5;
villageCode = areaCode.substring(0, 12);
}
}
}
let areaCodeList = [provinceCode, cityCodeFull, countyCodeFull, townshipCodeFull, villageCode];
if (level > 1) {
this.$api.common.fetchAreaByCode(provinceCode).then(({data = []}) => {
this.handleData(data, 2, cityCodeFull);
if (level > 2) {
this.$api.common.fetchAreaByCode(cityCodeFull).then(({data = []}) => {
this.handleData(data, 3, cityCodeFull);
if (level > 3) {
this.$api.common.fetchAreaByCode(countyCodeFull).then(({data = []}) => {
this.handleData(data, 4, countyCodeFull);
if (level > 4) {
this.$api.common.fetchAreaByCode(townshipCodeFull).then(({data = []}) => {
this.handleData(data, 5, townshipCodeFull);
this.areaCode = areaCodeList;
this.isEndHandle(provinceCode)
});
} else {
this.isEndHandle(provinceCode)
this.areaCode = areaCodeList;
}
})
} else {
this.areaCode = areaCodeList;
this.isEndHandle(provinceCode)
}
})
} else {
this.areaCode = areaCodeList;
this.isEndHandle(provinceCode)
}
})
} else {
this.areaCode = areaCodeList;
this.isEndHandle(provinceCode)
}
},
isEndHandle(provinceCode) {
this.options.forEach(x => {
if (x.areaCode == provinceCode) {
x.children = this.optionsObj;
}
})
},
handleData(data, level, areaCode) {
if (this.$api.utils.isBlank(data)) {
return;
}
data.forEach(item => {
item['isLeaf'] = item.areaLevel >= 5;
});
if (level == 2) {
this.optionsObj = data;
}
if (level == 3) {
let number3 = 0;
this.optionsObj.forEach(x => {
if (x.areaCode == areaCode) {
x.children = data;
this.number3 = number3;
}
number3++;
})
}
if (level == 4) {
let number4 = 0;
this.optionsObj[this.number3].children.forEach(x => {
if (x.areaCode == areaCode) {
x.children = data;
this.number4 = number4;
}
number4++;
})
}
if (level == 5) {
this.optionsObj[this.number3].children[this.number4].children.forEach(x => {
if (x.areaCode == areaCode) {
x.children = data;
}
})
}
},
loadAreaData(selectedOptions) {
const targetOption = selectedOptions[selectedOptions.length - 1];
targetOption.loading = true;
this.$api.common.fetchAreaByCode(targetOption.areaCode).then(({data = []}) => {
targetOption.loading = false;
if (this.$api.utils.isBlank(data)) {
return;
}
data.forEach(item => {
item['isLeaf'] = item.areaLevel >= 5;
})
if (targetOption.areaCode == 0) {
this.options = [...data];
} else {
targetOption.children = [...data]
this.options = [...this.options]
}
})
},
setValue(areaCode) {
this.handleAreaCode(areaCode);
},
getValue() {
return this.areaCode;
},
areaChange(areaCode) {
this.$emit("input", areaCode[areaCode.length - 1])
}
}
}
</script>
<style scoped>
</style>
\ No newline at end of file
...@@ -14,9 +14,10 @@ ...@@ -14,9 +14,10 @@
* 所有地区选择控件 * 所有地区选择控件
*/ */
export default { export default {
name: "allAreaSelect", name: "allAreaTreeSelect",
created() { created() {},
this.getDataList(53); mounted() {
this.getDataList(0);
}, },
data() { data() {
return { return {
......
...@@ -234,12 +234,12 @@ export default { ...@@ -234,12 +234,12 @@ export default {
if (process.env.NODE_ENV == "dev") { if (process.env.NODE_ENV == "dev") {
let params = { let params = {
id: record.id, id: record.id,
routerFlag: 'update', routerFlag: 'applyGrant',
menuId: this.menuId menuId: this.menuId
} }
this.$router.push({path: '/folviteDistribution/add', query: params}) this.$router.push({path: '/folviteDistribution/add', query: params})
} else { } else {
let now_location = escape(process.env.VUE_APP_LOCATION + `folviteDistribution/add?menuId=${this.menuId}&menuCode=${this.routerParams.menuName}&routerFlag=update&id=` + record.id) let now_location = escape(process.env.VUE_APP_LOCATION + `folviteDistribution/add?menuId=${this.menuId}&menuCode=${this.routerParams.menuName}&routerFlag=applyGrant&id=` + record.id)
window.top.postMessage({messageType: 'THIRD_PAGEADD', title: `叶酸申请`, url: now_location}, '*') window.top.postMessage({messageType: 'THIRD_PAGEADD', title: `叶酸申请`, url: now_location}, '*')
} }
......
...@@ -54,17 +54,17 @@ ...@@ -54,17 +54,17 @@
<a-descriptions-item label="详细地址"> <a-descriptions-item label="详细地址">
{{ detailInfo.nowAddress || '--' }} {{ detailInfo.nowAddress || '--' }}
</a-descriptions-item> </a-descriptions-item>
<a-descriptions-item label="签署方式" :span="routerParams.source == 2 ? 2: 1"> <a-descriptions-item label="签署方式" :span="detailInfo.source == 2 ? 2: 1">
{{ detailInfo.signedModeName || '--' }} {{ detailInfo.signedModeName || '--' }}
</a-descriptions-item> </a-descriptions-item>
<a-descriptions-item label="签署日期" :span="routerParams.source == 2 ? 2: 1"> <a-descriptions-item label="签署日期" :span="detailInfo.source == 2 ? 2: 1">
{{ detailInfo.parentDate || '--' }} {{ detailInfo.parentDate || '--' }}
</a-descriptions-item> </a-descriptions-item>
<a-descriptions-item label="上传照片" v-if="routerParams.source != 2"> <a-descriptions-item label="上传照片" v-if="detailInfo.source != 2">
<img style="cursor: pointer" width="120px" height="120px" :src="detailInfo.consentUrl" <img style="cursor: pointer" width="120px" height="120px" :src="detailInfo.consentUrl"
@click="showVisible=true"/> @click="showVisible=true"/>
</a-descriptions-item> </a-descriptions-item>
<a-descriptions-item label="签名" v-if="routerParams.source == 2"> <a-descriptions-item label="签名" v-if="detailInfo.source == 2">
<img style="margin-left: 30px;width: auto;height: 80px;transform: rotate(-90deg)" <img style="margin-left: 30px;width: auto;height: 80px;transform: rotate(-90deg)"
:src="detailInfo.applySignUrl"> :src="detailInfo.applySignUrl">
</a-descriptions-item> </a-descriptions-item>
...@@ -77,7 +77,10 @@ ...@@ -77,7 +77,10 @@
</div> </div>
<a-descriptions bordered class="folvite_title"> <a-descriptions bordered class="folvite_title">
<a-descriptions-item label="结果" > <a-descriptions-item label="结果" >
<p v-for="item in checkedList ">{{item}}</p> <div v-if="checkedList&&checkedList.length>0">
<p v-for="item in checkedList ">{{item}}</p>
</div>
<p v-else>--</p>
</a-descriptions-item> </a-descriptions-item>
<a-descriptions-item label="建议服用"> <a-descriptions-item label="建议服用">
{{ detailInfo.recommendEat || '--' }} {{ detailInfo.recommendEat || '--' }}
...@@ -159,7 +162,6 @@ export default { ...@@ -159,7 +162,6 @@ export default {
this.spinning = true this.spinning = true
let par = { let par = {
residentId: this.routerParams.id, residentId: this.routerParams.id,
menuId: this.routerParams.menuId
} }
this.$api.folviteDistributionManage.fetchFolviteDistributionDetail(par).then(({data = [], code}) => { this.$api.folviteDistributionManage.fetchFolviteDistributionDetail(par).then(({data = [], code}) => {
this.spinning = false; this.spinning = false;
......
...@@ -38,9 +38,9 @@ ...@@ -38,9 +38,9 @@
<template slot="nowAddress" slot-scope="text, record"> <template slot="nowAddress" slot-scope="text, record">
<a-tooltip placement="top"> <a-tooltip placement="top">
<template slot="title"> <template slot="title">
<span> {{ record.presentCodeName + record.nowAddress }}</span> <span> {{ (record.presentCodeName||"") + record.nowAddress }}</span>
</template> </template>
<span class="ellipsis">{{ record.presentCodeName + record.nowAddress }}</span> <span class="ellipsis">{{ (record.presentCodeName||"") + record.nowAddress }}</span>
</a-tooltip> </a-tooltip>
</template> </template>
<template slot="action" slot-scope="record"> <template slot="action" slot-scope="record">
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
</template> </template>
<script> <script>
import {GetUserInfoByCardDevice, isEmptyParams} from "../../utils/common"; import {GetUserInfoByCardDevice, isEmptyParams} from "../../utils/common";
import moment from 'moment'
const columns = [ const columns = [
{ {
...@@ -296,7 +296,7 @@ export default { ...@@ -296,7 +296,7 @@ export default {
if (process.env.NODE_ENV == "dev") { if (process.env.NODE_ENV == "dev") {
let par = { let par = {
menuId: this.menuId, menuId: this.menuId,
...record id:record.id
} }
this.$router.push({path: '/folviteDistribution/detail', query: par}) this.$router.push({path: '/folviteDistribution/detail', query: par})
} else { } else {
...@@ -314,7 +314,7 @@ export default { ...@@ -314,7 +314,7 @@ export default {
this.$router.push({path: '/folviteDistribution/add', query: params}) this.$router.push({path: '/folviteDistribution/add', query: params})
} else { } else {
let now_location = escape(process.env.VUE_APP_LOCATION + `folviteDistribution/add?menuId=${this.menuId}&menuCode=${this.routerParams.menuName}&routerFlag=updateRecord&id=` + record.id) let now_location = escape(process.env.VUE_APP_LOCATION + `folviteDistribution/add?menuId=${this.menuId}&menuCode=${this.routerParams.menuName}&routerFlag=updateRecord&id=` + record.id)
window.top.postMessage({messageType: 'THIRD_PAGEADD', title: `叶酸申请`, url: now_location}, '*') window.top.postMessage({messageType: 'THIRD_PAGEADD', title: `叶酸发放登记修改-`+record.womanName, url: now_location}, '*')
} }
}, },
deleteRecord(record) { deleteRecord(record) {
...@@ -414,6 +414,12 @@ export default { ...@@ -414,6 +414,12 @@ export default {
} }
}, },
mounted() {
let that=this;
window.addEventListener("message",function (data){
that.getDataList();
});
}
} }
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
...@@ -445,4 +451,9 @@ export default { ...@@ -445,4 +451,9 @@ export default {
white-space: nowrap; white-space: nowrap;
overflow: hidden; overflow: hidden;
} }
///deep/ .ant-table-tbody{
// > tr:hover:not(.ant-table-expanded-row) > td,.ant-table-row-hover,.ant-table-row-hover>td{
// background:darkcyan !important;
// }
//}
</style> </style>
...@@ -84,11 +84,10 @@ ...@@ -84,11 +84,10 @@
</template> </template>
<script> <script>
import moment from 'moment' import moment from 'moment'
import allAreaSelect from '../../../components/allAreaSelect'
import {checkPhone, closedDetail} from "../../../utils/common"; import {checkPhone, closedDetail} from "../../../utils/common";
export default { export default {
components: {allAreaSelect}, components: {},
data() { data() {
return { return {
subLoad: false, subLoad: false,
...@@ -155,11 +154,7 @@ ...@@ -155,11 +154,7 @@
loadAreaData(selectedOptions) { loadAreaData(selectedOptions) {
const targetOption = selectedOptions[selectedOptions.length - 1]; const targetOption = selectedOptions[selectedOptions.length - 1];
targetOption.loading = true; targetOption.loading = true;
let par = { this.$api.common.fetchAreaByCode(targetOption.areaCode).then(({data = []}) => {
menuId: this.queryParams.menuId,
areaCode: targetOption.areaCode
}
this.$api.common.fetchAreaByCode(par).then(({data = []}) => {
targetOption.loading = false; targetOption.loading = false;
data.forEach(item => { data.forEach(item => {
item['isLeaf'] = item.areaLevel >= 5; item['isLeaf'] = item.areaLevel >= 5;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment