|
@@ -66,79 +66,6 @@
|
|
<a-button @click="handleResetClick(true)">重置</a-button>
|
|
<a-button @click="handleResetClick(true)">重置</a-button>
|
|
<a-button type="primary" @click="handleSearchClick">查询</a-button>
|
|
<a-button type="primary" @click="handleSearchClick">查询</a-button>
|
|
</div>
|
|
</div>
|
|
- <!-- <div style="width:80%;;display:flex;flex-wrap:wrap;">
|
|
|
|
- <div style="display:flex;flex-wrap:wrap;">
|
|
|
|
- <a-form-item
|
|
|
|
- style="width:320px;margin: 5px 40px 5px 0;"
|
|
|
|
- label="知识标题"
|
|
|
|
- name="titles">
|
|
|
|
- <a-input v-model="queryParam.titles" placeholder="请输入"/>
|
|
|
|
- </a-form-item>
|
|
|
|
- <a-form-item
|
|
|
|
- style="width:320px;margin: 5px 40px 5px 0;"
|
|
|
|
- label="知识类型"
|
|
|
|
- name="type">
|
|
|
|
- <a-select v-model="queryParam.type" placeholder="请选择" allowClear>
|
|
|
|
- <a-select-option v-for="(item,index) in knowledgeList" :key="index" :value="item.value">
|
|
|
|
- {{item.label}}
|
|
|
|
- </a-select-option>
|
|
|
|
- </a-select>
|
|
|
|
- </a-form-item>
|
|
|
|
- </div>
|
|
|
|
- <div style="display:flex;flex-wrap:wrap;" v-if="extend" :class="{'show-other': extend}">
|
|
|
|
- <a-form-item
|
|
|
|
- style="width:320px;margin: 5px 40px 5px 0;"
|
|
|
|
- label="作者"
|
|
|
|
- name="author" >
|
|
|
|
- <a-input v-model="queryParam.author" placeholder="请输入" />
|
|
|
|
- </a-form-item>
|
|
|
|
- <a-form-item
|
|
|
|
- style="width:320px;margin: 5px 40px 5px 0;"
|
|
|
|
- label="所属分类"
|
|
|
|
- name="categoryIds">
|
|
|
|
- <a-cascader v-model="categoryIds"
|
|
|
|
- :options="classifyList"
|
|
|
|
- :fieldNames="{ label: 'name', value: 'pkId', children: 'children' }"
|
|
|
|
- placeholder="请选择"
|
|
|
|
- changeOnSelect
|
|
|
|
- @change="handleClassifyChange" />
|
|
|
|
- </a-form-item>
|
|
|
|
- <a-form-item
|
|
|
|
- style="width:320px;margin: 5px 40px 5px 0;"
|
|
|
|
- label="创建时间"
|
|
|
|
- name="createTime" >
|
|
|
|
- <a-range-picker v-model="createTime"
|
|
|
|
- separator="→"
|
|
|
|
- format="YYYY/MM/DD"
|
|
|
|
- valueFormat="YYYY-MM-DD"
|
|
|
|
- @change="handleClearTimeChange">
|
|
|
|
- <a-icon v-if="$store.state.appSetting.collapsed" slot="suffixIcon" type="calendar" />
|
|
|
|
- </a-range-picker>
|
|
|
|
- </a-form-item>
|
|
|
|
- </div>
|
|
|
|
- </div>
|
|
|
|
- <div style="width:20%;display:flex;justify-content:flex-end;align-content: flex-start;flex-wrap:wrap;">
|
|
|
|
- <div style="display:flex;justify-content:center;margin-top: 8px;">
|
|
|
|
- <a-button @click="handleResetClick">重置</a-button>
|
|
|
|
- <a-button type="primary" @click="handleSearchClick">查询</a-button>
|
|
|
|
- </div>
|
|
|
|
- <div style="margin-top: 8px;">
|
|
|
|
- <a-button type="link" @click="extend = !extend">
|
|
|
|
- <template v-if="!extend">
|
|
|
|
- <div>
|
|
|
|
- 展开
|
|
|
|
- <a-icon type="down" />
|
|
|
|
- </div>
|
|
|
|
- </template>
|
|
|
|
- <template v-else>
|
|
|
|
- <div>
|
|
|
|
- 收起
|
|
|
|
- <a-icon type="up" />
|
|
|
|
- </div>
|
|
|
|
- </template>
|
|
|
|
- </a-button>
|
|
|
|
- </div>
|
|
|
|
- </div> -->
|
|
|
|
</a-form>
|
|
</a-form>
|
|
<rx-button alias="knowAdd" :butn-icon="'false'" @click="handleAddKnowledgeClick">新增知识</rx-button>
|
|
<rx-button alias="knowAdd" :butn-icon="'false'" @click="handleAddKnowledgeClick">新增知识</rx-button>
|
|
<rx-button
|
|
<rx-button
|
|
@@ -150,6 +77,7 @@
|
|
>知识审核</rx-button
|
|
>知识审核</rx-button
|
|
>
|
|
>
|
|
<rx-button alias="reauthor" :butn-icon="'false'" @click="handleReauthorShowClick">批量改派作者</rx-button>
|
|
<rx-button alias="reauthor" :butn-icon="'false'" @click="handleReauthorShowClick">批量改派作者</rx-button>
|
|
|
|
+ <rx-button alias="changeClassify" :butn-icon="'false'" @click="handleUpdateClassifyShowClick">批量修改分类</rx-button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -160,6 +88,8 @@
|
|
class="table-style"
|
|
class="table-style"
|
|
style="background: #fff"
|
|
style="background: #fff"
|
|
:columns="columns"
|
|
:columns="columns"
|
|
|
|
+ :allowRowSelect="true"
|
|
|
|
+ :multiSelect="true"
|
|
:url="api.findAllKnowledge"
|
|
:url="api.findAllKnowledge"
|
|
:queryParam="queryParam"
|
|
:queryParam="queryParam"
|
|
data-field="result.data"
|
|
data-field="result.data"
|
|
@@ -199,6 +129,37 @@
|
|
</template>
|
|
</template>
|
|
</rx-grid>
|
|
</rx-grid>
|
|
</rx-fit>
|
|
</rx-fit>
|
|
|
|
+ <a-modal
|
|
|
|
+ v-model="updateClassifyShow"
|
|
|
|
+ title="批量修改分类"
|
|
|
|
+ centered
|
|
|
|
+ okText="执行"
|
|
|
|
+ @ok="handleUpdateOk"
|
|
|
|
+ :confirmLoading="saveLoading"
|
|
|
|
+ >
|
|
|
|
+ <a-form ref="labelRef" layout="inline">
|
|
|
|
+ <a-form-item label="分类名称" >
|
|
|
|
+ <a-cascader
|
|
|
|
+ v-model="categoryifyIds"
|
|
|
|
+ class="scroll-ckunk"
|
|
|
|
+ :popupStyle="{
|
|
|
|
+ maxWidth: widthVar + 'px',
|
|
|
|
+ 'overflow-x': 'auto',
|
|
|
|
+ }"
|
|
|
|
+ :getPopupContainer="
|
|
|
|
+ (triggerNode) => {
|
|
|
|
+ return triggerNode.parentNode
|
|
|
|
+ }
|
|
|
|
+ "
|
|
|
|
+ :options="classifyList"
|
|
|
|
+ :fieldNames="{ label: 'name', value: 'pkId', children: 'children' }"
|
|
|
|
+ placeholder="请选择"
|
|
|
|
+ changeOnSelect
|
|
|
|
+ @change="handleClassifyReset"
|
|
|
|
+ />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-form>
|
|
|
|
+ </a-modal>
|
|
<a-modal
|
|
<a-modal
|
|
v-model="reauthorShow"
|
|
v-model="reauthorShow"
|
|
title="批量改派作者"
|
|
title="批量改派作者"
|
|
@@ -353,6 +314,9 @@ export default {
|
|
],
|
|
],
|
|
num: 0,
|
|
num: 0,
|
|
classifyList: [],
|
|
classifyList: [],
|
|
|
|
+ updateClassifyShow: false,
|
|
|
|
+ knowledgeIds: [],
|
|
|
|
+ categoryifyIds: [],
|
|
reauthorShow: false,
|
|
reauthorShow: false,
|
|
reauthorFlag: 1,
|
|
reauthorFlag: 1,
|
|
saveLoading: false,
|
|
saveLoading: false,
|
|
@@ -439,8 +403,8 @@ export default {
|
|
this.showAuditFlag = true
|
|
this.showAuditFlag = true
|
|
},
|
|
},
|
|
transCheckedTarget(arg) {
|
|
transCheckedTarget(arg) {
|
|
- this.approverData.approverId = arg.approverId
|
|
|
|
- this.approverData.approverName = arg.approverName
|
|
|
|
|
|
+ this.approverData.approverId = arg.approverId
|
|
|
|
+ this.approverData.approverName = arg.approverName
|
|
},
|
|
},
|
|
handleOk() {
|
|
handleOk() {
|
|
if(!this.authorForm.authorsName) {
|
|
if(!this.authorForm.authorsName) {
|
|
@@ -473,6 +437,36 @@ export default {
|
|
this.showAuditFlag = false
|
|
this.showAuditFlag = false
|
|
this.approverData = Object.assign({},this.$options.data().approverData)
|
|
this.approverData = Object.assign({},this.$options.data().approverData)
|
|
},
|
|
},
|
|
|
|
+ handleUpdateClassifyShowClick() {
|
|
|
|
+ this.knowledgeIds = this.$refs.manageRef.getSelectedRows().map(item => {return item.pkId})
|
|
|
|
+ if(!this.knowledgeIds.length) {
|
|
|
|
+ this.$message.error("请选择要修改分类的知识");
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ this.handleClassifyReset('')
|
|
|
|
+ this.updateClassifyShow = true
|
|
|
|
+ },
|
|
|
|
+ handleClassifyReset(arg) {
|
|
|
|
+ if(!arg.length) {
|
|
|
|
+ this.categoryifyIds = []
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ handleUpdateOk() {
|
|
|
|
+ if(!this.categoryifyIds.length) {
|
|
|
|
+ this.$message.error("请选择分类名称");
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ let info = {
|
|
|
|
+ categoryId: this.categoryifyIds.slice('-1')[0],
|
|
|
|
+ knowledgeIds: this.knowledgeIds
|
|
|
|
+ }
|
|
|
|
+ api.transferCategory(info).then(res => {
|
|
|
|
+ if(res.code == 200) {
|
|
|
|
+ this.updateClassifyShow = false
|
|
|
|
+ this.reloadTable()
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ },
|
|
// 跳转审核管理
|
|
// 跳转审核管理
|
|
handleJumpPathClick() {
|
|
handleJumpPathClick() {
|
|
this.$router.push({
|
|
this.$router.push({
|
|
@@ -513,7 +507,7 @@ export default {
|
|
},
|
|
},
|
|
// 重新加载表格
|
|
// 重新加载表格
|
|
reloadTable() {
|
|
reloadTable() {
|
|
- this.$refs.manageRef.loadData()
|
|
|
|
|
|
+ this.$refs.manageRef.onRefresh()
|
|
},
|
|
},
|
|
},
|
|
},
|
|
}
|
|
}
|