优化规格选择
This commit is contained in:
parent
d83b593db1
commit
dc306aeff0
|
|
@ -1,40 +1 @@
|
||||||
"use strict";
|
"use strict";const o=require("path"),e=require("electron");let n;e.app.whenReady().then(()=>{n=new e.BrowserWindow({title:"银收客",width:1024,height:768,fullscreenable:!0,fullscreen:!process.env.VITE_DEV_SERVER_URL,simpleFullscreen:!0,frame:!!process.env.VITE_DEV_SERVER_URL,webPreferences:{nodeIntegration:!0,contextIsolation:!1}}),process.env.VITE_DEV_SERVER_URL?(n.loadURL(process.env.VITE_DEV_SERVER_URL),n.webContents.openDevTools()):n.loadFile(o.resolve(__dirname,"../dist/index.html")),e.app.on("activate",()=>{e.BrowserWindow.getAllWindows().length===0&&createWindow()}),e.ipcMain.on("quitHandler",(t,r)=>{e.app.quit()}),e.ipcMain.on("printStart",(t,r)=>{})});e.app.on("window-all-closed",()=>{process.platform!=="darwin"&&e.app.quit()});
|
||||||
const path = require("path");
|
|
||||||
const electron = require("electron");
|
|
||||||
let win;
|
|
||||||
electron.app.whenReady().then(() => {
|
|
||||||
win = new electron.BrowserWindow({
|
|
||||||
title: "银收客",
|
|
||||||
width: 1024,
|
|
||||||
height: 768,
|
|
||||||
fullscreenable: true,
|
|
||||||
fullscreen: process.env.VITE_DEV_SERVER_URL ? false : true,
|
|
||||||
simpleFullscreen: true,
|
|
||||||
frame: process.env.VITE_DEV_SERVER_URL ? true : false,
|
|
||||||
webPreferences: {
|
|
||||||
// 集成网页和 Node.js,也就是在渲染进程中,可以调用 Node.js 方法
|
|
||||||
nodeIntegration: true,
|
|
||||||
contextIsolation: false
|
|
||||||
}
|
|
||||||
});
|
|
||||||
if (process.env.VITE_DEV_SERVER_URL) {
|
|
||||||
win.loadURL(process.env.VITE_DEV_SERVER_URL);
|
|
||||||
win.webContents.openDevTools();
|
|
||||||
} else {
|
|
||||||
win.loadFile(path.resolve(__dirname, "../dist/index.html"));
|
|
||||||
}
|
|
||||||
electron.app.on("activate", () => {
|
|
||||||
if (electron.BrowserWindow.getAllWindows().length === 0) {
|
|
||||||
createWindow();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
electron.ipcMain.on("quitHandler", (_, msg) => {
|
|
||||||
electron.app.quit();
|
|
||||||
});
|
|
||||||
electron.ipcMain.on("printStart", (event, arg) => {
|
|
||||||
});
|
|
||||||
});
|
|
||||||
electron.app.on("window-all-closed", () => {
|
|
||||||
if (process.platform !== "darwin")
|
|
||||||
electron.app.quit();
|
|
||||||
});
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "vite-electron",
|
"name": "vite-electron",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "1.0.13",
|
"version": "1.0.1",
|
||||||
"main": "dist-electron/main.js",
|
"main": "dist-electron/main.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "chcp 65001 && vite",
|
"dev": "chcp 65001 && vite",
|
||||||
|
|
|
||||||
|
|
@ -123,9 +123,15 @@ async function checkPayStauts() {
|
||||||
try {
|
try {
|
||||||
const res = await queryOrder({ orderId: props.orderId })
|
const res = await queryOrder({ orderId: props.orderId })
|
||||||
if (res.status == 'closed') {
|
if (res.status == 'closed') {
|
||||||
|
ElMessage.success('支付成功')
|
||||||
emits('success')
|
emits('success')
|
||||||
|
return
|
||||||
|
} if (res.status == 'paying') {
|
||||||
|
ElMessage.warning('用户支付中...')
|
||||||
|
return
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.payRemark || '支付失败!')
|
ElMessage.error(res.payRemark || '支付失败!')
|
||||||
|
return
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log(error)
|
console.log(error)
|
||||||
|
|
|
||||||
|
|
@ -56,7 +56,7 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, onMounted } from 'vue'
|
import { ref } from 'vue'
|
||||||
import _ from 'lodash'
|
import _ from 'lodash'
|
||||||
|
|
||||||
import skuModal from '@/components/skuModal.vue'
|
import skuModal from '@/components/skuModal.vue'
|
||||||
|
|
@ -76,7 +76,7 @@ const emit = defineEmits(['success'])
|
||||||
|
|
||||||
const skuModalRef = ref(null)
|
const skuModalRef = ref(null)
|
||||||
|
|
||||||
const shopListType = ref('img')
|
const shopListType = ref('text')
|
||||||
|
|
||||||
const categoryId = ref('')
|
const categoryId = ref('')
|
||||||
const categorys = ref([])
|
const categorys = ref([])
|
||||||
|
|
@ -172,7 +172,7 @@ async function productqueryCommodityInfoAjax() {
|
||||||
categoryId: categoryId.value,
|
categoryId: categoryId.value,
|
||||||
commdityName: commdityName.value,
|
commdityName: commdityName.value,
|
||||||
page: 1,
|
page: 1,
|
||||||
pageSize: 1000,
|
pageSize: 500,
|
||||||
masterId: props.masterId
|
masterId: props.masterId
|
||||||
})
|
})
|
||||||
goodsList.value = res
|
goodsList.value = res
|
||||||
|
|
@ -195,6 +195,22 @@ defineExpose({
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
|
.loading_wrap {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
padding: 20px 0;
|
||||||
|
color: #999;
|
||||||
|
|
||||||
|
.loading {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
|
||||||
|
.icon {
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.popover_wrap {
|
.popover_wrap {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
|
|
||||||
|
|
@ -105,8 +105,8 @@ const rules = reactive({
|
||||||
const submitHandle = () => {
|
const submitHandle = () => {
|
||||||
formRef.value.validate(async (valid) => {
|
formRef.value.validate(async (valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
|
loading.value = true;
|
||||||
store.userlogin(form).then((res) => {
|
store.userlogin(form).then((res) => {
|
||||||
loading.value = true;
|
|
||||||
ElMessage.success("登录成功");
|
ElMessage.success("登录成功");
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
router.replace({
|
router.replace({
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue