From ac3cfc47a08ce8e9e99ecc43fdbada396a714def Mon Sep 17 00:00:00 2001
From: jiazx0107 <jiazx0107@163.com>
Date: 星期一, 05 一月 2026 21:26:17 +0800
Subject: [PATCH] 调整出入库配置2

---
 fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml |  108 +++++++++++++++++++++++++++++++++++++++++++++--------
 1 files changed, 91 insertions(+), 17 deletions(-)

diff --git a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml
index 705e7c2..568a51f 100644
--- a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml
+++ b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml
@@ -4,6 +4,25 @@
   <Context/>
   <Model>
     <DataType name="dtMain">
+      <ClientEvent name="onDataChange">if(arg.property == 'type'){&#xD;
+		//搴撳尯鑷缓閫氱煡鍗�&#xD;
+	if(arg.newValue == '10'){&#xD;
+		view.get(&quot;#formItemBank&quot;).set(&quot;visible&quot;,false);&#xD;
+	    var curData = view.get(&quot;#dsMain.data:#&quot;); //褰撳墠閫夋嫨鐨勬暟鎹�&#xD;
+	    curData.set(&quot;bankId&quot;,'-');&#xD;
+&#xD;
+	}&#xD;
+		//璐ㄦ娂鐩戠閫氱煡鍗�&#xD;
+	if(arg.newValue == '20'){&#xD;
+		view.get(&quot;#formItemBank&quot;).set(&quot;visible&quot;,true);&#xD;
+		var curData = view.get(&quot;#dsMain.data:#&quot;); //褰撳墠閫夋嫨鐨勬暟鎹�&#xD;
+	    curData.set(&quot;bankId&quot;,null);&#xD;
+	}&#xD;
+}&#xD;
+&#xD;
+&#xD;
+&#xD;
+</ClientEvent>
       <Property name="creationType">com.fzzy.igds.domain.InoutNoticeIn</Property>
       <PropertyDef name="id">
         <Property></Property>
@@ -18,7 +37,7 @@
         <Property name="label">鎵�灞炲垎搴�</Property>
         <Property name="mapping">
           <Property name="keyProperty">id</Property>
-          <Property name="mapValues">${dorado.getDataProvider(&quot;deptPR#getAllData&quot;).getResult()}</Property>
+          <Property name="mapValues">${dorado.getDataProvider(&quot;deptPR#getDeptByUserType&quot;).getResult()}</Property>
           <Property name="valueProperty">kqmc</Property>
         </Property>
       </PropertyDef>
@@ -34,11 +53,11 @@
           <Property name="mapValues">
             <Collection>
               <Entity>
-                <Property name="name">搴撳尯閫氱煡鍗�</Property>
+                <Property name="name">搴撳尯鑷缓閫氱煡鍗�</Property>
                 <Property name="code">10</Property>
               </Entity>
               <Entity>
-                <Property name="name">鐩戠閫氱煡鍗�</Property>
+                <Property name="name">璐ㄦ娂鐩戠閫氱煡鍗�</Property>
                 <Property name="code">20</Property>
               </Entity>
             </Collection>
@@ -57,10 +76,11 @@
         <Property></Property>
         <Property name="label">鍏ュ簱浠撳簱</Property>
         <Property name="mapping">
-          <Property name="mapValues">${dorado.getDataProvider(&quot;depotPR#getAllCache&quot;).getResult()}</Property>
+          <Property name="mapValues">${dorado.getDataProvider(&quot;depotPR#getData&quot;).getResult()}</Property>
           <Property name="keyProperty">id</Property>
           <Property name="valueProperty">name</Property>
         </Property>
+        <Property name="required">true</Property>
       </PropertyDef>
       <PropertyDef name="customerName">
         <Property></Property>
@@ -71,11 +91,6 @@
         <Property></Property>
         <Property name="label">鏀惰揣鍗曚綅</Property>
         <Property name="required">false</Property>
-        <Property name="mapping">
-          <Property name="mapValues">${dorado.getDataProvider(&quot;deptPR#getAllData&quot;).getResult()}</Property>
-          <Property name="keyProperty">id</Property>
-          <Property name="valueProperty">kqmc</Property>
-        </Property>
       </PropertyDef>
       <PropertyDef name="foodVariety">
         <Property></Property>
@@ -89,7 +104,7 @@
       </PropertyDef>
       <PropertyDef name="year">
         <Property></Property>
-        <Property name="label">骞翠唤</Property>
+        <Property name="label">绮骞翠唤</Property>
       </PropertyDef>
       <PropertyDef name="targetNumber">
         <Property name="dataType">Double</Property>
@@ -107,8 +122,8 @@
         <Property name="label">瀹℃牳鐘舵��</Property>
         <Property name="mapping">
           <Property name="mapValues">${dorado.getDataProvider(&quot;dicPR#triggerStatusType&quot;).getResult()}</Property>
-          <Property name="keyProperty">dictLabel</Property>
-          <Property name="valueProperty">dictValue</Property>
+          <Property name="keyProperty">dictValue</Property>
+          <Property name="valueProperty">dictLabel</Property>
         </Property>
       </PropertyDef>
       <PropertyDef name="auditUser">
@@ -162,6 +177,16 @@
       <PropertyDef name="updateBy">
         <Property></Property>
         <Property name="label">鏇存柊浜�</Property>
+      </PropertyDef>
+      <PropertyDef name="bankId">
+        <Property></Property>
+        <Property name="label">鐩戠潱閾惰</Property>
+        <Property name="mapping">
+          <Property name="mapValues">${dorado.getDataProvider(&quot;bankPR#listAll&quot;).getResult()}</Property>
+          <Property name="keyProperty">id</Property>
+          <Property name="valueProperty">name</Property>
+        </Property>
+        <Property name="visible">true</Property>
       </PropertyDef>
     </DataType>
   </Model>
@@ -308,9 +333,10 @@
           <Property name="width">120</Property>
           <Property name="iconClass">fa fa-print</Property>
         </ToolBarButton>
+        <Fill/>
       </ToolBar>
       <DataGrid id="dataGridMain" layoutConstraint="padding:8">
-        <ClientEvent name="onDataRowClick">view.get(&quot;#dataGridMain&quot;).set(&quot;selection&quot;,arg.data);</ClientEvent>
+        <ClientEvent name="onDataRowClick">self.set(&quot;selection&quot;,arg.data);</ClientEvent>
         <Property name="dataSet">dsMain</Property>
         <Property name="readOnly">true</Property>
         <Property name="selectionMode">singleRow</Property>
@@ -390,14 +416,23 @@
       <Property name="iconClass">fa fa-tasks</Property>
       <Buttons>
         <Button id="btnOk">
-          <ClientEvent name="onClick">view.get(&quot;#updateSave&quot;).execute(function(result){&#xD;
+          <ClientEvent name="onClick">var entity = view.get(&quot;#dsMain.data:#&quot;);&#xD;
+var bankId = entity.get(&quot;bankId&quot;);&#xD;
+if(!bankId){&#xD;
+		        $alert(&quot;璇峰厛閫夋嫨鐩戠閾惰&quot;);&#xD;
+}else{&#xD;
+	view.get(&quot;#updateSave&quot;).execute(function(result){&#xD;
 	if(result){&#xD;
 		$alert(result);&#xD;
 		return;&#xD;
 	}&#xD;
 	$notify(&quot;鏁版嵁鎵ц瀹屾垚锛侊紒&quot;);&#xD;
 	self.get(&quot;parent&quot;).hide();&#xD;
-});</ClientEvent>
+});&#xD;
+}&#xD;
+&#xD;
+&#xD;
+</ClientEvent>
           <Property name="caption">淇濆瓨</Property>
           <Property name="iconClass">fa fa-check-circle</Property>
           <Property name="exClassName">btn1</Property>
@@ -452,12 +487,19 @@
             <AutoFormElement>
               <Property name="name">type</Property>
               <Property name="property">type</Property>
-              <Property name="editorType">RadioGroup</Property>
+              <Property name="trigger">autoMappingDropDown1</Property>
+              <Editor/>
+            </AutoFormElement>
+            <AutoFormElement id="formItemBank">
+              <Property name="name">bankId</Property>
+              <Property name="property">bankId</Property>
+              <Property name="hideMode">display</Property>
               <Editor/>
             </AutoFormElement>
             <AutoFormElement>
               <Property name="name">depotId</Property>
               <Property name="property">depotId</Property>
+              <Property name="trigger">dsDepotDropDown</Property>
               <Editor/>
             </AutoFormElement>
             <AutoFormElement>
@@ -471,7 +513,7 @@
               <Property name="trigger">defaultYearDropDown</Property>
               <Editor/>
             </AutoFormElement>
-            <AutoFormElement layoutConstraint="colSpan:2">
+            <AutoFormElement id="formItemCustomerName" layoutConstraint="colSpan:2">
               <Property name="name">customerName</Property>
               <Property name="property">customerName</Property>
               <Editor/>
@@ -560,6 +602,38 @@
       </Children>
       <Tools/>
     </Dialog>
+    <DataSetDropDown id="dsDepotDropDown">
+      <ClientEvent name="onOpen">	&#xD;
+	var entity = view.get(&quot;#dsMain.data:#&quot;);&#xD;
+	if(!entity){&#xD;
+	    $alert(&quot;璇峰厛閫夋嫨鐩戠閾惰&quot;);&#xD;
+	}else{&#xD;
+		var typeData = entity.get(&quot;type&quot;);&#xD;
+		if(typeData=='20'){&#xD;
+			var bankId = entity.get(&quot;bankId&quot;);&#xD;
+			console.log(bankId);&#xD;
+		    if(!bankId){&#xD;
+		        $alert(&quot;璇峰厛閫夋嫨鐩戠閾惰&quot;);&#xD;
+		    }else{&#xD;
+				view.get(&quot;#dsDepotList&quot;).set(&quot;parameter&quot;,entity.get(&quot;bankId&quot;)).flushAsync();&#xD;
+		    }&#xD;
+		}else{&#xD;
+			view.get(&quot;#dsDepotList&quot;).set(&quot;parameter&quot;,null).flushAsync();&#xD;
+		}&#xD;
+	}&#xD;
+</ClientEvent>
+      <Property name="dataSet">dsDepotList</Property>
+      <Property name="height">450</Property>
+      <Property name="autoOpen">true</Property>
+      <Property name="assignmentMap">depotId=id</Property>
+      <Property name="width">400</Property>
+      <DataColumn>
+        <Property name="align">center</Property>
+        <Property name="name">name</Property>
+        <Property name="property">name</Property>
+        <Editor/>
+      </DataColumn>
+    </DataSetDropDown>
     <UpdateAction id="updateSave">
       <Property name="dataResolver">inoutNoticePR#saveIn</Property>
       <UpdateItem>

--
Gitblit v1.9.3