init(projects): 整体修改

master
xushilin 12 months ago
parent 56b17e1451
commit 130832bb21

@ -69,8 +69,12 @@ import {
useEditBtn
} from '@/hooks/common/useBtn';
// import { download } from '@/service/request/helpers';
import { useSocketStore } from '@/store/modules/socket/index';
import type { ModalType } from './components/table-action-modal.vue';
import TableActionModal from './components/table-action-modal.vue';
const socketStore = useSocketStore();
const router = useRouter();
const { proxy } = getCurrentInstance() as any;
const { wms_item_recpt_status } = proxy.useDict('wms_item_recpt_status', 'wms_item_recpt_type');
@ -265,6 +269,13 @@ const columns: Ref<DataTableColumns<wms.recptRawType.columns>> = ref([
align: 'center',
render: row => {
console.log(wms_item_recpt_status.value, row.status, '----');
if (row.status === 'FINISHED') {
return (
<n-button size="small" type="info" onClick={() => print(row)}>
补打标签
</n-button>
);
}
const Btn: JSX.Element[] = [];
if (row.status !== 'FINISHED') {
Btn.push(
@ -280,29 +291,6 @@ const columns: Ref<DataTableColumns<wms.recptRawType.columns>> = ref([
)
);
}
// Btn.push(
// useInfoBtn(
// () => {
// router.push({
// name: 'storage_auxiliaryProduceinfo',
// query: { id: row.recptId, warehouseId: row.warehouseId, info: 'true' }
// });
// },
// 'tiny',
// ''
// )
// );
// Btn.push(
// useDelBtn(() => {
// delWmsItemRecpt(row.recptId as number).then(res => {
// if (res.code === 200) {
// window.$message?.success('');
// init();
// }
// });
// }, 'tiny')
// );
return Btn;
}
}
@ -328,6 +316,15 @@ function reset() {
getWmsItemRecptData();
}
function print(row: wms.recptRawType.columns) {
socketStore.setMsg(
JSON.stringify({
templateType: 'YL-MB',
printValue: row.lineList
})
);
window.$message?.success('已发送打印命令');
}
// async function handleEditTable(issueId: number) {
// console.log('', issueId);
// }

Loading…
Cancel
Save