소스 검색

增加目录管理查询功能

Liuqi 6 년 전
부모
커밋
f9da15c213

+ 8 - 1
src/dashoo.cn/backend/api/controllers/oilsupplier/oilcatalog.go

@@ -33,12 +33,19 @@ func (this *OilCatalogController) GetEntityList() {
 			asc = true
 		}
 	}
-
+	CompanyName := this.GetString("CompanyName")
+	Business := this.GetString("Business")
 	catalogType := this.GetString("CatalogType")
 	CreateOn := this.GetString("CreateOn")
 	if catalogType != "" {
 		where = where + " and CatalogType=" + catalogType
 	}
+	if CompanyName != "" {
+		where = where + " and CompanyName like '%" + CompanyName +"%' "
+	}
+	if Business != "" {
+		where = where + " and Business like '%" + Business + "%' "
+	}
 
 	if CreateOn != "" {
 		dates := strings.Split(CreateOn, ",")

+ 8 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/oilcatalog/index.vue

@@ -14,6 +14,12 @@
             <el-date-picker size="mini" style="width: 220px" v-model="CreateOn" type="daterange" range-separator="至"
                             start-placeholder="有效期" end-placeholder="有效期"></el-date-picker>
           </el-form-item>
+          <el-form-item label="企业名称">
+            <el-input size="mini" v-model="searchForm.CompanyName" style="width:100%" placeholder="请输入"></el-input>
+          </el-form-item>
+          <el-form-item label="业务范围">
+            <el-input size="mini" v-model="searchForm.Business" style="width:100%" placeholder="请输入"></el-input>
+          </el-form-item>
           <!--<el-form-item label="准入类型">-->
             <!--<el-select size="mini" style="width:100px" v-model="searchForm.SupplierTypeName" placeholder="准入类别">-->
               <!--<el-option label="全部" value=""></el-option>-->
@@ -157,6 +163,8 @@
         // 查询项
         searchFormReset: {},
         searchForm: {
+          CompanyName: '',
+          Business: ''
 
         },
         rules: {