index.js 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. var template = ''
  2. $.ajax('../../../component/statistics/LascCervicalGynecologicalExaminationEntityList/index.html', {
  3. data: {},
  4. dataType: 'html',
  5. cache: false,
  6. timeout: 60000,
  7. async: false,
  8. error: function (res) {},
  9. success: function (res) {
  10. template = res
  11. }
  12. })
  13. Vue.component('lasc-cervical-gynecological-examination-entityList', {
  14. template: template,
  15. props: ['data'],
  16. data: function () {
  17. return {
  18. readonly: true,
  19. readonlyTwo: 1,
  20. isShowPicker: false,
  21. vulvaInspectList: ['正常', '白斑', '溃疡', '湿疣', '疱疹', '肿物', '其他'],
  22. vaginalInspectList: ['正常', '充血', '溃疡', '湿疣', '疱疹', '肿物', '其他'],
  23. secretionList: ['正常', '异味', '血性', '脓性', '泡沫样', '豆渣样', '其他'],
  24. cervixInspectList: ['正常', '触血', '息肉', '糜烂样', '菜花样', '其他'],
  25. columns: [],
  26. pickType: '',
  27. curItem: '',
  28. isShowDatePicker: false,
  29. activeDateField: '',
  30. date: '',
  31. // minDate: moment().add(-100, 'year').toDate(),
  32. minDate: null,
  33. form: {
  34. screenId: '', //两癌筛查id
  35. receiveCervicalCarcinomaInspect: '2', //是否接收乳腺临床检查1拒绝2接收
  36. list: []
  37. }
  38. }
  39. },
  40. methods: {
  41. formatList: function (str) {
  42. return (str && str.split(',')) || []
  43. }
  44. },
  45. mounted() {
  46. var vm = this
  47. this.form.screenId = this.data.screenId || ''
  48. if (this.data.value && this.data.value.length) {
  49. var list = JSON.parse(JSON.stringify(this.data.value))
  50. list.forEach(function (v) {
  51. v.vulvaInspect = vm.formatList(v.vulvaInspect)
  52. v.vaginalInspect = vm.formatList(v.vaginalInspect)
  53. v.secretion = vm.formatList(v.secretion)
  54. v.cervixInspect = vm.formatList(v.cervixInspect)
  55. v.uterusInspect = vm.formatList(v.uterusInspect)
  56. v.pelvicInspect = vm.formatList(v.pelvicInspect)
  57. v.secretionInspectPathogens = vm.formatList(v.secretionInspectPathogens)
  58. v.clinicalDiagnosis = vm.formatList(v.clinicalDiagnosis)
  59. v.pelvicTendernessLocation = vm.formatList(v.pelvicTendernessLocation)
  60. v.uterusInspectTumorPosition = vm.formatList(v.uterusInspectTumorPosition)
  61. v.vaginalInspectTumorPosition = vm.formatList(v.vaginalInspectTumorPosition)
  62. v.vulvaInspectTumorPosition = vm.formatList(v.vulvaInspectTumorPosition)
  63. v.pelvicInspectTumorPosition = vm.formatList(v.pelvicInspectTumorPosition)
  64. })
  65. this.form.list = list
  66. this.form.receiveCervicalCarcinomaInspect = list[0].receiveCervicalCarcinomaInspect
  67. }
  68. }
  69. })