Commit f84cce1b authored by 张俊's avatar 张俊

Merge branch 'dev' of https://cloud.wodcloud.com/git/apaas/apaas-v3-ui into dev

parents 13714474 dbd2b024
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
:file-list="fileList" :file-list="fileList"
:before-upload="beforeUpload" :before-upload="beforeUpload"
:on-success="uploadSuccess" :on-success="uploadSuccess"
:on-remove="uploadRemove"
> >
<i class="el-icon-upload"></i> <i class="el-icon-upload"></i>
<div class="el-upload__text"> <div class="el-upload__text">
...@@ -83,8 +84,14 @@ export default { ...@@ -83,8 +84,14 @@ export default {
}, },
uploadSuccess({ data }) { uploadSuccess({ data }) {
this.$emit("change", data); this.$emit("change", data);
this.removePreFile();
// 替换文件后要把旧文件删除掉 },
uploadRemove() {
this.preUrl = this.url;
this.$emit("change", "");
this.removePreFile();
},
removePreFile() {
if (this.preUrl) { if (this.preUrl) {
this.$http this.$http
.delete("/apaas/static/file/delete", { .delete("/apaas/static/file/delete", {
......
...@@ -42,13 +42,13 @@ ...@@ -42,13 +42,13 @@
</li> </li>
</ul> </ul>
</div> </div>
<div class="contributor_info" v-if="contributorQuizList"> <div class="contributor_info" v-if="contributorQuestionList">
<h3 class="contributor_title"> <h3 class="contributor_title">
<span>本月提问贡献榜</span> <span>本月提问贡献榜</span>
</h3> </h3>
<ul class="contributor_list"> <ul class="contributor_list">
<li <li
v-for="(item, index) in contributorQuizList" v-for="(item, index) in contributorQuestionList"
:key="'quiz_' + index" :key="'quiz_' + index"
> >
<span class="list_index" v-text="index + 1"></span> <span class="list_index" v-text="index + 1"></span>
...@@ -69,7 +69,7 @@ export default { ...@@ -69,7 +69,7 @@ export default {
return { return {
userInfo: null, userInfo: null,
contributorAnswerList: null, contributorAnswerList: null,
contributorQuizList: null, contributorQuestionList: null,
head_pic: require("../../../assets/imgs/img_head.png"), head_pic: require("../../../assets/imgs/img_head.png"),
}; };
}, },
...@@ -87,7 +87,7 @@ export default { ...@@ -87,7 +87,7 @@ export default {
}, },
getAnwerList() { getAnwerList() {
this.$http this.$http
.get("/apaas/support/qa/question/contribution") .get("/apaas/support/qa/answer/contribution")
.then(({ data }) => { .then(({ data }) => {
if (data.success) { if (data.success) {
this.contributorAnswerList = data.data || []; this.contributorAnswerList = data.data || [];
...@@ -95,18 +95,18 @@ export default { ...@@ -95,18 +95,18 @@ export default {
}); });
this.$http this.$http
.get("/apaas/support/qa/answer/contribution") .get("/apaas/support/qa/question/contribution")
.then(({ data }) => { .then(({ data }) => {
if (data.success) { if (data.success) {
this.contributorQuizList = data.data || []; this.contributorQuestionList = data.data || [];
} }
}); });
}, },
intoListPage(type) { intoListPage(type) {
if (type === 0) { if (type === 0) {
this.$router.push("/qa/questions"); this.$router.push("/qa/my_qa?name=0");
} else { } else {
this.$router.push("/qa/answers"); this.$router.push("/qa/my_qa?name=1");
} }
}, },
}, },
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
技术支持 技术支持
</el-breadcrumb-item> </el-breadcrumb-item>
<el-breadcrumb-item to="/technical_support/doc_manage"> <el-breadcrumb-item to="/technical_support/doc_manage">
开发文档 开发文档管理
</el-breadcrumb-item> </el-breadcrumb-item>
<el-breadcrumb-item> 文档编辑 </el-breadcrumb-item> <el-breadcrumb-item> 文档编辑 </el-breadcrumb-item>
<el-breadcrumb-item> {{ title }} </el-breadcrumb-item> <el-breadcrumb-item> {{ title }} </el-breadcrumb-item>
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
技术支持 技术支持
</el-breadcrumb-item> </el-breadcrumb-item>
<el-breadcrumb-item to="/technical_support/doc_manage"> <el-breadcrumb-item to="/technical_support/doc_manage">
开发文档 开发文档管理
</el-breadcrumb-item> </el-breadcrumb-item>
<el-breadcrumb-item> <el-breadcrumb-item>
管理列表 管理列表
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<span class="filter_title">文档名称:</span> <span class="filter_title">文档名称:</span>
<el-input <el-input
v-model="topFilter.name" v-model="topFilter.name"
placeholder="请输入banner关键词" placeholder="请输入文档名称"
@keyup.enter.native="topFilterAction" @keyup.enter.native="topFilterAction"
></el-input> ></el-input>
</div> </div>
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
<p>注:同一文档类型下可维护多个文档名称</p> <p>注:同一文档类型下可维护多个文档名称</p>
</div> </div>
<el-form ref="addForm" :model="addForm" :rules="addFormRules"> <el-form ref="addForm" :model="addForm" :rules="addFormRules">
<el-form-item label="活动区域" prop="style"> <el-form-item label="文档类型" prop="style">
<el-select <el-select
v-model="addForm.style" v-model="addForm.style"
placeholder="请选择文档类型" placeholder="请选择文档类型"
......
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
</span> </span>
<a class="clean_btn" @click.prevent="clearSelection">清空</a> <a class="clean_btn" @click.prevent="clearSelection">清空</a>
<el-button class="add_btn" type="primary" @click="addNewSdk"> <el-button class="add_btn" type="primary" @click="addNewSdk">
新增SDK类型 新增SDK示例
</el-button> </el-button>
</div> </div>
</apass-list> </apass-list>
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
> >
<div class="detail_content" slot="content"> <div class="detail_content" slot="content">
<div class="detail_notice"> <div class="detail_notice">
<p>注:同一文档类型下可维护多个文档名称</p> <p>注:同一SDK类型下可维护多个示例名称</p>
</div> </div>
<el-form ref="detailForm" :model="detailForm" :rules="detailFormRules"> <el-form ref="detailForm" :model="detailForm" :rules="detailFormRules">
<el-form-item label="SDK类型" prop="style_id"> <el-form-item label="SDK类型" prop="style_id">
...@@ -381,22 +381,20 @@ export default { ...@@ -381,22 +381,20 @@ export default {
return helper.dateStringTransform(time); return helper.dateStringTransform(time);
}, },
selectAction(values) { selectAction(values) {
// 页码操作需要保存所选项
if (this.saveSection) { if (this.saveSection) {
return; return;
} }
let cleanPage = values.length === 0; // 是否清空当前页所有选中
let selection = [...this.selection]; let selection = [...this.selection];
if (cleanPage) {
selection = selection.filter((item) => { selection = selection.filter((item) => {
return !this.listData.find((v) => { return !this.listData.find((v) => {
return v.id === item.id; return v.id === item.id;
}); });
}); });
} else {
selection.push(...values); selection.push(...values);
}
this.selection = selection; this.selection = selection;
}, },
......
...@@ -417,22 +417,20 @@ export default { ...@@ -417,22 +417,20 @@ export default {
return helper.dateStringTransform(time); return helper.dateStringTransform(time);
}, },
selectAction(values) { selectAction(values) {
// 页码操作需要保存所选项
if (this.saveSection) { if (this.saveSection) {
return; return;
} }
let cleanPage = values.length === 0; // 是否清空当前页所有选中
let selection = [...this.selection]; let selection = [...this.selection];
if (cleanPage) {
selection = selection.filter((item) => { selection = selection.filter((item) => {
return !this.listData.find((v) => { return !this.listData.find((v) => {
return v.id === item.id; return v.id === item.id;
}); });
}); });
} else {
selection.push(...values); selection.push(...values);
}
this.selection = selection; this.selection = selection;
}, },
......
...@@ -346,6 +346,11 @@ export default { ...@@ -346,6 +346,11 @@ export default {
}); });
}, },
}, },
created() {
if (this.$route.query.name !== undefined) {
this.activeName = this.$route.query.name;
}
},
mounted() { mounted() {
this.getUserQA(); this.getUserQA();
this.getQList(); this.getQList();
......
...@@ -80,7 +80,13 @@ ...@@ -80,7 +80,13 @@
(用于查询流程状态) (用于查询流程状态)
</p> </p>
</div> </div>
<div v-show="(activeBtn == 4 && zhyyVal == 24) || activeBtn == 3"> <div
v-show="
(activeBtn == 4 && zhyyVal == 24) ||
activeBtn == 3 ||
activeBtn == 2
"
>
<div class="fwcs_fwdz"> <div class="fwcs_fwdz">
上传接口文档 上传接口文档
<span class="title_bc">(请上传所有服务地址完整接口文档)</span> <span class="title_bc">(请上传所有服务地址完整接口文档)</span>
...@@ -147,7 +153,7 @@ ...@@ -147,7 +153,7 @@
服务测试 服务测试
</el-button> </el-button>
</div> </div>
<div v-if="activeBtn == 0 || activeBtn == 3"> <div v-if="activeBtn == 0 || activeBtn == 2 || activeBtn == 3">
<el-tabs v-model="activeName" class="fwcs_tabs" @tab-click="clickTab"> <el-tabs v-model="activeName" class="fwcs_tabs" @tab-click="clickTab">
<el-tab-pane label="请求参数" name="0"> <el-tab-pane label="请求参数" name="0">
<ces-table <ces-table
...@@ -370,7 +376,10 @@ ...@@ -370,7 +376,10 @@
</div> </div>
<div <div
v-show=" v-show="
(activeBtn == 1 || (activeBtn == 4 && zhyyVal == 34)) && resSuccess (activeBtn == 1 ||
activeBtn == 2 ||
(activeBtn == 4 && zhyyVal == 34)) &&
resSuccess
" "
> >
<div class="skfw_csfwxx">测试服务信息:</div> <div class="skfw_csfwxx">测试服务信息:</div>
...@@ -387,6 +396,7 @@ ...@@ -387,6 +396,7 @@
v-show=" v-show="
(activeBtn == 0 || (activeBtn == 0 ||
activeBtn == 1 || activeBtn == 1 ||
activeBtn == 2 ||
activeBtn == 3 || activeBtn == 3 ||
activeBtn == 4) && activeBtn == 4) &&
!resSuccess !resSuccess
...@@ -804,8 +814,8 @@ export default { ...@@ -804,8 +814,8 @@ export default {
{ label: "DELETE", value: "DELETE" }, { label: "DELETE", value: "DELETE" },
], ],
optionType1: [{ label: "GET", value: "GET" }], optionType1: [{ label: "GET", value: "GET" }],
activeName: 0, activeName: "0",
activeZh: 0, activeZh: "0",
sjfwQqcs: [ sjfwQqcs: [
{ {
label: "请求字段编码", label: "请求字段编码",
...@@ -1132,7 +1142,7 @@ export default { ...@@ -1132,7 +1142,7 @@ export default {
bodys = this.$refs.jsonCodes ? this.$refs.jsonCodes.getCodesVal() : ""; bodys = this.$refs.jsonCodes ? this.$refs.jsonCodes.getCodesVal() : "";
contentType = this.sjfwQqt; contentType = this.sjfwQqt;
} else if (this.activeBtn == 4) { } else if (this.activeBtn == 4) {
if (this.activeZh == 1) { if (this.activeZh == "1") {
contentType = this.zhfwQqt; contentType = this.zhfwQqt;
if (this.zhfwQqt == "JSON") { if (this.zhfwQqt == "JSON") {
bodys = this.$refs.zhfwJsonCodes bodys = this.$refs.zhfwJsonCodes
...@@ -1204,10 +1214,12 @@ export default { ...@@ -1204,10 +1214,12 @@ export default {
nextJcxx() { nextJcxx() {
if ( if (
this.activeBtn == 0 || this.activeBtn == 0 ||
this.activeBtn == 2 ||
this.activeBtn == 3 || this.activeBtn == 3 ||
(this.activeBtn == 4 && (this.zhyyVal == 22 || this.zhyyVal == 23)) (this.activeBtn == 4 && (this.zhyyVal == 22 || this.zhyyVal == 23))
) { ) {
if ( if (
this.activeBtn == 2 ||
this.activeBtn == 3 || this.activeBtn == 3 ||
(this.activeBtn == 4 && this.zhyyVal == 22) (this.activeBtn == 4 && this.zhyyVal == 22)
) { ) {
...@@ -1231,6 +1243,23 @@ export default { ...@@ -1231,6 +1243,23 @@ export default {
this.$message.error("请完善返回参数信息中的字段名称"); this.$message.error("请完善返回参数信息中的字段名称");
} }
} }
} else {
let requestData = this.$refs.fwcs_sjfw_qqcs.getTableData();
let responseData = this.$refs.fwcs_sjfw_fhcs.getTableData();
this.requestRules = 0;
this.responseRules = 0;
this.checkTable(requestData, 0);
this.checkTable(responseData, 1);
if (this.requestRules == 0 && this.responseRules == 0) {
this.request_fields = requestData;
this.response_fields = responseData;
this.jcxxtx = true;
this.getOrganization();
} else if (this.requestRules != 0) {
this.$message.error("请完善请求参数信息中的字段名称");
} else if (this.responseRules != 0) {
this.$message.error("请完善返回参数信息中的字段名称");
}
} }
} else if (this.activeBtn == 1) { } else if (this.activeBtn == 1) {
let value = helper.getQueryString("id", this.serviceUrl); let value = helper.getQueryString("id", this.serviceUrl);
...@@ -1410,7 +1439,7 @@ export default { ...@@ -1410,7 +1439,7 @@ export default {
if (this.activeBtn == 0 || this.activeBtn == 3) { if (this.activeBtn == 0 || this.activeBtn == 3) {
contentType = this.sjfwQqt; contentType = this.sjfwQqt;
} else if (this.activeBtn == 4) { } else if (this.activeBtn == 4) {
if (this.activeZh == 1) { if (this.activeZh == "1") {
contentType = this.zhfwQqt; contentType = this.zhfwQqt;
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment