成本挖掘页面 #7
@@ -2,7 +2,7 @@ import request from "@/service/request";
|
|||||||
|
|
||||||
/*新增版本号*/
|
/*新增版本号*/
|
||||||
export function costStandardVersionAdd(data) {
|
export function costStandardVersionAdd(data) {
|
||||||
return request.post("/costStandardVersion/add", {}, data, {
|
return request.post("/costCount/addCostCountTask", {}, data, {
|
||||||
message: {
|
message: {
|
||||||
success: "生成成功",
|
success: "生成成功",
|
||||||
error: true
|
error: true
|
||||||
@@ -11,7 +11,7 @@ export function costStandardVersionAdd(data) {
|
|||||||
}
|
}
|
||||||
// 查询列表
|
// 查询列表
|
||||||
export function costStandardList(params) {
|
export function costStandardList(params) {
|
||||||
return request.get(`/costStandard/list`, params);
|
return request.get(`/costCount/list`, params);
|
||||||
}
|
}
|
||||||
//删除
|
//删除
|
||||||
export function deleteCostStandard(data) {
|
export function deleteCostStandard(data) {
|
||||||
|
|||||||
+31
-19
@@ -3,30 +3,42 @@ import request from "@/service/request";
|
|||||||
export function modelList(params) {
|
export function modelList(params) {
|
||||||
return request.get(`/cost-model/pageList`, params);
|
return request.get(`/cost-model/pageList`, params);
|
||||||
}
|
}
|
||||||
// /*新增小时费率*/
|
/*新增*/
|
||||||
// export function addHourRate(data) {
|
export function addModel(data) {
|
||||||
// return request.post("/hourRate/add", {}, data, {
|
return request.post("/cost-model/add", {}, data, {
|
||||||
// message: {
|
message: {
|
||||||
// success: "新增成功",
|
success: "新增成功",
|
||||||
// error: true
|
error: true
|
||||||
// }
|
}
|
||||||
// });
|
});
|
||||||
// }
|
}
|
||||||
// /*编辑小时费率*/
|
/*编辑*/
|
||||||
// export function editHourRate(data) {
|
export function editCostModel(data) {
|
||||||
// return request.post("/hourRate/edit", {}, data, {
|
return request.post("/cost-model/edit", {}, data, {
|
||||||
// message: {
|
message: {
|
||||||
// success: "编辑成功",
|
success: "编辑成功",
|
||||||
// error: true
|
error: true
|
||||||
// }
|
}
|
||||||
// });
|
});
|
||||||
// }
|
}
|
||||||
/*删除*/
|
/*删除*/
|
||||||
export function deleteModel(data) {
|
export function deleteModel(data) {
|
||||||
return request.post("/cost-model/delete",{}, data,{
|
return request.delete("/cost-model/delete", data,{
|
||||||
message: {
|
message: {
|
||||||
success: "删除成功",
|
success: "删除成功",
|
||||||
error: true
|
error: true
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
/*获取流程管理员列表*/
|
||||||
|
export function listAll() {
|
||||||
|
return request.get(`/sys/user/listAll`);
|
||||||
|
}
|
||||||
|
/*获取环境配置*/
|
||||||
|
export function environmentList(params) {
|
||||||
|
return request.get(`/api/environment/list`, params);
|
||||||
|
}
|
||||||
|
/*获取操作系统租户*/
|
||||||
|
export function tenantList(params) {
|
||||||
|
return request.get(`/api/tenant/list`, params);
|
||||||
|
}
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ export function costStandardDetailList(params) {
|
|||||||
return request.get(`/costStandardDetail/list`, params);
|
return request.get(`/costStandardDetail/list`, params);
|
||||||
}
|
}
|
||||||
/*导出excel*/
|
/*导出excel*/
|
||||||
export function exportcostStandardDetail(data) {
|
export function exportcostStandardDetail(params) {
|
||||||
return request.get("/costStandardDetail/exportXls", data, {
|
return request.get("/costStandardDetail/exportXls", params,{ responseType:"blob"}, {
|
||||||
message: {
|
message: {
|
||||||
success: "导出成功",
|
success: "导出成功",
|
||||||
error: true
|
error: true
|
||||||
|
|||||||
@@ -60,6 +60,24 @@ export const qomoPlatformOptions = {
|
|||||||
label: "物流费",
|
label: "物流费",
|
||||||
value: "LogisticsFee"
|
value: "LogisticsFee"
|
||||||
}
|
}
|
||||||
|
],
|
||||||
|
statusList:[
|
||||||
|
{
|
||||||
|
label: "未执行",
|
||||||
|
value: "0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "计算中",
|
||||||
|
value: "1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "计算完成",
|
||||||
|
value: "2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "出错中止",
|
||||||
|
value: "3"
|
||||||
|
},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
async provider(dictType) {
|
async provider(dictType) {
|
||||||
|
|||||||
@@ -165,6 +165,66 @@ export const constantRoutes = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: "standardComparison/index",
|
||||||
|
component: () => import("@/views/standardComparison/index"),
|
||||||
|
name: "Standardcomparison",
|
||||||
|
meta: { title: "标准成本对比", icon: "tree", affix: true }
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: "standardComparison/manHour",
|
||||||
|
component: () => import("@/views/standardComparison/component/manHour"),
|
||||||
|
name: "ManHour",
|
||||||
|
hidden: true,
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: "standardComparison/artificial",
|
||||||
|
component: () => import("@/views/standardComparison/component/artificial"),
|
||||||
|
name: "Artificial",
|
||||||
|
hidden: true,
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: "standardComparison/materials",
|
||||||
|
component: () => import("@/views/standardComparison/component/materials"),
|
||||||
|
name: "Materials",
|
||||||
|
hidden: true,
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: "stageComparison/index",
|
||||||
|
component: () => import("@/views/stageComparison/index"),
|
||||||
|
name: "StageComparison",
|
||||||
|
meta: { title: "阶段成本对比", icon: "tree", affix: true }
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
// Bom,工序,采购价格
|
// Bom,工序,采购价格
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -1,120 +1,159 @@
|
|||||||
<script lang="tsx">
|
<script lang="tsx">
|
||||||
//表格
|
//表格
|
||||||
import { defineComponent, ref, watch } from "vue";
|
import { defineComponent, ref, watch } from "vue";
|
||||||
import { costStandardVersionAdd } from '@/api/costCalculation';
|
import { costStandardVersionAdd } from "@/api/costCalculation";
|
||||||
|
import { modelList } from "@/api/modelManagement";
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
props: {
|
props: {
|
||||||
visible: Boolean,
|
visible: Boolean,
|
||||||
tableRef: Object,
|
tableRef: Object
|
||||||
},
|
},
|
||||||
setup(props, { emit }) {
|
setup(props, { emit }) {
|
||||||
const forecastDialogRef = ref();
|
const forecastDialogRef = ref();
|
||||||
const rileForm = ref();
|
const rileForm = ref();
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
figureNumber: '',
|
drawingNo: "",
|
||||||
stage: '',
|
stage: "",
|
||||||
createTime: '',
|
createTime: "",
|
||||||
versionNumber: '',
|
costVersion: "",
|
||||||
materialNumber: '',
|
materialNo: "",
|
||||||
versionYear: ''
|
year: "",
|
||||||
});
|
flowDefinitionId: ""
|
||||||
// const rules ={
|
});
|
||||||
// figureNumber: [
|
const modelSelect = ref([]);
|
||||||
// { required: true, message: '请输入图号', trigger: ['blur','change'] }
|
// const rules ={
|
||||||
// ],
|
// figureNumber: [
|
||||||
// stage: [
|
// { required: true, message: '请输入图号', trigger: ['blur','change'] }
|
||||||
// { required: true, message: '请选择项目阶段', trigger: ['blur','change'] }
|
// ],
|
||||||
// ],
|
// stage: [
|
||||||
// createTime: [
|
// { required: true, message: '请选择项目阶段', trigger: ['blur','change'] }
|
||||||
// { required: true, message: '请选择项目时间', trigger: ['blur','change'] }
|
// ],
|
||||||
// ],
|
// createTime: [
|
||||||
// versionNumber: [
|
// { required: true, message: '请选择项目时间', trigger: ['blur','change'] }
|
||||||
// { required: true, message: '请生成版本号', trigger: ['blur','change'] }
|
// ],
|
||||||
// ]
|
// versionNumber: [
|
||||||
// };
|
// { required: true, message: '请生成版本号', trigger: ['blur','change'] }
|
||||||
const render = () => {
|
// ]
|
||||||
return (
|
// };
|
||||||
<div>
|
const render = () => {
|
||||||
<base-dialog-form
|
return (
|
||||||
ref={forecastDialogRef}
|
<div>
|
||||||
v-model={props.visible}
|
<base-dialog-form
|
||||||
title={"生成设置版本号"}
|
ref={forecastDialogRef}
|
||||||
width={400}
|
v-model={props.visible}
|
||||||
labelWidth={0}
|
title={"生成设置版本号"}
|
||||||
confirm={() => {
|
width={400}
|
||||||
emit('cancelVisible');
|
labelWidth={0}
|
||||||
const year = formData.value.createTime.split("-")[0];
|
confirm={() => {
|
||||||
formData.value.versionYear = year;
|
emit("cancelVisible");
|
||||||
costStandardVersionAdd(formData.value).then(res => {
|
const year = formData.value.createTime.split("-")[0];
|
||||||
props.tableRef.doReload();
|
formData.value.year = year;
|
||||||
})
|
costStandardVersionAdd(formData.value).then(res => {
|
||||||
}}
|
props.tableRef.doReload();
|
||||||
cancel={() => {
|
});
|
||||||
emit('cancelVisible');
|
}}
|
||||||
}}
|
cancel={() => {
|
||||||
>
|
emit("cancelVisible");
|
||||||
<el-form ref={rileForm} v-model={formData.value} label-width="100px">
|
}}
|
||||||
<el-form-item label="图号" prop="figureNumber">
|
>
|
||||||
<el-input v-model={formData.value.figureNumber} onChange={splicing} />
|
<el-form
|
||||||
</el-form-item>
|
ref={rileForm}
|
||||||
<el-form-item label="物料号" prop="figurmaterialNumbereNumber">
|
v-model={formData.value}
|
||||||
<el-input v-model={formData.value.materialNumber} />
|
label-width="100px"
|
||||||
</el-form-item>
|
>
|
||||||
<el-form-item label="项目阶段" prop="stage">
|
<el-form-item label="图号" prop="drawingNo">
|
||||||
<el-select v-model={formData.value.stage} placeholder="请选择项目阶段" onChange={splicing}>
|
<el-input
|
||||||
<el-option label="初始" value="A"></el-option>
|
v-model={formData.value.drawingNo}
|
||||||
<el-option label="量产" value="B"></el-option>
|
onChange={splicing}
|
||||||
<el-option label="首批" value="C"></el-option>
|
/>
|
||||||
</el-select>
|
</el-form-item>
|
||||||
</el-form-item>
|
<el-form-item label="物料号" prop="materialNo">
|
||||||
{/* <el-form-item label="年份" prop="versionYear">
|
<el-input v-model={formData.value.materialNo} />
|
||||||
<el-date-picker
|
</el-form-item>
|
||||||
v-model={formData.value.versionYear}
|
<el-form-item label="项目阶段" prop="stage">
|
||||||
type="year"
|
<el-select
|
||||||
value-format="YYYY"
|
v-model={formData.value.stage}
|
||||||
onChange={splicing}
|
placeholder="请选择项目阶段"
|
||||||
placeholder="选择年份">
|
onChange={splicing}
|
||||||
</el-date-picker>
|
>
|
||||||
</el-form-item> */}
|
<el-option label="初始" value="A"></el-option>
|
||||||
<el-form-item label="创建日期" prop="createTime">
|
<el-option label="量产" value="B"></el-option>
|
||||||
<el-date-picker
|
<el-option label="首批" value="C"></el-option>
|
||||||
v-model={formData.value.createTime}
|
</el-select>
|
||||||
type="datetime"
|
</el-form-item>
|
||||||
disabledDate={(time) => {
|
<el-form-item label="选择模型" prop="stage">
|
||||||
return time.getTime() > Date.now();
|
<el-select
|
||||||
}}
|
v-model={formData.value.flowDefinitionId}
|
||||||
value-format="YYYY-MM-DD HH:MM:ss"
|
placeholder="请选择项目阶段"
|
||||||
onChange={splicing}
|
onChange={splicing}
|
||||||
placeholder="选择日期">
|
>
|
||||||
</el-date-picker>
|
{modelSelect.value.map(item => (
|
||||||
</el-form-item>
|
<ElOption
|
||||||
<el-form-item label="生成版本号" prop="versionNumber">
|
key={item.value}
|
||||||
<el-input type="textarea" disabled rows="2" v-model={formData.value.versionNumber} />
|
label={item.label}
|
||||||
</el-form-item>
|
value={item.value}
|
||||||
</el-form>
|
/>
|
||||||
</base-dialog-form>
|
))}
|
||||||
</div>
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
);
|
<el-form-item label="创建日期" prop="createTime">
|
||||||
|
<el-date-picker
|
||||||
|
v-model={formData.value.createTime}
|
||||||
|
type="datetime"
|
||||||
|
disabledDate={time => {
|
||||||
|
return time.getTime() > Date.now();
|
||||||
|
}}
|
||||||
|
value-format="YYYY-MM-DD HH:MM:ss"
|
||||||
|
onChange={splicing}
|
||||||
|
placeholder="选择日期"
|
||||||
|
></el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生成版本号" prop="costVersion">
|
||||||
|
<el-input
|
||||||
|
type="textarea"
|
||||||
|
disabled
|
||||||
|
rows="2"
|
||||||
|
v-model={formData.value.costVersion}
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</base-dialog-form>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
const splicing = () => {
|
||||||
|
formData.value.costVersion = "";
|
||||||
|
formData.value.costVersion =
|
||||||
|
formData.value.drawingNo +
|
||||||
|
"_" +
|
||||||
|
formData.value.stage +
|
||||||
|
"_" +
|
||||||
|
formData.value.createTime;
|
||||||
|
};
|
||||||
|
watch(props, (newVal, oldVal) => {
|
||||||
|
if (newVal.visible) {
|
||||||
|
formData.value = {
|
||||||
|
drawingNo: "",
|
||||||
|
stage: "",
|
||||||
|
createTime: "",
|
||||||
|
costVersion: "",
|
||||||
|
materialNo: "",
|
||||||
|
year: "",
|
||||||
|
flowDefinitionId: ""
|
||||||
};
|
};
|
||||||
const splicing = () => {
|
modelList({ pageNo: 1, pageSize: 999, projectId: 49 }).then(res => {
|
||||||
formData.value.versionNumber = "";
|
modelSelect.value = res.records.map(item => {
|
||||||
formData.value.versionNumber = formData.value.figureNumber + '_' + formData.value.stage + '_' + formData.value.createTime;
|
return {
|
||||||
};
|
value: item.id,
|
||||||
watch(props, (newVal, oldVal) => {
|
label: item.name
|
||||||
if (newVal.visible) {
|
};
|
||||||
formData.value = {
|
});
|
||||||
figureNumber: '',
|
console.log(modelSelect.value, "PPPPPPPPPPPPPPPPPPPPP");
|
||||||
stage: '',
|
|
||||||
createTime: '',
|
|
||||||
versionNumber: '',
|
|
||||||
materialNumber: '',
|
|
||||||
versionYear: ''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
return render;
|
}
|
||||||
},
|
});
|
||||||
|
return render;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped></style>
|
<style lang="scss" scoped></style>
|
||||||
|
|||||||
@@ -13,27 +13,12 @@ export default defineComponent({
|
|||||||
//列
|
//列
|
||||||
const columns = ref([
|
const columns = ref([
|
||||||
{ type: "selection" },
|
{ type: "selection" },
|
||||||
{ label: "版本号", prop: "versionNumber" },
|
{ label: "版本号", prop: "costVersion" },
|
||||||
{ label: "年份", prop: "versionYear", valueType: "year" },
|
{ label: "年份", prop: "year", valueType: "year" },
|
||||||
{ label: "物料编号", prop: "materialNumber" },
|
{ label: "物料编号", prop: "materialNo" },
|
||||||
{ prop: "bomCost", label: "bom材料费", hideInAddOrEditForm: true, hideInSearchForm: true },
|
|
||||||
{ label: "包装费", prop: "packingCost", hideInSearchForm: true },
|
|
||||||
{ label: "辅料费", prop: "auxiliaryCost", hideInSearchForm: true },
|
|
||||||
{ label: "人工费", prop: "laborCost", hideInSearchForm: true },
|
|
||||||
{ label: "机器折旧费", prop: "euipDepreciationCost", hideInSearchForm: true },
|
|
||||||
{ label: "机器料消耗费", prop: "equipConsumeCost", hideInSearchForm: true },
|
|
||||||
{ label: "水电费", prop: "hydroelectricityCost", hideInSearchForm: true },
|
|
||||||
{ label: "其他制造费", prop: "otherCost", hideInSearchForm: true },
|
|
||||||
{ label: "物流费用", prop: "trailCost", hideInSearchForm: true },
|
|
||||||
{ label: "制造成本", prop: "manufactureCost", hideInSearchForm: true },
|
|
||||||
{ label: "工装费", prop: "toolingCost", hideInSearchForm: true },
|
|
||||||
{ label: "检具费", prop: "inspectionCost", hideInSearchForm: true },
|
|
||||||
{ label: "模具费", prop: "moldCost", hideInSearchForm: true },
|
|
||||||
{ label: "测试费", prop: "testCost", hideInSearchForm: true },
|
|
||||||
{ label: "创建日期", prop: "createTime", hideInSearchForm: true, valueType: "datetime" },
|
{ label: "创建日期", prop: "createTime", hideInSearchForm: true, valueType: "datetime" },
|
||||||
{ label: "阶段", prop: "stage", valueType: 'dict-select', extraProps: { dictType: 'stageData' } },
|
{ label: "阶段", prop: "stage", valueType: 'dict-select', extraProps: { dictType: 'stageData' } },
|
||||||
{ label: "版本状态", prop: "versionStatus" },
|
{ label: "状态", prop: "status",valueType: 'dict-select',extraProps: { dictType: 'statusList' } },
|
||||||
{ label: "总成本", prop: "totalCost", hideInSearchForm: true },
|
|
||||||
{
|
{
|
||||||
type: "operation",
|
type: "operation",
|
||||||
label: "操作",
|
label: "操作",
|
||||||
|
|||||||
@@ -3,6 +3,7 @@
|
|||||||
import { defineComponent, ref } from "vue";
|
import { defineComponent, ref } from "vue";
|
||||||
import { costStandardDetailList,exportcostStandardDetail } from "@/api/singleLineQuery.js";
|
import { costStandardDetailList,exportcostStandardDetail } from "@/api/singleLineQuery.js";
|
||||||
import { transformPageResponse } from "@/utils/qomo";
|
import { transformPageResponse } from "@/utils/qomo";
|
||||||
|
import { download } from "@qomo-platform/utils";
|
||||||
import { ElMessage } from "element-plus";
|
import { ElMessage } from "element-plus";
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
setup() {
|
setup() {
|
||||||
@@ -14,20 +15,24 @@ export default defineComponent({
|
|||||||
{ label: "版本号", prop: "versionNumber" },
|
{ label: "版本号", prop: "versionNumber" },
|
||||||
{ label: "层级", prop: "level", hideInSearchForm: true },
|
{ label: "层级", prop: "level", hideInSearchForm: true },
|
||||||
{ label: "图号", prop: "figureNumber", hideInSearchForm: true },
|
{ label: "图号", prop: "figureNumber", hideInSearchForm: true },
|
||||||
{ label: "规格", prop: "specification", hideInSearchForm: true },
|
|
||||||
{ label: "用量", prop: "dosage", hideInSearchForm: true },
|
{ label: "用量", prop: "dosage", hideInSearchForm: true },
|
||||||
{ label: "bom材料费", prop: "bomCost", hideInSearchForm: true },
|
{ label: "单位", prop: "unit", hideInSearchForm: true },
|
||||||
{ label: "本阶人工费", prop: "laborCost", hideInSearchForm: true },
|
{ label: "本阶物料成本", prop: "materialCost", hideInSearchForm: true },
|
||||||
{ label: "机器折旧费", prop: "euipDepreciationCost", hideInSearchForm: true },
|
{ label: "本阶人工成本", prop: "laborCost", hideInSearchForm: true },
|
||||||
{ label: "水电费", prop: "hydroelectricityCost", hideInSearchForm: true },
|
{ label: "本阶设备费", prop: "equipmentCost", hideInSearchForm: true },
|
||||||
{ label: "本阶辅料费", prop: "auxiliaryCost", hideInSearchForm: true },
|
{ label: "本阶燃动费", prop: "driveCost", hideInSearchForm: true },
|
||||||
{ label: "其他制造费", prop: "otherCost", hideInSearchForm: true },
|
{ label: "本阶辅料费", prop: "supplyMaterialCost", hideInSearchForm: true },
|
||||||
// { label: "累计bom材料费", prop: "date123", hideInSearchForm: true },
|
{ label: "本阶其他费", prop: "otherCost", hideInSearchForm: true },
|
||||||
{ label: "累计人工费", prop: "totalLaborCost", hideInSearchForm: true },
|
{ label: "本阶物流费", prop: "logisticsCost", hideInSearchForm: true },
|
||||||
// { label: "累计设备费", prop: "date123", hideInSearchForm: true },
|
{ label: "本阶标准成本", prop: "currentStandardCost", hideInSearchForm: true },
|
||||||
{ label: "累计水电费", prop: "totalHydroelectricityCost", hideInSearchForm: true },
|
{ label: "累计物料成本", prop: "totalMaterialCost", hideInSearchForm: true },
|
||||||
// { label: "累计辅料费", prop: "date123", hideInSearchForm: true },
|
{ label: "累计人工成本", prop: "totalLaborCost", hideInSearchForm: true },
|
||||||
|
{ label: "累计设备费", prop: "totalEquipmentCost", hideInSearchForm: true },
|
||||||
|
{ label: "累计燃动费", prop: "totalDriveCost", hideInSearchForm: true },
|
||||||
|
{ label: "累计辅料费", prop: "totalSupplyMaterialCost", hideInSearchForm: true },
|
||||||
{ label: "累计其他费", prop: "totalOtherCost", hideInSearchForm: true },
|
{ label: "累计其他费", prop: "totalOtherCost", hideInSearchForm: true },
|
||||||
|
{ label: "累计物流成本", prop: "totalLogisticsCost", hideInSearchForm: true },
|
||||||
|
{ label: "累计标准成本", prop: "totalCurrentStandardCost", hideInSearchForm: true },
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const render = () => {
|
const render = () => {
|
||||||
@@ -62,7 +67,9 @@ export default defineComponent({
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
const handleExport = () => {
|
const handleExport = () => {
|
||||||
exportcostStandardDetail(tableRef.value.selectionRows ? {selections:tableRef.value.selectionRows.map(item => item.id).join(',')} : {} )
|
exportcostStandardDetail(tableRef.value.selectionRows ? {selections:tableRef.value.selectionRows.map(item => item.id).join(',')} : {} ).then(res=>{
|
||||||
|
download(res, '费用预测明细.xlsx');
|
||||||
|
})
|
||||||
};
|
};
|
||||||
return render;
|
return render;
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -35,7 +35,6 @@ export default defineComponent({
|
|||||||
await queryBomTree({
|
await queryBomTree({
|
||||||
...otherSearchParams
|
...otherSearchParams
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
console.log(res, "PPPPPPPPPPPPPPPPPPP")
|
|
||||||
treeData.value = addLabelRecursively(res);
|
treeData.value = addLabelRecursively(res);
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
@@ -48,56 +47,98 @@ export default defineComponent({
|
|||||||
<div class="treeMain-right">
|
<div class="treeMain-right">
|
||||||
<el-form v-model={formData.value} label-width="150px" disabled>
|
<el-form v-model={formData.value} label-width="150px" disabled>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col span="12">
|
<el-col span="12" v-show={formData.value.materialNumber}>
|
||||||
<el-form-item label="物料编号" prop="materialNumber">
|
<el-form-item label="物料编号" prop="materialNumber">
|
||||||
<el-input v-model={formData.value.materialNumber} />
|
<el-input v-model={formData.value.materialNumber} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col span="12">
|
<el-col span="12" v-show={formData.value.figureNumber}>
|
||||||
<el-form-item label="图号" prop="figureNumber">
|
<el-form-item label="图号" prop="figureNumber">
|
||||||
<el-input v-model={formData.value.figureNumber} />
|
<el-input v-model={formData.value.figureNumber} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col span="12">
|
<el-col span="12" v-show={formData.value.materialCost}>
|
||||||
<el-form-item label="本阶标准成本" prop="standardCost">
|
|
||||||
<el-input v-model={formData.value.standardCost} />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col span="12">
|
|
||||||
<el-form-item label="累计标准成本" prop="accumulatedStandardCost">
|
|
||||||
<el-input v-model={formData.value.accumulatedStandardCost} />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col span="12">
|
|
||||||
<el-form-item label="本阶物料成本" prop="materialCost">
|
<el-form-item label="本阶物料成本" prop="materialCost">
|
||||||
<el-input v-model={formData.value.materialCost} />
|
<el-input v-model={formData.value.materialCost} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col span="12">
|
<el-col span="12" v-show={formData.value.laborCost}>
|
||||||
<el-form-item label="累计物料成本" prop="accumulatedMaterialCost">
|
|
||||||
<el-input v-model={formData.value.accumulatedMaterialCost} />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col span="12">
|
|
||||||
<el-form-item label="本阶人工成本" prop="laborCost">
|
<el-form-item label="本阶人工成本" prop="laborCost">
|
||||||
<el-input v-model={formData.value.laborCost} />
|
<el-input v-model={formData.value.laborCost} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col span="12">
|
<el-col span="12" v-show={formData.value.equipmentCost}>
|
||||||
<el-form-item label="累计人工成本" prop="accumulatedLaborCost">
|
<el-form-item label="本阶设备费" prop="equipmentCost">
|
||||||
<el-input v-model={formData.value.accumulatedLaborCost} />
|
<el-input v-model={formData.value.equipmentCost} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
{/* <el-col span="12">
|
<el-col span="12" v-show={formData.value.driveCost}>
|
||||||
<el-form-item label="本阶制造费用" prop="figureNumber">
|
<el-form-item label="本阶燃动费" prop="driveCost">
|
||||||
<el-input v-model={formData.value.figureNumber} />
|
<el-input v-model={formData.value.driveCost} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col> */}
|
</el-col>
|
||||||
{/* <el-col span="12">
|
<el-col span="12" v-show={formData.value.supplyMaterialCost}>
|
||||||
<el-form-item label="累计制作费用" prop="figureNumber">
|
<el-form-item label="本阶辅料费" prop="supplyMaterialCost">
|
||||||
<el-input v-model={formData.value.figureNumber} />
|
<el-input v-model={formData.value.supplyMaterialCost} />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col> */}
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.otherCost}>
|
||||||
|
<el-form-item label="本阶其他费" prop="otherCost">
|
||||||
|
<el-input v-model={formData.value.otherCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.logisticsCost}>
|
||||||
|
<el-form-item label="本阶物流费" prop="logisticsCost">
|
||||||
|
<el-input v-model={formData.value.logisticsCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.currentStandardCost}>
|
||||||
|
<el-form-item label="本阶标准成本" prop="currentStandardCost">
|
||||||
|
<el-input v-model={formData.value.currentStandardCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalMaterialCost}>
|
||||||
|
<el-form-item label="累计物料成本" prop="totalMaterialCost">
|
||||||
|
<el-input v-model={formData.value.totalMaterialCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalLaborCost}>
|
||||||
|
<el-form-item label="累计人工成本" prop="totalLaborCost">
|
||||||
|
<el-input v-model={formData.value.totalLaborCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalEquipmentCost}>
|
||||||
|
<el-form-item label="累计设备费" prop="totalEquipmentCost">
|
||||||
|
<el-input v-model={formData.value.totalEquipmentCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalDriveCost}>
|
||||||
|
<el-form-item label="累计燃动费" prop="totalDriveCost">
|
||||||
|
<el-input v-model={formData.value.totalDriveCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalSupplyMaterialCost}>
|
||||||
|
<el-form-item label="累计辅料费" prop="totalSupplyMaterialCost">
|
||||||
|
<el-input v-model={formData.value.totalSupplyMaterialCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalOtherCost}>
|
||||||
|
<el-form-item label="累计其他费" prop="totalOtherCost">
|
||||||
|
<el-input v-model={formData.value.totalOtherCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalLogisticsCost}>
|
||||||
|
<el-form-item label="累计物流成本" prop="totalLogisticsCost">
|
||||||
|
<el-input v-model={formData.value.totalLogisticsCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col span="12" v-show={formData.value.totalCurrentStandardCost}>
|
||||||
|
<el-form-item label="累计标准成本" prop="totalCurrentStandardCost">
|
||||||
|
<el-input v-model={formData.value.totalCurrentStandardCost} />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
{/* TODO 分割 */}
|
||||||
|
<el-divider></el-divider>
|
||||||
<el-col span="12">
|
<el-col span="12">
|
||||||
<el-form-item label="人工工时" prop="figureNumber">
|
<el-form-item label="人工工时" prop="figureNumber">
|
||||||
<el-input v-model={formData.value.figureNumber} />
|
<el-input v-model={formData.value.figureNumber} />
|
||||||
|
|||||||
@@ -1,41 +1,105 @@
|
|||||||
<script lang="tsx">
|
<script lang="tsx">
|
||||||
//表格
|
//表格
|
||||||
import { defineComponent, ref } from "vue";
|
import { defineComponent, ref, onMounted } from "vue";
|
||||||
import { ElMessage } from "element-plus";
|
import { ElMessage } from "element-plus";
|
||||||
|
import { useRouter } from "vue-router";
|
||||||
import { transformPageResponse } from "@/utils/qomo";
|
import { transformPageResponse } from "@/utils/qomo";
|
||||||
import { modelList,deleteModel } from "@/api/modelManagement";
|
import {
|
||||||
import { useRouter } from 'vue-router';
|
modelList,
|
||||||
|
deleteModel,
|
||||||
|
addModel,
|
||||||
|
listAll,
|
||||||
|
environmentList,
|
||||||
|
tenantList,
|
||||||
|
editCostModel
|
||||||
|
} from "@/api/modelManagement";
|
||||||
import { ro } from "element-plus/es/locale";
|
import { ro } from "element-plus/es/locale";
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
setup() {
|
setup() {
|
||||||
const router = useRouter();
|
|
||||||
const tableRef = ref();
|
const tableRef = ref();
|
||||||
const forecastDialogRef = ref();
|
|
||||||
const selectionRows = ref([]);
|
const selectionRows = ref([]);
|
||||||
// const uploadUrl = ref("/c7525cost/importExcel");
|
const userList = ref([]);
|
||||||
|
const environmentOptions = ref([]);
|
||||||
|
const tenantOptions = ref([]);
|
||||||
|
const router = useRouter();
|
||||||
|
onMounted(() => {
|
||||||
|
listAll().then(res => {
|
||||||
|
res.records.forEach(item => {
|
||||||
|
userList.value.push({
|
||||||
|
label: item.username,
|
||||||
|
value: item.id
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
|
environmentList({ pageNo: 1, pageSize: 999 }).then(res => {
|
||||||
|
res.records.forEach(item => {
|
||||||
|
environmentOptions.value.push({
|
||||||
|
label: item.name,
|
||||||
|
value: item.id
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
|
tenantList({ pageNo: 1, pageSize: 999 }).then(res => {
|
||||||
|
res.records.forEach(item => {
|
||||||
|
tenantOptions.value.push({
|
||||||
|
label: item.tenantCode,
|
||||||
|
value: item.id
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
//列
|
//列
|
||||||
const columns = ref([
|
const columns = ref([
|
||||||
{ prop: "drawingNo", label: "图号" },
|
{ prop: "name", label: "模型名称",render: ({ row }) => <el-link onClick={() => router.push({ path: "/test/index", query: { id: row.id, code:row.code,type:1,space:'标准成本',spaceId:row.projectId } })}>{row?.name}</el-link>},
|
||||||
{ label: "物料号", prop: "materialNo" },
|
{ label: "模型编码", prop: "code" },
|
||||||
{ label: "物料类型", prop: "materialType" },
|
|
||||||
{ prop: "modelName", label: "模型名称", hideInSearchForm: true },
|
|
||||||
{ prop: "modelVersion", label: "模型版本", hideInSearchForm: true },
|
|
||||||
{
|
{
|
||||||
valueType: "date",
|
label: "模型管理员",
|
||||||
prop: "createTime",
|
prop: "userName",
|
||||||
label: "创建时间",
|
hideInSearchForm: true,
|
||||||
hideInSearchForm: true
|
hideInAddOrEditForm: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: "status",
|
label: "模型管理员",
|
||||||
label: "状态",
|
prop: "userId",
|
||||||
valueType: "dict-select",
|
valueType: "select",
|
||||||
extraProps: { dictType: "modelStatus" }
|
hideInSearchForm: true,
|
||||||
|
hideInTable: true,
|
||||||
|
extraProps: { options: userList.value }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
valueType: "date",
|
||||||
|
prop: "updateTime",
|
||||||
|
label: "最后修改",
|
||||||
|
hideInSearchForm: true,
|
||||||
|
hideInAddOrEditForm: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "environmentId",
|
||||||
|
label: "环境配置",
|
||||||
|
valueType: "select",
|
||||||
|
extraProps: { options: environmentOptions.value },
|
||||||
|
hideInSearchForm: true,
|
||||||
|
hideInTable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "tenantId",
|
||||||
|
label: "系统租户",
|
||||||
|
valueType: "select",
|
||||||
|
extraProps: { options: tenantOptions.value },
|
||||||
|
hideInSearchForm: true,
|
||||||
|
hideInTable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "description",
|
||||||
|
label: "备注",
|
||||||
|
valueType: "textarea",
|
||||||
|
extraProps: { dictType: "modelStatus" },
|
||||||
|
hideInSearchForm: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
type: "operation",
|
type: "operation",
|
||||||
label: "操作",
|
label: "操作",
|
||||||
minWidth: 120,
|
minWidth: 70,
|
||||||
render: ({ row, doAddOrEdit, doDeleteRows, doPreview }) => (
|
render: ({ row, doAddOrEdit, doDeleteRows, doPreview }) => (
|
||||||
<base-table-operation
|
<base-table-operation
|
||||||
btnList={[
|
btnList={[
|
||||||
@@ -44,22 +108,27 @@ export default defineComponent({
|
|||||||
label: "编辑",
|
label: "编辑",
|
||||||
onclick: () => doAddOrEdit(row)
|
onclick: () => doAddOrEdit(row)
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
key: "edit",
|
||||||
|
label: "配置模型",
|
||||||
|
onclick: () => editModel(row)
|
||||||
|
},
|
||||||
{
|
{
|
||||||
key: "delete",
|
key: "delete",
|
||||||
label: "删除",
|
label: "删除",
|
||||||
onclick: () => doDeleteRows(row)
|
onclick: () => doDeleteRows(row)
|
||||||
},
|
|
||||||
{
|
|
||||||
key: "release",
|
|
||||||
label: "发布",
|
|
||||||
onclick: () => releaseRows(row)
|
|
||||||
}
|
}
|
||||||
]}
|
]}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
]);
|
]);
|
||||||
|
const editModel = row => {
|
||||||
|
router.push({
|
||||||
|
path: "/test/index",
|
||||||
|
query: { id: 123 }
|
||||||
|
});
|
||||||
|
};
|
||||||
const render = () => {
|
const render = () => {
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
@@ -75,26 +144,14 @@ export default defineComponent({
|
|||||||
current = 1,
|
current = 1,
|
||||||
...otherSearchParams
|
...otherSearchParams
|
||||||
}) => {
|
}) => {
|
||||||
let tableData = {};
|
return transformPageResponse(
|
||||||
tableData = transformPageResponse(
|
|
||||||
await modelList({
|
await modelList({
|
||||||
pageNo: current,
|
pageNo: current,
|
||||||
pageSize,
|
pageSize,
|
||||||
|
projectId: 49,
|
||||||
...otherSearchParams
|
...otherSearchParams
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
tableData.data.forEach(item => {
|
|
||||||
if (item.status == "1") {
|
|
||||||
item.status = "草稿";
|
|
||||||
} else if (item.status == "2") {
|
|
||||||
item.status = "已发布";
|
|
||||||
} else if (item.status == "3") {
|
|
||||||
item.status = "运行中";
|
|
||||||
} else if (item.status == "4") {
|
|
||||||
item.status = "已完成";
|
|
||||||
}
|
|
||||||
});
|
|
||||||
return tableData;
|
|
||||||
}}
|
}}
|
||||||
curdConfig={{
|
curdConfig={{
|
||||||
/**
|
/**
|
||||||
@@ -103,21 +160,30 @@ export default defineComponent({
|
|||||||
*/
|
*/
|
||||||
async onAddOrEdit(data) {
|
async onAddOrEdit(data) {
|
||||||
if (data.id) {
|
if (data.id) {
|
||||||
await editHourRate(data);
|
const findName = userList.value.find(
|
||||||
|
item => item.value == data.userId
|
||||||
|
);
|
||||||
|
data.userName = findName.label;
|
||||||
|
await editCostModel(data);
|
||||||
} else {
|
} else {
|
||||||
await addHourRate(data);
|
const findName = userList.value.find(
|
||||||
|
item => item.value == data.userId
|
||||||
|
);
|
||||||
|
data.userName = findName.label;
|
||||||
|
data.projectId = 49;
|
||||||
|
await addModel(data);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
/*删除*/
|
/*删除*/
|
||||||
async onDeleteRows(data) {
|
async onDeleteRows(data) {
|
||||||
await deleteModel({ id: data.id });
|
await deleteModel({ id: data.id });
|
||||||
},
|
},
|
||||||
unitColSpan: 12
|
unitColSpan: 24
|
||||||
}}
|
}}
|
||||||
v-slots={{
|
v-slots={{
|
||||||
toolbar: () => (
|
toolbar: ({ doAddOrEdit }) => (
|
||||||
<el-space>
|
<el-space>
|
||||||
<el-button type="primary" onClick={addModel}>
|
<el-button type="primary" onClick={doAddOrEdit}>
|
||||||
新增模型
|
新增模型
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-space>
|
</el-space>
|
||||||
@@ -127,12 +193,6 @@ export default defineComponent({
|
|||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
const releaseRows = () => {
|
|
||||||
console.log("发布");
|
|
||||||
};
|
|
||||||
const addModel = () => {
|
|
||||||
router.push({ path: "/test/index" });
|
|
||||||
}
|
|
||||||
return render;
|
return render;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -0,0 +1,98 @@
|
|||||||
|
<script lang="tsx">
|
||||||
|
//表格
|
||||||
|
import { defineComponent, ref } from "vue";
|
||||||
|
import {
|
||||||
|
costStandardDetailList,
|
||||||
|
exportcostStandardDetail
|
||||||
|
} from "@/api/singleLineQuery.js";
|
||||||
|
import { transformPageResponse } from "@/utils/qomo";
|
||||||
|
import { download } from "@qomo-platform/utils";
|
||||||
|
import { ElMessage } from "element-plus";
|
||||||
|
export default defineComponent({
|
||||||
|
setup() {
|
||||||
|
const tableRef = ref();
|
||||||
|
//列
|
||||||
|
const columns = ref([
|
||||||
|
{ type: "selection" },
|
||||||
|
{ prop: "materialNumber", label: "产品编码" },
|
||||||
|
{ label: "产品名称", prop: "versionNumber" },
|
||||||
|
{ label: "市场经理", prop: "level", hideInSearchForm: true },
|
||||||
|
{ label: "项目经理", prop: "figureNumber", hideInSearchForm: true },
|
||||||
|
{ label: "成本阶段", prop: "dosage", hideInSearchForm: true },
|
||||||
|
{ label: "版本", prop: "unit", hideInSearchForm: true },
|
||||||
|
{ label: "BOM材料(含包装材料+辅料)", prop: "materialCost", hideInSearchForm: true },
|
||||||
|
{ label: "人工费用", prop: "laborCost", hideInSearchForm: true },
|
||||||
|
{ label: "机器折旧", prop: "equipmentCost", hideInSearchForm: true },
|
||||||
|
{ label: "机器料消耗", prop: "driveCost", hideInSearchForm: true },
|
||||||
|
{
|
||||||
|
label: "水电费",
|
||||||
|
prop: "supplyMaterialCost",
|
||||||
|
hideInSearchForm: true
|
||||||
|
},
|
||||||
|
{ label: "他制费(含物流)", prop: "otherCost", hideInSearchForm: true },
|
||||||
|
{ label: "制造成本", prop: "logisticsCost", hideInSearchForm: true },
|
||||||
|
{
|
||||||
|
label: "模具",
|
||||||
|
prop: "currentStandardCost",
|
||||||
|
hideInSearchForm: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "工装",
|
||||||
|
prop: "totalMaterialCost",
|
||||||
|
hideInSearchForm: true
|
||||||
|
},
|
||||||
|
{ label: "检具", prop: "totalLaborCost", hideInSearchForm: true },
|
||||||
|
{ label: "测试费用", prop: "totalDriveCost", hideInSearchForm: true },
|
||||||
|
]);
|
||||||
|
|
||||||
|
const render = () => {
|
||||||
|
return (
|
||||||
|
<BaseTable
|
||||||
|
columns={columns.value}
|
||||||
|
queryParamsToUrl
|
||||||
|
toolbar={{ layout: "search-dnamic,reload,column-setting,fullscreen" }}
|
||||||
|
ref={tableRef}
|
||||||
|
issortTable
|
||||||
|
request={async ({
|
||||||
|
pageSize = 10,
|
||||||
|
current = 1,
|
||||||
|
...otherSearchParams
|
||||||
|
}) => {
|
||||||
|
return transformPageResponse(
|
||||||
|
await costStandardDetailList({
|
||||||
|
pageNo: current,
|
||||||
|
pageSize,
|
||||||
|
...otherSearchParams
|
||||||
|
})
|
||||||
|
);
|
||||||
|
}}
|
||||||
|
v-slots={{
|
||||||
|
toolbar: ({ doAddOrEdit }) => (
|
||||||
|
<el-space>
|
||||||
|
<el-button type="success" onclick={handleExport}>
|
||||||
|
批量导出
|
||||||
|
</el-button>
|
||||||
|
</el-space>
|
||||||
|
)
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
const handleExport = () => {
|
||||||
|
exportcostStandardDetail(
|
||||||
|
tableRef.value.selectionRows
|
||||||
|
? {
|
||||||
|
selections: tableRef.value.selectionRows
|
||||||
|
.map(item => item.id)
|
||||||
|
.join(",")
|
||||||
|
}
|
||||||
|
: {}
|
||||||
|
).then(res => {
|
||||||
|
download(res, "费用预测明细.xlsx");
|
||||||
|
});
|
||||||
|
};
|
||||||
|
return render;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped></style>
|
||||||
@@ -0,0 +1,118 @@
|
|||||||
|
<script lang="tsx">
|
||||||
|
//表格
|
||||||
|
import { defineComponent, ref } from "vue";
|
||||||
|
import { ElMessage } from "element-plus";
|
||||||
|
import { useRouter } from 'vue-router';
|
||||||
|
export default defineComponent({
|
||||||
|
setup() {
|
||||||
|
const tableRef = ref();
|
||||||
|
const router = useRouter();
|
||||||
|
//列
|
||||||
|
const columns = ref([
|
||||||
|
{ prop: "districtName", label: "内部订单号",hideInSearchForm: true },
|
||||||
|
{ label: "物料编码", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "物料信息", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "成本中心代码" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "成本中心名称",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本1)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本1)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "人工工时(版本1)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "人工费率(版本1)",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本2)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本2)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "人工工时(版本2)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "人工费率(版本2)",hideInSearchForm: true },
|
||||||
|
{ label: "人工差价", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "人工量差", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "人工总差" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "基于成品结构用量(版本1)",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本1)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "燃动力工时(版本1)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "燃动力费率(版本1)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "基于成品结构用量(版本2)",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本2)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "燃动力工时(版本2)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "燃动力费率(版本2)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "燃动力价差",hideInSearchForm: true },
|
||||||
|
{ label: "燃动力量差", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "燃动力总差", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "基于成品结构用量(版本1)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "单个零件报工工时(版本1)",hideInSearchForm: true },
|
||||||
|
{ label: "辅料工时(版本1)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "辅料费率(版本1)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "基于成品结构用量(版本2)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "单个零件报工工时(版本2)",hideInSearchForm: true },
|
||||||
|
{ label: "辅料工时(版本2)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "辅料费率(版本2)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "辅料价差" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "辅料量差",hideInSearchForm: true },
|
||||||
|
{ label: "辅料总差", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本1)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "单个零件报工工时(版本1)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "其他工时(版本1)",hideInSearchForm: true },
|
||||||
|
{ label: "其他费率(版本1)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本2)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "单个零件报工工时(版本2)" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "其他工时(版本2)",hideInSearchForm: true },
|
||||||
|
{ label: "其他费率(版本2)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "其他价差", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "其他量差" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "其他总差",hideInSearchForm: true },
|
||||||
|
]);
|
||||||
|
|
||||||
|
const render = () => {
|
||||||
|
return (
|
||||||
|
<BaseTable
|
||||||
|
columns={columns.value}
|
||||||
|
queryParamsToUrl
|
||||||
|
ref={tableRef}
|
||||||
|
request={async ({ pageSize = 10, current = 1, ...otherSearchParams }) => {
|
||||||
|
await new Promise((resolve) => setTimeout(resolve, Math.random() * 1111));
|
||||||
|
return {
|
||||||
|
data: Array(pageSize)
|
||||||
|
.fill(0)
|
||||||
|
.map((item, index) => ({
|
||||||
|
id: Math.random(),
|
||||||
|
name: "Tom" + current,
|
||||||
|
date123: "date123" + current,
|
||||||
|
createTime: new Date().getTime(),
|
||||||
|
districtName: "区划" + index,
|
||||||
|
districtName1: "区划1" + index,
|
||||||
|
})),
|
||||||
|
current,
|
||||||
|
// pages: 500 / pageSize,
|
||||||
|
total: 500,
|
||||||
|
};
|
||||||
|
}}
|
||||||
|
curdConfig={{
|
||||||
|
}}
|
||||||
|
v-slots={{
|
||||||
|
toolbar: ({ doAddOrEdit }) => (
|
||||||
|
<el-space>
|
||||||
|
<el-button type="danger" onClick={toBack}>返回</el-button>
|
||||||
|
</el-space>
|
||||||
|
),
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
const toBack = ()=>{
|
||||||
|
router.go(-1);
|
||||||
|
}
|
||||||
|
return render;
|
||||||
|
},
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped></style>
|
||||||
@@ -0,0 +1,73 @@
|
|||||||
|
<script lang="tsx">
|
||||||
|
//表格
|
||||||
|
import { defineComponent, ref } from "vue";
|
||||||
|
import { ElMessage } from "element-plus";
|
||||||
|
import { useRouter } from 'vue-router';
|
||||||
|
export default defineComponent({
|
||||||
|
setup() {
|
||||||
|
const tableRef = ref();
|
||||||
|
const router = useRouter();
|
||||||
|
//列
|
||||||
|
const columns = ref([
|
||||||
|
{ prop: "districtName", label: "成本中心代码",hideInSearchForm: true },
|
||||||
|
{ label: "成本中心代码名称", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本1)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "单个零件报工工时(版本1)" ,hideInSearchForm: true },
|
||||||
|
{ prop: "districtName", label: "人工工时(版本1)",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本2)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本2)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "人工工时(版本2)" ,hideInSearchForm: true },
|
||||||
|
{ prop: "districtName", label: "人工工时总差",hideInSearchForm: true },
|
||||||
|
{ label: "基于成品结构用量(版本1)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本1)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "机器工时(版本1)" ,hideInSearchForm: true },
|
||||||
|
{ prop: "districtName", label: "基于成品结构用量(版本2)",hideInSearchForm: true },
|
||||||
|
{ label: "单个零件报工工时(版本2)", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "机器工时(版本2)", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "机器工时总差" ,hideInSearchForm: true },
|
||||||
|
]);
|
||||||
|
|
||||||
|
const render = () => {
|
||||||
|
return (
|
||||||
|
<BaseTable
|
||||||
|
columns={columns.value}
|
||||||
|
queryParamsToUrl
|
||||||
|
ref={tableRef}
|
||||||
|
request={async ({ pageSize = 10, current = 1, ...otherSearchParams }) => {
|
||||||
|
await new Promise((resolve) => setTimeout(resolve, Math.random() * 1111));
|
||||||
|
return {
|
||||||
|
data: Array(pageSize)
|
||||||
|
.fill(0)
|
||||||
|
.map((item, index) => ({
|
||||||
|
id: Math.random(),
|
||||||
|
name: "Tom" + current,
|
||||||
|
date123: "date123" + current,
|
||||||
|
createTime: new Date().getTime(),
|
||||||
|
districtName: "区划" + index,
|
||||||
|
districtName1: "区划1" + index,
|
||||||
|
})),
|
||||||
|
current,
|
||||||
|
// pages: 500 / pageSize,
|
||||||
|
total: 500,
|
||||||
|
};
|
||||||
|
}}
|
||||||
|
curdConfig={{
|
||||||
|
}}
|
||||||
|
v-slots={{
|
||||||
|
toolbar: ({ doAddOrEdit }) => (
|
||||||
|
<el-space>
|
||||||
|
<el-button type="danger" onClick={toBack}>返回</el-button>
|
||||||
|
</el-space>
|
||||||
|
),
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
const toBack = ()=>{
|
||||||
|
router.go(-1);
|
||||||
|
}
|
||||||
|
return render;
|
||||||
|
},
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped></style>
|
||||||
@@ -0,0 +1,75 @@
|
|||||||
|
<script lang="tsx">
|
||||||
|
//表格
|
||||||
|
import { defineComponent, ref } from "vue";
|
||||||
|
import { ElMessage } from "element-plus";
|
||||||
|
import { useRouter } from 'vue-router';
|
||||||
|
export default defineComponent({
|
||||||
|
setup() {
|
||||||
|
const tableRef = ref();
|
||||||
|
const router = useRouter();
|
||||||
|
//列
|
||||||
|
const columns = ref([
|
||||||
|
{ prop: "districtName", label: "单位",hideInSearchForm: true },
|
||||||
|
{ label: "采购类型", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "特殊采购类型", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "结构用量" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "单位材料价格",hideInSearchForm: true },
|
||||||
|
{ label: "单位总成本", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "版本1", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "结构用量" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "单位材料价格",hideInSearchForm: true },
|
||||||
|
{ label: "单位总成本", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "版本2", prop: "date123",hideInSearchForm: true },
|
||||||
|
{ prop: "createTime", label: "结构用量量差" ,hideInSearchForm: true },
|
||||||
|
|
||||||
|
{ prop: "districtName", label: "材料价格价差",hideInSearchForm: true },
|
||||||
|
{ label: "单位成本差异", prop: "name",hideInSearchForm: true },
|
||||||
|
{ label: "备注", prop: "date123",hideInSearchForm: true },
|
||||||
|
]);
|
||||||
|
|
||||||
|
const render = () => {
|
||||||
|
return (
|
||||||
|
<BaseTable
|
||||||
|
columns={columns.value}
|
||||||
|
queryParamsToUrl
|
||||||
|
ref={tableRef}
|
||||||
|
request={async ({ pageSize = 10, current = 1, ...otherSearchParams }) => {
|
||||||
|
await new Promise((resolve) => setTimeout(resolve, Math.random() * 1111));
|
||||||
|
return {
|
||||||
|
data: Array(pageSize)
|
||||||
|
.fill(0)
|
||||||
|
.map((item, index) => ({
|
||||||
|
id: Math.random(),
|
||||||
|
name: "Tom" + current,
|
||||||
|
date123: "date123" + current,
|
||||||
|
createTime: new Date().getTime(),
|
||||||
|
districtName: "区划" + index,
|
||||||
|
districtName1: "区划1" + index,
|
||||||
|
})),
|
||||||
|
current,
|
||||||
|
// pages: 500 / pageSize,
|
||||||
|
total: 500,
|
||||||
|
};
|
||||||
|
}}
|
||||||
|
curdConfig={{
|
||||||
|
}}
|
||||||
|
v-slots={{
|
||||||
|
toolbar: ({ doAddOrEdit }) => (
|
||||||
|
<el-space>
|
||||||
|
<el-button type="danger" onClick={toBack}>返回</el-button>
|
||||||
|
</el-space>
|
||||||
|
),
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
const toBack = ()=>{
|
||||||
|
router.go(-1);
|
||||||
|
}
|
||||||
|
return render;
|
||||||
|
},
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped></style>
|
||||||
@@ -0,0 +1,216 @@
|
|||||||
|
<script lang="tsx">
|
||||||
|
//表格
|
||||||
|
import { defineComponent, ref } from "vue";
|
||||||
|
import { ElMessage } from "element-plus";
|
||||||
|
import { transformPageResponse } from "@/utils/qomo";
|
||||||
|
import { useRouter } from "vue-router";
|
||||||
|
export default defineComponent({
|
||||||
|
setup() {
|
||||||
|
const router = useRouter();
|
||||||
|
const tableRef = ref();
|
||||||
|
const forecastDialogRef = ref();
|
||||||
|
const selectionRows = ref([]);
|
||||||
|
const btnTitle = ref("工时差异");
|
||||||
|
// const uploadUrl = ref("/c7525cost/importExcel");
|
||||||
|
//列
|
||||||
|
const columnsCheck = ref([
|
||||||
|
{ prop: "type", label: "对比项", hideInSearchForm: true },
|
||||||
|
{
|
||||||
|
label: "金额(单位:元)",
|
||||||
|
prop: "costCenterCode",
|
||||||
|
hideInSearchForm: true
|
||||||
|
},
|
||||||
|
{ label: "版本1", prop: "factory", hideInSearchForm: true },
|
||||||
|
{ label: "版本2", prop: "factory", hideInSearchForm: true },
|
||||||
|
{ label: "差异金额", prop: "factory", hideInSearchForm: true },
|
||||||
|
{
|
||||||
|
type: "operation",
|
||||||
|
label: "差异分析",
|
||||||
|
minWidth: 120,
|
||||||
|
render: ({ row }) => (
|
||||||
|
<base-table-operation
|
||||||
|
btnList={[
|
||||||
|
{
|
||||||
|
key: "check",
|
||||||
|
label:
|
||||||
|
row.type === 0
|
||||||
|
? "工时差异"
|
||||||
|
: row.type === 1
|
||||||
|
? "人工制费差异"
|
||||||
|
: "材料成本差异",
|
||||||
|
onclick: () => timeVariance(row)
|
||||||
|
}
|
||||||
|
]}
|
||||||
|
/>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
]);
|
||||||
|
const columns = ref([
|
||||||
|
{ type: "selection" },
|
||||||
|
{ prop: "year", label: "内部订单号" },
|
||||||
|
{ label: "物料号", prop: "costCenterCode" },
|
||||||
|
{ label: "成本阶段", prop: "factory" },
|
||||||
|
{ prop: "laborHourRate", label: "版本号", hideInSearchForm: true },
|
||||||
|
{ prop: "equipHourRate", label: "状态",hideInAddOrEditForm: true},
|
||||||
|
{
|
||||||
|
prop: "fuelHourRate",
|
||||||
|
label: "总标准成本(版本1)",
|
||||||
|
hideInSearchForm: true,
|
||||||
|
hideInAddOrEditForm: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "auxiliaryHourRate",
|
||||||
|
label: "总标准成本(版本2)",
|
||||||
|
hideInSearchForm: true,
|
||||||
|
hideInAddOrEditForm: true
|
||||||
|
},
|
||||||
|
{ prop: "otherHourRate", label: "总差额", hideInSearchForm: true,hideInAddOrEditForm: true },
|
||||||
|
{ prop: "effectiveDate", label: "差额比", hideInSearchForm: true,hideInAddOrEditForm: true },
|
||||||
|
{
|
||||||
|
valueType: "date",
|
||||||
|
prop: "expirationDate",
|
||||||
|
label: "创建时间",
|
||||||
|
hideInSearchForm: true,
|
||||||
|
hideInAddOrEditForm: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: "operation",
|
||||||
|
label: "操作",
|
||||||
|
minWidth: 120,
|
||||||
|
render: ({ row, doAddOrEdit, doDeleteRows, doPreview }) => (
|
||||||
|
<base-table-operation
|
||||||
|
btnList={[
|
||||||
|
{
|
||||||
|
key: "check",
|
||||||
|
label: "查看报告",
|
||||||
|
onclick: () => checkReport(row)
|
||||||
|
}
|
||||||
|
]}
|
||||||
|
/>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
]);
|
||||||
|
|
||||||
|
const render = () => {
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<BaseTable
|
||||||
|
columns={columns.value}
|
||||||
|
ref={tableRef}
|
||||||
|
selectionRows={selectionRows.value}
|
||||||
|
toolbar={{
|
||||||
|
layout: "search-dnamic,reload,column-setting,fullscreen"
|
||||||
|
}}
|
||||||
|
request={async ({
|
||||||
|
pageSize = 10,
|
||||||
|
current = 1,
|
||||||
|
...otherSearchParams
|
||||||
|
}) => {
|
||||||
|
await new Promise(resolve =>
|
||||||
|
setTimeout(resolve, Math.random() * 1111)
|
||||||
|
);
|
||||||
|
return {
|
||||||
|
data: Array(pageSize)
|
||||||
|
.fill(0)
|
||||||
|
.map((item, index) => ({
|
||||||
|
id: Math.random(),
|
||||||
|
name: "Tom" + current,
|
||||||
|
date123: "date123" + current,
|
||||||
|
createTime: new Date().getTime(),
|
||||||
|
districtName: "区划" + index,
|
||||||
|
districtName1: "区划1" + index
|
||||||
|
})),
|
||||||
|
current,
|
||||||
|
// pages: 500 / pageSize,
|
||||||
|
total: 500
|
||||||
|
};
|
||||||
|
}}
|
||||||
|
curdConfig={{
|
||||||
|
/**
|
||||||
|
* 接受自动表单的数据
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
async onAddOrEdit(data) {},
|
||||||
|
|
||||||
|
unitColSpan: 24
|
||||||
|
}}
|
||||||
|
v-slots={{
|
||||||
|
toolbar: ({ doAddOrEdit, doDeleteRows }) => (
|
||||||
|
<el-space>
|
||||||
|
<el-button type="primary" onClick={doAddOrEdit}>
|
||||||
|
添加对比项
|
||||||
|
</el-button>
|
||||||
|
</el-space>
|
||||||
|
)
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
<BaseDialog
|
||||||
|
title="报告详情"
|
||||||
|
width="80%"
|
||||||
|
ref={forecastDialogRef}
|
||||||
|
confirmButtonProps={false}
|
||||||
|
>
|
||||||
|
<BaseTable
|
||||||
|
columns={columnsCheck.value}
|
||||||
|
ref={tableRef}
|
||||||
|
selectionRows={selectionRows.value}
|
||||||
|
request={async ({ pageSize = 10, current = 1 }) => {
|
||||||
|
await new Promise(resolve =>
|
||||||
|
setTimeout(resolve, Math.random() * 1111)
|
||||||
|
);
|
||||||
|
return {
|
||||||
|
data: Array(pageSize)
|
||||||
|
.fill(0)
|
||||||
|
.map((item, index) => ({
|
||||||
|
id: Math.random(),
|
||||||
|
name: "Tom" + current,
|
||||||
|
date123: "date123" + current,
|
||||||
|
createTime: new Date().getTime(),
|
||||||
|
districtName: "区划" + index,
|
||||||
|
districtName1: "区划1" + index,
|
||||||
|
type: index % 3
|
||||||
|
})),
|
||||||
|
current,
|
||||||
|
total: 500
|
||||||
|
};
|
||||||
|
}}
|
||||||
|
curdConfig={{
|
||||||
|
/**
|
||||||
|
* 接受自动表单的数据
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
async onAddOrEdit(data) {},
|
||||||
|
|
||||||
|
unitColSpan: 24
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
</BaseDialog>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
const checkReport = () => {
|
||||||
|
forecastDialogRef.value.open();
|
||||||
|
};
|
||||||
|
const timeVariance = row => {
|
||||||
|
if (row.type == 0) {
|
||||||
|
// 工时
|
||||||
|
router.push({
|
||||||
|
path: "/standardComparison/manHour",
|
||||||
|
});
|
||||||
|
} else if (row.type == 1) {
|
||||||
|
// 人工
|
||||||
|
router.push({
|
||||||
|
path: "/standardComparison/artificial",
|
||||||
|
});
|
||||||
|
} else if (row.type == 2) {
|
||||||
|
// 材料
|
||||||
|
router.push({
|
||||||
|
path: "/standardComparison/materials",
|
||||||
|
});
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return render;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped></style>
|
||||||
@@ -18,9 +18,11 @@ import { transformPageResponse } from "@/utils/qomo";
|
|||||||
import _ from "lodash";
|
import _ from "lodash";
|
||||||
import { download } from "@qomo-platform/utils";
|
import { download } from "@qomo-platform/utils";
|
||||||
import request from "@/service/request";
|
import request from "@/service/request";
|
||||||
|
import { useRoute } from 'vue-router';
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
name: "flowableOptions",
|
name: "flowableOptions",
|
||||||
setup(props, { attrs, expose, slots = {} }) {
|
setup(props, { attrs, expose, slots = {} }) {
|
||||||
|
const route = useRoute();
|
||||||
const { dialogRef, ...exposeDialogArgs } = useExposeDialogArgs();
|
const { dialogRef, ...exposeDialogArgs } = useExposeDialogArgs();
|
||||||
|
|
||||||
return () => (
|
return () => (
|
||||||
@@ -33,7 +35,7 @@ export default defineComponent({
|
|||||||
return data;
|
return data;
|
||||||
}}
|
}}
|
||||||
saveRequest={async data => {
|
saveRequest={async data => {
|
||||||
data.id = '19';
|
data.id = route.query.id;
|
||||||
data.topMaterialCode = 'mn001';
|
data.topMaterialCode = 'mn001';
|
||||||
await saveFlowModel(data);
|
await saveFlowModel(data);
|
||||||
//await saveMode(data);
|
//await saveMode(data);
|
||||||
|
|||||||
+2
-1
@@ -55,7 +55,8 @@ export default defineConfig(({ mode, command }) => {
|
|||||||
// https://cn.vitejs.dev/config/#server-proxy
|
// https://cn.vitejs.dev/config/#server-proxy
|
||||||
"/qomo": {
|
"/qomo": {
|
||||||
// target: "http://172.16.0.241:8095", //wq
|
// target: "http://172.16.0.241:8095", //wq
|
||||||
target: "http://172.16.0.162:8082", //bgy
|
// target: "http://172.16.0.162:8082", //bgy
|
||||||
|
target: "http://172.16.2.127:8082", //bgy远程
|
||||||
// target: "http://192.168.50.9:2999",//中智平台
|
// target: "http://192.168.50.9:2999",//中智平台
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
|
|||||||
Reference in New Issue
Block a user