You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

83 lines
2.7 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. import Vue from "vue";
  2. import Vuex from "vuex";
  3. Vue.use(Vuex);
  4. export default new Vuex.Store({
  5. state: {
  6. set: 'qqqq',
  7. customerOrg: { //体检单位设置
  8. customerOrgTree: [], //体检单位列表
  9. treeprops: {
  10. label: "displayName",
  11. value: "id",
  12. children: "treeChildren",
  13. }, //树形组件的数据结构
  14. customerOrgId:'',//当前单位ID(可根据此值是否为空,判断是新增还是编辑)
  15. customerOrgRd:{displayName:'单位名称'}, //单个体检单位记录值
  16. customerOrgRegisterList: [], //单位体检次数登记列表
  17. contactPersonList:[], //联系人列表
  18. contactMethodList:[], //联系方式列表
  19. },
  20. personnelUnit:{
  21. personnelgrouping:[], //人员分组
  22. id:'',//根据Id选择的数据
  23. form:'',//列表每一项
  24. nogroupselected:[],//已选分组
  25. },
  26. //体检人员登记 add by pengjun
  27. patientRegister:{
  28. customerOrgTreeAll: [], //体检单位列表(含个人)
  29. patientRegisterId:'', //当前单位ID(可根据此值是否为空,判断是新增还是编辑)
  30. patientRegisterRd:{}, //体检人员记录
  31. query:{
  32. times:0, //触发查询次数
  33. customerOrgId:'', //体检单位ID
  34. },//查询条件
  35. customerOrgGroup:[], //分组(针对单位)
  36. },
  37. //公共字典数据 add by pengjun
  38. dict:{
  39. personOrgId:'00000000-0000-0000-0000-000000000000', //个人体检单位ID
  40. organization:[], //体检中心
  41. sex:[], //性别
  42. medicalType:[], //体检类别
  43. personnelType:[], //人员类别
  44. maritalStatus:[],//婚姻状况
  45. sexHormoneTerm:[],//性激素期
  46. nation:[], //民族
  47. birthPlace:[], //籍惯 ,出生地
  48. completeFlag:[ //体检完成标志
  49. {id:'0',displayName:'预登记'},{id:'1',displayName:'正式登记'},{id:'2',displayName:'部份已检'},{id:'3',displayName:'已总检'},
  50. ],
  51. medicalPackage:[], //所有套餐
  52. customerOrgGroupAll:[], //所有分组,不限单位,不限次数
  53. },
  54. },
  55. getters: {},
  56. mutations: {//同步更改状态
  57. //通用设置 state 值 option {key-value} add by pengjun
  58. setData(state, option) {
  59. let array = option.key.split('.')
  60. switch (array.length) {
  61. case 1:
  62. state[array[0]] = option.value; break;
  63. case 2:
  64. state[array[0]][array[1]] = option.value; break;
  65. case 3:
  66. state[array[0]][array[1]][array[2]] = option.value; break;
  67. case 4:
  68. state[array[0]][array[1]][array[2]][array[3]] = option.value; break;
  69. }
  70. }
  71. },
  72. actions: {},
  73. modules: {},
  74. });