|
@@ -30,14 +30,31 @@
|
|
|
<span style="font-weight: bold">分类文档</span>
|
|
<span style="font-weight: bold">分类文档</span>
|
|
|
<el-button style="float: right; padding: 3px 0" type="text" @click="subfiledialog">添加</el-button>
|
|
<el-button style="float: right; padding: 3px 0" type="text" @click="subfiledialog">添加</el-button>
|
|
|
</div>
|
|
</div>
|
|
|
- <subfile-list ref="subfileList" :data="subfileList" :SupplierCertSubId="cersubId" :businessList="businessList"
|
|
|
|
|
- height="360px" style="margin-top: 20px"></subfile-list>
|
|
|
|
|
|
|
+ <subfile-list ref="subfileList" :data="subfileList" :SupplierCertId="SupplierCertId" :SupplierCertSubId="cersubId"
|
|
|
|
|
+ :businessList="businessList" height="360px" style="margin-top: 20px"></subfile-list>
|
|
|
</el-card>
|
|
</el-card>
|
|
|
|
|
|
|
|
<el-dialog :title="Title" :visible.sync="visible" top="5vh">
|
|
<el-dialog :title="Title" :visible.sync="visible" top="5vh">
|
|
|
<el-form :model="BusinessForm" label-width="100px">
|
|
<el-form :model="BusinessForm" label-width="100px">
|
|
|
<el-row>
|
|
<el-row>
|
|
|
- <el-col :span="12">
|
|
|
|
|
|
|
+ <el-col :span="12" v-if="SubClassId == '1'">
|
|
|
|
|
+ <el-form-item label="名称" required>
|
|
|
|
|
+ <el-select filterable default-first-option v-model="OneCode" placeholder="请选择" style="width: 100%"
|
|
|
|
|
+ @change="getChild()">
|
|
|
|
|
+ <el-option v-for="item in oneList" :key="item.Id" :label="item.Name" :value="item.Id">
|
|
|
|
|
+ </el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ </el-col>
|
|
|
|
|
+ <el-col :span="12" v-if="SubClassId == '3'">
|
|
|
|
|
+ <el-form-item label="名称" required>
|
|
|
|
|
+ <el-input placeholder="请选择名称" v-model="BusinessForm.Code" style="width:100%">
|
|
|
|
|
+ <el-button type="primary" style="width:30%" @click="basicDialog = true" slot="append">选择
|
|
|
|
|
+ </el-button>
|
|
|
|
|
+ </el-input>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ </el-col>
|
|
|
|
|
+ <el-col :span="12" v-if="SubClassId != '3'">
|
|
|
<el-form-item label="名称" required>
|
|
<el-form-item label="名称" required>
|
|
|
<el-cascader :options="techTreeList" :props="orgtreeprops" change-on-select :show-all-levels="false"
|
|
<el-cascader :options="techTreeList" :props="orgtreeprops" change-on-select :show-all-levels="false"
|
|
|
v-model="selectedorg" placeholder="请选择菜单" @change="getCode()" style="width:100%"></el-cascader>
|
|
v-model="selectedorg" placeholder="请选择菜单" @change="getCode()" style="width:100%"></el-cascader>
|
|
@@ -60,6 +77,39 @@
|
|
|
<el-button type="primary" @click="savedata()">确 定</el-button>
|
|
<el-button type="primary" @click="savedata()">确 定</el-button>
|
|
|
</div>
|
|
</div>
|
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
|
+
|
|
|
|
|
+ <el-dialog title="基建类业务列表" :visible.sync="basicDialog" top="5vh" style="width:1000px">
|
|
|
|
|
+ <span style="float: right;">
|
|
|
|
|
+ <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" @click="seachdata()">查询
|
|
|
|
|
+ </el-button>
|
|
|
|
|
+ <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" @click="basicDialog = false">
|
|
|
|
|
+ 取消</el-button>
|
|
|
|
|
+ </span>
|
|
|
|
|
+ <el-form ref="form" :inline="true" style="float: right; margin-top: -10px">
|
|
|
|
|
+ <el-form-item label="业务名称">
|
|
|
|
|
+ <el-input size="mini" style="width: 165px;" v-model="keyword" placeholder="请输入业务名称"></el-input>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ </el-form>
|
|
|
|
|
+ <el-table :data="businessList" @selection-change="handleSelectionChange">
|
|
|
|
|
+ <el-table-column type="selection" width="55"></el-table-column>
|
|
|
|
|
+ <el-table-column label="操作" width="70" align="center" fixed>
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-button type="text" title="编辑" size="small" icon="el-icon-edit" @click="openDialog(scope.row)">
|
|
|
|
|
+ </el-button>
|
|
|
|
|
+ <el-button size="small" type="text" style="margin-left:3px" icon="el-icon-delete" title="删除"
|
|
|
|
|
+ @click="deletedata(scope.row)"></el-button>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ <el-table-column prop="Code" label="分类编码" show-overflow-tooltip></el-table-column>
|
|
|
|
|
+ <el-table-column prop="Name" label="分类名称" show-overflow-tooltip></el-table-column>
|
|
|
|
|
+ <el-table-column prop="Remark" label="备注" show-overflow-tooltip></el-table-column>
|
|
|
|
|
+ </el-table>
|
|
|
|
|
+ <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
|
|
|
|
|
+ :page-sizes="[10, 15, 20, 25]" :page-size="size" layout="total, sizes, prev, pager, next, jumper"
|
|
|
|
|
+ :total="currentItemCount">
|
|
|
|
|
+ </el-pagination>
|
|
|
|
|
+
|
|
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
@@ -90,7 +140,6 @@
|
|
|
},
|
|
},
|
|
|
created() {
|
|
created() {
|
|
|
this.initData()
|
|
this.initData()
|
|
|
- this.getbusiness()
|
|
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
|
...mapGetters({
|
|
...mapGetters({
|
|
@@ -99,6 +148,8 @@
|
|
|
},
|
|
},
|
|
|
data() {
|
|
data() {
|
|
|
return {
|
|
return {
|
|
|
|
|
+ oneList: [],
|
|
|
|
|
+ OneCode: '',
|
|
|
businessList: [],
|
|
businessList: [],
|
|
|
techList: [],
|
|
techList: [],
|
|
|
techTreeList: [],
|
|
techTreeList: [],
|
|
@@ -125,6 +176,7 @@
|
|
|
currentPage: 1, // 分页
|
|
currentPage: 1, // 分页
|
|
|
size: 10,
|
|
size: 10,
|
|
|
currentItemCount: 0,
|
|
currentItemCount: 0,
|
|
|
|
|
+ basicDialog: false,
|
|
|
|
|
|
|
|
cersubId: '', //对应的证书分类ID
|
|
cersubId: '', //对应的证书分类ID
|
|
|
subfileList: [], //文档
|
|
subfileList: [], //文档
|
|
@@ -148,7 +200,7 @@
|
|
|
_this.businessList = res.data.items
|
|
_this.businessList = res.data.items
|
|
|
_this.currentItemCount = res.data.currentItemCount
|
|
_this.currentItemCount = res.data.currentItemCount
|
|
|
if (_this.businessList && _this.businessList.length > 0) {
|
|
if (_this.businessList && _this.businessList.length > 0) {
|
|
|
- for(var i = 0; i < _this.businessList.length; i ++){
|
|
|
|
|
|
|
+ for (var i = 0; i < _this.businessList.length; i++) {
|
|
|
_this.selectId.push(_this.businessList[i].Id)
|
|
_this.selectId.push(_this.businessList[i].Id)
|
|
|
}
|
|
}
|
|
|
_this.cersubId = _this.selectId.join(",")
|
|
_this.cersubId = _this.selectId.join(",")
|
|
@@ -160,26 +212,6 @@
|
|
|
console.error(err)
|
|
console.error(err)
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
- getbusiness() {
|
|
|
|
|
- let _this = this
|
|
|
|
|
- this.$axios.get('technologyservice/businesslist', {})
|
|
|
|
|
- .then(res => {
|
|
|
|
|
- _this.techList = res.data.items
|
|
|
|
|
- _this.techTreeList = window.toolfun_gettreejson(res.data.items, 'Id', 'ParentId', 'Id,Name')
|
|
|
|
|
- })
|
|
|
|
|
- .catch(err => {
|
|
|
|
|
- // handle error
|
|
|
|
|
- console.error(err)
|
|
|
|
|
- })
|
|
|
|
|
- },
|
|
|
|
|
- getCode() {
|
|
|
|
|
- for (var i = 0; i < this.techList.length; i++) {
|
|
|
|
|
- if (this.selectedorg[this.selectedorg.length - 1] == this.techList[i].Id) {
|
|
|
|
|
- this.BusinessForm.Name = this.techList[i].Name
|
|
|
|
|
- this.BusinessForm.Code = this.techList[i].Code
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- },
|
|
|
|
|
savedata() {
|
|
savedata() {
|
|
|
if (this.Title == '新增准入范围') {
|
|
if (this.Title == '新增准入范围') {
|
|
|
this.addBusiness()
|
|
this.addBusiness()
|
|
@@ -269,6 +301,7 @@
|
|
|
},
|
|
},
|
|
|
showDialog() {
|
|
showDialog() {
|
|
|
this.Title = '新增准入范围'
|
|
this.Title = '新增准入范围'
|
|
|
|
|
+ this.BusinessForm.Id = ''
|
|
|
this.BusinessForm.SupplierId = this.SupplierId
|
|
this.BusinessForm.SupplierId = this.SupplierId
|
|
|
this.BusinessForm.SupplierCertId = this.SupplierCertId
|
|
this.BusinessForm.SupplierCertId = this.SupplierCertId
|
|
|
this.BusinessForm.SubClassId = this.SubClassId
|
|
this.BusinessForm.SubClassId = this.SubClassId
|
|
@@ -276,6 +309,7 @@
|
|
|
this.BusinessForm.Name = ''
|
|
this.BusinessForm.Name = ''
|
|
|
this.BusinessForm.Remark = ''
|
|
this.BusinessForm.Remark = ''
|
|
|
this.BusinessForm.IsDelete = 0
|
|
this.BusinessForm.IsDelete = 0
|
|
|
|
|
+ this.getbusiness()
|
|
|
this.visible = true
|
|
this.visible = true
|
|
|
},
|
|
},
|
|
|
openDialog(val) {
|
|
openDialog(val) {
|
|
@@ -288,8 +322,74 @@
|
|
|
this.BusinessForm.Name = val.Name
|
|
this.BusinessForm.Name = val.Name
|
|
|
this.BusinessForm.Remark = val.Remark
|
|
this.BusinessForm.Remark = val.Remark
|
|
|
this.BusinessForm.IsDelete = val.IsDelete
|
|
this.BusinessForm.IsDelete = val.IsDelete
|
|
|
|
|
+ this.getbusiness()
|
|
|
this.visible = true
|
|
this.visible = true
|
|
|
},
|
|
},
|
|
|
|
|
+ getbusiness() {
|
|
|
|
|
+ let _this = this
|
|
|
|
|
+ if (_this.SubClassId == '1') { //获取物资类业务列表
|
|
|
|
|
+ this.$axios.get('goodsaptitude/goodsparentlist', {})
|
|
|
|
|
+ .then(res => {
|
|
|
|
|
+ _this.oneList = res.data.items
|
|
|
|
|
+ if (_this.Title == '编辑准入范围') {
|
|
|
|
|
+ for (var i = 0; i < _this.oneList.length; i++) {
|
|
|
|
|
+ if (_this.BusinessForm.Code == _this.oneList[i].Code) {
|
|
|
|
|
+ _this.OneCode = _this.oneList[i].Id
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ .catch(err => {
|
|
|
|
|
+ console.error(err)
|
|
|
|
|
+ })
|
|
|
|
|
+ } else if (_this.SubClassId == '2') { //获取技术服务类业务列表
|
|
|
|
|
+ this.$axios.get('technologyservice/businesslist', {})
|
|
|
|
|
+ .then(res => {
|
|
|
|
|
+ _this.techList = res.data.items
|
|
|
|
|
+ _this.techTreeList = window.toolfun_gettreejson(res.data.items, 'Id', 'ParentId', 'Id,Name')
|
|
|
|
|
+ })
|
|
|
|
|
+ .catch(err => {
|
|
|
|
|
+ // handle error
|
|
|
|
|
+ console.error(err)
|
|
|
|
|
+ })
|
|
|
|
|
+ } else {}
|
|
|
|
|
+ },
|
|
|
|
|
+ getCode() {
|
|
|
|
|
+ for (var i = 0; i < this.techList.length; i++) {
|
|
|
|
|
+ if (this.selectedorg[this.selectedorg.length - 1] == this.techList[i].Id) {
|
|
|
|
|
+ this.BusinessForm.Name = this.techList[i].Name
|
|
|
|
|
+ this.BusinessForm.Code = this.techList[i].Code
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+ getChild() {
|
|
|
|
|
+ const params = {
|
|
|
|
|
+ ParentId: this.OneCode
|
|
|
|
|
+ }
|
|
|
|
|
+ this.$axios.get('goodsaptitude/goodschildlist', {
|
|
|
|
|
+ params
|
|
|
|
|
+ })
|
|
|
|
|
+ .then(res => {
|
|
|
|
|
+ this.techList = res.data.items
|
|
|
|
|
+ if (this.techList && this.techList.length > 0) {
|
|
|
|
|
+ this.techTreeList = window.toolfun_gettreejson(res.data.items, 'Id', 'ParentId', 'Id,Name')
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.getParentCode()
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ .catch(err => {
|
|
|
|
|
+ // handle error
|
|
|
|
|
+ console.error(err)
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
|
|
+ getParentCode() {
|
|
|
|
|
+ for (var i = 0; i < this.oneList.length; i++) {
|
|
|
|
|
+ if (this.OneCode == this.oneList[i].Id) {
|
|
|
|
|
+ this.BusinessForm.Name = this.oneList[i].Name
|
|
|
|
|
+ this.BusinessForm.Code = this.oneList[i].Code
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
|
|
|
handleSelectionChange(val) {
|
|
handleSelectionChange(val) {
|
|
|
this.selectBusiness = val
|
|
this.selectBusiness = val
|
|
@@ -309,9 +409,6 @@
|
|
|
this.$refs["subfileList"].initData(this.cersubId)
|
|
this.$refs["subfileList"].initData(this.cersubId)
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- seachdata() {
|
|
|
|
|
- this.initData()
|
|
|
|
|
- },
|
|
|
|
|
handleSizeChange(value) {
|
|
handleSizeChange(value) {
|
|
|
this.size = value
|
|
this.size = value
|
|
|
this.currentPage = 1
|
|
this.currentPage = 1
|