[WIP] Добавил переход на медкарту, возможность редактирования основных данных

This commit is contained in:
megavrilinvv
2023-08-16 16:44:03 +03:00
parent 37f5520796
commit b7af4b15ca
5 changed files with 81 additions and 24 deletions

View File

@@ -24,15 +24,15 @@ const state = () => ({
region: null,
city: null,
street: null,
house_number: null,
apartment_number: null,
house: null,
flat: null,
},
residenceAddress: {
region: null,
city: null,
street: null,
house_number: null,
apartment_number: null,
house: null,
flat: null,
},
insuranceDMS: {
series: null,
@@ -163,17 +163,17 @@ const getters = {
region: registrationAddress?.region || "",
city: registrationAddress?.city || "",
street: registrationAddress?.street || "",
house_number: registrationAddress?.house_number || "",
apartment_number: registrationAddress?.apartment_number || "",
id: registrationAddress?.id || "",
house: registrationAddress?.house || "",
flat: registrationAddress?.flat || "",
category: "Адрес регистрации",
},
residenceAddress: {
region: residenceAddress?.region || "",
city: residenceAddress?.city || "",
street: residenceAddress?.street || "",
house_number: residenceAddress?.house_number || "",
apartment_number: residenceAddress?.apartment_number || "",
id: residenceAddress?.id || "",
house: residenceAddress?.house || "",
flat: residenceAddress?.flat || "",
category: "Адрес проживания",
},
insuranceDMS: {
series: DMS?.series,
@@ -429,6 +429,11 @@ const getters = {
};
const actions = {
postAddress(context, { id, address }) {
fetchWrapper.post(`address/${id}`, {
...address,
});
},
deleteItemData({ commit }, props) {
commit("setDataWithouDeleted", props);
},