|
|
@@ -859,6 +859,16 @@
|
|
|
/>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="所属小程序" prop="appIds">
|
|
|
+ <el-select style="width: 240px" v-model="appIds" placeholder="请选择所属小程序" clearable size="small" multiple>
|
|
|
+ <el-option
|
|
|
+ v-for="dict in appMallOptions"
|
|
|
+ :key="dict.appid"
|
|
|
+ :label="dict.name + '(' + dict.appid + ')'"
|
|
|
+ :value="dict.appid"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
<el-form-item label="国药准字" v-if="form.productType==2" prop="prescribeCode">
|
|
|
<el-input v-model="form.prescribeCode" placeholder="请输入国药准字" />
|
|
|
</el-form-item>
|
|
|
@@ -931,6 +941,7 @@ import Material from '@/components/Material'
|
|
|
import singleImg from '@/components/Material/single'
|
|
|
import { getCompanyList } from "@/api/company/company";
|
|
|
import { listStore } from '@/api/hisStore/store'
|
|
|
+import {list as getAppMallOptions} from "@/api/course/coursePlaySourceConfig";
|
|
|
export default {
|
|
|
name: "HisStoreProduct",
|
|
|
components: {
|
|
|
@@ -1048,7 +1059,9 @@ export default {
|
|
|
title: "",
|
|
|
// 是否显示弹出层
|
|
|
open: false,
|
|
|
-
|
|
|
+ // 小程序列表
|
|
|
+ appMallOptions:[],
|
|
|
+ appIds:[], // 选择的小程序
|
|
|
// 查询参数
|
|
|
queryParams: {
|
|
|
pageNum: 1,
|
|
|
@@ -1201,6 +1214,9 @@ export default {
|
|
|
getCompanyList().then(response => {
|
|
|
this.companyOptions = response.data;
|
|
|
});
|
|
|
+ // 查询小程序
|
|
|
+ this.getAppMallOptions();
|
|
|
+
|
|
|
listStore(this.storeForm).then(response => {
|
|
|
this.storeOptions = response.rows;
|
|
|
});
|
|
|
@@ -1208,6 +1224,11 @@ export default {
|
|
|
this.getList();
|
|
|
},
|
|
|
methods: {
|
|
|
+ getAppMallOptions() {
|
|
|
+ getAppMallOptions({pageNum:1,pageSize:100}).then(response => {
|
|
|
+ this.appMallOptions = response.rows;
|
|
|
+ })
|
|
|
+ },
|
|
|
getStatusText(row) {
|
|
|
console.log()
|
|
|
if (row.isAudit == 0) {
|
|
|
@@ -1606,6 +1627,7 @@ export default {
|
|
|
if (response.data.companyIds != null && response.data.companyIds != undefined && response.data.companyIds.length > 0) {
|
|
|
this.form.companyIds = response.data.companyIds.split(',').map(Number);
|
|
|
}
|
|
|
+ this.appIds = this.form.appIds ? this.form.appIds.split(',') : [];
|
|
|
setTimeout(() => {
|
|
|
that.generate();
|
|
|
}, 200);
|
|
|
@@ -1666,9 +1688,19 @@ export default {
|
|
|
if (this.form.companyIds != null && this.form.companyIds != undefined) {
|
|
|
this.form.companyIds = this.form.companyIds.join(',');
|
|
|
}
|
|
|
- addOrEdit(this.form).then(response => {
|
|
|
+ // 小程序
|
|
|
+ const params = {
|
|
|
+ ...this.form,
|
|
|
+ appIds: this.appIds.join(',') // 数组转字符串
|
|
|
+ };
|
|
|
+ addOrEdit(params).then(response => {
|
|
|
if (response.code === 200) {
|
|
|
- this.msgSuccess("修改成功");
|
|
|
+ // 根据是否有productId判断是新增还是修改
|
|
|
+ if (this.form.productId) {
|
|
|
+ this.msgSuccess("修改成功");
|
|
|
+ } else {
|
|
|
+ this.msgSuccess("新增成功");
|
|
|
+ }
|
|
|
this.open = false;
|
|
|
this.getList();
|
|
|
}
|