|
@@ -1519,10 +1519,12 @@ func (c *SZHisApiController) GetSettleAccounts() {
|
1519
|
1519
|
|
1520
|
1520
|
func (c *SZHisApiController) GetDrugList() {
|
1521
|
1521
|
|
|
1522
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
1523
|
+ orgId := adminUserInfo.CurrentOrgId
|
1522
|
1524
|
//获取药品库数据
|
1523
|
|
- list, _ := service.GetDrugList(10028)
|
|
1525
|
+ list, _ := service.GetDrugList(orgId)
|
1524
|
1526
|
//获取药品剂型
|
1525
|
|
- drugs, _ := service.GetDrugDosageForm(10028)
|
|
1527
|
+ drugs, _ := service.GetDrugDosageForm(orgId)
|
1526
|
1528
|
for _, item := range list {
|
1527
|
1529
|
fmt.Println(item.DrugDosageForm)
|
1528
|
1530
|
for _, it := range drugs {
|
|
@@ -1533,7 +1535,7 @@ func (c *SZHisApiController) GetDrugList() {
|
1533
|
1535
|
}
|
1534
|
1536
|
}
|
1535
|
1537
|
fmt.Print("list22222222", list)
|
1536
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
1538
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
1537
|
1539
|
var doctor_name string
|
1538
|
1540
|
var doctor_code string
|
1539
|
1541
|
|
|
@@ -1568,15 +1570,15 @@ func (c *SZHisApiController) GetDrugList() {
|
1568
|
1570
|
detail := &models.DrugDetail{
|
1569
|
1571
|
|
1570
|
1572
|
MedicalInsuranceNumber: item.MedicalInsuranceNumber,
|
1571
|
|
- Code: item.Code,
|
1572
|
|
- DrugName: item.DrugName,
|
1573
|
|
- DrugSpec: item.DrugSpec,
|
1574
|
|
- DrugDosageName: item.DrugDosageName,
|
1575
|
|
- ManufacturerName: item.ManufacturerName,
|
1576
|
|
- MinUnit: item.MinUnit,
|
1577
|
|
- RetailPrice: item.RetailPrice,
|
1578
|
|
- LastPrice: item.LastPrice,
|
1579
|
|
- LimitRemark: item.LimitRemark,
|
|
1573
|
+ Code: item.Code,
|
|
1574
|
+ DrugName: item.DrugName,
|
|
1575
|
+ DrugSpec: item.DrugSpec,
|
|
1576
|
+ DrugDosageName: item.DrugDosageName,
|
|
1577
|
+ ManufacturerName: item.ManufacturerName,
|
|
1578
|
+ MinUnit: item.MinUnit,
|
|
1579
|
+ RetailPrice: item.RetailPrice,
|
|
1580
|
+ LastPrice: item.LastPrice,
|
|
1581
|
+ LimitRemark: item.LimitRemark,
|
1580
|
1582
|
}
|
1581
|
1583
|
customs = append(customs, detail)
|
1582
|
1584
|
}
|
|
@@ -1613,11 +1615,13 @@ func (c *SZHisApiController) GetDrugList() {
|
1613
|
1615
|
}
|
1614
|
1616
|
|
1615
|
1617
|
func (c *SZHisApiController) GetTreatmentProject() {
|
|
1618
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
1619
|
+ orgId := adminUserInfo.CurrentOrgId
|
1616
|
1620
|
|
1617
|
1621
|
//获取药品库数据
|
1618
|
|
- list, _ := service.GetDrugList(10028)
|
|
1622
|
+ list, _ := service.GetDrugList(orgId)
|
1619
|
1623
|
|
1620
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
1624
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
1621
|
1625
|
var doctor_name string
|
1622
|
1626
|
var doctor_code string
|
1623
|
1627
|
|
|
@@ -1652,13 +1656,13 @@ func (c *SZHisApiController) GetTreatmentProject() {
|
1652
|
1656
|
detail := &models.DrugDetail{
|
1653
|
1657
|
|
1654
|
1658
|
MedicalInsuranceNumber: item.MedicalInsuranceNumber, //社保目录
|
1655
|
|
- Code: item.Code, //协议机构内部目录编码
|
1656
|
|
- DrugName: item.DrugName, //协议机构内部目录名称
|
1657
|
|
- DrugSpec: item.DrugSpec,
|
1658
|
|
- ManufacturerName: item.ManufacturerName,
|
1659
|
|
- MinUnit: item.MinUnit,
|
1660
|
|
- RetailPrice: item.RetailPrice, //协议机构内部项目收费价格
|
1661
|
|
- LimitRemark: item.LimitRemark,
|
|
1659
|
+ Code: item.Code, //协议机构内部目录编码
|
|
1660
|
+ DrugName: item.DrugName, //协议机构内部目录名称
|
|
1661
|
+ DrugSpec: item.DrugSpec,
|
|
1662
|
+ ManufacturerName: item.ManufacturerName,
|
|
1663
|
+ MinUnit: item.MinUnit,
|
|
1664
|
+ RetailPrice: item.RetailPrice, //协议机构内部项目收费价格
|
|
1665
|
+ LimitRemark: item.LimitRemark,
|
1662
|
1666
|
}
|
1663
|
1667
|
customs = append(customs, detail)
|
1664
|
1668
|
}
|
|
@@ -1694,6 +1698,8 @@ func (c *SZHisApiController) GetTreatmentProject() {
|
1694
|
1698
|
|
1695
|
1699
|
func (c *SZHisApiController) GetRevocation() {
|
1696
|
1700
|
|
|
1701
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
1702
|
+ orgId := adminUserInfo.CurrentOrgId
|
1697
|
1703
|
id, _ := c.GetInt64("id")
|
1698
|
1704
|
//用来区分是药品的撤销还是耗材的撤销 1.药品 2.诊疗项目 3.材料 5.辅助器具项目
|
1699
|
1705
|
|
|
@@ -1701,9 +1707,9 @@ func (c *SZHisApiController) GetRevocation() {
|
1701
|
1707
|
fmt.Println("type_id2222222", type_id)
|
1702
|
1708
|
if type_id == 1 {
|
1703
|
1709
|
//获取药品库数据
|
1704
|
|
- list, _ := service.GetDrugListByDetail(10028, id)
|
|
1710
|
+ list, _ := service.GetDrugListByDetail(orgId, id)
|
1705
|
1711
|
|
1706
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
1712
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
1707
|
1713
|
var doctor_name string
|
1708
|
1714
|
var doctor_code string
|
1709
|
1715
|
|
|
@@ -1756,25 +1762,6 @@ func (c *SZHisApiController) GetRevocation() {
|
1756
|
1762
|
} else {
|
1757
|
1763
|
fmt.Println(err)
|
1758
|
1764
|
}
|
1759
|
|
- MedicalInsuranceNumber: item.MedicalInsuranceNumber, //社保目录
|
1760
|
|
- Code: item.Code, //协议机构内部目录编码
|
1761
|
|
- DrugName: item.DrugName, //协议机构内部目录名称
|
1762
|
|
- DrugSpec: item.DrugSpec,
|
1763
|
|
- ManufacturerName: item.ManufacturerName,
|
1764
|
|
- MinUnit: item.MinUnit,
|
1765
|
|
- RetailPrice: item.RetailPrice, //协议机构内部项目收费价格
|
1766
|
|
- LimitRemark: item.LimitRemark,
|
1767
|
|
- }
|
1768
|
|
- customs = append(customs, detail)
|
1769
|
|
- }
|
1770
|
|
- result := service.SzybML010(doctor_name, doctor_code, miConfig.Code, customs)
|
1771
|
|
- fmt.Println("reuslt9999999999999999", result)
|
1772
|
|
- var dat map[string]interface{}
|
1773
|
|
- if err := json.Unmarshal([]byte(result), &dat); err == nil {
|
1774
|
|
- fmt.Println(dat)
|
1775
|
|
- } else {
|
1776
|
|
- fmt.Println(err)
|
1777
|
|
- }
|
1778
|
1765
|
|
1779
|
1766
|
userJSONBytes, _ := json.Marshal(dat)
|
1780
|
1767
|
|
|
@@ -1796,130 +1783,131 @@ func (c *SZHisApiController) GetRevocation() {
|
1796
|
1783
|
fmt.Println(isSuccess)
|
1797
|
1784
|
}
|
1798
|
1785
|
|
1799
|
|
- }
|
|
1786
|
+ if type_id == 3 {
|
1800
|
1787
|
|
1801
|
|
- if type_id == 3 {
|
|
1788
|
+ //获取药品库数据
|
|
1789
|
+ list, _ := service.GetGoodListByDetail(orgId, id)
|
1802
|
1790
|
|
1803
|
|
- //获取药品库数据
|
1804
|
|
- list, _ := service.GetGoodListByDetail(10028, id)
|
|
1791
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
|
1792
|
+ var doctor_name string
|
|
1793
|
+ var doctor_code string
|
1805
|
1794
|
|
1806
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
1807
|
|
- var doctor_name string
|
1808
|
|
- var doctor_code string
|
|
1795
|
+ doctor_name = "黄亦轩"
|
|
1796
|
+ doctor_code = "1001"
|
1809
|
1797
|
|
1810
|
|
- doctor_name = "黄亦轩"
|
1811
|
|
- doctor_code = "1001"
|
|
1798
|
+ var pagesize int = 50
|
|
1799
|
+ var start int = 1
|
|
1800
|
+ var stop int
|
|
1801
|
+ var pagecount int
|
|
1802
|
+ var curpage int
|
|
1803
|
+ var isSuccess bool = true
|
|
1804
|
+ //总页数,向上取整,注意除之前要先转换类型为float64
|
|
1805
|
+ pagecount = int(math.Ceil(float64(len(list)) / float64(pagesize)))
|
|
1806
|
+
|
|
1807
|
+ var ress []*Result
|
|
1808
|
+ for curpage = 1; curpage <= pagecount; curpage++ {
|
|
1809
|
+ if curpage == 1 {
|
|
1810
|
+ start = 1
|
|
1811
|
+ } else {
|
|
1812
|
+ start = (curpage-1)*pagesize + 1
|
|
1813
|
+ }
|
|
1814
|
+ stop = curpage * pagesize
|
|
1815
|
+ if stop > len(list) {
|
|
1816
|
+ stop = len(list)
|
|
1817
|
+ }
|
|
1818
|
+ //这里就可以查看开始和结束了
|
|
1819
|
+ fmt.Println(list[start-1 : stop])
|
|
1820
|
+ var customs []*models.DrugDetail
|
|
1821
|
+ for _, item := range list {
|
|
1822
|
+ fmt.Println("医疗机构编码", item.MedicalInsuranceNumber)
|
|
1823
|
+ detail := &models.DrugDetail{
|
|
1824
|
+ SocialSecurityDirectoryCode: item.SocialSecurityDirectoryCode,
|
|
1825
|
+ ManufacturerName: item.ManufacturerName,
|
|
1826
|
+ }
|
|
1827
|
+ customs = append(customs, detail)
|
|
1828
|
+ }
|
|
1829
|
+ result := service.SzybML010(doctor_name, doctor_code, miConfig.Code, customs, type_id)
|
|
1830
|
+ fmt.Println("reuslt", result)
|
|
1831
|
+ var dat map[string]interface{}
|
|
1832
|
+ if err := json.Unmarshal([]byte(result), &dat); err == nil {
|
|
1833
|
+ fmt.Println(dat)
|
|
1834
|
+ } else {
|
|
1835
|
+ fmt.Println(err)
|
|
1836
|
+ }
|
1812
|
1837
|
|
1813
|
|
- var pagesize int = 50
|
1814
|
|
- var start int = 1
|
1815
|
|
- var stop int
|
1816
|
|
- var pagecount int
|
1817
|
|
- var curpage int
|
1818
|
|
- var isSuccess bool = true
|
1819
|
|
- //总页数,向上取整,注意除之前要先转换类型为float64
|
1820
|
|
- pagecount = int(math.Ceil(float64(len(list)) / float64(pagesize)))
|
|
1838
|
+ userJSONBytes, _ := json.Marshal(dat)
|
1821
|
1839
|
|
1822
|
|
- var ress []*Result
|
1823
|
|
- for curpage = 1; curpage <= pagecount; curpage++ {
|
1824
|
|
- if curpage == 1 {
|
1825
|
|
- start = 1
|
1826
|
|
- } else {
|
1827
|
|
- start = (curpage-1)*pagesize + 1
|
1828
|
|
- }
|
1829
|
|
- stop = curpage * pagesize
|
1830
|
|
- if stop > len(list) {
|
1831
|
|
- stop = len(list)
|
1832
|
|
- }
|
1833
|
|
- //这里就可以查看开始和结束了
|
1834
|
|
- fmt.Println(list[start-1 : stop])
|
1835
|
|
- var customs []*models.DrugDetail
|
1836
|
|
- for _, item := range list {
|
1837
|
|
- fmt.Println("医疗机构编码", item.MedicalInsuranceNumber)
|
1838
|
|
- detail := &models.DrugDetail{
|
1839
|
|
- SocialSecurityDirectoryCode: item.SocialSecurityDirectoryCode,
|
1840
|
|
- ManufacturerName: item.ManufacturerName,
|
|
1840
|
+ var res Result
|
|
1841
|
+ if err := json.Unmarshal(userJSONBytes, &res); err != nil {
|
|
1842
|
+ utils.ErrorLog("解析失败:%v", err)
|
|
1843
|
+ c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDataException)
|
|
1844
|
+ return
|
1841
|
1845
|
}
|
1842
|
|
- customs = append(customs, detail)
|
1843
|
|
- }
|
1844
|
|
- result := service.SzybML010(doctor_name, doctor_code, miConfig.Code, customs, type_id)
|
1845
|
|
- fmt.Println("reuslt", result)
|
1846
|
|
- var dat map[string]interface{}
|
1847
|
|
- if err := json.Unmarshal([]byte(result), &dat); err == nil {
|
1848
|
|
- fmt.Println(dat)
|
1849
|
|
- } else {
|
1850
|
|
- fmt.Println(err)
|
1851
|
|
- }
|
1852
|
|
-
|
1853
|
|
- userJSONBytes, _ := json.Marshal(dat)
|
|
1846
|
+ if res.Transreturncode == "00000000" {
|
|
1847
|
+ ress = append(ress, &res)
|
|
1848
|
+ } else {
|
|
1849
|
+ isSuccess = false
|
|
1850
|
+ //失败
|
1854
|
1851
|
|
1855
|
|
- var res Result
|
1856
|
|
- if err := json.Unmarshal(userJSONBytes, &res); err != nil {
|
1857
|
|
- utils.ErrorLog("解析失败:%v", err)
|
1858
|
|
- c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDataException)
|
1859
|
|
- return
|
|
1852
|
+ c.ServeFailJSONWithSGJErrorCode(enums.ErrorDrugReturnFaildParamWrong)
|
|
1853
|
+ return
|
|
1854
|
+ }
|
|
1855
|
+ fmt.Println(isSuccess)
|
1860
|
1856
|
}
|
1861
|
|
- if res.Transreturncode == "00000000" {
|
1862
|
|
- ress = append(ress, &res)
|
1863
|
|
- } else {
|
1864
|
|
- isSuccess = false
|
1865
|
|
- //失败
|
1866
|
1857
|
|
1867
|
|
- c.ServeFailJSONWithSGJErrorCode(enums.ErrorDrugReturnFaildParamWrong)
|
1868
|
|
- return
|
1869
|
|
- }
|
1870
|
|
- fmt.Println(isSuccess)
|
1871
|
1858
|
}
|
1872
|
1859
|
|
1873
|
1860
|
}
|
1874
|
1861
|
|
|
1862
|
+ //func (c *SZHisApiController) GetInformationQuery() {
|
|
1863
|
+ //
|
|
1864
|
+ // var doctor_name string
|
|
1865
|
+ // var doctor_code string
|
|
1866
|
+ //
|
|
1867
|
+ // doctor_name = "黄亦轩"
|
|
1868
|
+ // doctor_code = "1001"
|
|
1869
|
+ // miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
1870
|
+ // result := service.SzybML010(doctor_name, doctor_code, miConfig.Code, customs)
|
|
1871
|
+ // fmt.Println("reuslt9999999999999999", result)
|
|
1872
|
+ // var dat map[string]interface{}
|
|
1873
|
+ // if err := json.Unmarshal([]byte(result), &dat); err == nil {
|
|
1874
|
+ // fmt.Println(dat)
|
|
1875
|
+ // } else {
|
|
1876
|
+ // fmt.Println(err)
|
|
1877
|
+ // }
|
|
1878
|
+ //
|
|
1879
|
+ // userJSONBytes, _ := json.Marshal(dat)
|
|
1880
|
+ //
|
|
1881
|
+ // var res Result
|
|
1882
|
+ // if err := json.Unmarshal(userJSONBytes, &res); err != nil {
|
|
1883
|
+ // utils.ErrorLog("解析失败:%v", err)
|
|
1884
|
+ // c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDataException)
|
|
1885
|
+ // return
|
|
1886
|
+ // }
|
|
1887
|
+ // if res.Transreturncode == "00000000" {
|
|
1888
|
+ // ress = append(ress, &res)
|
|
1889
|
+ // } else {
|
|
1890
|
+ // isSuccess = false
|
|
1891
|
+ // //失败
|
|
1892
|
+ //
|
|
1893
|
+ // c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodePreSettleFaildParamWrong)
|
|
1894
|
+ // return
|
|
1895
|
+ // }
|
|
1896
|
+ // fmt.Println(isSuccess)
|
|
1897
|
+ //
|
|
1898
|
+ //}
|
1875
|
1899
|
}
|
1876
|
|
-
|
1877
|
|
-//func (c *SZHisApiController) GetInformationQuery() {
|
1878
|
|
-//
|
1879
|
|
-// var doctor_name string
|
1880
|
|
-// var doctor_code string
|
1881
|
|
-//
|
1882
|
|
-// doctor_name = "黄亦轩"
|
1883
|
|
-// doctor_code = "1001"
|
1884
|
|
-// miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
1885
|
|
-// result := service.SzybML010(doctor_name, doctor_code, miConfig.Code, customs)
|
1886
|
|
-// fmt.Println("reuslt9999999999999999", result)
|
1887
|
|
-// var dat map[string]interface{}
|
1888
|
|
-// if err := json.Unmarshal([]byte(result), &dat); err == nil {
|
1889
|
|
-// fmt.Println(dat)
|
1890
|
|
-// } else {
|
1891
|
|
-// fmt.Println(err)
|
1892
|
|
-// }
|
1893
|
|
-//
|
1894
|
|
-// userJSONBytes, _ := json.Marshal(dat)
|
1895
|
|
-//
|
1896
|
|
-// var res Result
|
1897
|
|
-// if err := json.Unmarshal(userJSONBytes, &res); err != nil {
|
1898
|
|
-// utils.ErrorLog("解析失败:%v", err)
|
1899
|
|
-// c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDataException)
|
1900
|
|
-// return
|
1901
|
|
-// }
|
1902
|
|
-// if res.Transreturncode == "00000000" {
|
1903
|
|
-// ress = append(ress, &res)
|
1904
|
|
-// } else {
|
1905
|
|
-// isSuccess = false
|
1906
|
|
-// //失败
|
1907
|
|
-//
|
1908
|
|
-// c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodePreSettleFaildParamWrong)
|
1909
|
|
-// return
|
1910
|
|
-// }
|
1911
|
|
-// fmt.Println(isSuccess)
|
1912
|
|
-//
|
1913
|
|
-//}
|
1914
|
|
-
|
1915
|
1900
|
func (c *SZHisApiController) GetDoctorList() {
|
1916
|
1901
|
|
|
1902
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
1903
|
+ orgid := adminUserInfo.CurrentOrgId
|
|
1904
|
+ fmt.Println("or3gi", orgid)
|
1917
|
1905
|
//获取所有医生护士信息
|
1918
|
|
- list, _ := service.GetDoctorList(10028)
|
|
1906
|
+ list, _ := service.GetDoctorList(orgid)
|
1919
|
1907
|
//获取所有角色名称
|
1920
|
|
- roleList, _ := service.GetRoleList(10028)
|
|
1908
|
+ roleList, _ := service.GetRoleList(orgid)
|
1921
|
1909
|
|
1922
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
1910
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgid)
|
1923
|
1911
|
for _, item := range list {
|
1924
|
1912
|
for _, it := range roleList {
|
1925
|
1913
|
if item.RoleId == it.ID {
|
|
@@ -1959,39 +1947,39 @@ func (c *SZHisApiController) GetDoctorList() {
|
1959
|
1947
|
for _, item := range list {
|
1960
|
1948
|
fmt.Println("医护类别", item.Name)
|
1961
|
1949
|
detail := &models.DocDetail{
|
1962
|
|
- UserName: item.UserName,
|
1963
|
|
- RoleId: item.Name,
|
1964
|
|
- Sex: "",
|
1965
|
|
- CardType: "",
|
1966
|
|
- IdCard: "",
|
1967
|
|
- Phone: "",
|
1968
|
|
- WorkMajorName: "",
|
1969
|
|
- Nation: "",
|
1970
|
|
- BirthDay: 20201022,
|
1971
|
|
- WorkTime: 12,
|
1972
|
|
- Education: "",
|
1973
|
|
- StudyMajorName: "",
|
1974
|
|
- CertificateCode: "", //证书编码
|
1975
|
|
- MedicalCode: "", //医师资格编码
|
1976
|
|
- MedicalRangeCode: "", //医师执业范围代码
|
1977
|
|
- MedicalLevel: "", //医生级别
|
1978
|
|
- TypeJob: "", //职业类别
|
1979
|
|
- DoctorNumber: "", //医师编号
|
1980
|
|
- Licensing: "", //职业标志
|
1981
|
|
- DoctorServiceStatus: "", //医师医保服务资格状态
|
1982
|
|
- MonitoringLevel: "", //监控等级
|
1983
|
|
- DrugPsychotropicSubstances: "", //毒麻精神药品资格
|
1984
|
|
- HealthCareCode: "", // 母婴保健技术考核合格证书编号
|
1985
|
|
- PlanningTechnicalServiceCode: "", //计划生育技术服务人员合格证编号
|
1986
|
|
- PharmacistType: "", //药师类别
|
1987
|
|
- PharmacistPracticeCategory: "", //药师执业类别
|
1988
|
|
- PharmacistsLicensing: "", //药师执业范围
|
1989
|
|
- PharmacistRegistrationNumber: "", //执业药师注册证编号
|
1990
|
|
- OfficeCode: "", //科室编码
|
1991
|
|
- JobNumber: "", //工号
|
1992
|
|
- PostName: "", //职位名称
|
1993
|
|
- TechnicalJobLevelCode: "", //专业技术职务级别编码
|
1994
|
|
- IsActive: "", //在职与否
|
|
1950
|
+ UserName: item.UserName,
|
|
1951
|
+ RoleId: item.Name,
|
|
1952
|
+ Sex: "",
|
|
1953
|
+ CardType: "",
|
|
1954
|
+ IdCard: "",
|
|
1955
|
+ Phone: "",
|
|
1956
|
+ WorkMajorName: "",
|
|
1957
|
+ Nation: "",
|
|
1958
|
+ BirthDay: 20201022,
|
|
1959
|
+ WorkTime: 12,
|
|
1960
|
+ Education: "",
|
|
1961
|
+ StudyMajorName: "",
|
|
1962
|
+ CertificateCode: "", //证书编码
|
|
1963
|
+ MedicalCode: "", //医师资格编码
|
|
1964
|
+ MedicalRangeCode: "", //医师执业范围代码
|
|
1965
|
+ MedicalLevel: "", //医生级别
|
|
1966
|
+ TypeJob: "", //职业类别
|
|
1967
|
+ DoctorNumber: "", //医师编号
|
|
1968
|
+ Licensing: "", //职业标志
|
|
1969
|
+ DoctorServiceStatus: "", //医师医保服务资格状态
|
|
1970
|
+ MonitoringLevel: "", //监控等级
|
|
1971
|
+ DrugPsychotropicSubstances: "", //毒麻精神药品资格
|
|
1972
|
+ HealthCareCode: "", // 母婴保健技术考核合格证书编号
|
|
1973
|
+ PlanningTechnicalServiceCode: "", //计划生育技术服务人员合格证编号
|
|
1974
|
+ PharmacistType: "", //药师类别
|
|
1975
|
+ PharmacistPracticeCategory: "", //药师执业类别
|
|
1976
|
+ PharmacistsLicensing: "", //药师执业范围
|
|
1977
|
+ PharmacistRegistrationNumber: "", //执业药师注册证编号
|
|
1978
|
+ OfficeCode: "", //科室编码
|
|
1979
|
+ JobNumber: "", //工号
|
|
1980
|
+ PostName: "", //职位名称
|
|
1981
|
+ TechnicalJobLevelCode: "", //专业技术职务级别编码
|
|
1982
|
+ IsActive: "", //在职与否
|
1995
|
1983
|
PrescriptionQualificationIdentification: "", //处方资格标识
|
1996
|
1984
|
IdentificationOutpatients: "", //门诊大病医师标识
|
1997
|
1985
|
OutpatientIllnessCategory: "", //门诊大病类别
|
|
@@ -2023,22 +2011,24 @@ func (c *SZHisApiController) GetDoctorList() {
|
2023
|
2011
|
isSuccess = false
|
2024
|
2012
|
//失败
|
2025
|
2013
|
|
2026
|
|
- c.ServeFailJSONWithSGJErrorCode(enums.ErrorDrugPreSettleFaildParamWrong)
|
|
2014
|
+ c.ServeFailJSONWithSGJErrorCode(enums.ErrorDoctorLoginFaildParamWrong)
|
2027
|
2015
|
return
|
2028
|
2016
|
}
|
2029
|
2017
|
fmt.Println(isSuccess)
|
2030
|
|
-
|
2031
|
2018
|
}
|
|
2019
|
+
|
2032
|
2020
|
}
|
2033
|
2021
|
|
2034
|
2022
|
func (c *SZHisApiController) GetMedicalList() {
|
2035
|
2023
|
|
|
2024
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
2025
|
+ orgId := adminUserInfo.CurrentOrgId
|
2036
|
2026
|
//获取所有医生护士信息
|
2037
|
|
- list, _ := service.GetDoctorList(10028)
|
|
2027
|
+ list, _ := service.GetDoctorList(orgId)
|
2038
|
2028
|
//获取所有角色名称
|
2039
|
|
- roleList, _ := service.GetRoleList(10028)
|
|
2029
|
+ roleList, _ := service.GetRoleList(orgId)
|
2040
|
2030
|
|
2041
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
2031
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
2042
|
2032
|
for _, item := range list {
|
2043
|
2033
|
for _, it := range roleList {
|
2044
|
2034
|
if item.RoleId == it.ID {
|
|
@@ -2116,43 +2106,7 @@ func (c *SZHisApiController) GetMedicalList() {
|
2116
|
2106
|
IdentificationOutpatients: "1", //门诊大病医师标识
|
2117
|
2107
|
OutpatientIllnessCategory: "血友病", //门诊大病类别
|
2118
|
2108
|
StartTime: 20210311, //开始日期
|
2119
|
|
- UserName: item.UserName,
|
2120
|
|
- RoleId: item.Name,
|
2121
|
|
- Sex: "",
|
2122
|
|
- CardType: "",
|
2123
|
|
- IdCard: "",
|
2124
|
|
- Phone: "",
|
2125
|
|
- WorkMajorName: "",
|
2126
|
|
- Nation: "",
|
2127
|
|
- BirthDay: 20201022,
|
2128
|
|
- WorkTime: 12,
|
2129
|
|
- Education: "",
|
2130
|
|
- StudyMajorName: "",
|
2131
|
|
- CertificateCode: "", //证书编码
|
2132
|
|
- MedicalCode: "", //医师资格编码
|
2133
|
|
- MedicalRangeCode: "", //医师执业范围代码
|
2134
|
|
- MedicalLevel: "", //医生级别
|
2135
|
|
- TypeJob: "", //职业类别
|
2136
|
|
- DoctorNumber: "", //医师编号
|
2137
|
|
- Licensing: "", //职业标志
|
2138
|
|
- DoctorServiceStatus: "", //医师医保服务资格状态
|
2139
|
|
- MonitoringLevel: "", //监控等级
|
2140
|
|
- DrugPsychotropicSubstances: "", //毒麻精神药品资格
|
2141
|
|
- HealthCareCode: "", // 母婴保健技术考核合格证书编号
|
2142
|
|
- PlanningTechnicalServiceCode: "", //计划生育技术服务人员合格证编号
|
2143
|
|
- PharmacistType: "", //药师类别
|
2144
|
|
- PharmacistPracticeCategory: "", //药师执业类别
|
2145
|
|
- PharmacistsLicensing: "", //药师执业范围
|
2146
|
|
- PharmacistRegistrationNumber: "", //执业药师注册证编号
|
2147
|
|
- OfficeCode: "", //科室编码
|
2148
|
|
- JobNumber: "", //工号
|
2149
|
|
- PostName: "", //职位名称
|
2150
|
|
- TechnicalJobLevelCode: "", //专业技术职务级别编码
|
2151
|
|
- IsActive: "", //在职与否
|
2152
|
|
- PrescriptionQualificationIdentification: "", //处方资格标识
|
2153
|
|
- IdentificationOutpatients: "", //门诊大病医师标识
|
2154
|
|
- OutpatientIllnessCategory: "", //门诊大病类别
|
2155
|
|
- StartTime: 1233, //开始日期
|
|
2109
|
+
|
2156
|
2110
|
}
|
2157
|
2111
|
customs = append(customs, detail)
|
2158
|
2112
|
}
|
|
@@ -2190,12 +2144,14 @@ func (c *SZHisApiController) GetMedicalList() {
|
2190
|
2144
|
|
2191
|
2145
|
func (c *SZHisApiController) GetUpdateMedicalList() {
|
2192
|
2146
|
|
|
2147
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
2148
|
+ orgId := adminUserInfo.CurrentOrgId
|
2193
|
2149
|
//获取所有医生护士信息
|
2194
|
|
- list, _ := service.GetDoctorList(10028)
|
|
2150
|
+ list, _ := service.GetDoctorList(orgId)
|
2195
|
2151
|
//获取所有角色名称
|
2196
|
|
- roleList, _ := service.GetRoleList(10028)
|
|
2152
|
+ roleList, _ := service.GetRoleList(orgId)
|
2197
|
2153
|
|
2198
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
2154
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
2199
|
2155
|
for _, item := range list {
|
2200
|
2156
|
for _, it := range roleList {
|
2201
|
2157
|
if item.RoleId == it.ID {
|
|
@@ -2235,84 +2191,45 @@ func (c *SZHisApiController) GetUpdateMedicalList() {
|
2235
|
2191
|
for _, item := range list {
|
2236
|
2192
|
fmt.Println("医护类别", item.Name)
|
2237
|
2193
|
detail := &models.DocDetail{
|
2238
|
|
- StaffCode: "", //医护人员编码
|
2239
|
|
- UserName: item.UserName, //医护人员姓名
|
2240
|
|
- RoleId: item.Name, //医护人员类别
|
2241
|
|
- Sex: "", //性别
|
2242
|
|
- CardType: "", //证件类型
|
2243
|
|
- IdCard: "", //证件号码
|
2244
|
|
- Phone: "", //联系电话
|
2245
|
|
- WorkMajorName: "", //现从事专业名称
|
2246
|
|
- Nation: "", //民族
|
2247
|
|
- BirthDay: 20201022, //出生日期
|
2248
|
|
- WorkTime: 12, //参加工作日期
|
2249
|
|
- Education: "", //学历
|
2250
|
|
- StudyMajorName: "", //所学的专业名称
|
2251
|
|
- CertificateCode: "", //证书编码
|
2252
|
|
- MedicalCode: "", //医师资格编码
|
2253
|
|
- MedicalRangeCode: "", //医师执业范围代码
|
2254
|
|
- MedicalLevel: "", //医生级别
|
2255
|
|
- TypeJob: "", //职业类别
|
2256
|
|
- DoctorNumber: "", //医师编号
|
2257
|
|
- Licensing: "", //职业标志
|
2258
|
|
- DoctorServiceStatus: "", //医师医保服务资格状态
|
2259
|
|
- MonitoringLevel: "", //监控等级
|
2260
|
|
- DrugPsychotropicSubstances: "", //毒麻精神药品资格
|
2261
|
|
- HealthCareCode: "", // 母婴保健技术考核合格证书编号
|
2262
|
|
- PlanningTechnicalServiceCode: "", //计划生育技术服务人员合格证编号
|
2263
|
|
- PharmacistType: "", //药师类别
|
2264
|
|
- PharmacistPracticeCategory: "", //药师执业类别
|
2265
|
|
- PharmacistsLicensing: "", //药师执业范围
|
2266
|
|
- PharmacistRegistrationNumber: "", //执业药师注册证编号
|
2267
|
|
- OfficeCode: "", //科室编码
|
2268
|
|
- JobNumber: "", //工号
|
2269
|
|
- PostName: "", //职位名称
|
2270
|
|
- TechnicalJobLevelCode: "", //专业技术职务级别编码
|
2271
|
|
- IsActive: "", //在职与否
|
2272
|
|
- PrescriptionQualificationIdentification: "", //处方资格标识
|
2273
|
|
- IdentificationOutpatients: "", //门诊大病医师标识
|
2274
|
|
- OutpatientIllnessCategory: "", //门诊大病类别
|
2275
|
|
- StartTime: 1233, //开始日期
|
|
2194
|
+ StaffCode: "", //医护人员编码
|
|
2195
|
+ UserName: item.UserName, //医护人员姓名
|
|
2196
|
+ RoleId: item.Name, //医护人员类别
|
|
2197
|
+ Sex: "", //性别
|
|
2198
|
+ CardType: "", //证件类型
|
|
2199
|
+ IdCard: "", //证件号码
|
|
2200
|
+ Phone: "", //联系电话
|
|
2201
|
+ WorkMajorName: "", //现从事专业名称
|
|
2202
|
+ Nation: "", //民族
|
|
2203
|
+ BirthDay: 20201022, //出生日期
|
|
2204
|
+ WorkTime: 12, //参加工作日期
|
|
2205
|
+ Education: "", //学历
|
|
2206
|
+ StudyMajorName: "", //所学的专业名称
|
|
2207
|
+ CertificateCode: "", //证书编码
|
|
2208
|
+ MedicalCode: "", //医师资格编码
|
|
2209
|
+ MedicalRangeCode: "", //医师执业范围代码
|
|
2210
|
+ MedicalLevel: "", //医生级别
|
|
2211
|
+ TypeJob: "", //职业类别
|
|
2212
|
+ DoctorNumber: "", //医师编号
|
|
2213
|
+ Licensing: "", //职业标志
|
|
2214
|
+ DoctorServiceStatus: "", //医师医保服务资格状态
|
|
2215
|
+ MonitoringLevel: "", //监控等级
|
|
2216
|
+ DrugPsychotropicSubstances: "", //毒麻精神药品资格
|
|
2217
|
+ HealthCareCode: "", // 母婴保健技术考核合格证书编号
|
|
2218
|
+ PlanningTechnicalServiceCode: "", //计划生育技术服务人员合格证编号
|
|
2219
|
+ PharmacistType: "", //药师类别
|
|
2220
|
+ PharmacistPracticeCategory: "", //药师执业类别
|
|
2221
|
+ PharmacistsLicensing: "", //药师执业范围
|
|
2222
|
+ PharmacistRegistrationNumber: "", //执业药师注册证编号
|
|
2223
|
+ OfficeCode: "", //科室编码
|
|
2224
|
+ JobNumber: "", //工号
|
|
2225
|
+ PostName: "", //职位名称
|
|
2226
|
+ TechnicalJobLevelCode: "", //专业技术职务级别编码
|
|
2227
|
+ IsActive: "", //在职与否
|
|
2228
|
+ PrescriptionQualificationIdentification: "", //处方资格标识
|
|
2229
|
+ IdentificationOutpatients: "", //门诊大病医师标识
|
|
2230
|
+ OutpatientIllnessCategory: "", //门诊大病类别
|
|
2231
|
+ StartTime: 1233, //开始日期
|
2276
|
2232
|
EndTime: 123333,
|
2277
|
|
- StaffCode: "H27224269", //医护人员编码
|
2278
|
|
- UserName: item.UserName,
|
2279
|
|
- RoleId: "1",
|
2280
|
|
- Sex: "1",
|
2281
|
|
- CardType: "01",
|
2282
|
|
- IdCard: "430526199408156511",
|
2283
|
|
- Phone: "13318464642",
|
2284
|
|
- WorkMajorName: "医生",
|
2285
|
|
- Nation: "01",
|
2286
|
|
- BirthDay: 20201022,
|
2287
|
|
- WorkTime: 20201022,
|
2288
|
|
- Education: "21",
|
2289
|
|
- StudyMajorName: "医生",
|
2290
|
|
- CertificateCode: "y2222222", //证书编码
|
2291
|
|
- MedicalCode: "y2222222", //医师资格编码
|
2292
|
|
- MedicalRangeCode: "101", //医师执业范围代码
|
2293
|
|
- MedicalLevel: "1", //医生级别
|
2294
|
|
- TypeJob: "1", //职业类别
|
2295
|
|
- DoctorNumber: "22222", //医师编号b
|
2296
|
|
- Licensing: "1", //职业标志
|
2297
|
|
- DoctorServiceStatus: "1", //医师医保服务资格状态
|
2298
|
|
- MonitoringLevel: "1", //监控等级
|
2299
|
|
- DrugPsychotropicSubstances: "1", //毒麻精神药品资格
|
2300
|
|
- HealthCareCode: "1001", // 母婴保健技术考核合格证书编号
|
2301
|
|
- PlanningTechnicalServiceCode: "1002", //计划生育技术服务人员合格证编号
|
2302
|
|
- PharmacistType: "1", //药师类别
|
2303
|
|
- PharmacistPracticeCategory: "1", //药师执业类别
|
2304
|
|
- PharmacistsLicensing: "1", //药师执业范围
|
2305
|
|
- PharmacistRegistrationNumber: "000200", //执业药师注册证编号
|
2306
|
|
- OfficeCode: "9933", //科室编码
|
2307
|
|
- JobNumber: "82021344", //工号
|
2308
|
|
- PostName: "主任", //职位名称
|
2309
|
|
- TechnicalJobLevelCode: "231", //专业技术职务级别编码
|
2310
|
|
- IsActive: "1", //在职与否
|
2311
|
|
- PrescriptionQualificationIdentification: "1", //处方资格标识
|
2312
|
|
- IdentificationOutpatients: "1", //门诊大病医师标识
|
2313
|
|
- OutpatientIllnessCategory: "血友病", //门诊大病类别
|
2314
|
|
- StartTime: 20210311, //开始日期
|
2315
|
|
- EndTime: 20210313,
|
2316
|
2233
|
}
|
2317
|
2234
|
customs = append(customs, detail)
|
2318
|
2235
|
}
|
|
@@ -2350,11 +2267,13 @@ func (c *SZHisApiController) GetUpdateMedicalList() {
|
2350
|
2267
|
|
2351
|
2268
|
func (c *SZHisApiController) GetGoodsList() {
|
2352
|
2269
|
|
|
2270
|
+ adminUserInfo := c.GetAdminUserInfo()
|
|
2271
|
+ orgId := adminUserInfo.CurrentOrgId
|
2353
|
2272
|
//获取所有耗材信息
|
2354
|
|
- list, _ := service.GetGoodInformationList(10028)
|
|
2273
|
+ list, _ := service.GetGoodInformationList(orgId)
|
2355
|
2274
|
fmt.Println("list22222", list)
|
2356
|
2275
|
//获取单位
|
2357
|
|
- miConfig, _ := service.FindMedicalInsuranceInfo(10028)
|
|
2276
|
+ miConfig, _ := service.FindMedicalInsuranceInfo(orgId)
|
2358
|
2277
|
var doctor_name string
|
2359
|
2278
|
var doctor_code string
|
2360
|
2279
|
|