|
|
@@ -155,40 +155,48 @@
|
|
|
<el-col :span="12">
|
|
|
<el-form label-position="right" label-width="120px" :model="listData">
|
|
|
<el-form-item label="商品封面">
|
|
|
- <div class="imgBoxins">
|
|
|
- <img
|
|
|
- :src="$methodsTools.splitImgHost(listData.coverUrl)"
|
|
|
- alt=""
|
|
|
- />
|
|
|
- <div
|
|
|
- class="posimg"
|
|
|
- v-if="
|
|
|
- listData.coverUrl === null ||
|
|
|
- listData.coverUrl === '' ||
|
|
|
- listData.coverUrl === undefined
|
|
|
- "
|
|
|
- >
|
|
|
- <label for="uplose">
|
|
|
- <i class="el-icon-circle-plus-outline iconStsz"></i
|
|
|
- ></label>
|
|
|
- <input
|
|
|
- ref="file"
|
|
|
- type="file"
|
|
|
- style="display: none"
|
|
|
- id="uplose"
|
|
|
- @change="getImgFile"
|
|
|
- />
|
|
|
- <p>
|
|
|
- 注:请上传小于300kb,尺寸为750*440的图片,支持gif、jpg、jpeg、png等类型
|
|
|
- </p>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
+ <el-row :gutter="10" style="margin-bottom: 10px">
|
|
|
+ <el-col :span="12">
|
|
|
+ <div
|
|
|
+ style="
|
|
|
+ width: 100%;
|
|
|
+ height: 150px;
|
|
|
+ border: 2px dashed #999;
|
|
|
+ border-radius: 28px;
|
|
|
+ line-height: 150px;
|
|
|
+ text-align: center;
|
|
|
+ "
|
|
|
+ v-if="!listData.coverUrl"
|
|
|
+ >
|
|
|
+ <label for="uplose">
|
|
|
+ <i class="el-icon-circle-plus-outline iconStsz"></i
|
|
|
+ ></label>
|
|
|
+ <input
|
|
|
+ ref="file"
|
|
|
+ type="file"
|
|
|
+ style="display: none"
|
|
|
+ id="uplose"
|
|
|
+ @change="getImgFile"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <el-image
|
|
|
+ v-else
|
|
|
+ style="width: 100%"
|
|
|
+ :src="$methodsTools.splitImgHost(listData.coverUrl)"
|
|
|
+ :preview-src-list="[
|
|
|
+ $methodsTools.splitImgHost(listData.coverUrl),
|
|
|
+ ]"
|
|
|
+ >
|
|
|
+ </el-image>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="11">
|
|
|
+ <span style="color: #999; font-size: 13px"
|
|
|
+ >注:请上传小于300kb,尺寸为750*440的图片,支持gif、jpg、jpeg、png等类型</span
|
|
|
+ >
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
<el-button
|
|
|
- v-if="
|
|
|
- listData.coverUrl !== null &&
|
|
|
- listData.coverUrl !== '' &&
|
|
|
- listData.coverUrl !== undefined
|
|
|
- "
|
|
|
+ v-if="listData.coverUrl"
|
|
|
type="danger"
|
|
|
size="mini"
|
|
|
class="margin-top: 20px;"
|
|
|
@@ -210,12 +218,18 @@
|
|
|
ref="listData2"
|
|
|
>
|
|
|
<el-form-item label="商品标准价格" prop="standPrice">
|
|
|
- <el-input class="numInputs" v-model="listData.standPrice"
|
|
|
+ <el-input
|
|
|
+ class="numInputs"
|
|
|
+ v-model="listData.standPrice"
|
|
|
+ @change="judgeResult1"
|
|
|
><template slot="prepend">¥</template></el-input
|
|
|
>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="商品最低价格" prop="lowestPrice">
|
|
|
- <el-input class="numInputs" v-model="listData.lowestPrice"
|
|
|
+ <el-input
|
|
|
+ class="numInputs"
|
|
|
+ v-model="listData.lowestPrice"
|
|
|
+ @change="judgeResult2"
|
|
|
><template slot="prepend">¥</template></el-input
|
|
|
>
|
|
|
</el-form-item>
|
|
|
@@ -803,6 +817,7 @@
|
|
|
</span>
|
|
|
</el-dialog>
|
|
|
<el-dialog
|
|
|
+ @opened="prepareEnd"
|
|
|
:visible.sync="dialogVisibleTableBoxs"
|
|
|
width="800px"
|
|
|
:show-close="false"
|
|
|
@@ -1115,6 +1130,9 @@
|
|
|
>
|
|
|
</el-popover>
|
|
|
</ul>
|
|
|
+ <span v-else-if="item.scope === 'canDownload'">{{
|
|
|
+ scope.row[item.prop] === 1 ? "是" : "否"
|
|
|
+ }}</span>
|
|
|
<span v-else>{{ scope.row[item.prop] }}</span></template
|
|
|
>
|
|
|
</el-table-column></template
|
|
|
@@ -1362,6 +1380,7 @@ export default {
|
|
|
coverUrl: "oss/images/avatar/20211013/1634097664410_1397766697",
|
|
|
educationTypeId: "",
|
|
|
businessId: "",
|
|
|
+ status: 1,
|
|
|
schoolId: "",
|
|
|
majorId: "",
|
|
|
subjectId: "",
|
|
|
@@ -1654,18 +1673,19 @@ export default {
|
|
|
// 视频商品表格数据------------------------------------------------------------------------start
|
|
|
tableSetTSB: [
|
|
|
{ label: "排序", prop: "sort", scope: "inputs", width: "100" },
|
|
|
- { label: "科目名称", prop: "code" },
|
|
|
- { label: "课程名称", prop: "prefixName", width: "120" },
|
|
|
- { label: "科目", prop: "subjectName" },
|
|
|
+ { label: "课程编码", prop: "code", width: "140" },
|
|
|
+ { label: "课程名称", prop: "prefixName", width: "190" },
|
|
|
+ { label: "科目", prop: "subjectName", width: "150" },
|
|
|
{ label: "专业", prop: "categoryName" },
|
|
|
- { label: "院校", prop: "schoolName" },
|
|
|
+ { label: "院校", prop: "schoolName", width: "150" },
|
|
|
{
|
|
|
label: "业务层次",
|
|
|
prop1: "projectName",
|
|
|
prop2: "businessName",
|
|
|
scope: "busin",
|
|
|
+ width: "350px",
|
|
|
},
|
|
|
- { label: "教育类型", prop: "educationName" },
|
|
|
+ { label: "教育类型", prop: "educationName", width: "160" },
|
|
|
{
|
|
|
label: "发布状态",
|
|
|
prop: "publishStatus",
|
|
|
@@ -1674,14 +1694,14 @@ export default {
|
|
|
},
|
|
|
],
|
|
|
tableSetTSBBOX: [
|
|
|
- { label: "课程编码", prop: "code" },
|
|
|
- { label: "名称前缀", prop: "prefixName", width: "120" },
|
|
|
- { label: "课程标题", prop: "courseName" },
|
|
|
+ { label: "课程编码", prop: "code", width: "140px" },
|
|
|
+ { label: "名称前缀", prop: "prefixName", width: "160px" },
|
|
|
+ { label: "课程标题", prop: "courseName", width: "300px" },
|
|
|
{
|
|
|
label: "发布状态",
|
|
|
prop: "publishStatus",
|
|
|
scope: "Status",
|
|
|
- width: "120",
|
|
|
+ width: "120px",
|
|
|
},
|
|
|
],
|
|
|
total: 0, //一共多少条
|
|
|
@@ -1705,18 +1725,24 @@ export default {
|
|
|
// scope: "businessLevel",
|
|
|
// edu: "educationTypeId",
|
|
|
// },
|
|
|
- {
|
|
|
- prop: "schoolId",
|
|
|
- placeholder: "院校",
|
|
|
- scope: "schoolList",
|
|
|
- edu: "educationTypeId",
|
|
|
- },
|
|
|
+ // {
|
|
|
+ // prop: "schoolId",
|
|
|
+ // placeholder: "院校",
|
|
|
+ // scope: "schoolList",
|
|
|
+ // edu: "educationTypeId",
|
|
|
+ // },
|
|
|
{
|
|
|
prop: "majorId",
|
|
|
placeholder: "专业",
|
|
|
scope: "Professional",
|
|
|
edu: "educationTypeId",
|
|
|
},
|
|
|
+ {
|
|
|
+ prop: "subjectId",
|
|
|
+ placeholder: "科目",
|
|
|
+ scope: "sujectType",
|
|
|
+ edu: "educationTypeId",
|
|
|
+ },
|
|
|
// {
|
|
|
// prop: "publishStatus",
|
|
|
// placeholder: "发布状态",
|
|
|
@@ -1734,7 +1760,7 @@ export default {
|
|
|
// },
|
|
|
{
|
|
|
prop: "key",
|
|
|
- placeholder: "请输入课程标题/课程编码",
|
|
|
+ placeholder: "课程标题/课程编码/标题前缀",
|
|
|
},
|
|
|
],
|
|
|
disCheckList: [],
|
|
|
@@ -1745,17 +1771,18 @@ export default {
|
|
|
auditionList: [],
|
|
|
aboutJYBox: false,
|
|
|
jYtableSet: [
|
|
|
- { label: "讲义编码", prop: "encoder" },
|
|
|
- { label: "讲义标题", prop: "handoutsName" },
|
|
|
- {
|
|
|
- label: "适合业务层级",
|
|
|
- prop: "courseHandoutsBusinessVo",
|
|
|
- prop1: "educationName",
|
|
|
- prop2: "projectName",
|
|
|
- prop3: "businessName",
|
|
|
- scope: "eduType",
|
|
|
- },
|
|
|
- { label: "发布状态", prop: "status", scope: "Status" },
|
|
|
+ { label: "讲义编码", prop: "encoder", width: "150px" },
|
|
|
+ { label: "讲义标题", prop: "handoutsName"},
|
|
|
+ // {
|
|
|
+ // label: "适合业务层级",
|
|
|
+ // prop: "courseHandoutsBusinessVo",
|
|
|
+ // prop1: "educationName",
|
|
|
+ // prop2: "projectName",
|
|
|
+ // prop3: "businessName",
|
|
|
+ // scope: "eduType",
|
|
|
+ // },
|
|
|
+ { label: "是否可下载", prop: "canDownload", scope: "canDownload",width:"140px" },
|
|
|
+ { label: "发布状态", prop: "status", scope: "Status",width:"140px" },
|
|
|
],
|
|
|
jYtableData: [],
|
|
|
jYactiveBoxs: false,
|
|
|
@@ -1840,6 +1867,21 @@ export default {
|
|
|
// this.getJyData();
|
|
|
},
|
|
|
methods: {
|
|
|
+ judgeResult1(v) {
|
|
|
+ console.log(this.listData.lowestPrice, v);
|
|
|
+ if (this.listData.lowestPrice && this.listData.lowestPrice > v) {
|
|
|
+ this.listData.lowestPrice = "";
|
|
|
+ this.$message.warning("商品最低价格高于标准价格,请重新输入");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ judgeResult2(v) {
|
|
|
+ if (this.listData.standPrice && this.listData.standPrice < v) {
|
|
|
+ this.listData.lowestPrice = "";
|
|
|
+ this.$message.warning("商品最低价格高于标准价格,请重新输入");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ },
|
|
|
changeTypes() {
|
|
|
this.listData.studyCount = 1;
|
|
|
if (this.listData.goodsType === 3 || this.listData.goodsType === 4) {
|
|
|
@@ -2556,6 +2598,13 @@ export default {
|
|
|
);
|
|
|
// this.listData.standPriceJson[this.NUMBerS] = this.listitemData;
|
|
|
} else {
|
|
|
+ const INQU = this.listData.standPriceJson.some((item) => {
|
|
|
+ return item.priceTypeId === this.listitemData.priceTypeId;
|
|
|
+ });
|
|
|
+ if (INQU) {
|
|
|
+ this.$message.warning("已存在相同费用类型,禁止重复");
|
|
|
+ return;
|
|
|
+ }
|
|
|
this.listitem[0].options.map((i, k) => {
|
|
|
if (i.costId === Number(this.listitemData.priceTypeId)) {
|
|
|
this.listitemData.priceTypeName = i.costName;
|
|
|
@@ -2575,7 +2624,9 @@ export default {
|
|
|
var a = "";
|
|
|
this.certificateOption.map((item, index) => {
|
|
|
if (item.tpId === id) {
|
|
|
- a = item.typeId ? item.certificateName + ":" + item.title : item.title;
|
|
|
+ a = item.typeId
|
|
|
+ ? item.certificateName + ":" + item.title
|
|
|
+ : item.title;
|
|
|
}
|
|
|
});
|
|
|
return a;
|
|
|
@@ -2637,12 +2688,12 @@ export default {
|
|
|
this.dialogVisibleTableBoxs = true;
|
|
|
this.$nextTick(function () {
|
|
|
self.$refs.multipleTable.clearSelection();
|
|
|
- // self.$refs.searchBox.changeEducationType(
|
|
|
- // self.listData.educationTypeId
|
|
|
- // );
|
|
|
});
|
|
|
});
|
|
|
},
|
|
|
+ prepareEnd() {
|
|
|
+ this.$refs.searchBox.changeEducationType(this.listData.educationTypeId);
|
|
|
+ },
|
|
|
submitTab() {
|
|
|
if (this.activeLists.length === 0) {
|
|
|
this.dialogVisibleTableBoxs = false;
|