|
@@ -137,6 +137,7 @@
|
|
|
v-model="propertyForm.code"
|
|
|
auto-complete="off"
|
|
|
class="dialog-input-width"
|
|
|
+ disabled
|
|
|
></el-input>
|
|
|
</el-form-item>
|
|
|
</el-row>
|
|
@@ -178,6 +179,7 @@
|
|
|
|
|
|
<script>
|
|
|
import { QUESTION_API } from "@/constants/constants";
|
|
|
+import { mapState } from "vuex";
|
|
|
|
|
|
export default {
|
|
|
data() {
|
|
@@ -245,6 +247,7 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
|
+ ...mapState({ user: (state) => state.user }),
|
|
|
courseInfoSelect() {
|
|
|
var courseList = [];
|
|
|
for (var i = 0; i < this.courseList.length; i++) {
|
|
@@ -339,6 +342,17 @@ export default {
|
|
|
this.loading = false;
|
|
|
});
|
|
|
},
|
|
|
+ getPropertyCode(parentId) {
|
|
|
+ this.$http
|
|
|
+ .post(QUESTION_API + "/property/get_code", {
|
|
|
+ rootOrgId: this.user.rootOrgId,
|
|
|
+ coursePropertyId: this.coursePropertyId,
|
|
|
+ parentId,
|
|
|
+ })
|
|
|
+ .then((response) => {
|
|
|
+ this.propertyForm.code = response.data;
|
|
|
+ });
|
|
|
+ },
|
|
|
//新增一级
|
|
|
insertParent() {
|
|
|
this.disAllBtn();
|
|
@@ -353,6 +367,7 @@ export default {
|
|
|
remark: "",
|
|
|
};
|
|
|
this.propertyDialog = true;
|
|
|
+ this.getPropertyCode(0);
|
|
|
},
|
|
|
//新增二级
|
|
|
insertSon() {
|
|
@@ -369,6 +384,7 @@ export default {
|
|
|
remark: "",
|
|
|
};
|
|
|
this.propertyDialog = true;
|
|
|
+ this.getPropertyCode(this.curProperty.id);
|
|
|
},
|
|
|
//修改
|
|
|
updateProperty() {
|