|
@@ -43,6 +43,14 @@
|
|
|
<el-button
|
|
|
link
|
|
|
type="primary"
|
|
|
+ icon="el-icon-edit"
|
|
|
+ :disabled="false"
|
|
|
+ @click="doEdit(row, index)"
|
|
|
+ >编辑</el-button
|
|
|
+ >
|
|
|
+ <el-button
|
|
|
+ link
|
|
|
+ type="primary"
|
|
|
icon="el-icon-copy-document"
|
|
|
:disabled="false"
|
|
|
@click="copyRow(row)"
|
|
@@ -133,7 +141,10 @@ onMounted(() => {
|
|
|
// console.log("crudRef", crudRef)
|
|
|
dataList();
|
|
|
});
|
|
|
-
|
|
|
+const doEdit = (row, index) => {
|
|
|
+ row.prodtName1 = row.prodtName;
|
|
|
+ crudRef.value && crudRef.value.rowEdit(row, index);
|
|
|
+};
|
|
|
/**
|
|
|
* 上传excel相关
|
|
|
*/
|
|
@@ -155,6 +166,7 @@ const ctableRef = ref(null);
|
|
|
const onSelectedFinish = (selectedValue) => {
|
|
|
// search.value.prodtName = selectedValue.materialName;
|
|
|
form.value.prodtName = selectedValue.materialName;
|
|
|
+ form.value.prodtName1 = selectedValue.materialName;
|
|
|
form.value.prodtCode = selectedValue.materialCode;
|
|
|
form.value.prodtModel = selectedValue.spec;
|
|
|
};
|
|
@@ -201,6 +213,7 @@ const bindProcess = (row) => {
|
|
|
option.value = Object.assign(option.value, {
|
|
|
selection: true,
|
|
|
labelWidth: 110,
|
|
|
+ editBtn: false,
|
|
|
searchLabelWidth: 110,
|
|
|
column: [
|
|
|
{
|
|
@@ -259,6 +272,23 @@ option.value = Object.assign(option.value, {
|
|
|
overHidden: true,
|
|
|
width: 150,
|
|
|
search: true,
|
|
|
+ editDisplay: false,
|
|
|
+ addDisplay: false,
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ message: "请选择产品",
|
|
|
+ trigger: "blur",
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ readOnly: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "产品名称",
|
|
|
+ prop: "prodtName1",
|
|
|
+ overHidden: true,
|
|
|
+ width: 150,
|
|
|
+ viewDisplay: false,
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|