diff --git a/src/views/system/classifyItem/index.vue b/src/views/system/classifyItem/index.vue
index d2817d1..d1ce5f4 100644
--- a/src/views/system/classifyItem/index.vue
+++ b/src/views/system/classifyItem/index.vue
@@ -25,16 +25,8 @@
/>
- 搜索
- 重置
+ 搜索
+ 重置
@@ -47,8 +39,7 @@
size="mini"
@click="handleAdd"
v-hasPermi="['system:classifyItem:add']"
- >新增
+ >新增
修改
+ >修改
删除
+ >删除
-
+ -->
+
-
+
@@ -104,13 +86,9 @@
>{{ scope.row.classifyType == "NURSE_AGNECY" ? "护理机构分类" : "" }}
{{ scope.row.classifyType == "NURSE_ITEM" ? "护理项目分类" : "" }}
- -->
+ -->
-
+
修改
+ >修改
删除
+ >删除
@@ -167,7 +143,7 @@
:prop="`nurseClassifyInfoList.${index}.classifyName`"
>
-
+
@@ -273,7 +245,7 @@ import {
getInfo,
delInfo,
addInfo,
- updateInfo,
+ updateInfo
} from "@/api/system/classifyItem.js";
import { updatePicture } from "@/api/system/station";
export default {
@@ -287,7 +259,7 @@ export default {
ids: [],
// 非单个禁用
single: true,
- imgone:"",
+ imgone: "",
// 非多个禁用
multiple: true,
// 显示搜索条件
@@ -308,15 +280,15 @@ export default {
parentId: null,
classifyCode: null,
classifyName: null,
-
+
classifyLevel: null,
classifyType: null,
classifyPictureUrl: null,
- classifySort: null,
+ classifySort: null
},
// 表单参数
form: {
- nurseClassifyInfoList: [],
+ nurseClassifyInfoList: []
},
idd: 0,
classifyPictureUrl: null,
@@ -328,46 +300,46 @@ export default {
{
required: true,
message: "请输入分类名称",
- trigger: "blur",
- },
+ trigger: "blur"
+ }
],
classifyPictureUrl: [
{
required: true,
message: "请选择分类图标",
- trigger: "blur",
- },
+ trigger: "blur"
+ }
],
classifySort: [
{
required: true,
message: "请输入分类排序",
- trigger: "blur",
- },
- ],
+ trigger: "blur"
+ }
+ ]
},
classifyName: [
{
required: true,
message: "请输入分类名称",
- trigger: "blur",
- },
+ trigger: "blur"
+ }
],
classifyPictureUrl: [
{
required: true,
message: "请选择分类图标",
- trigger: "blur",
- },
+ trigger: "blur"
+ }
],
classifySort: [
{
required: true,
message: "请输入分类排序",
- trigger: "blur",
- },
- ],
- },
+ trigger: "blur"
+ }
+ ]
+ }
};
},
created() {
@@ -385,7 +357,7 @@ export default {
classifyName: "",
classifyPictureUrl: "",
classifySort: "",
- idd: this.idd,
+ idd: this.idd
};
if (this.form.nurseClassifyInfoList.length == 5) {
this.$message.error("最多批量添加5条");
@@ -399,7 +371,7 @@ export default {
imgclassifyPictureitem(item) {
let items = JSON.parse(item);
if (items.idd && !items.id) {
- this.form.nurseClassifyInfoList.forEach((e) => {
+ this.form.nurseClassifyInfoList.forEach(e => {
if (e.idd == items.idd) {
e.classifyPictureUrl = items.classifyPictureUrl;
}
@@ -411,7 +383,7 @@ export default {
/** 查询护理机构和护理项目分类信息列表 */
getList() {
this.loading = true;
- listInfo(this.queryParams).then((response) => {
+ listInfo(this.queryParams).then(response => {
this.infoList = response.rows;
this.total = response.total;
this.loading = false;
@@ -424,18 +396,18 @@ export default {
if (this.form.classifyPictureUrl != this.imgone) {
obj.pictureUrlList.push(this.form.classifyPictureUrl);
}
- updatePicture(obj).then((res) => {
+ updatePicture(obj).then(res => {
this.editopen = false;
});
}
if (this.open) {
var obj = { pictureUrlList: [] };
if (this.form.nurseClassifyInfoList) {
- this.form.nurseClassifyInfoList.forEach((e) => {
+ this.form.nurseClassifyInfoList.forEach(e => {
obj.pictureUrlList.push(e.classifyPictureUrl);
});
}
- updatePicture(obj).then((res) => {
+ updatePicture(obj).then(res => {
this.open = false;
});
}
@@ -455,7 +427,7 @@ export default {
createBy: null,
createTime: null,
updateBy: null,
- updateTime: null,
+ updateTime: null
};
this.resetForm("form");
},
@@ -471,7 +443,7 @@ export default {
},
// 多选框选中数据
handleSelectionChange(selection) {
- this.ids = selection.map((item) => item.id);
+ this.ids = selection.map(item => item.id);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
@@ -483,11 +455,9 @@ export default {
classifyName: "",
classifyPictureUrl: "",
classifySort: "",
- idd: this.idd,
- },
- ],
-
-
+ idd: this.idd
+ }
+ ]
};
this.open = true;
this.title = "添加护理项目分类信息";
@@ -496,7 +466,7 @@ export default {
handleUpdate(row) {
this.reset();
const id = row.id || this.ids;
- getInfo(id).then((response) => {
+ getInfo(id).then(response => {
this.form = response.data;
this.imgone = this.form.classifyPictureUrl;
this.classifyPictureUrl = response.data.classifyPictureUrl;
@@ -506,27 +476,27 @@ export default {
},
/** 提交按钮 */
submitForm() {
- console.log(this.form);
- this.$refs["form"].validate((valid) => {
+ this.form.classifySort = Number(this.form.classifySort);
+ this.$refs["form"].validate(valid => {
if (valid) {
-
if (this.form.id != null) {
- updateInfo(this.form).then((response) => {
+ updateInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
if (this.form.classifyPictureUrl != this.imgone) {
var obj = { pictureUrlList: [] };
obj.pictureUrlList.push(this.imgone);
- updatePicture(obj).then((res) => {});
+ updatePicture(obj).then(res => {});
}
this.editopen = false;
this.getList();
});
} else {
- if(this.form.nurseClassifyInfoList[0].classifySort){
- this.form.nurseClassifyInfoList[0].classifySort = parseInt(this.form.nurseClassifyInfoList[0].classifySort);
+ if (this.form.nurseClassifyInfoList[0].classifySort) {
+ this.form.nurseClassifyInfoList[0].classifySort = parseInt(
+ this.form.nurseClassifyInfoList[0].classifySort
+ );
}
-
- addInfo(this.form).then((response) => {
+ addInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
@@ -541,7 +511,7 @@ export default {
console.log(row);
this.$modal
.confirm("是否确认删除?")
- .then(function () {
+ .then(function() {
return delInfo(ids);
})
.then(() => {
@@ -555,11 +525,11 @@ export default {
this.download(
"classify/info/export",
{
- ...this.queryParams,
+ ...this.queryParams
},
`info_${new Date().getTime()}.xlsx`
);
- },
- },
+ }
+ }
};
diff --git a/src/views/system/poser/index.vue b/src/views/system/poser/index.vue
index e06ded0..590e0d8 100644
--- a/src/views/system/poser/index.vue
+++ b/src/views/system/poser/index.vue
@@ -9,14 +9,18 @@
label-width="110px"
>
- {{
+
+ {{
queryParams.nurseStationName
- }}
+ }}
+
- {{
+
+ {{
queryParams.nurseItemName
- }}
+ }}
+
-
+
-
+ >
@@ -50,16 +49,8 @@
/>
- 搜索
- 重置
+ 搜索
+ 重置
@@ -71,8 +62,7 @@
size="mini"
@click="handleAdd"
v-hasPermi="['system:poser:add']"
- >新增
+ >新增
修改
+ >修改
删除
+ >删除
-
+ -->
+
-
+
-
-
+
+
{{
- scope.row.moduleType == "NURSE_AGENCY_MODULE" ? "护理机构模块" : ""
+ scope.row.moduleType == "NURSE_AGENCY_MODULE" ? "护理机构模块" : ""
}}
{{
- scope.row.moduleType == "NURSE_ITEM_MODULE" ? "护理项目模块" : ""
+ scope.row.moduleType == "NURSE_ITEM_MODULE" ? "护理项目模块" : ""
}}
{{
- scope.row.moduleType == "HEALTH_CONSUTION_MODULE"
- ? "健康咨询模块"
- : ""
+ scope.row.moduleType == "HEALTH_CONSUTION_MODULE"
+ ? "健康咨询模块"
+ : ""
}}
{{ scope.row.moduleType == "HOME_PAGE_MODULE" ? "首页模块" : "" }}
{{
- scope.row.moduleType == "NURSE_AGENCY_INTRODUCE_MODULE"
- ? "护理机构简介模块"
- : ""
+ scope.row.moduleType == "NURSE_AGENCY_INTRODUCE_MODULE"
+ ? "护理机构简介模块"
+ : ""
}}
-
+
修改
+ >修改
删除
+ >删除
@@ -194,19 +161,9 @@
:before-close="cancel"
append-to-body
>
-
+
-
+
@@ -221,8 +178,7 @@
:key="item.value"
:label="item.label"
:value="item.value"
- >
-
+ >
@@ -230,7 +186,7 @@
v-model="form.poserSort"
placeholder="请输入海报显示顺序"
oninput="value=value.replace(/[^\d]/g,'')"
- maxLength="5"
+ maxlength="5"
/>
{{ form.nurseStationName }}
+ >{{ form.nurseStationName }}
{{ form.nurseStationName }}
+ >{{ form.nurseStationName }}
{{ form.nurseItemName }}
+ >{{ form.nurseItemName }}
{{ form.nurseItemName }}
-
+ >{{ form.nurseItemName }}
+
+
-
+
-
+
-
+ >
- 新增
- 删除
+ 新增
+ 删除
@@ -370,8 +306,7 @@
style="width: 540px"
placeholder="请输入海报简介"
v-model="form.posterIntroduce"
- >
-
+ >
+ -->
-
+
-
+
-
+
- 搜索
- 重置
+ 搜索
+ 重置
-
+
-
+ >
-
-
-
-
-
-
+
+
+
-
+ >
-
+
-
+
- 搜索
- 重置
+ 搜索
+ 重置
-
+
-
+ >
-
+
-
-
-
+
+
+
@@ -595,7 +456,7 @@ import {
addPoser,
getListByUser,
updatePoser,
- updatePicture,
+ updatePicture
} from "@/api/system/poser";
import { list } from "@/api/system/nurseItem";
import stationAcatar from "../stationAvatar/index.vue";
@@ -609,7 +470,7 @@ export default {
loading: true,
getListByUserquery: {
pageNum: 1,
- pageSize: 10,
+ pageSize: 10
},
nurseStationlist: [],
nurseStationshow: false,
@@ -645,7 +506,7 @@ export default {
pageNum: 1,
pageSize: 10,
nurseItemCode: null,
- nurseItemName: null,
+ nurseItemName: null
},
// 查询参数
queryParams: {
@@ -662,7 +523,7 @@ export default {
moduleType: null,
poserSort: null,
jumpLink: null,
- jumpType: null,
+ jumpType: null
},
// 表单参数
form: {
@@ -676,75 +537,75 @@ export default {
nurseStationId: "",
nurseStationName: "请选择所属护理站",
nurseItemName: "请选择所属护理项目",
- nurseItemId: "",
+ nurseItemId: ""
},
imgsurl: { pictureUrlList: [] },
// 表单校验
rules: {
moduleType: [
- { required: true, message: "请选择海报所属模块", trigger: "blur" },
+ { required: true, message: "请选择海报所属模块", trigger: "blur" }
],
poserName: [
- { required: true, message: "请输入海报名称", trigger: "blur" },
+ { required: true, message: "请输入海报名称", trigger: "blur" }
],
nurseStationId: [
- { required: true, message: "请选择所属护理站", trigger: "blur" },
+ { required: true, message: "请选择所属护理站", trigger: "blur" }
],
posterIntroduce: [
- { required: true, message: "请输入海报简介", trigger: "blur" },
+ { required: true, message: "请输入海报简介", trigger: "blur" }
],
posterVideoUrl: [
- { required: true, message: "请选择海报视频", trigger: "blur" },
+ { required: true, message: "请选择海报视频", trigger: "blur" }
],
poserSort: [
- { required: true, message: "请输入海报顺序", trigger: "blur" },
+ { required: true, message: "请输入海报顺序", trigger: "blur" }
],
nurseItemId: [
- { required: true, message: "请选择所属护理项目", trigger: "blur" },
- ],
+ { required: true, message: "请选择所属护理项目", trigger: "blur" }
+ ]
},
options: [
{
value: "NURSE_AGENCY_MODULE",
- label: "护理机构模块",
+ label: "护理机构模块"
},
{
value: "NURSE_ITEM_MODULE",
- label: "护理项目模块",
+ label: "护理项目模块"
},
{
value: "HEALTH_CONSUTION_MODULE",
- label: "健康咨询模块",
+ label: "健康咨询模块"
},
{
value: "HOME_PAGE_MODULE",
- label: "首页模块",
+ label: "首页模块"
},
{
value: "NURSE_AGENCY_INTRODUCE_MODULE",
- label: "护理机构简介模块",
- },
+ label: "护理机构简介模块"
+ }
],
-
- objitem:[],
+
+ objitem: [],
jumpTypes: [
{
value: "NEW_PEOPLE_WELFARE",
- label: "新人福利",
+ label: "新人福利"
},
{
value: "HOME_PAGE",
- label: "首页",
+ label: "首页"
},
{
value: "SHOPPING",
- label: "商城",
- },
+ label: "商城"
+ }
],
//页面链接
stationid: "",
- imgone:[],
+ imgone: [],
nurseitemid: "",
homenumber: false,
videourl: "",
@@ -755,10 +616,10 @@ export default {
isShowUploadVideo: false,
//显示上传按钮
videoForm: {
- showVideoPath: "", //回显的变量
+ showVideoPath: "" //回显的变量
},
// 存储新上传的图片数组
- deletNewImgs:[],
+ deletNewImgs: []
};
},
created() {
@@ -774,15 +635,17 @@ export default {
if (this.form.posterPictureUrlLists.length == 1) {
this.$message.error("最后一条不可删除");
} else {
- this.form.posterPictureUrlLists =
- this.form.posterPictureUrlLists.filter((e) => e.idd != item.idd);
+ this.form.posterPictureUrlLists = this.form.posterPictureUrlLists.filter(
+ e => e.idd != item.idd
+ );
}
} else if (!item.idd && item.id) {
if (this.form.posterPictureUrlLists.length == 1) {
this.$message.error("最后一条不可删除");
} else {
- this.form.posterPictureUrlLists =
- this.form.posterPictureUrlLists.filter((e) => e.id != item.id);
+ this.form.posterPictureUrlLists = this.form.posterPictureUrlLists.filter(
+ e => e.id != item.id
+ );
}
}
},
@@ -792,7 +655,7 @@ export default {
var obj = {
posterPictureUrl: "",
jumpType: "",
- idd: this.idd,
+ idd: this.idd
};
if (this.form.posterPictureUrlLists.length >= 5) {
this.$message.error("最多新增5条");
@@ -828,13 +691,13 @@ export default {
pageNum: 1,
pageSize: 10,
nurseItemCode: null,
- nurseItemName: null,
+ nurseItemName: null
};
this.nurseItemlistInfo();
},
//搜索
nurseItemlistInfo() {
- list(this.nurseItemquery).then((res) => {
+ list(this.nurseItemquery).then(res => {
this.nurseItemlist = res.rows;
this.nurseItemtotal = res.total;
});
@@ -867,7 +730,7 @@ export default {
},
//护理站list
info() {
- getListByUser(this.getListByUserquery).then((res) => {
+ getListByUser(this.getListByUserquery).then(res => {
this.nurseStationlist = res.rows;
this.total4 = res.total;
});
@@ -882,7 +745,7 @@ export default {
stationcancel() {
this.getListByUserquery = {
pageNum: 1,
- pageSize: 10,
+ pageSize: 10
};
this.info();
},
@@ -909,15 +772,10 @@ export default {
},
//图片传值过来接收
imgUrl(imgUrl) {
-
- console.log(JSON.parse(imgUrl),'url');
- let imgUrlData=JSON.parse(imgUrl)
+ let imgUrlData = JSON.parse(imgUrl);
// 存贮新上传的图片数组
- this.deletNewImgs.push(imgUrlData.posterPictureUrl)
- console.log(this.deletNewImgs,'触发了上传时间')
- this.objitem.push(imgUrlData.posterPictureUrl)
-
- console.log(this.objitem)
+ this.deletNewImgs.push(imgUrlData.posterPictureUrl);
+ this.objitem.push(imgUrlData.posterPictureUrl);
},
imgUrl2(imgUrl) {
this.videoForm.showVideoPath = baseurl + imgUrl;
@@ -926,7 +784,7 @@ export default {
/** 查询泉医到家系统海报模块信息(包含咨询简介信息)列表 */
getList() {
this.loading = true;
- listPoser(this.queryParams).then((response) => {
+ listPoser(this.queryParams).then(response => {
this.poserList = response.rows;
this.total = response.total;
this.loading = false;
@@ -934,22 +792,17 @@ export default {
},
// 取消按钮
cancel() {
- console.log(this.objitem)
var obj = { pictureUrlList: [] };
- if (this.form.posterPictureUrlLists) {
- this.form.posterPictureUrlLists.forEach((e) => {
- obj.pictureUrlList.push(e.posterPictureUrl);
- });
- }
-
- console.log(this.deletNewImgs)
- if(obj.pictureUrlList.length>0){
- updatePicture({pictureUrlList:this.deletNewImgs}).then((res) => {
+ if (this.form.posterPictureUrlLists) {
+ this.form.posterPictureUrlLists.forEach(e => {
+ obj.pictureUrlList.push(e.posterPictureUrl);
+ });
+ }
+ if (obj.pictureUrlList.length > 0) {
+ updatePicture({ pictureUrlList: this.deletNewImgs }).then(res => {
this.open = false;
});
- }
-
- this.deletNewImgs=[],
+ }
this.nurseItemquery.nurseStationId = null;
this.imgs = { pictureUrlList: [] };
this.open = false;
@@ -962,8 +815,8 @@ export default {
{
posterPictureUrl: "",
jumpType: "",
- idd: this.idd,
- },
+ idd: this.idd
+ }
],
id: null,
poserName: null,
@@ -974,8 +827,9 @@ export default {
nurseStationName: "请选择所属护理站",
nurseStationId: null,
nurseItemName: "请选择所属护理项目",
- nurseItemId: null,
+ nurseItemId: null
};
+ this.deletNewImgs = [];
this.resetForm("form");
},
/** 搜索按钮操作 */
@@ -986,22 +840,22 @@ export default {
resetQuery() {
this.nurseItemquery = {
pageNum: 1,
- pageSize: 10,
+ pageSize: 10
};
this.stationid = "";
this.nurseitemid = "";
this.queryParams = {
pageNum: 1,
- pageSize: 10,
+ pageSize: 10
};
this.resetForm("queryForm");
this.handleQuery();
},
// 多选框选中数据
handleSelectionChange(selection) {
- this.ids = selection.map((item) => item.nurseStationId);
- this.itemids = selection.map((item) => item.nurseItemId);
- this.Types = selection.map((item) => item.moduleType);
+ this.ids = selection.map(item => item.nurseStationId);
+ this.itemids = selection.map(item => item.nurseItemId);
+ this.Types = selection.map(item => item.moduleType);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
@@ -1017,7 +871,7 @@ export default {
const id = row.nurseStationId || this.ids;
const itemid = row.nurseItemId || this.itemids;
const type = row.moduleType || this.Types;
- getPoser(type, id, itemid).then((response) => {
+ getPoser(type, id, itemid).then(response => {
this.form = response.data;
if (response.data.goodAttributeDetailsLists) {
this.goodDetailsLists = response.data.goodAttributeDetailsLists;
@@ -1029,19 +883,19 @@ export default {
},
/** 提交按钮 */
submitForm() {
- this.$refs["form"].validate((valid) => {
+ this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.id != null) {
- updatePoser(this.form).then((response) => {
- // var obj = { pictureUrlList: [] };
- // if (this.form.posterPictureUrlLists) {
- // this.form.posterPictureUrlLists.forEach((e) => {
- // obj.pictureUrlList.push(e.posterPictureUrl);
- // });
- // }
- // updatePicture({pictureUrlList:this.deletNewImgs}).then((res) => {
- // this.open = false;
- // });
+ updatePoser(this.form).then(response => {
+ // var obj = { pictureUrlList: [] };
+ // if (this.form.posterPictureUrlLists) {
+ // this.form.posterPictureUrlLists.forEach((e) => {
+ // obj.pictureUrlList.push(e.posterPictureUrl);
+ // });
+ // }
+ // updatePicture({pictureUrlList:this.deletNewImgs}).then((res) => {
+ // this.open = false;
+ // });
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
@@ -1049,10 +903,10 @@ export default {
} else {
if (this.form.poserSort) {
this.form.poserSort = parseInt(this.form.poserSort);
- }else{
- this.form.poserSort=null
+ } else {
+ this.form.poserSort = null;
}
- addPoser(this.form).then((response) => {
+ addPoser(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
@@ -1063,18 +917,13 @@ export default {
},
/** 删除按钮操作 */
handleDelete(row) {
- console.log(row);
const ids = row.id || this.ids;
const nurseStationIds = row.nurseStationId || this.nurseStationIds;
const moduleTypes = row.moduleType || this.moduleTypes;
const nurseItemIds = row.nurseItemId || this.nurseItemIds;
this.$modal
- .confirm(
- '是否确认删除泉医到家系统海报模块信息(包含咨询简介信息)编号为"' +
- ids +
- '"的数据项?'
- )
- .then(function () {
+ .confirm("是否确认删除?")
+ .then(function() {
return delPoser(nurseStationIds, moduleTypes, nurseItemIds);
})
.then(() => {
@@ -1088,15 +937,15 @@ export default {
this.download(
"system/poser/export",
{
- ...this.queryParams,
+ ...this.queryParams
},
`poser_${new Date().getTime()}.xlsx`
);
- },
- },
+ }
+ }
};
-