|
|
@@ -146,6 +146,32 @@
|
|
|
<template slot="append">期</template>
|
|
|
</el-input> -->
|
|
|
</el-form-item>
|
|
|
+ <template v-if="issueKS && issueKS.ks !== issueKS.comb_count">
|
|
|
+ <el-form-item label="配置刊数">
|
|
|
+ <el-input
|
|
|
+ placeholder="请输入"
|
|
|
+ v-model="issueKS.comb_count"
|
|
|
+ disabled
|
|
|
+ style="width: 114px"
|
|
|
+ >
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="当前刊数">
|
|
|
+ <el-input
|
|
|
+ placeholder="请输入"
|
|
|
+ v-model="issueKS.ks"
|
|
|
+ disabled
|
|
|
+ style="width: 114px; margin-right: 10px"
|
|
|
+ >
|
|
|
+ </el-input>
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ @click="handleSyncIssueKS"
|
|
|
+ >同步刊数</el-button
|
|
|
+ >
|
|
|
+ </el-form-item>
|
|
|
+ </template>
|
|
|
<el-form-item label="发行日期" prop="release_date">
|
|
|
<el-date-picker
|
|
|
v-model="newspaperForm.release_date"
|
|
|
@@ -695,6 +721,7 @@ export default {
|
|
|
loading: false,
|
|
|
previewBook: false,
|
|
|
oldArtsList: [], // 记录旧文章栏目列表
|
|
|
+ issueKS: null, // 刊数信息
|
|
|
};
|
|
|
},
|
|
|
//计算属性 类似于data概念
|
|
|
@@ -1277,6 +1304,34 @@ export default {
|
|
|
closePreview() {
|
|
|
this.previewBook = false;
|
|
|
},
|
|
|
+ // 获取报纸刊数
|
|
|
+ getIssueKS() {
|
|
|
+ let MethodName = "/ShopServer/Manager/GoodsQuery/GetIssueKS";
|
|
|
+ let data = {
|
|
|
+ issue_id: this.id,
|
|
|
+ };
|
|
|
+ getLogin(MethodName, data).then((res) => {
|
|
|
+ if (res.status === 1) {
|
|
|
+ this.issueKS = {
|
|
|
+ ks: res.ks,
|
|
|
+ comb_count: res.comb_count,
|
|
|
+ };
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ // 同步刊数
|
|
|
+ handleSyncIssueKS() {
|
|
|
+ let MethodName = "/ShopServer/Manager/GoodsManager/SyncIssueKS";
|
|
|
+ let data = {
|
|
|
+ issue_id: this.id,
|
|
|
+ };
|
|
|
+ getLogin(MethodName, data).then((res) => {
|
|
|
+ if (res.status === 1) {
|
|
|
+ this.$message.success("同步成功");
|
|
|
+ this.getIssueKS();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
},
|
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
|
async created() {
|
|
|
@@ -1292,6 +1347,8 @@ export default {
|
|
|
}
|
|
|
if (this.id) {
|
|
|
this.getInfo();
|
|
|
+
|
|
|
+ this.getIssueKS();
|
|
|
}
|
|
|
this.breadcrumbList.push(obj);
|
|
|
},
|