|
@@ -130,6 +130,17 @@
|
|
|
</el-select>
|
|
</el-select>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
|
|
|
|
|
|
|
+ <el-form-item label="是否已推送" prop="isPush">
|
|
|
|
|
+ <el-select filterable v-model="queryParams.isPush" placeholder="推送状态" clearable size="small">
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="dict in isPushOptions"
|
|
|
|
|
+ :key="dict.dictValue"
|
|
|
|
|
+ :label="dict.dictLabel"
|
|
|
|
|
+ :value="dict.dictValue"
|
|
|
|
|
+ />
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+
|
|
|
|
|
|
|
|
<el-form-item label="下单时间" prop="createTime">
|
|
<el-form-item label="下单时间" prop="createTime">
|
|
|
<el-date-picker v-model="createTime" size="small" style="width: 220px" value-format="yyyy-MM-dd" type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" @change="changeTime"></el-date-picker>
|
|
<el-date-picker v-model="createTime" size="small" style="width: 220px" value-format="yyyy-MM-dd" type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" @change="changeTime"></el-date-picker>
|
|
@@ -139,6 +150,8 @@
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
<el-form-item>
|
|
<el-form-item>
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
@@ -167,6 +180,17 @@
|
|
|
v-hasPermi="['store:storeOrder:export']"
|
|
v-hasPermi="['store:storeOrder:export']"
|
|
|
>导出订单</el-button>
|
|
>导出订单</el-button>
|
|
|
</el-col> -->
|
|
</el-col> -->
|
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
|
+ <el-button
|
|
|
|
|
+ type="success"
|
|
|
|
|
+ plain
|
|
|
|
|
+ icon="el-icon-s-promotion"
|
|
|
|
|
+ size="mini"
|
|
|
|
|
+ :loading="pushLoading"
|
|
|
|
|
+ @click="handlePush"
|
|
|
|
|
+ v-hasPermi="['his:storeOrder:push']"
|
|
|
|
|
+ >推送</el-button>
|
|
|
|
|
+ </el-col>
|
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
|
</el-row>
|
|
</el-row>
|
|
|
<el-tabs type="card" v-model="actName" @tab-click="handleClickX">
|
|
<el-tabs type="card" v-model="actName" @tab-click="handleClickX">
|
|
@@ -238,7 +262,7 @@
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
-import { listStoreSubOrder, getStoreSubOrder, addOrder,importExpressTemplate, exportStoreSubOrder,importTemplate } from "@/api/his/storeSubOrder";
|
|
|
|
|
|
|
+import { listStoreSubOrder, getStoreSubOrder, addOrder,importExpressTemplate, exportStoreSubOrder,importTemplate,pushStoreSubOrder } from "@/api/his/storeSubOrder";
|
|
|
import storeSubOrderDetails from '../../components/his/storeSubOrderDetails.vue';
|
|
import storeSubOrderDetails from '../../components/his/storeSubOrderDetails.vue';
|
|
|
import { getToken } from "@/utils/auth";
|
|
import { getToken } from "@/utils/auth";
|
|
|
import {listStore} from "@/api/his/storeProduct";
|
|
import {listStore} from "@/api/his/storeProduct";
|
|
@@ -299,8 +323,10 @@ export default {
|
|
|
loading: true,
|
|
loading: true,
|
|
|
// 导出遮罩层
|
|
// 导出遮罩层
|
|
|
exportLoading: false,
|
|
exportLoading: false,
|
|
|
|
|
+ pushLoading: false,
|
|
|
// 选中数组
|
|
// 选中数组
|
|
|
ids: [],
|
|
ids: [],
|
|
|
|
|
+ subOrderIds: [],
|
|
|
// 非单个禁用
|
|
// 非单个禁用
|
|
|
single: true,
|
|
single: true,
|
|
|
// 非多个禁用
|
|
// 非多个禁用
|
|
@@ -388,6 +414,16 @@ export default {
|
|
|
channelOptions:[],
|
|
channelOptions:[],
|
|
|
qwSubjectOptions:[],
|
|
qwSubjectOptions:[],
|
|
|
orderTypeOptions:[],
|
|
orderTypeOptions:[],
|
|
|
|
|
+ isPushOptions:[
|
|
|
|
|
+ {
|
|
|
|
|
+ dictLabel :"已推送",
|
|
|
|
|
+ dictValue:"1"
|
|
|
|
|
+ },
|
|
|
|
|
+ {
|
|
|
|
|
+ dictLabel :"未推送",
|
|
|
|
|
+ dictValue:"0"
|
|
|
|
|
+ },
|
|
|
|
|
+ ],
|
|
|
orderBuyTypeOptions:[],
|
|
orderBuyTypeOptions:[],
|
|
|
tuiOptions:[],
|
|
tuiOptions:[],
|
|
|
orOptions:[],
|
|
orOptions:[],
|
|
@@ -458,7 +494,7 @@ export default {
|
|
|
|
|
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
handledetails(row){
|
|
handledetails(row){
|
|
|
this.show.open=true;
|
|
this.show.open=true;
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
@@ -636,6 +672,7 @@ export default {
|
|
|
// 多选框选中数据
|
|
// 多选框选中数据
|
|
|
handleSelectionChange(selection) {
|
|
handleSelectionChange(selection) {
|
|
|
this.ids = selection.map(item => item.orderId)
|
|
this.ids = selection.map(item => item.orderId)
|
|
|
|
|
+ this.subOrderIds= selection.map(item => item.subOrderId)
|
|
|
this.single = selection.length!==1
|
|
this.single = selection.length!==1
|
|
|
this.multiple = !selection.length
|
|
this.multiple = !selection.length
|
|
|
},
|
|
},
|
|
@@ -689,6 +726,27 @@ export default {
|
|
|
this.msgSuccess("删除成功");
|
|
this.msgSuccess("删除成功");
|
|
|
}).catch(() => {});
|
|
}).catch(() => {});
|
|
|
},
|
|
},
|
|
|
|
|
+ handlePush() {
|
|
|
|
|
+ let params = {...this.queryParams}; // 先浅拷贝一份
|
|
|
|
|
+ if (this.subOrderIds?.length > 0) { // 使用可选链操作符
|
|
|
|
|
+ params = {...params, orderIds: this.subOrderIds};
|
|
|
|
|
+ }
|
|
|
|
|
+ this.$confirm('是否确认推送所选订单数据项?', "警告", {
|
|
|
|
|
+ confirmButtonText: "确定",
|
|
|
|
|
+ cancelButtonText: "取消",
|
|
|
|
|
+ type: "warning"
|
|
|
|
|
+ }).then(() => {
|
|
|
|
|
+ this.pushLoading = true;
|
|
|
|
|
+ return pushStoreSubOrder(params);
|
|
|
|
|
+ }).then(response => {
|
|
|
|
|
+ var msg = response.msg
|
|
|
|
|
+ this.pushLoading = false;
|
|
|
|
|
+ if (msg !== null && msg.length > 0) {
|
|
|
|
|
+ this.$message.error(msg);
|
|
|
|
|
+ }
|
|
|
|
|
+ }).catch(() => {
|
|
|
|
|
+ });
|
|
|
|
|
+ },
|
|
|
/** 导出按钮操作 */
|
|
/** 导出按钮操作 */
|
|
|
handleExport() {
|
|
handleExport() {
|
|
|
if(this.payTypeArr.length>0){
|
|
if(this.payTypeArr.length>0){
|