Bläddra i källkod

加入预留接口 公司信息和准入范围

Liuqi 6 år sedan
förälder
incheckning
96b2eb24b5

+ 17 - 0
src/dashoo.cn/backend/api/business/oilsupplier/selectbusiness/selectservice.go

@@ -184,3 +184,20 @@ LEFT JOIN (SELECT  b.Month,a.CatalogSpe from (select extract(month from CreateOn
 
 	return total
 }
+
+//获取公司信息和准入范围
+
+func (s *SelectService) GetInfoByCompId(where string,entitiesPtr interface{}) (total int64) {
+	var sql string
+	sql = `SELECT a.*,b.Name,b.Code from OilSupplier a LEFT JOIN OilSupplierCertSub b ON a.Id = b.SupplierId `+ where
+
+	var totalResult TotalResult
+	session := s.DBE.NewSession()
+	session.Begin()
+	session.SQL(sql).Find(entitiesPtr)
+	//session.SQL(sqlCount).Get(&totalResult)
+	session.Commit()
+	total = totalResult.Total
+
+	return total
+}

+ 78 - 0
src/dashoo.cn/backend/api/business/oilsupplier/supplier/oilsupplier.go

@@ -264,4 +264,82 @@ type InterfaceData struct {
 	SupplierName  string
 	RegCapital    time.Time
 	ExpireAllFile string
+}
+
+type OilSupplierAndApply struct {
+	Id                  int       `xorm:"not null pk autoincr INT(10)"`
+	SupplierName        string    `xorm:"comment('企业名称') VARCHAR(255)"`
+	OilCertificateNo    string    `xorm:"comment('中石油供应商证书号') VARCHAR(50)"`
+	Grade               string    `xorm:"comment('级别') VARCHAR(2)"`
+	MgrUnit             string    `xorm:"comment('管理单位') VARCHAR(50)"`
+	OperType            string    `xorm:"comment('经营方式') VARCHAR(50)"`
+	Country             string    `xorm:"comment('国家') VARCHAR(20)"`
+	MaunAgent           string    `xorm:"comment('所代理制造商名称') VARCHAR(100)"`
+	ConstructTeam       string    `xorm:"comment('施工队伍名称') VARCHAR(100)"`
+	CredentialFlag      string    `xorm:"default '1' comment('证件合一标志') VARCHAR(5)"`
+	CommercialNo        string    `xorm:"comment('工商注册号') VARCHAR(50)"`
+	OrganCode           string    `xorm:"comment('组织机构代码') VARCHAR(50)"`
+	CountryTaxNo        string    `xorm:"comment('税务登记证国税编号') VARCHAR(50)"`
+	LocalTaxNo          string    `xorm:"comment('税务登记证地税编号') VARCHAR(50)"`
+	Address             string    `xorm:"comment('单位地址') VARCHAR(500)"`
+	AllAddress          string    `xorm:"comment('注册地址') VARCHAR(500)"`
+	LinkAllAddress      string    `xorm:"comment('通信地址') VARCHAR(500)"`
+	Province            string    `xorm:"comment('省直辖市') VARCHAR(20)"`
+	City                string    `xorm:"comment('地市区县') VARCHAR(20)"`
+	Street              string    `xorm:"comment('街道') VARCHAR(20)"`
+	HouseNo             string    `xorm:"comment('门牌号') VARCHAR(10)"`
+	ZipCode             string    `xorm:"comment('邮编') VARCHAR(20)"`
+	LinkAddress         string    `xorm:"comment('通信地址-单位地址') VARCHAR(500)"`
+	LinkProvince        string    `xorm:"comment('通信地址-省直辖市') VARCHAR(20)"`
+	LinkCity            string    `xorm:"comment('通信地址-地市区县') VARCHAR(20)"`
+	LinkStreet          string    `xorm:"comment('通信地址-街道') VARCHAR(20)"`
+	LinkHouseNo         string    `xorm:"comment('通信地址-门牌号') VARCHAR(10)"`
+	LinkZipCode         string    `xorm:"comment('通信地址-邮编') VARCHAR(20)"`
+	HseTraining         string    `xorm:"comment('是否需要进行HSE审查培训') VARCHAR(2)"`
+	QualitySystemCert   string    `xorm:"comment('质量管理体系认证情况及认证机构') VARCHAR(200)"`
+	ProductQualityCert  string    `xorm:"comment('产品质量认证情况及认证机构') VARCHAR(200)"`
+	MaunLicense         string    `xorm:"comment('生产制造许可证获证情况及编号') VARCHAR(200)"`
+	QualifCert          string    `xorm:"comment('企业资质证书编号') VARCHAR(200)"`
+	QualifCertLevel     string    `xorm:"comment('企业资质证书级别') VARCHAR(10)"`
+	SafetyLicense       string    `xorm:"comment('安全生产许可证') VARCHAR(200)"`
+	TechServiceLic      string    `xorm:"comment('技术服务类准入许可证') VARCHAR(200)"`
+	TjinNotify          string    `xorm:"comment('外地企业进津备案通知书') VARCHAR(50)"`
+	SpecIndustryCert    string    `xorm:"comment('行业特殊要求的认证证书') VARCHAR(200)"`
+	BusinessScope       string    `xorm:"comment('营业范围') TEXT"`
+	LegalPerson         string    `xorm:"comment('法定代表人姓名') VARCHAR(20)"`
+	CategoryCode        string    `xorm:"comment('行业类别代码') VARCHAR(10)"`
+	CategoryName        string    `xorm:"comment('行业类别名称') VARCHAR(20)"`
+	RegCapital          float64   `xorm:"default 0 comment('注册资本') FLOAT"`
+	Currency            string    `xorm:"comment('币种') VARCHAR(10)"`
+	ContactName         string    `xorm:"comment('联系人姓名') VARCHAR(20)"`
+	CompanyType         string    `xorm:"comment('公司类型') VARCHAR(20)"`
+	SetupTime           time.Time `xorm:"comment('成立时间') Date"`
+	DepositBank         string    `xorm:"comment('开户银行') VARCHAR(50)"`
+	BankAccount         string    `xorm:"comment('银行账号') VARCHAR(50)"`
+	EMail               string    `xorm:"comment('电子邮箱') VARCHAR(50)"`
+	BankCreditRating    string    `xorm:"comment('银行信用等级') VARCHAR(10)"`
+	Mobile              string    `xorm:"comment('移动电话') VARCHAR(20)"`
+	Telphone            string    `xorm:"comment('固定电话') VARCHAR(20)"`
+	Fax                 string    `xorm:"comment('传真') VARCHAR(20)"`
+	CompanyTel          string    `xorm:"comment('公司电话') VARCHAR(20)"`
+	QQ                  string    `xorm:"comment('QQ号码') VARCHAR(20)"`
+	CompanyUrl          string    `xorm:"comment('公司网址') VARCHAR(20)"`
+	SpecSupplier        string    `xorm:"default '0' comment('是否特殊业务供应商(可不招标)') VARCHAR(2)"`
+	SpecTypeCode        string    `xorm:"comment('业务类型(1战略合作,2内部多经,3区域关键,4专业化实施)') VARCHAR(2)"`
+	SpecTypeName        string    `xorm:"comment('业务类型(1战略合作,2内部多经,3区域关键,4专业化实施)') VARCHAR(20)"`
+	WZAccessCardNo      string    `xorm:"comment('准入证编码--物质') VARCHAR(20)"`
+	JSAccessCardNo      string    `xorm:"comment('准入证编码--基建') VARCHAR(20)"`
+	JFAccessCardNo      string    `xorm:"comment('准入证编码--技术服务类') VARCHAR(20)"`
+	Remark              string    `xorm:"comment('备注') VARCHAR(500)"`
+	IsDelete            int       `xorm:"default 0 comment('删除状态,0正常,1已删除') INT(10)"`
+	CreateOn            time.Time `xorm:"DATETIME"`
+	CreateUserId        int       `xorm:"INT(10)"`
+	CreateBy            string    `xorm:"VARCHAR(50)"`
+	ModifiedOn          time.Time `xorm:"DATETIME"`
+	ModifiedUserId      int       `xorm:"INT(10)"`
+	ModifiedBy          string    `xorm:"VARCHAR(50)"`
+	PACNumber           string    `xorm:"comment('中石油准入证编号') VARCHAR(50)"`
+	SupplierCertificate string    `xorm:"comment('中石油物资供应商证书') VARCHAR(200)"`
+	Name                string    `xorm:"comment('准入范围') VARCHAR(500)"`
+	Code                string    `xorm:"comment('准入范围编号') VARCHAR(15)"`
 }

+ 28 - 0
src/dashoo.cn/backend/api/controllers/oilsupplier/select.go

@@ -239,6 +239,34 @@ func (this *SelectController) GetTList() {
 
 }
 
+// @Title 获取所有
+// @Description
+// @Success 200 {object}
+// @router /getbaseinfo [post]
+func (this *SelectController) GetBaseInfo() {
+	where := " where 1 = 1 AND a.SupplierName in ( "
+	Spesearch := this.GetString("Spesearch")
+	if Spesearch != "" {
+		spe := strings.Split(Spesearch, ",")
+		for _, c := range spe {
+			where = where +"'" + c + "'" +","
+		}
+		where = strings.Trim(where, ",")
+		where = where + " )"
+	}
+
+	svc := selectbusiness.GetSelectService(utils.DBE)
+	var list []supplier.OilSupplierAndApply
+
+	svc.GetInfoByCompId(where,&list)
+	var datainfo DataInfo
+	datainfo.Items = list
+
+	this.Data["json"] = &datainfo
+	this.ServeJSON()
+
+}
+
 // @Title 获取所有
 // @Description
 // @Success 200 {object}

+ 7 - 0
src/dashoo.cn/frontend_web/src/api/oilsupplier/select.js

@@ -7,6 +7,13 @@ export default {
       data: formdata
     })
   },
+  getbaseinfo (params, myAxios) {
+    return myAxios({
+      url: '/select/getbaseinfo',
+      method: 'post',
+      params: params
+    })
+  },
   getList (params, myAxios) {
     return myAxios({
       url: '/select/totallist',

+ 23 - 0
src/dashoo.cn/frontend_web/src/pages/select/companyselect/index.vue

@@ -58,6 +58,13 @@
           <el-form-item>
             <el-button type="primary" size="mini" @click="exportExcel">导出</el-button>
           </el-form-item>
+          <!-- 预留接口 公司基本信息和准入范围 -->
+          <!-- <el-form-item label="特殊查询">
+            <el-input size="mini" v-model="Spesearch" placeholder="输入特殊查询"></el-input>
+          </el-form-item>
+          <el-form-item>
+            <el-button type="primary" size="mini" @click="ssearch">特殊查询</el-button>
+          </el-form-item> -->
         </el-form>
       </div>
 
@@ -778,6 +785,7 @@ export default {
       dialogVisibleCertsSub: false,
       dialogVisibleSubFile: false,
       loading: false,
+      Spesearch: '',
       HSEOptions: [
         {
           value: '',
@@ -857,6 +865,7 @@ export default {
       currentItemCount: 0,
       SetupTime: '', // 成立时间
       CreateOn: [],
+      ssList:[],
       searchForm: {
         AccessCardNo: '',
         SupplierName: '',
@@ -1134,6 +1143,20 @@ export default {
           console.error(err)
         })
     },
+    ssearch(){
+      let params = {
+        Spesearch: this.Spesearch
+      }
+      api
+        .getbaseinfo(params, this.$axios)
+        .then(res => {
+          this.ssList = res.data.items
+          console.log(res,"预留接口 公司基本信息和准入")
+        })
+        .catch(err => {
+          console.error(err)
+        })
+    },
     // 分页方法
     handleCurrentChangeSub (value) {
       this.currentPageSub = value