图片取消

This commit is contained in:
闫晓茹 2022-11-10 13:50:38 +08:00
parent 28e8ab9c2a
commit 88138ba59d
8 changed files with 117 additions and 163 deletions

View File

@ -16,6 +16,14 @@ export function getGoodsInfo(id) {
method: 'get' method: 'get'
}) })
} }
//取消
export function updatePicture(data) {
return request({
url: '/system/patientArchives/updatePicture',
method: 'post',
data: data
})
}
// 新增商品基本信息 // 新增商品基本信息
export function addGoodsInfo(data) { export function addGoodsInfo(data) {

View File

@ -16,6 +16,14 @@ export function getGoodsCategory(id) {
method: 'get' method: 'get'
}) })
} }
//取消
export function updatePicture(data) {
return request({
url: '/system/patientArchives/updatePicture',
method: 'post',
data: data
})
}
// 新增商品分类信息 // 新增商品分类信息
export function addGoodsCategory(data) { export function addGoodsCategory(data) {

View File

@ -76,3 +76,12 @@ export function delGoodsInfo(goodsInfoId) {
method: 'delete' method: 'delete'
}) })
} }
//取消
export function updatePicture(data) {
return request({
url: '/system/patientArchives/updatePicture',
method: 'post',
data: data
})
}

View File

@ -96,3 +96,11 @@ export function getLabelList(id) {
method: 'get' method: 'get'
}) })
} }
//取消
export function updatePicture(data) {
return request({
url: '/system/patientArchives/updatePicture',
method: 'post',
data: data
})
}

View File

@ -672,6 +672,7 @@ import {
goodsInfoList, goodsInfoList,
goodsCategory, goodsCategory,
editGoodsWhetherShelf, editGoodsWhetherShelf,
updatePicture,
} from "@/api/system/OperateGoodsInfo"; } from "@/api/system/OperateGoodsInfo";
import editor from "@/components/Editor"; import editor from "@/components/Editor";
import { getListByUser } from "@/api/system/userlist.js"; import { getListByUser } from "@/api/system/userlist.js";
@ -682,6 +683,7 @@ export default {
name: "OperateGoodsInfo", name: "OperateGoodsInfo",
data() { data() {
return { return {
imgone:"",
imageUrl: "", // imageUrl: "", //
value: "", value: "",
datas: null, datas: null,
@ -884,6 +886,14 @@ export default {
}, },
// //
cancel() { cancel() {
console.log(this.form);
var obj = { pictureUrlList: [] };
if(this.imgone !=this.form.goodsPictureUrl ){
obj.pictureUrlList.push(this.form.goodsPictureUrl);
}
updatePicture(obj).then((res) => {
console.log(res);
});
this.open = false; this.open = false;
this.reset(); this.reset();
this.StationName = "请选择所属护理站"; this.StationName = "请选择所属护理站";

View File

@ -212,6 +212,7 @@ import {
listGoodsCategory, listGoodsCategory,
getGoodsCategory, getGoodsCategory,
delGoodsCategory, delGoodsCategory,
updatePicture ,
addGoodsCategory, addGoodsCategory,
updateGoodsCategory, updateGoodsCategory,
} from "@/api/system/goodsCategory"; } from "@/api/system/goodsCategory";
@ -222,6 +223,7 @@ export default {
components: { stationAcatar }, components: { stationAcatar },
data() { data() {
return { return {
imgone:"",
baseurl: "", baseurl: "",
// //
loading: true, loading: true,
@ -289,6 +291,14 @@ export default {
}, },
// //
cancel() { cancel() {
console.log(this.form);
var obj = { pictureUrlList: [] };
if(this.imgone !=this.form.goodsCategoryPicture ){
obj.pictureUrlList.push(this.form.goodsCategoryPicture);
}
updatePicture (obj).then((res) => {
console.log(res);
});
this.open = false; this.open = false;
this.reset(); this.reset();
}, },

View File

@ -255,6 +255,7 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="商品用途" prop="goodsPurpose"> <el-form-item label="商品用途" prop="goodsPurpose">
<el-select <el-select
@ -380,7 +381,7 @@
> >
<el-form <el-form
ref="queryForm" ref="queryForm"
:model="nurseStationqueryParams" :model="getListByUserquery"
:rules="rules" :rules="rules"
label-width="80px" label-width="80px"
:inline="true" :inline="true"
@ -391,7 +392,7 @@
label-width="120" label-width="120"
> >
<el-input <el-input
v-model="nurseStationqueryParams.nurseStationCode" v-model="getListByUserquery.nurseStationCode"
placeholder="请输入护理站编码" placeholder="请输入护理站编码"
clearable clearable
/> />
@ -402,7 +403,7 @@
label-width="120" label-width="120"
> >
<el-input <el-input
v-model="nurseStationqueryParams.nurseStationName" v-model="getListByUserquery.nurseStationName"
placeholder="请输入护理站名称" placeholder="请输入护理站名称"
clearable clearable
/> />
@ -463,10 +464,10 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination <pagination
v-show="nursetotal > 0" v-show="total2 > 0"
:total="nursetotal" :total="total2"
:page.sync="nurseStationqueryParams.pageNum" :page.sync="getListByUserquery.pageNum"
:limit.sync="nurseStationqueryParams.pageSize" :limit.sync="getListByUserquery.pageSize"
@pagination="handleQuery2" @pagination="handleQuery2"
/> />
</el-dialog> </el-dialog>
@ -479,10 +480,11 @@ import {
delGoodsInfo, delGoodsInfo,
addGoodsInfo, addGoodsInfo,
updateGoodsInfo, updateGoodsInfo,
updatePicture,
goodsInfoList, goodsInfoList,
goodsCategory, goodsCategory,
editGoodsWhetherShelf, editGoodsWhetherShelf,
} from "@/api/system/OperateGoodsInfo"; } from "@/api/system/goodsInfo";
import editor from "@/components/Editor"; import editor from "@/components/Editor";
import { getListByUser } from "@/api/system/userlist.js"; import { getListByUser } from "@/api/system/userlist.js";
import stationAcatar from "../stationAvatar/index.vue"; import stationAcatar from "../stationAvatar/index.vue";
@ -492,6 +494,7 @@ export default {
name: "OperateGoodsInfo", name: "OperateGoodsInfo",
data() { data() {
return { return {
imgone:"",
imageUrl: "", // imageUrl: "", //
value: "", value: "",
datas: null, datas: null,
@ -507,6 +510,8 @@ export default {
showSearch: true, showSearch: true,
// //
total: 0, total: 0,
total2: 0,
// //
goodsInfoList: [], goodsInfoList: [],
// //
@ -550,7 +555,7 @@ export default {
id: null, id: null,
whetherShelf: null, whetherShelf: null,
}, },
nurseStationqueryParams: { getListByUserquery: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
}, },
@ -604,7 +609,7 @@ export default {
created() { created() {
this.getList(); this.getList();
this.info(); this.info();
this.getList2(); // this.getList2();
}, },
methods: { methods: {
upwhetherShelf(row) { upwhetherShelf(row) {
@ -688,6 +693,14 @@ export default {
}, },
// //
cancel() { cancel() {
console.log(this.form);
var obj = { pictureUrlList: [] };
if(this.imgone !=this.form.goodsPictureUrl ){
obj.pictureUrlList.push(this.form.goodsPictureUrl);
}
updatePicture(obj).then((res) => {
console.log(res);
});
this.open = false; this.open = false;
this.reset(); this.reset();
this.StationName = "请选择所属护理站"; this.StationName = "请选择所属护理站";
@ -717,17 +730,17 @@ export default {
}, },
handleQuery2(){ handleQuery2(){
this.queryParams.pageNum = 1; this.queryParams.pageNum = 1;
this.getList2() this.info()
},
getList2(){
getListByUser(this.nurseStationqueryParams).then((res) => {
this.nursetotal = res.total;
this.nurseStationlist = res.rows;
});
}, },
// getList2(){
// getListByUser(this.nurseStationqueryParams).then((res) => {
// this.nursetotal = res.total;
// this.nurseStationlist = res.rows;
// });
// },
resetQuery2() { resetQuery2() {
this.resetForm("queryForm"); this.resetForm("queryForm");
this.nurseStationqueryParams={ this.getListByUserquery={
pageNum:1, pageNum:1,
pageSize:10 pageSize:10
}, },

View File

@ -145,18 +145,7 @@
>修改</el-button >修改</el-button
> >
</el-col> </el-col>
<!-- <el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['system:station:remove']"
>删除</el-button
>
</el-col> -->
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
type="info" type="info"
@ -168,17 +157,7 @@
>导入</el-button >导入</el-button
> >
</el-col> </el-col>
<!-- <el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['system:station:export']"
>导出</el-button
>
</el-col> -->
<right-toolbar <right-toolbar
:showSearch.sync="showSearch" :showSearch.sync="showSearch"
@queryTable="getList" @queryTable="getList"
@ -225,18 +204,7 @@
prop="address" prop="address"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<!-- <el-table-column
label="护理站简介"
align="center"
prop="agencyIntroduce"
:show-overflow-tooltip="true"
/>
<el-table-column
label="护理站总概述"
align="center"
prop="nurseStationDescription"
:show-overflow-tooltip="true"
/> -->
<el-table-column label="护理站经度" align="center" prop="longitude" /> <el-table-column label="护理站经度" align="center" prop="longitude" />
<el-table-column label="护理站纬度" align="center" prop="latitude" /> <el-table-column label="护理站纬度" align="center" prop="latitude" />
<el-table-column label="联系电话" align="center" prop="phone" /> <el-table-column label="联系电话" align="center" prop="phone" />
@ -250,13 +218,6 @@
class-name="small-padding fixed-width" class-name="small-padding fixed-width"
> >
<template slot-scope="scope"> <template slot-scope="scope">
<!-- <el-button
size="mini"
type="text"
icon="el-icon-search"
@click="looknurseStationLabelList(scope.row)"
>查看标签信息</el-button
> -->
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
@ -310,33 +271,6 @@
</div> </div>
</el-dialog> </el-dialog>
<!-- 查看标签信息 -->
<!-- <el-dialog
title="标签信息"
:visible.sync="nurseStationLabelopen"
width="700px"
append-to-body
>
<el-table v-loading="loading" :data="looknurseStationLabel">
<el-table-column
label="标签名称"
align="center"
prop="labelDescription"
/>
<el-table-column label="标签编号" align="center" prop="labelCode" />
<el-table-column label="排序" align="center" prop="sort" />
</el-table>
<div slot="footer" class="dialog-footer">
<el-button
type="primary"
plain
@click="nurseStationLabelopen = false"
size="small"
>关闭窗口</el-button
>
</div>
</el-dialog> -->
<!-- 新增护理站信息对话框 --> <!-- 新增护理站信息对话框 -->
<el-dialog <el-dialog
:title="title" :title="title"
@ -445,22 +379,7 @@
oninput=" if(value.length>10){value=value.slice(0,20)}" oninput=" if(value.length>10){value=value.slice(0,20)}"
/> />
</el-form-item> </el-form-item>
<!-- <el-form-item label="护理类型" prop="nurseStationType">
<el-select
v-model="nurseStationType2"
multiple
placeholder="请选择护理类型"
style="width: 208px"
>
<el-option
v-for="item in nurseStationTypelist"
:key="item.nurseTypeCode"
:label="item.nurseTypeName"
:value="item.nurseTypeCode"
>
</el-option>
</el-select>
</el-form-item> -->
<el-form-item label="联系电话" prop="phone"> <el-form-item label="联系电话" prop="phone">
<el-input <el-input
v-model="form.phone" v-model="form.phone"
@ -635,10 +554,9 @@ import {
updateStation, updateStation,
getFirstLevelInfo, getFirstLevelInfo,
getSecondaryLevelInfo, getSecondaryLevelInfo,
getSubordinateRegions,
getInfoLists, getInfoLists,
nurseStationlabel, updatePicture,
getLabelList,
} from "@/api/system/station"; } from "@/api/system/station";
import { getInfoList } from "@/api/system/nurseItem"; import { getInfoList } from "@/api/system/nurseItem";
import stationAcatar from "../stationAvatar/index.vue"; import stationAcatar from "../stationAvatar/index.vue";
@ -677,6 +595,8 @@ export default {
return { return {
imageUrl: "", imageUrl: "",
imageUrl2: "", imageUrl2: "",
imgtwo:"",
imgone:"",
// //
upload: { upload: {
// //
@ -749,6 +669,7 @@ export default {
pageSize: 10, pageSize: 10,
}, },
// //
queryParams: { queryParams: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
@ -798,18 +719,14 @@ export default {
trigger: "blur", trigger: "blur",
message: "", message: "",
}, },
// { required: true, message: "", trigger: "blur" },
], ],
// dutyPerson: [
// { required: true, message: "", trigger: "blur" },
// ],
dutyPhone: [ dutyPhone: [
{ {
validator: checkMobile2, validator: checkMobile2,
trigger: "blur", trigger: "blur",
message: "", message: "",
}, },
// { required: false, message: "", trigger: "blur" },
], ],
sort: [{ required: true, message: "排序不能为空", trigger: "blur" }], sort: [{ required: true, message: "排序不能为空", trigger: "blur" }],
address: [{ required: true, message: "地址不能为空", trigger: "blur" }], address: [{ required: true, message: "地址不能为空", trigger: "blur" }],
@ -859,37 +776,7 @@ export default {
} else { } else {
this.looknurseStationLabel.splice(index, 1); this.looknurseStationLabel.splice(index, 1);
} }
// if (item.ids && !item.id) {
// if (this.looknurseStationLabel.length == 1) {
// // this.$message.error("");
// this.looknurseStationLabel = [
// {
// labelDescription: "",
// sort: "",
// ids: 1,
// },
// ];
// } else {
// this.looknurseStationLabel = this.looknurseStationLabel.filter(
// (e) => e.ids != item.ids
// );
// }
// } else if (!item.ids && item.id) {
// if (this.looknurseStationLabel.length == 1) {
// // this.$message.error("");
// this.nurseStationLabelList = [
// {
// labelDescription: "",
// sort: "",
// ids: 1,
// },
// ];
// } else {
// this.looknurseStationLabel = this.looknurseStationLabel.filter(
// (e) => e.id != item.id
// );
// }
// }
console.log(this.form.nurseStationLabelList); console.log(this.form.nurseStationLabelList);
}, },
addnurseStationLabelList() { addnurseStationLabelList() {
@ -906,15 +793,7 @@ export default {
} }
console.log(this.looknurseStationLabel); console.log(this.looknurseStationLabel);
}, },
//
// looknurseStationLabelList(item) {
// console.log(item);
// nurseStationlabel(item.id).then((res) => {
// this.looknurseStationLabel = res.rows;
// this.nurseStationLabelopen = true;
// console.log(this.looknurseStationLabel);
// });
// },
// //
looktype(item) { looktype(item) {
// console.log(item); // console.log(item);
@ -972,6 +851,17 @@ export default {
}, },
// //
cancel() { cancel() {
console.log(this.form);
var obj = { pictureUrlList: [] };
if(this.imgone !=this.form.stationIntroducePcitureUrl ){
obj.pictureUrlList.push(this.form.stationIntroducePcitureUrl);
}
if(this.imgtwo !=this.form.stationPictureUrl ){
obj.pictureUrlList.push(this.form.stationPictureUrl);
}
updatePicture(obj).then((res) => {
console.log(res);
});
this.open = false; this.open = false;
this.reset(); this.reset();
this.value3 = ""; this.value3 = "";
@ -1083,9 +973,7 @@ export default {
console.log(response); console.log(response);
this.form = response.data; this.form = response.data;
this.looknurseStationLabel = response.data.nurseStationLabel; this.looknurseStationLabel = response.data.nurseStationLabel;
this.nurseStationType2 = this.form.nurseStationType.split(",");
console.log(this.list); console.log(this.list);
this.open = true; this.open = true;
this.loading = false; this.loading = false;
console.log(this.form); console.log(this.form);