|
@@ -364,6 +364,16 @@
|
|
v-hasPermi="['his:storeOrder:exportDeliver']"
|
|
v-hasPermi="['his:storeOrder:exportDeliver']"
|
|
>导入发货</el-button>
|
|
>导入发货</el-button>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
+ <el-button
|
|
|
|
+ type="info"
|
|
|
|
+ plain
|
|
|
|
+ icon="el-icon-upload2"
|
|
|
|
+ size="mini"
|
|
|
|
+ @click="handleImportStatus"
|
|
|
|
+ v-hasPermi="['his:storeOrder:editImport']"
|
|
|
|
+ >导入订单状态</el-button>
|
|
|
|
+ </el-col>
|
|
<el-col :span="1.5">
|
|
<el-col :span="1.5">
|
|
<el-button
|
|
<el-button
|
|
type="info"
|
|
type="info"
|
|
@@ -589,6 +599,34 @@
|
|
<el-button @click="upload.open = false">取 消</el-button>
|
|
<el-button @click="upload.open = false">取 消</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
+
|
|
|
|
+ <el-dialog :title="uploadStatus.title" :visible.sync="uploadStatus.open" width="400px" append-to-body>
|
|
|
|
+ <el-upload
|
|
|
|
+ ref="uploadStatus"
|
|
|
|
+ :limit="1"
|
|
|
|
+ accept=".xlsx, .xls"
|
|
|
|
+ :headers="uploadStatus.headers"
|
|
|
|
+ :action="uploadStatus.url + '?updateSupport=' + upload.updateSupport"
|
|
|
|
+ :disabled="uploadStatus.isUploading"
|
|
|
|
+ :on-progress="handleFileUploadProgressOrder"
|
|
|
|
+ :on-success="handleFileSuccessOrder"
|
|
|
|
+ :auto-upload="false"
|
|
|
|
+ drag
|
|
|
|
+ >
|
|
|
|
+ <i class="el-icon-upload"></i>
|
|
|
|
+ <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
|
|
|
|
+ <div class="el-upload__tip text-center" slot="tip">
|
|
|
|
+ <div class="el-upload__tip" slot="tip">
|
|
|
|
+ </div>
|
|
|
|
+ <span>仅允许导入xls、xlsx格式文件。</span>
|
|
|
|
+ <el-link type="primary" :underline="false" style="font-size:12px;vertical-align: baseline;" @click="importUpdateOrderTemplate">下载模板</el-link>
|
|
|
|
+ </div>
|
|
|
|
+ </el-upload>
|
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
|
+ <el-button type="primary" @click="submitOrderStatusFileForm">确 定</el-button>
|
|
|
|
+ <el-button @click="uploadStatus.open = false">取 消</el-button>
|
|
|
|
+ </div>
|
|
|
|
+ </el-dialog>
|
|
|
|
|
|
<!-- 设置推送手机对话框 -->
|
|
<!-- 设置推送手机对话框 -->
|
|
<el-dialog :title="erpPhone.title" :visible.sync="erpPhone.open" width="600px" append-to-body>
|
|
<el-dialog :title="erpPhone.title" :visible.sync="erpPhone.open" width="600px" append-to-body>
|
|
@@ -721,7 +759,7 @@
|
|
|
|
|
|
<script>
|
|
<script>
|
|
import { listOrder, getOrder, delOrder, addOrder,importExpressTemplate, updateOrder, exportOrder,importTemplate,exportOrder2,queryErpPhone,
|
|
import { listOrder, getOrder, delOrder, addOrder,importExpressTemplate, updateOrder, exportOrder,importTemplate,exportOrder2,queryErpPhone,
|
|
- saveErpPhone,editErpPhone,batchCreateErpOrder,getErpAccount,batchSetErpOrder } from "@/api/his/storeOrder";
|
|
|
|
|
|
+ saveErpPhone,editErpPhone,batchCreateErpOrder,getErpAccount,batchSetErpOrder,importUpdateOrderTemplate } from "@/api/his/storeOrder";
|
|
import storeOrderDetails from '../../components/his/storeOrderDetails.vue';
|
|
import storeOrderDetails from '../../components/his/storeOrderDetails.vue';
|
|
import { getToken } from "@/utils/auth";
|
|
import { getToken } from "@/utils/auth";
|
|
import {listStore} from "@/api/his/storeProduct";
|
|
import {listStore} from "@/api/his/storeProduct";
|
|
@@ -831,6 +869,20 @@ export default {
|
|
// 上传的地址
|
|
// 上传的地址
|
|
url: process.env.VUE_APP_BASE_API + "/his/storeOrder/importData"
|
|
url: process.env.VUE_APP_BASE_API + "/his/storeOrder/importData"
|
|
},
|
|
},
|
|
|
|
+ uploadStatus: {
|
|
|
|
+ // 是否显示弹出层
|
|
|
|
+ open: false,
|
|
|
|
+ // 弹出层标题
|
|
|
|
+ title: "",
|
|
|
|
+ // 是否禁用上传
|
|
|
|
+ isUploading: false,
|
|
|
|
+ // 是否更新已经存在的用户数据
|
|
|
|
+ updateSupport: 0,
|
|
|
|
+ // 设置上传的请求头部
|
|
|
|
+ headers: { Authorization: "Bearer " + getToken() },
|
|
|
|
+ // 上传的地址
|
|
|
|
+ url: process.env.VUE_APP_BASE_API + "/his/storeOrder/importOrderStatusData"
|
|
|
|
+ },
|
|
// 遮罩层
|
|
// 遮罩层
|
|
loading: true,
|
|
loading: true,
|
|
// 导出遮罩层
|
|
// 导出遮罩层
|
|
@@ -1657,6 +1709,10 @@ export default {
|
|
handleFileUploadProgressExpress(event, file, fileList) {
|
|
handleFileUploadProgressExpress(event, file, fileList) {
|
|
this.upload.isUploading = true;
|
|
this.upload.isUploading = true;
|
|
},
|
|
},
|
|
|
|
+ // 文件上传中处理
|
|
|
|
+ handleFileUploadProgressOrder(event, file, fileList) {
|
|
|
|
+ this.uploadStatus.isUploading = true;
|
|
|
|
+ },
|
|
// 文件上传成功处理
|
|
// 文件上传成功处理
|
|
handleFileSuccessExpress(response, file, fileList) {
|
|
handleFileSuccessExpress(response, file, fileList) {
|
|
this.importExpress.open = false;
|
|
this.importExpress.open = false;
|
|
@@ -1665,14 +1721,26 @@ export default {
|
|
this.$alert(response.msg, "导入结果", { dangerouslyUseHTMLString: true });
|
|
this.$alert(response.msg, "导入结果", { dangerouslyUseHTMLString: true });
|
|
this.getList();
|
|
this.getList();
|
|
},
|
|
},
|
|
|
|
+ // 文件上传成功处理
|
|
|
|
+ handleFileSuccessOrder(response, file, fileList) {
|
|
|
|
+ this.uploadStatus.open = false;
|
|
|
|
+ this.uploadStatus.isUploading = false;
|
|
|
|
+ this.$refs.uploadStatus.clearFiles();
|
|
|
|
+ this.$alert(response.msg, "导入结果", { dangerouslyUseHTMLString: true });
|
|
|
|
+ this.getList();
|
|
|
|
+ },
|
|
|
|
+
|
|
// 提交上传文件
|
|
// 提交上传文件
|
|
submitFileFormExpress() {
|
|
submitFileFormExpress() {
|
|
this.$refs.importExpress.submit();
|
|
this.$refs.importExpress.submit();
|
|
},
|
|
},
|
|
|
|
|
|
-
|
|
|
|
- /** 导入按钮操作 */
|
|
|
|
- handleImport() {
|
|
|
|
|
|
+ handleImportStatus() {
|
|
|
|
+ this.uploadStatus.title = "导入";
|
|
|
|
+ this.uploadStatus.open = true;
|
|
|
|
+ },
|
|
|
|
+ /** 导入按钮操作 */
|
|
|
|
+ handleImport() {
|
|
this.upload.title = "导入";
|
|
this.upload.title = "导入";
|
|
this.upload.open = true;
|
|
this.upload.open = true;
|
|
},
|
|
},
|
|
@@ -1683,6 +1751,11 @@ export default {
|
|
this.download(response.msg);
|
|
this.download(response.msg);
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ importUpdateOrderTemplate(){
|
|
|
|
+ importUpdateOrderTemplate().then(response => {
|
|
|
|
+ this.download(response.msg);
|
|
|
|
+ });
|
|
|
|
+ },
|
|
// 文件上传中处理
|
|
// 文件上传中处理
|
|
handleFileUploadProgress(event, file, fileList) {
|
|
handleFileUploadProgress(event, file, fileList) {
|
|
this.upload.isUploading = true;
|
|
this.upload.isUploading = true;
|
|
@@ -1699,6 +1772,9 @@ export default {
|
|
submitFileForm() {
|
|
submitFileForm() {
|
|
this.$refs.upload.submit();
|
|
this.$refs.upload.submit();
|
|
},
|
|
},
|
|
|
|
+ submitOrderStatusFileForm(){
|
|
|
|
+ this.$refs.uploadStatus.submit();
|
|
|
|
+ },
|
|
handledetails(row){
|
|
handledetails(row){
|
|
this.show.open=true;
|
|
this.show.open=true;
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|