|
|
@@ -616,6 +616,26 @@ func (this *InfoChangeController) GetChangeEntity() {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+// @Title 获取已准入的类别
|
|
|
+// @Description 获取已准入的类别
|
|
|
+// @Success 200 {object} []string
|
|
|
+// @router /getaccessedtype/:id [get]
|
|
|
+func (this *InfoChangeController) GetAccessedType() {
|
|
|
+ Id := this.Ctx.Input.Param(":id")
|
|
|
+
|
|
|
+ // 获取已准入的类别
|
|
|
+ supplierCertSrv := suppliercert.GetOilSupplierCertService(utils.DBE)
|
|
|
+ var supplierCertList []suppliercert.OilSupplierCert
|
|
|
+ supplierCertSrv.GetEntitysByWhere(OilSupplierCertName, "SupplierId="+Id+" and Status in (8, 11)", &supplierCertList)
|
|
|
+ var accessedType []string
|
|
|
+ for _, cert := range supplierCertList {
|
|
|
+ accessedType = append(accessedType, cert.SupplierTypeCode)
|
|
|
+ }
|
|
|
+
|
|
|
+ this.Data["json"] = &accessedType
|
|
|
+ this.ServeJSON()
|
|
|
+}
|
|
|
+
|
|
|
// @Title 获取列表
|
|
|
// @Description get user by token
|
|
|
// @Success 200 {object} []annualaudit.OilAnnualAudit
|